NASM - The Netwide Assembler
NASM Forum => Programming with NASM => Topic started by: rouki on July 15, 2014, 03:40:08 PM
-
Hey,
The following line leads to a segmentation fault: movdqu xmm0, [rcx]
This line works fine in MASM but not in NASM. What am I missing? What should I supply nasm in order for that command to work properly?
thanks
-
Hi!
No seg fault for me.
Works without fault's.
bits 64
section .data
align 16
message0: db "HeLLO 123!!!",13,10,0
align 16
number: dq 0
section .text
global main
extern printf
align 16
main:
sub rsp,0x28
mov rcx,number
movdqu xmm0,[rcx]
mov rcx,message0
call printf
add rsp,0x28
ret
"nasm.exe -f win64 code.asm -o code.obj"
"gcc code.obj -o code.exe"