Hi there. I really do not have much time so sorry if this topic was written earlier.
I'm newbie in nasm [ i preffer at&t syntax ]
And I'm trying to find out wtf is wrong in this line:
mov edi, offset table
(nasm says: error: comma or end of line expected
(lea edi, table) same result.
where table is global char array from extern file1.c
whole code:
file2.asm
---snip snip----
section .text
global cpuid_vendor
(...)
cpuid_vendor:
mov eax, 0
cpuid
mov edi, offset table
mov [edi], ebx
mov [edi+4],edx
mov [edi+8],ecx
ret
(...)
---snip snip---
and C code:
#include
int cpuid_vendor();
char table[1024];
int main() {
int i; (...)
cpuid_vendor();
for(i=0;i<12;i++)
printf("%c",table);
(...)
Thanx for any kind of help.
greetingz