Need help with Bootless Star 7.5

Post a reply

Smilies
:D :) :( :o :shock: :? 8) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :!: :?: :idea: :arrow: :| :mrgreen: :angel: :angry: :beer: :bfg: :chaingun: :cheers: :blergh:
View more smilies

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

If you wish to attach one or more files enter the details below.

Maximum filesize per attachment: 1.5 MiB.

Expand view Topic review: Need help with Bootless Star 7.5

Re: Need help with Bootless Star 7.5

by Gez » Sat Apr 06, 2013 15:04

They may have meant "compiled for Intel" rather than "compiled on Intel". In any case, you'd have to be using instructions or registers that are specific to one make in particular, rather than the common x86 standard.

Cross-compilation is possible anyway, so people have compiled on x86 programs intended to run on m68K or PowerPC, and vice-versa. Heck I use Windows 64, but when I compile GZDoom, ZDoom, SLADE or Eternity, it's technically cross-compilation since they're compiled as x86-32 programs rather than x86-64.

Re: Need help with Bootless Star 7.5

by Tiger » Sat Apr 06, 2013 1:44

Gez wrote:
Tiger wrote:So regardless of the CPU's manufacturer (Intel, AMD, Cryrix, etc) - the binary should be created the same way regardless of their own unique instruction sets?
2+2=4 regardless of CPU. If you write a program that computes 2+2 and writes the output in a file, that file will contain 4 in all cases. Likewise, the compiler should produce the same output regardless of CPU, because what it writes is determined in software. It's not the CPU that chooses what happens; the CPU merely make it happen.

Now you can have CPU-specific code (such as SSE instructions) but then again they'll be added by the compiler.

Finally, keep in mind that Intel, AMD and VIA all use the same core architecture, which is compatible with the x86 family. When you compile something for Win32, it could technically run on a 486 (probably even a 386) because that's the core architecture. The additional instructions ought to be optional paths that the program can use or not (as ZDoom does for SSE2) but even if that's not the case the compiler will be able to compile them nonetheless. You can compile SSE instructions without having an SSE-compatible CPU; it's just that you won't be able to run them to test that it compiled successfully.

If you compiled for your CPU precisely, then what would happen? Programs wouldn't be portable. Instead of building one Builder.exe, you'd have to build Builder-Intel.exe and Builder-AMD.exe, and you'd have to use two different computers for that. This would obviously be stupid.

See x86 for more in-depth informations.
Thank you for the response - and I learned something new! What lead me to think that the instruction set could be the cause of the differential size - was merely my experience with the Assembly (lower-level programming). Additionally, I have very little experience and proper knowledge within the higher-level languages. Thus, I was unsure how the code could be read properly across different CPU's (primarily CISC), and I heard from one of my professors that some programs that were compiled on Intel processors - would not execute at all on AMD processors (not much of a problem anymore - but merely history).

Re: Need help with Bootless Star 7.5

by Gez » Fri Apr 05, 2013 22:30

NeoHippo wrote:If code should be the same regardless of the compiler used, then either Builder.exe should be the same.
Yet, they are not.
Not regardless of the compiler. Regardless of the CPU.

Different compilers might transform the code differently. Heck, even the same compiler might do things differently depending on optimization settings. And all projects come with different "profiles" (usually at least debug vs. release).

But if you have:
- the same compiler
- the same project configuration and profile
- the same version of the libraries
- the same version of the source code
- different CPUs

the result should be exactly the same. On the other hand, you can bet you will have different results if you have:
- different compilers
- different project configurations and profiles
- different versions of the libraries
- different versions of the source code
- the exact same CPU


To go back on our simplistic example of the 2+2 program, it'll output a file containing 4 in all cases because it'll be what the CPU computed 2+2 to be, but it could be 4 padded with zeros (0004), 4 followed by a newline, 4 written as a floating point value (4.0), "four" written in English, IV in roman numerals, 0100b in binary, and so on. This depends on how the "compiler" was designed. It doesn't matter for the value of the outcome, but there's still room for differences.

Re: Need help with Bootless Star 7.5

by NeoHippo » Fri Apr 05, 2013 16:41

