This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[ARM/FDPIC v6 23/24] [ARM] FDPIC: Implement libitm support.
- From: Christophe Lyon <christophe dot lyon at st dot com>
- To: <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 9 Sep 2019 17:45:05 +0200
- Subject: [ARM/FDPIC v6 23/24] [ARM] FDPIC: Implement libitm support.
- References: <20190909154526.11630-1-christophe.lyon@st.com>
From: Christophe Lyon <christophe.lyon@linaro.org>
The ldaddr macro in sjlj.S needs to be updated to support the FDPIC
model.
2019-XX-XX Christophe Lyon <christophe.lyon@st.com>
libitm/
* config/arm/sjlj.S (ldaddr): Add FDPIC support.
Change-Id: Ieb2c6613363341d109c3500af0575b133b17407d
diff --git a/libitm/config/arm/sjlj.S b/libitm/config/arm/sjlj.S
index a9abf16..5d44964 100644
--- a/libitm/config/arm/sjlj.S
+++ b/libitm/config/arm/sjlj.S
@@ -49,7 +49,16 @@
.arch armv7-m
#endif
-#if defined(HAVE_MOVT) && defined(PIC)
+#if defined(__FDPIC__)
+.macro ldaddr reg, addr
+ ldr \reg, 99f
+ add \reg, \reg, r9
+.subsection 1
+ .align 2
+99: .word \addr(GOTOFF)
+.subsection 0
+.endm
+#elif defined(HAVE_MOVT) && defined(PIC)
.macro ldaddr reg, addr
movw \reg, #:lower16:(\addr - (98f + PC_OFS))
movt \reg, #:upper16:(\addr - (98f + PC_OFS))
--
2.6.3