Commit e77a1236 by Tom de Vries Committed by Tom de Vries

[nvptx, PR84028] Add exit insn after noreturn call for neutered workers

2018-01-25  Tom de Vries  <tom@codesourcery.com>

	PR target/84028
	* config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
	for neutered workers.

	* testsuite/libgomp.oacc-fortran/pr84028.f90: New test.

From-SVN: r257046
parent 8819c919
2018-01-25 Tom de Vries <tom@codesourcery.com>
PR target/84028
* config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
for neutered workers.
2018-01-24 Joseph Myers <joseph@codesourcery.com> 2018-01-24 Joseph Myers <joseph@codesourcery.com>
PR target/68467 PR target/68467
......
...@@ -4065,8 +4065,8 @@ nvptx_single (unsigned mask, basic_block from, basic_block to) ...@@ -4065,8 +4065,8 @@ nvptx_single (unsigned mask, basic_block from, basic_block to)
else else
{ {
rtx_insn *label_insn = emit_label_after (label, tail); rtx_insn *label_insn = emit_label_after (label, tail);
if (mode == GOMP_DIM_VECTOR && CALL_P (tail) if ((mode == GOMP_DIM_VECTOR || mode == GOMP_DIM_WORKER)
&& find_reg_note (tail, REG_NORETURN, NULL)) && CALL_P (tail) && find_reg_note (tail, REG_NORETURN, NULL))
emit_insn_after (gen_exit (), label_insn); emit_insn_after (gen_exit (), label_insn);
} }
} }
......
2018-01-25 Tom de Vries <tom@codesourcery.com>
PR target/84028
* testsuite/libgomp.oacc-fortran/pr84028.f90: New test.
2018-01-24 Tom de Vries <tom@codesourcery.com> 2018-01-24 Tom de Vries <tom@codesourcery.com>
PR target/83589 PR target/83589
......
! { dg-do run }
program foo
integer :: a(3,3,3), ll, lll
a = 1
!$acc parallel num_gangs(1) num_workers(2)
if (any(a(1:3,1:3,1:3).ne.1)) call abort
do ll=1,3
!$acc loop vector
do lll=1,3
a(1,ll,lll) = 2
enddo
enddo
if (a(1,1,1).ne.2) call abort
!$acc end parallel
end program foo
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment