summaryrefslogtreecommitdiff
path: root/gcc/omp-simd-clone.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2016-11-21 20:17:36 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2016-11-21 20:17:36 +0100
commit699e8cb7b4d067cabff5a92bdbbb2d0d0dddc262 (patch)
treec46eb1d0c6df69460c15a6d52bd11212170ddb53 /gcc/omp-simd-clone.c
parentafb34582771843f86e72c4d7dca60220d0591c95 (diff)
downloadgcc-699e8cb7b4d067cabff5a92bdbbb2d0d0dddc262.tar.gz
re PR middle-end/67335 (ICE in compiling omp simd function with unused argument)
PR middle-end/67335 * omp-simd-clone.c (simd_clone_adjust_argument_types): Use NULL prefix for tmp simd array if DECL_NAME (parm) is NULL. * g++.dg/vect/simd-clone-7.cc: New test. From-SVN: r242678
Diffstat (limited to 'gcc/omp-simd-clone.c')
-rw-r--r--gcc/omp-simd-clone.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/omp-simd-clone.c b/gcc/omp-simd-clone.c
index 15f80ab0766..7b8d2a9dc8a 100644
--- a/gcc/omp-simd-clone.c
+++ b/gcc/omp-simd-clone.c
@@ -630,8 +630,9 @@ simd_clone_adjust_argument_types (struct cgraph_node *node)
if (node->definition)
sc->args[i].simd_array
- = create_tmp_simd_array (IDENTIFIER_POINTER (DECL_NAME (parm)),
- parm_type, sc->simdlen);
+ = create_tmp_simd_array (DECL_NAME (parm)
+ ? IDENTIFIER_POINTER (DECL_NAME (parm))
+ : NULL, parm_type, sc->simdlen);
}
adjustments.safe_push (adj);
}