Curiosity made me do it .......

I should preclude that both versions are working as they should. I compared r1664.

If code should be the same regardless of the compiler used, then either Builder.exe should be the same.
Yet, they are not.


Some images, on the top my compilation with Bootless Star, on the bottom the official compilation:

right from the start, there are some differences

Image

up to there, bytes are mostly the same but then everything changed

Image

plus some additional stuff in the official compilation

Image

I did not go as far as to try and disassemble the code. I just wanted to see where the differences came in.
Maybe it is due to the order in which the various elements were added in.

Re: Need help with Bootless Star 7.5

by Gez » Fri Apr 05, 2013 9:53

Tiger wrote:So regardless of the CPU's manufacturer (Intel, AMD, Cryrix, etc) - the binary should be created the same way regardless of their own unique instruction sets?
2+2=4 regardless of CPU. If you write a program that computes 2+2 and writes the output in a file, that file will contain 4 in all cases. Likewise, the compiler should produce the same output regardless of CPU, because what it writes is determined in software. It's not the CPU that chooses what happens; the CPU merely make it happen.

Now you can have CPU-specific code (such as SSE instructions) but then again they'll be added by the compiler.

Finally, keep in mind that Intel, AMD and VIA all use the same core architecture, which is compatible with the x86 family. When you compile something for Win32, it could technically run on a 486 (probably even a 386) because that's the core architecture. The additional instructions ought to be optional paths that the program can use or not (as ZDoom does for SSE2) but even if that's not the case the compiler will be able to compile them nonetheless. You can compile SSE instructions without having an SSE-compatible CPU; it's just that you won't be able to run them to test that it compiled successfully.

If you compiled for your CPU precisely, then what would happen? Programs wouldn't be portable. Instead of building one Builder.exe, you'd have to build Builder-Intel.exe and Builder-AMD.exe, and you'd have to use two different computers for that. This would obviously be stupid.

See x86 for more in-depth informations.

Re: Need help with Bootless Star 7.5

by NeoHippo » Fri Apr 05, 2013 1:29

My compilation process with BootlessStarGZDB.bat

That worked out quite well.

After the compilation process, the plugins folder held this

Image

and after running RemovePackages.bat, the plugins folder held this

Image

So, that worked out quite well also.

Re: Need help with Bootless Star 7.5

by Tiger » Thu Apr 04, 2013 21:40

Gez wrote:That shouldn't change anything to the compiler though. If it were the case, the compiled build would not be portable. Well, either that, or the differences would be due to massive divergences in computation results, which would mean at least one of the processors is severely bugged, and the compiled build is therefore unreliable as it is no longer a mathematically exact translation of the source code.

More likely, the difference is due to different versions of statically-linked libraries, or possibly different optimization settings.
Thank you for sharing that :)

So regardless of the CPU's manufacturer (Intel, AMD, Cryrix, etc) - the binary should be created the same way regardless of their own unique instruction sets?

Re: Need help with Bootless Star 7.5

by Gez » Thu Apr 04, 2013 12:52

NeoHippo wrote:Maybe the 12k difference is due to the processor used.
That shouldn't change anything to the compiler though. If it were the case, the compiled build would not be portable. Well, either that, or the differences would be due to massive divergences in computation results, which would mean at least one of the processors is severely bugged, and the compiled build is therefore unreliable as it is no longer a mathematically exact translation of the source code.

More likely, the difference is due to different versions of statically-linked libraries, or possibly different optimization settings.

Re: Need help with Bootless Star 7.5

by Tiger » Thu Apr 04, 2013 12:08

NeoHippo wrote:Maybe the 12k difference is due to the processor used. I have an AMD 1055T.
That would make sense as Intel and AMD has their own instruction sets (CISC), though for the most part - some of their instructions sets are compatible with each other but only for market reasons.
NeoHippo wrote:That worked quite nicely, except that 3 files were duplicated
If you were to run the 'RemovePackages.bat' (misnomer...), do these files still exists? You can invoke this script by going to "[4] Execute Sub-Scripts" from the main menu.

Re: Need help with Bootless Star 7.5

