x86-64 Assembler

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
pskyboy

x86-64 Assembler

Post by pskyboy »

Hey Guys

Does anyone know of an assembler that will assemble for the x86-64 architecture. It would be really good if it took NASM syntax but thats probably hoping for to much.

Peter
DarylD

Re:x86-64 Assembler

Post by DarylD »

I use gas myself for all my assembler, basically because I use gcc for compilation.

That supports x86-64.
pskyboy

Re:x86-64 Assembler

Post by pskyboy »

Yeah haven't quite got used to the gas syntax yet. Is there any utility that will convert nasm based code to gas based code?
Peter
jrfritz

Re:x86-64 Assembler

Post by jrfritz »

GCC 3 has intel syntax...but it doesn't use db for bytes...it uses understandible things like .byte and .word.

Example: .word some_word

As for going without the %'s and all that weird stuff, use this macro in GCC:

#define inasm(s) asm( ".intel_syntax no_prefix" ); asm(s);asm(".att_syntax prefix" );
pskyboy

Re:x86-64 Assembler

Post by pskyboy »

Excellent

Thanks for that k.j. That now means i can get on and develop my 64 bit kernel.

Peter
pskyboy

Re:x86-64 Assembler

Post by pskyboy »

K.J have you got it to compile as i can't get it to compile at the moment

Peter
jrfritz

Re:x86-64 Assembler

Post by jrfritz »

I'm about to install the RPM and test it.
pskyboy

Re:x86-64 Assembler

Post by pskyboy »

I got the RPM to install under my Linux install but i couldn't fin d where it had put the executable. If you could tell me where it goes after its installed that would be great

Cheers
Peter
jrfritz

Re:x86-64 Assembler

Post by jrfritz »

Opps...I forgot to install it...i'll install it later...maybe Sunday.
Post Reply