On Nov 17 2016, Segher Boessenkool <seg...@kernel.crashing.org> wrote:
> PR rtl-optimization/71785 > * bb-reorder.c (maybe_duplicate_computed_goto): New function. > (duplicate_computed_gotos): New function. > (pass_duplicate_computed_gotos::execute): Rewrite. This breaks gcc.c-torture/execute/comp-goto-1.c execution test with -O2 -flto on ia64 and m68k. The label sim_base_addr has been placed after the L_LOAD32_RR and L_METAOP_DONE labels, so that op_map[program[i].f1.offset] - base_addr becomes negative. That can be fixed by making .offset a signed bitfield. Installed as obvious. Andreas. * gcc.c-torture/execute/comp-goto-1.c (insn_t): Change offset to signed int. diff --git a/gcc/testsuite/gcc.c-torture/execute/comp-goto-1.c b/gcc/testsuite/gcc.c-torture/execute/comp-goto-1.c index 3bf9a26f65..4c41b71c34 100644 --- a/gcc/testsuite/gcc.c-torture/execute/comp-goto-1.c +++ b/gcc/testsuite/gcc.c-torture/execute/comp-goto-1.c @@ -14,7 +14,7 @@ typedef union { struct { - unsigned int offset:18; + signed int offset:18; unsigned int ignore:4; unsigned int s1:8; int :2; -- 2.10.2 -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."