Skip to content

Instantly share code, notes, and snippets.

@epcnt19
Created December 19, 2018 12:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save epcnt19/e03808fd3df132fd3bfeab54259c3148 to your computer and use it in GitHub Desktop.
Save epcnt19/e03808fd3df132fd3bfeab54259c3148 to your computer and use it in GitHub Desktop.
#include<stdio.h>
int eax_value = 0;
void cpuid(){
__asm__ volatile ("movl eax_value,%eax \n\t"
"cpuid");
}
int main(void){
cpuid();
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment