diff options
author | Nathan Sidwell <nathan@codesourcery.com> | 2016-05-02 18:27:40 +0000 |
---|---|---|
committer | Nathan Sidwell <nathan@gcc.gnu.org> | 2016-05-02 18:27:40 +0000 |
commit | 4877b5a4ac000f13c9e167710d1b060eff5764f4 (patch) | |
tree | 79c6577f0806986faee0c5b48b26f48a508d0c31 | |
parent | 4344d7fa74ae01f86536f8b476627f982de34391 (diff) | |
download | gcc-4877b5a4ac000f13c9e167710d1b060eff5764f4.zip gcc-4877b5a4ac000f13c9e167710d1b060eff5764f4.tar.gz gcc-4877b5a4ac000f13c9e167710d1b060eff5764f4.tar.bz2 |
omp-low.c (lower_oacc_head_tail): Assert there is at least one marker.
* omp-low.c (lower_oacc_head_tail): Assert there is at least one
marker.
(oacc_loop_process): Check mask for loop termination.
From-SVN: r235775
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/omp-low.c | 8 |
2 files changed, 8 insertions, 6 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 051b871..a527809 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2016-05-02 Nathan Sidwell <nathan@codesourcery.com> + + * omp-low.c (lower_oacc_head_tail): Assert there is at least one + marker. + (oacc_loop_process): Check mask for loop termination. + 2016-05-02 Jan Hubicka <hubicka@ucw.cz> * cif-code.def (CIF_THUNK): Add. diff --git a/gcc/omp-low.c b/gcc/omp-low.c index e4a1e47..048c879 100644 --- a/gcc/omp-low.c +++ b/gcc/omp-low.c @@ -6402,12 +6402,10 @@ lower_oacc_head_tail (location_t loc, tree clauses, gimple_seq_add_stmt (head, gimple_build_assign (ddvar, integer_zero_node)); unsigned count = lower_oacc_head_mark (loc, ddvar, clauses, head, ctx); - if (!count) - lower_oacc_loop_marker (loc, ddvar, false, integer_zero_node, tail); - tree fork_kind = build_int_cst (unsigned_type_node, IFN_UNIQUE_OACC_FORK); tree join_kind = build_int_cst (unsigned_type_node, IFN_UNIQUE_OACC_JOIN); + gcc_assert (count); for (unsigned done = 1; count; count--, done++) { gimple_seq fork_seq = NULL; @@ -19331,10 +19329,8 @@ oacc_loop_process (oacc_loop *loop) oacc_loop_xform_loop (loop->head_end, loop->ifns, mask_arg, chunk_arg); - for (ix = 0; ix != GOMP_DIM_MAX && loop->heads[ix]; ix++) + for (ix = 0; ix != GOMP_DIM_MAX && mask; ix++) { - gcc_assert (mask); - while (!(GOMP_DIM_MASK (dim) & mask)) dim++; |