Page 1 of 1
64-bit Assembler problems
Posted: Sun Nov 06, 2005 5:55 am
by falconfx
Hello!
I have decided to convert my own OS to 64 bit, as 32 bit era is just going to finally finish.
Until yesterday, I used nasm to compile my assembly code successfully; but now, I changed [BITS 32] to [BITS 64] and it doesn't recognize the new code type. If I delete that statement, nasm complains about the "inexistent" rax, rbx... registers.
Any suggestion?
Re:64-bit Assembler problems
Posted: Sun Nov 06, 2005 6:10 am
by bluecode
hi,
nasm imho doesn't support 64-bit code so far. You could use fasm or yasm. I think yasm forked out of the nasm codebase and they also added support for 64-bit code, but I can't tell you anything about yasm syntax.
Re:64-bit Assembler problems
Posted: Sun Nov 06, 2005 6:16 am
by AR
AFAIK YASM supports 64bit assembly in NASM syntax. I don't know of any other Intel syntax assembler that does 64bit. Then you also have GAS, of course.
I wouldn't be so quick to rule out 32bit, it'll still be around for a few years, migration is a slow process (some people still use win98).
Re:64-bit Assembler problems
Posted: Sun Nov 06, 2005 8:57 am
by Candy
AR wrote:
AFAIK YASM supports 64bit assembly in NASM syntax. I don't know of any other Intel syntax assembler that does 64bit. Then you also have GAS, of course.
I wouldn't be so quick to rule out 32bit, it'll still be around for a few years, migration is a slow process (some people still use win98).
YASM supports 64-bit assembler out-of-the-box, in the same way that nasm supports 32-bit and 16-bit assembler. GAS supports it too, but I'm disgusted by its syntax. Since there are enough places where 16-bit is still used (which is why bioses still boot up with 16-bit mode active) don't count on 32-bit to disappear too quickly. It will be used in places where you don't care about 64-bits, such as pretty much everywhere.