aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/config/aarch64
diff options
context:
space:
mode:
authorRong Xu <xur@google.com>2014-10-31 10:54:01 -0700
committerRong Xu <xur@google.com>2014-10-31 10:54:01 -0700
commite86367917b8400cc955d8bba75dcc329cb0e75d0 (patch)
tree20d1ceb86e7d77b2d8f775f3eb8c716181a4d1f1 /gcc-4.9/gcc/config/aarch64
parent62ff1558ba46eb15a98ef906a696a12a23211185 (diff)
downloadtoolchain_gcc-e86367917b8400cc955d8bba75dcc329cb0e75d0.tar.gz
toolchain_gcc-e86367917b8400cc955d8bba75dcc329cb0e75d0.tar.bz2
toolchain_gcc-e86367917b8400cc955d8bba75dcc329cb0e75d0.zip
[4.9] LINK_SPEC changes for Cortex-A53 erratum 835769 workaround
This is proted from upstream gcc-4_9 branch: svn r216979. Change-Id: I1cee530fb4f50843a9832aa678c1630f51564fa6
Diffstat (limited to 'gcc-4.9/gcc/config/aarch64')
-rw-r--r--gcc-4.9/gcc/config/aarch64/aarch64-elf-raw.h11
-rw-r--r--gcc-4.9/gcc/config/aarch64/aarch64-linux.h11
2 files changed, 20 insertions, 2 deletions
diff --git a/gcc-4.9/gcc/config/aarch64/aarch64-elf-raw.h b/gcc-4.9/gcc/config/aarch64/aarch64-elf-raw.h
index adec7e7ba..eafdd551d 100644
--- a/gcc-4.9/gcc/config/aarch64/aarch64-elf-raw.h
+++ b/gcc-4.9/gcc/config/aarch64/aarch64-elf-raw.h
@@ -25,9 +25,18 @@
#define STARTFILE_SPEC " crti%O%s crtbegin%O%s crt0%O%s"
#define ENDFILE_SPEC " crtend%O%s crtn%O%s"
+#ifdef TARGET_FIX_ERR_A53_835769_DEFAULT
+#define CA53_ERR_835769_SPEC \
+ " %{!mno-fix-cortex-a53-835769:--fix-cortex-a53-835769}"
+#else
+#define CA53_ERR_835769_SPEC \
+ " %{mfix-cortex-a53-835769:--fix-cortex-a53-835769}"
+#endif
+
#ifndef LINK_SPEC
#define LINK_SPEC "%{mbig-endian:-EB} %{mlittle-endian:-EL} -X \
- -maarch64elf%{mabi=ilp32*:32}%{mbig-endian:b}"
+ -maarch64elf%{mabi=ilp32*:32}%{mbig-endian:b}" \
+ CA53_ERR_835769_SPEC
#endif
#endif /* GCC_AARCH64_ELF_RAW_H */
diff --git a/gcc-4.9/gcc/config/aarch64/aarch64-linux.h b/gcc-4.9/gcc/config/aarch64/aarch64-linux.h
index 3b191856d..09ae1cfc0 100644
--- a/gcc-4.9/gcc/config/aarch64/aarch64-linux.h
+++ b/gcc-4.9/gcc/config/aarch64/aarch64-linux.h
@@ -40,7 +40,16 @@
%{mbig-endian:-EB} %{mlittle-endian:-EL} \
-maarch64linux%{mbig-endian:b}"
-#define LINK_SPEC LINUX_TARGET_LINK_SPEC
+#ifdef TARGET_FIX_ERR_A53_835769_DEFAULT
+#define CA53_ERR_835769_SPEC \
+ " %{!mno-fix-cortex-a53-835769:--fix-cortex-a53-835769}"
+#else
+#define CA53_ERR_835769_SPEC \
+ " %{mfix-cortex-a53-835769:--fix-cortex-a53-835769}"
+#endif
+
+#define LINK_SPEC LINUX_TARGET_LINK_SPEC \
+ CA53_ERR_835769_SPEC
#define TARGET_OS_CPP_BUILTINS() \
do \