by NeoHippo » Thu Apr 04, 2013 6:57

Maybe the 12k difference is due to the processor used. I have an AMD 1055T.

Thanks for Bootless Star 7.6.
I used BootlessStarGZDB.bat to compile including all plugins.
That worked quite nicely, except that 3 files were duplicated
into the Plugins folder:
Builder.exe, SharpCompress.3.5.dll and Trackbar.dll
which I had to delete from Plugins.
Otherwise it worked flawlessly.

Re: Need help with Bootless Star 7.5

by Tiger » Tue Apr 02, 2013 22:53

NeoHippo wrote:So, it must be due to the version of Microsoft Visual Studio used.
I use Microsoft Visual Studio 2010, so this is still rather puzzling :\

Re: Need help with Bootless Star 7.5

by NeoHippo » Sun Mar 31, 2013 20:18

I went with option 1: Compile Only Default Plug-ins.

The following are reported by Microsoft Visual C# 2010 Express in the About box:
Microsoft Visual Studio 2010
Version 10.0.40219.1 SP1Rel

Installed products:
Microsoft Visual C# 2010
Hotfix for Microsoft Visual C# 2010 Express
Microsoft Visual C# 2010 Express - ENU Service Pack 1

As you mentioned, maybe that accounts for the extra 12k.

Used my compilation some more with 3D constructs. Seems to be okay.

Bootless Star :thumb:

[edit]
Again, for r1664, the difference in Builder.exe is 12k.
So, it must be due to the version of Microsoft Visual Studio used.

Re: Need help with Bootless Star 7.5

by Tiger » Sun Mar 31, 2013 19:08

NeoHippo wrote:I compared the properties of Builder.exe from DRDteam with my compilation, and the file sizes, while close, are not
the same.
By chance do you remember if you compiled all of the plug-ins or just the default plugins? The {Doom Builder 2|GZDoom Builder|Doom Builder 64} SVN builds that have been uploaded on this site contains all of the plugins that is located in directory:

Code: Select all

GZDoomBuilder\Source\Plugins

Additionally, could it be possible that Visual Studio has added a few more instructions - but for optimization for your CPU? Perhaps someone might be able to shed some light on this theory, but other than that - I don't see why there's a difference....

Re: Need help with Bootless Star 7.5

by NeoHippo » Sun Mar 31, 2013 18:12

Tiger wrote:..... As this semester is closing in - there is more exams due and more work that has to be finished before this semester is finished. I am sorry that I can not give you an expeditious resolution - time is not my friend :\
That is totally understandable. Your studying and passing the exams is far more important.
I'm in no particular rush. So feel free to ignore my ramblings if they get in the way.



I'll just tinker along for a bit, and in doing so, I think I made some progress, mainly in that I renamed doombuilder
on line 118 to GZDoombuilder, just to stay with the theme, and I deleted branches\GZDoomBuilder on line 166 and
was able to have a successful compilation.

I just quickly ran my compilation and loaded a map, the program seems to run without problem. Further testing is
needed before I'm comfortable using it, though, because of the following:

I compared the properties of Builder.exe from DRDteam with my compilation, and the file sizes, while close, are not
the same.

Image

Would there be a specific reason for the slight discrepancy?

Re: Need help with Bootless Star 7.5

by Tiger » Sat Mar 30, 2013 19:09

Thank you for providing alot of details about the problems you are currently facing with the program. The main problem that I see (and that I also had) - is based on this screen shot you provided:
NeoHippo wrote:Image
The Bootless Star program expects 'Trunk or Branch' upper directory and the type of projects from the branches. Meaning, GZDoomBuilder used to be in:

Code: Select all

.\doombuilder\branch\gzdoombuilder\
Now, this has changed - and the program is not designed to deal with this conflict. (why? I didn't really think that any project would 'split' away from the doombuilder repo, live and learn :| )

In the near future, I'll release a bastard child of the program that contains only a few changes to allow the program work correctly in (and only in) GZDoom Builder.

As this semester is closing in - there is more exams due and more work that has to be finished before this semester is finished. I am sorry that I can not give you an expeditious resolution - time is not my friend :\

Top