mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-09 13:18:15 +00:00
seem to be simply duplication of the x86 instruction set tests into the addrcheck and helgrind trees. I'm not sure what this duplication achieves. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@3264
16 lines
274 B
C
16 lines
274 B
C
/* test segment register getting */
|
|
#include <stdio.h>
|
|
|
|
int main()
|
|
{
|
|
unsigned short gsw;
|
|
unsigned long gsl;
|
|
|
|
asm ("mov $~0, %0; movl %%gs, %0" : "=r" (gsl));
|
|
asm ("mov $~0, %0; movw %%gs, %0" : "=r" (gsw));
|
|
|
|
printf("%s\n", gsl == gsw ? "PASS" : "FAIL");
|
|
|
|
return 0;
|
|
}
|