aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/vax
diff options
context:
space:
mode:
authorMaciej W. Rozycki <macro@linux-mips.org>2020-12-05 18:26:25 +0000
committerMaciej W. Rozycki <macro@linux-mips.org>2020-12-05 18:26:25 +0000
commit630c9a4d54de7c084e146afe82c6e89a9f2cf3d7 (patch)
treea116e8f75d2741dc913f823edfd571f8f7abf8cd /gcc/config/vax
parent4b70b2e07a589c4d50e14fa597eb164375a10a20 (diff)
downloadgcc-630c9a4d54de7c084e146afe82c6e89a9f2cf3d7.zip
gcc-630c9a4d54de7c084e146afe82c6e89a9f2cf3d7.tar.gz
gcc-630c9a4d54de7c084e146afe82c6e89a9f2cf3d7.tar.bz2
jump: Also handle jumps wrapped in UNSPEC or UNSPEC_VOLATILE
VAX has interlocked branch instructions used for atomic operations and we want to have them wrapped in UNSPEC_VOLATILE so as not to have code carried across. This however breaks with jump optimization and leads to an ICE in the build of libbacktrace like: .../libbacktrace/mmap.c:190:1: internal compiler error: in fixup_reorder_chain, at cfgrtl.c:3934 190 | } | ^ 0x1087d46b fixup_reorder_chain .../gcc/cfgrtl.c:3934 0x1087f29f cfg_layout_finalize() .../gcc/cfgrtl.c:4447 0x1087c74f execute .../gcc/cfgrtl.c:3662 on RTL like: (jump_insn 18 17 150 4 (unspec_volatile [ (set (pc) (if_then_else (eq (zero_extract:SI (mem/v:SI (reg/f:SI 23 [ _2 ]) [-1 S4 A32]) (const_int 1 [0x1]) (const_int 0 [0])) (const_int 1 [0x1])) (label_ref 20) (pc))) (set (zero_extract:SI (mem/v:SI (reg/f:SI 23 [ _2 ]) [-1 S4 A32]) (const_int 1 [0x1]) (const_int 0 [0])) (const_int 1 [0x1])) ] 101) ".../libbacktrace/mmap.c":135:14 158 {jbbssisi} (nil) -> 20) when those branches are enabled with a follow-up change. Also showing with: FAIL: gcc.dg/pr61756.c (internal compiler error) Handle branches wrapped in UNSPEC_VOLATILE then and, for consistency, also in UNSPEC. The presence of UNSPEC_VOLATILE will prevent such branches from being removed as they won't be accepted by `onlyjump_p', we just need to let them through. gcc/ * jump.c (pc_set): Also accept a jump wrapped in UNSPEC or UNSPEC_VOLATILE. (any_uncondjump_p, any_condjump_p): Update comment accordingly.
Diffstat (limited to 'gcc/config/vax')
0 files changed, 0 insertions, 0 deletions