]> git.ipfire.org Git - thirdparty/gcc.git/commit
[openacc] Disable pass_thread_jumps for IFN_UNIQUE
authorvries <vries@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 15 Jun 2019 07:06:19 +0000 (07:06 +0000)
committervries <vries@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 15 Jun 2019 07:06:19 +0000 (07:06 +0000)
commitf1a27d20b7f6ef3e59e7477d76892a7c9eeaeea4
tree00e3daa8ac952df48b317271c3370dac780e62c7
parent85d732f6eacd6f7eeef44450f2d7abe685a1c815
[openacc] Disable pass_thread_jumps for IFN_UNIQUE

If we compile the openacc testcase with -fopenacc -O2, we run into a SIGSEGV
or assert.  The root cause for this is that pass_thread_jumps breaks the
invariant that OACC_FORK and OACC_JOIN mark the start and end of a
single-entry-single-exit region.

Fix this by bailing out when encountering an IFN_UNIQUE in
thread_jumps::profitable_jump_thread_path.

Bootstrapped and reg-tested on x86_64.
Build and reg-tested libgomp on x86_64 with nvptx accelerator.

2019-06-15  Tom de Vries  <tdevries@suse.de>

PR tree-optimization/90009
* tree-ssa-threadbackward.c (thread_jumps::profitable_jump_thread_path):
Return NULL if bb contains IFN_UNIQUE.

* testsuite/libgomp.oacc-c-c++-common/pr90009.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@272321 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/tree-ssa-threadbackward.c
libgomp/ChangeLog
libgomp/testsuite/libgomp.oacc-c-c++-common/pr90009.c [new file with mode: 0644]