aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Earnshaw <rearnsha@arm.com>2018-05-11 09:28:10 +0000
committerRichard Earnshaw <rearnsha@gcc.gnu.org>2018-05-11 09:28:10 +0000
commitc40a8be80895679e8100e6ed32274bbed57d6543 (patch)
tree2f37b6ed2587c1087866f1f187be579bcb56c8b9
parent1c9ee609dffac3f7d59ac9b8ca725d3cb9769b61 (diff)
downloadgcc-c40a8be80895679e8100e6ed32274bbed57d6543.zip
gcc-c40a8be80895679e8100e6ed32274bbed57d6543.tar.gz
gcc-c40a8be80895679e8100e6ed32274bbed57d6543.tar.bz2
[arm] PR target/85606 prefer armv6s-m for armv6-m parts
When Arm introduced ARMv6-M there were two variants, ARMv6-M and ARMv6S-M. The two differed only in support for the SVC instruction. Later on SVC was then made a mandatory part of ARMv6-M and the ARMv6S-M name was dropped. GCC and GAS, however still recognize both names and at least some versions of GAS still distinguish between the two. To address this, this patch changes the architecture for the ARMv6-m cortex parts (m0, m0plus, m1 and the variants will small multiply units) to use the ARMv6S-M name in conjunction with the assembler. This avoids problems with them rejecting code that was previously accepted with older versions of GCC where we did not pass an explicit architecture string through to the compiler when using -mcpu on the command line. PR target/85606 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now equivalent. (cortex-m0): Use armv6s-m isa. (cortex-m0plus): Likewise. (cortex-m1): Likewise. (cortex-m0.small-multiply): Likewise. (cortex-m0plus.small-multiply): Likewise. (cortex-m1.small-multiply): Likewise. From-SVN: r260157
-rw-r--r--gcc/ChangeLog12
-rw-r--r--gcc/config/arm/arm-cpus.in14
2 files changed, 20 insertions, 6 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 01d3b18..434d443 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,15 @@
+2018-05-11 Richard Earnshaw <rearnsha@arm.com>
+
+ PR target/85606
+ * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
+ equivalent.
+ (cortex-m0): Use armv6s-m isa.
+ (cortex-m0plus): Likewise.
+ (cortex-m1): Likewise.
+ (cortex-m0.small-multiply): Likewise.
+ (cortex-m0plus.small-multiply): Likewise.
+ (cortex-m1.small-multiply): Likewise.
+
2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
Jakub Jelinek <jakub@redhat.com>
diff --git a/gcc/config/arm/arm-cpus.in b/gcc/config/arm/arm-cpus.in
index cc08f5a..fce30e4 100644
--- a/gcc/config/arm/arm-cpus.in
+++ b/gcc/config/arm/arm-cpus.in
@@ -446,6 +446,8 @@ begin arch armv6-m
isa ARMv6m
end arch armv6-m
+# This is now equivalent to armv6-m, but we keep it because some
+# versions of GAS still distinguish between the two.
begin arch armv6s-m
tune for cortex-m1
base 6M
@@ -1168,21 +1170,21 @@ end cpu arm1156t2f-s
begin cpu cortex-m1
cname cortexm1
tune flags LDSCHED
- architecture armv6-m
+ architecture armv6s-m
costs v6m
end cpu cortex-m1
begin cpu cortex-m0
cname cortexm0
tune flags LDSCHED
- architecture armv6-m
+ architecture armv6s-m
costs v6m
end cpu cortex-m0
begin cpu cortex-m0plus
cname cortexm0plus
tune flags LDSCHED
- architecture armv6-m
+ architecture armv6s-m
costs v6m
end cpu cortex-m0plus
@@ -1192,7 +1194,7 @@ begin cpu cortex-m1.small-multiply
cname cortexm1smallmultiply
tune for cortex-m1
tune flags LDSCHED SMALLMUL
- architecture armv6-m
+ architecture armv6s-m
costs v6m
end cpu cortex-m1.small-multiply
@@ -1200,7 +1202,7 @@ begin cpu cortex-m0.small-multiply
cname cortexm0smallmultiply
tune for cortex-m0
tune flags LDSCHED SMALLMUL
- architecture armv6-m
+ architecture armv6s-m
costs v6m
end cpu cortex-m0.small-multiply
@@ -1208,7 +1210,7 @@ begin cpu cortex-m0plus.small-multiply
cname cortexm0plussmallmultiply
tune for cortex-m0plus
tune flags LDSCHED SMALLMUL
- architecture armv6-m
+ architecture armv6s-m
costs v6m
end cpu cortex-m0plus.small-multiply