aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2016-08-31 10:09:00 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2016-08-31 10:09:00 +0000
commitc1105fa7e43a9169187012010eeee81893e6a3cc (patch)
treed5e42cfc892ca42219522067352709e0dcac27be /gcc
parent1a576b133282fd16192fd76e6f10bc4bc16e033c (diff)
downloadgcc-c1105fa7e43a9169187012010eeee81893e6a3cc.zip
gcc-c1105fa7e43a9169187012010eeee81893e6a3cc.tar.gz
gcc-c1105fa7e43a9169187012010eeee81893e6a3cc.tar.bz2
* config/arm/arm.c (thumb1_size_rtx_costs) <SET>: Add missing guard.
From-SVN: r239888
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/config/arm/arm.c3
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 54f2f7a..e9dd537 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2016-08-31 Eric Botcazou <ebotcazou@adacore.com>
+
+ * config/arm/arm.c (thumb1_size_rtx_costs) <SET>: Add missing guard.
+
2016-08-30 David Malcolm <dmalcolm@redhat.com>
* diagnostic-show-locus.c (colorizer::begin_state): Support more
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index 43a832e..946f308 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -9127,7 +9127,8 @@ thumb1_size_rtx_costs (rtx x, enum rtx_code code, enum rtx_code outer)
if (satisfies_constraint_J (SET_SRC (x))
|| satisfies_constraint_K (SET_SRC (x))
/* Too big an immediate for a 2-byte mov, using MOVT. */
- || (UINTVAL (SET_SRC (x)) >= 256
+ || (CONST_INT_P (SET_SRC (x))
+ && UINTVAL (SET_SRC (x)) >= 256
&& TARGET_HAVE_MOVT
&& satisfies_constraint_j (SET_SRC (x)))
/* thumb1_movdi_insn. */