From 6b6a77d25e83e071ba5d08648c5bd3953d8a0c03 Mon Sep 17 00:00:00 2001 From: Andre Vieira Date: Mon, 27 Apr 2020 14:54:46 +0100 Subject: [PATCH] arm: Fix bootstrap failure with rtl-checking The code change that caused this regression was not meant to affect neon code-gen, however I missed the REG fall through. This patch makes sure we only get the left-hand of the PLUS if it is indeed a PLUS expr. gcc/ChangeLog: 2020-04-27 Andre Vieira * config/arm/arm.c (output_move_neon): Only get the first operand if addr is PLUS. --- gcc/ChangeLog | 5 +++++ gcc/config/arm/arm.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index bd5e95a9133..0027071f717 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2020-04-27 Andre Vieira + + * config/arm/arm.c (output_move_neon): Only get the first operand if + addr is PLUS. + 2020-04-27 Felix Yang PR tree-optimization/94784 diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c index 0151bda90d9..74454dddbb9 100644 --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -20145,7 +20145,8 @@ output_move_neon (rtx *operands) } /* Fall through. */ case PLUS: - addr = XEXP (addr, 0); + if (GET_CODE (addr) == PLUS) + addr = XEXP (addr, 0); /* Fall through. */ case LABEL_REF: { -- 2.30.2