Hello, I've been wanting to learn assembler for quite some time now and I'd just want to know which type of asm works with FPC and C++ of windows (Intel?)?
Could someone explain the differences?
Thanks!
Hello, I've been wanting to learn assembler for quite some time now and I'd just want to know which type of asm works with FPC and C++ of windows (Intel?)?
Could someone explain the differences?
Thanks!
As far as I know AT&T style assembler is the best implemented style in FPC. All my optimizations are however made in intel style assembler which works fine in both delphi and fpc(-Rintel).
The key difference between AT&T and Intel style is the ordering of the arguments and the syntax
Intelstyle:
MOV eax, 100 //eax := 100
ADD eax, edx //eax := eax+edx
AT&T:
MOV 100, eax //eax := 100
ADD edx, eax //eax := eax+edx
AT&T also has a few differences when accessing pointers and such where Intel style has a more delphi like syntax(That's my oppinion).
I have no idea what assembler style you usually would use in c++ though
Peregrinus, expectavi pedes meos in cymbalis
Nullus norvegicorum sole urinat
Thanks. Ok so I should basically use whichever I prefer, the tutorials will work for both. Great
I also like the Intel style better, the Intel mov seems more logical to me, don't know why they mess with them :/
Bookmarks