You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
#include <assert.h>
|
|
|
|
#include <stdio.h>
|
|
|
|
|
|
|
|
int main() {
|
|
|
|
int i = 0xffff;
|
|
|
|
|
|
|
|
asm("movl $23, %0"
|
|
|
|
: "=r" (i) /* output */
|
|
|
|
/* : no input */
|
|
|
|
/* : no clobbered */
|
|
|
|
);
|
|
|
|
|
|
|
|
printf("i = %d\n", i);
|
|
|
|
assert(i == 23);
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|