Why does the following code give a runtime error?
It prints: "Vendor id: GenuineIntel" and then crashes.
compiled with: nams -fwin32 ...
global _main
extern _printf
section .text
_main:
push ebx
push ebp
xor eax, eax
cpuid
mov [vendor], ebx
mov [vendor + 4], edx
mov [vendor + 8], ecx
push vendor
push format
call _printf
sub esp, 4
pop ebp
pop ebx
ret
section .data
format db 'Vendor id: %s', 10, 0
vendor times 12 db 0