From the top of my head:
Code:
void main() {
char vendor[13];
_asm {
xor eax,eax
db 0fh,0a2h // CPUID
mov vendor,ebx
mov [vendor+4],edx
mov [vendor+8],ecx
}
vendor[12] = '\0';
printf("%s\n",vendor);
}
This is far from the best way to do it but you can do a lot more magic with the CPUID instruction.
Btw, it's been a while since i coded assembler, but you should get the picture. =)