diff options
Diffstat (limited to 'gcc/testsuite/gcc.c-torture/compile/pr120807.c')
-rw-r--r-- | gcc/testsuite/gcc.c-torture/compile/pr120807.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr120807.c b/gcc/testsuite/gcc.c-torture/compile/pr120807.c new file mode 100644 index 0000000..9b37e60 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr120807.c @@ -0,0 +1,20 @@ +typedef __UINT8_TYPE__ uint8_t; +typedef __UINT32_TYPE__ uint32_t; + +typedef struct +{ + uint32_t dword[2]; + uint8_t byte[8]; +} reg64_t; +reg64_t TestF20F_opgd, TestF20F_oped; + +void +TestF20F () +{ + TestF20F_opgd.dword[0] ^= TestF20F_oped.byte[0]; + for (int i = 0; i < 8; i++) + if (TestF20F_opgd.dword[0] & 1) + TestF20F_opgd.dword[0] = TestF20F_opgd.dword[0] >> 1 ^ (uint32_t)2197175160UL; + else + TestF20F_opgd.dword[0] = TestF20F_opgd.dword[0] >> 1; +} |