diff options
author | Tom de Vries <tdevries@suse.de> | 2022-03-18 16:19:25 +0100 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2022-03-18 16:27:28 +0100 |
commit | 63746c253a83be0022d920e045dfd356b1ca0149 (patch) | |
tree | 361afd42dfa9270a1102efe3fe9688809eb938f6 | |
parent | 41f01c97153d403fb34eefac245bab8ba472beea (diff) | |
download | gcc-63746c253a83be0022d920e045dfd356b1ca0149.zip gcc-63746c253a83be0022d920e045dfd356b1ca0149.tar.gz gcc-63746c253a83be0022d920e045dfd356b1ca0149.tar.bz2 |
Fix "[openmp] Set location for taskloop stmts"
I accidentally committed an outdated version of patch "[openmp] Set location
for taskloop stmts".
Fix this by adding the missing changes.
gcc/ChangeLog:
2022-03-18 Tom de Vries <tdevries@suse.de>
* gimplify.cc (gimplify_omp_for): Set location using 'input_location'.
Set gfor location only when dealing with a OMP_TASKLOOP.
-rw-r--r-- | gcc/gimplify.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/gimplify.cc b/gcc/gimplify.cc index c465896..f62f150 100644 --- a/gcc/gimplify.cc +++ b/gcc/gimplify.cc @@ -13178,7 +13178,6 @@ gimplify_omp_for (tree *expr_p, gimple_seq *pre_p) gfor = gimple_build_omp_for (for_body, kind, OMP_FOR_CLAUSES (orig_for_stmt), TREE_VEC_LENGTH (OMP_FOR_INIT (for_stmt)), for_pre_body); - gimple_set_location (gfor, EXPR_LOCATION (*expr_p)); if (orig_for_stmt != for_stmt) gimple_omp_for_set_combined_p (gfor, true); if (gimplify_omp_ctxp @@ -13359,10 +13358,11 @@ gimplify_omp_for (tree *expr_p, gimple_seq *pre_p) *gtask_clauses_ptr = NULL_TREE; *gforo_clauses_ptr = NULL_TREE; BITMAP_FREE (lastprivate_uids); + gimple_set_location (gfor, input_location); g = gimple_build_bind (NULL_TREE, gfor, NULL_TREE); g = gimple_build_omp_task (g, task_clauses, NULL_TREE, NULL_TREE, NULL_TREE, NULL_TREE, NULL_TREE); - gimple_set_location (g, EXPR_LOCATION (*expr_p)); + gimple_set_location (g, input_location); gimple_omp_task_set_taskloop_p (g, true); g = gimple_build_bind (NULL_TREE, g, NULL_TREE); gomp_for *gforo |