diff options
author | Tom de Vries <tdevries@suse.de> | 2020-09-10 12:44:20 +0200 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2020-09-10 12:59:29 +0200 |
commit | f96b6328fa7162111e4440c5901ef313ed3e6c9a (patch) | |
tree | 6b4bcfee3f83263d4e9744b3fc6ad5ed0d2b7f40 /gcc/tree-ssa-structalias.c | |
parent | 3d0af0c997fe42a7f0963d970a9c495b81041206 (diff) | |
download | gcc-f96b6328fa7162111e4440c5901ef313ed3e6c9a.zip gcc-f96b6328fa7162111e4440c5901ef313ed3e6c9a.tar.gz gcc-f96b6328fa7162111e4440c5901ef313ed3e6c9a.tar.bz2 |
[tree-optimization] Don't clear ctrl-altering flag for IFN_UNIQUE
There's an invariant for IFN_UNIQUE, listed here in
gimple_call_initialize_ctrl_altering:
...
/* IFN_UNIQUE should be the last insn, to make checking for it
as cheap as possible. */
|| (gimple_call_internal_p (stmt)
&& gimple_call_internal_unique_p (stmt)))
gimple_call_set_ctrl_altering (stmt, true);
...
Recent commit fab77644842 "tree-optimization/96931 - clear ctrl-altering flag
more aggressively" breaks this invariant, causing an ICE triggered during
libgomp testing for x86_64 with nvptx accelerator:
...
during RTL pass: mach
asyncwait-1.f90: In function ‘MAIN__._omp_fn.0’:
asyncwait-1.f90:19: internal compiler error: in nvptx_find_par, at \
config/nvptx/nvptx.c:3293
...
Fix this by listing IFN_UNIQUE as exception in
cleanup_call_ctrl_altering_flag.
Build for x86_64 with nvptx accelerator, tested libgomp.
gcc/ChangeLog:
PR tree-optimization/97000
* tree-cfgcleanup.c (cleanup_call_ctrl_altering_flag): Don't clear
flag for IFN_UNIQUE.
Diffstat (limited to 'gcc/tree-ssa-structalias.c')
0 files changed, 0 insertions, 0 deletions