From 3460fdf328976b9f328478e12e0c87c48091d33a Mon Sep 17 00:00:00 2001 From: Richard Sandiford Date: Wed, 23 Mar 2011 09:57:26 +0000 Subject: [PATCH] re PR target/47553 (ARM neon vld1q_lane_u8 & co. don't accept lanes >= 8) gcc/ PR target/47553 * config/arm/predicates.md (neon_lane_number): Accept 0..15. gcc/testsuite/ PR target/47553 * gcc.target/arm/neon-vld-1.c: New test. From-SVN: r171344 --- gcc/ChangeLog | 5 +++++ gcc/config/arm/predicates.md | 2 +- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/gcc.target/arm/neon-vld-1.c | 13 +++++++++++++ 4 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 gcc/testsuite/gcc.target/arm/neon-vld-1.c diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 14f8008214c..fb754ab629b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2011-03-23 Richard Sandiford + + PR target/47553 + * config/arm/predicates.md (neon_lane_number): Accept 0..15. + 2011-03-23 Richard Sandiford * optabs.h (emit_unop_insn, maybe_emit_unop_insn): Change insn code diff --git a/gcc/config/arm/predicates.md b/gcc/config/arm/predicates.md index 399938fbc29..40ce1f3c8e9 100644 --- a/gcc/config/arm/predicates.md +++ b/gcc/config/arm/predicates.md @@ -610,7 +610,7 @@ ;; TODO: We could check lane numbers more precisely based on the mode. (define_predicate "neon_lane_number" (and (match_code "const_int") - (match_test "INTVAL (op) >= 0 && INTVAL (op) <= 7"))) + (match_test "INTVAL (op) >= 0 && INTVAL (op) <= 15"))) ;; Predicates for named expanders that overlap multiple ISAs. (define_predicate "cmpdi_operand" diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 8bc06037175..31896e2e0d0 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2011-03-23 Richard Sandiford + + PR target/47553 + * gcc.target/arm/neon-vld-1.c: New test. + 2011-03-23 Eric Botcazou * gnat.dg/array14.ad[sb]: New test. diff --git a/gcc/testsuite/gcc.target/arm/neon-vld-1.c b/gcc/testsuite/gcc.target/arm/neon-vld-1.c new file mode 100644 index 00000000000..f6bf6911d42 --- /dev/null +++ b/gcc/testsuite/gcc.target/arm/neon-vld-1.c @@ -0,0 +1,13 @@ +/* { dg-do compile } */ +/* { dg-require-effective-target arm_neon_ok } */ +/* { dg-options "-O1" } */ +/* { dg-add-options arm_neon } */ + +#include + +uint8x16_t +foo (uint8_t *a, uint8x16_t b) +{ + vst1q_lane_u8 (a, b, 14); + return vld1q_lane_u8 (a + 0x100, b, 15); +} -- 2.30.2