1 /* Tests that Valgrind coredump support for SSE registers works correctly
2 by producing a core dump analyzable by mdb.
3 Basic register set is tested in coredump_single_thread. */
8 __attribute__((noinline
))
9 static void inner(void)
11 /* Set XMM registers to apriori known values.
12 Unfortunately there is no instruction to load
13 an immediate value directly into xmm register. */
14 __asm__
__volatile__("\n"
19 "movups (%%esp), %%xmm0\n"
24 "movups (%%esp), %%xmm1\n"
29 "movups (%%esp), %%xmm2\n"
34 "movups (%%esp), %%xmm3\n"
39 "movups (%%esp), %%xmm4\n"
44 "movups (%%esp), %%xmm5\n"
49 "movups (%%esp), %%xmm6\n"
54 "movups (%%esp), %%xmm7\n"
56 "movl $0x1234, (%%eax)\n" // should cause SEGV here
57 : // no output registers
58 : // no input registers
59 : "memory", "%xmm0", "%xmm1", "%xmm2", "%xmm3",
60 "%xmm4", "%xmm5", "%xmm6", "%xmm7");
63 __attribute__((noinline
))
64 static void outer(void)
69 int main(int argc
, const char *argv
[])