From 2989d25dc9ca3696eeba6faf44f6500f66cecc7e Mon Sep 17 00:00:00 2001 From: cbaylis Date: Wed, 11 Nov 2015 01:11:20 +0000 Subject: [PATCH] [ARM] PR63870 Remove error for invalid lane numbers 2015-11-11 Charles Baylis PR target/63870 * config/arm/neon.md (neon_vld1_lane): Remove error for invalid lane number. (neon_vst1_lane): Likewise. (neon_vld2_lane): Likewise. (neon_vst2_lane): Likewise. (neon_vld3_lane): Likewise. (neon_vst3_lane): Likewise. (neon_vld4_lane): Likewise. (neon_vst4_lane): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@230144 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 13 +++++++++++++ gcc/config/arm/neon.md | 48 ++++++++---------------------------------------- 2 files changed, 21 insertions(+), 40 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f0865eb..318de8f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,6 +1,19 @@ 2015-11-11 Charles Baylis PR target/63870 + * config/arm/neon.md (neon_vld1_lane): Remove error for invalid + lane number. + (neon_vst1_lane): Likewise. + (neon_vld2_lane): Likewise. + (neon_vst2_lane): Likewise. + (neon_vld3_lane): Likewise. + (neon_vst3_lane): Likewise. + (neon_vld4_lane): Likewise. + (neon_vst4_lane): Likewise. + +2015-11-11 Charles Baylis + + PR target/63870 * config/arm/arm-builtins.c: (arm_load1_qualifiers) Use qualifier_struct_load_store_lane_index. (arm_storestruct_lane_qualifiers) Likewise. diff --git a/gcc/config/arm/neon.md b/gcc/config/arm/neon.md index c70e08a..119550c 100644 --- a/gcc/config/arm/neon.md +++ b/gcc/config/arm/neon.md @@ -4267,8 +4267,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT lane = NEON_ENDIAN_LANE_N(mode, INTVAL (operands[3])); HOST_WIDE_INT max = GET_MODE_NUNITS (mode); operands[3] = GEN_INT (lane); - if (lane < 0 || lane >= max) - error ("lane out of range"); if (max == 1) return "vld1.\t%P0, %A1"; else @@ -4291,9 +4289,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); operands[3] = GEN_INT (lane); int regno = REGNO (operands[0]); - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -4379,8 +4375,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT lane = NEON_ENDIAN_LANE_N(mode, INTVAL (operands[2])); HOST_WIDE_INT max = GET_MODE_NUNITS (mode); operands[2] = GEN_INT (lane); - if (lane < 0 || lane >= max) - error ("lane out of range"); if (max == 1) return "vst1.\t{%P1}, %A0"; else @@ -4402,9 +4396,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT lane = NEON_ENDIAN_LANE_N(mode, INTVAL (operands[2])); HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -4475,8 +4467,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[0]); rtx ops[4]; - if (lane < 0 || lane >= max) - error ("lane out of range"); ops[0] = gen_rtx_REG (DImode, regno); ops[1] = gen_rtx_REG (DImode, regno + 2); ops[2] = operands[1]; @@ -4502,9 +4492,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[0]); rtx ops[4]; - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -4594,8 +4582,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); rtx ops[4]; - if (lane < 0 || lane >= max) - error ("lane out of range"); ops[0] = operands[0]; ops[1] = gen_rtx_REG (DImode, regno); ops[2] = gen_rtx_REG (DImode, regno + 2); @@ -4621,9 +4607,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); rtx ops[4]; - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -4742,8 +4726,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[0]); rtx ops[5]; - if (lane < 0 || lane >= max) - error ("lane out of range"); ops[0] = gen_rtx_REG (DImode, regno); ops[1] = gen_rtx_REG (DImode, regno + 2); ops[2] = gen_rtx_REG (DImode, regno + 4); @@ -4771,9 +4753,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[0]); rtx ops[5]; - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -4918,8 +4898,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); rtx ops[5]; - if (lane < 0 || lane >= max) - error ("lane out of range"); ops[0] = operands[0]; ops[1] = gen_rtx_REG (DImode, regno); ops[2] = gen_rtx_REG (DImode, regno + 2); @@ -4947,9 +4925,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); rtx ops[5]; - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -5072,8 +5048,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[0]); rtx ops[6]; - if (lane < 0 || lane >= max) - error ("lane out of range"); ops[0] = gen_rtx_REG (DImode, regno); ops[1] = gen_rtx_REG (DImode, regno + 2); ops[2] = gen_rtx_REG (DImode, regno + 4); @@ -5102,9 +5076,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[0]); rtx ops[6]; - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; @@ -5256,8 +5228,6 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); rtx ops[6]; - if (lane < 0 || lane >= max) - error ("lane out of range"); ops[0] = operands[0]; ops[1] = gen_rtx_REG (DImode, regno); ops[2] = gen_rtx_REG (DImode, regno + 2); @@ -5286,9 +5256,7 @@ if (BYTES_BIG_ENDIAN) HOST_WIDE_INT max = GET_MODE_NUNITS (mode); int regno = REGNO (operands[1]); rtx ops[6]; - if (lane < 0 || lane >= max) - error ("lane out of range"); - else if (lane >= max / 2) + if (lane >= max / 2) { lane -= max / 2; regno += 2; -- 2.7.4