gcc/testsuite/gcc.c-torture/compile/dse.c
raw| 1 | /* { dg-additional-options "-fpermissive" } */ |
| 2 | |
| 3 | typedef unsigned long microblaze_reg_t; |
| 4 | struct pt_regs |
| 5 | { |
| 6 | microblaze_reg_t msr; |
| 7 | int pt_mode; |
| 8 | }; |
| 9 | struct task_struct |
| 10 | { |
| 11 | void *stack; |
| 12 | }; |
| 13 | int |
| 14 | copy_thread (struct task_struct *p) |
| 15 | { |
| 16 | struct pt_regs *childregs = |
| 17 | (((struct pt_regs *) ((1 << 13) + ((void *) (p)->stack))) - 1); |
| 18 | memset (childregs, 0, sizeof (struct pt_regs)); |
| 19 | childregs->pt_mode = 1; |
| 20 | } |
| 21 |