This is the mail archive of the
libc-ports@sources.redhat.com
mailing list for the libc-ports project.
[PATCH 12/26] arm: Enable thumb2 mode in assembly files
- From: Richard Henderson <rth at twiddle dot net>
- To: libc-ports at sourceware dot org
- Cc: Joseph Myers <joseph at codesourcery dot com>
- Date: Tue, 26 Feb 2013 19:16:12 -0800
- Subject: [PATCH 12/26] arm: Enable thumb2 mode in assembly files
- References: <1361934986-17018-1-git-send-email-rth@twiddle.net>
The preceeding patches have allowed for the few incompatibilities
between arm and thumb2 mode, or have marked the file as not wanting
to use thumb2 mode.
Note that one still has to edit config.make in the build directory
to add ASFLAGS to add -mthumb...
---
* sysdeps/arm/sysdep.h [__ASSEMBLER__]: Enable thumb2 if __thumb2__.
---
ports/sysdeps/arm/sysdep.h | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/ports/sysdeps/arm/sysdep.h b/ports/sysdeps/arm/sysdep.h
index 2d40823..3459219 100644
--- a/ports/sysdeps/arm/sysdep.h
+++ b/ports/sysdeps/arm/sysdep.h
@@ -114,6 +114,17 @@
the caller. */
.eabi_attribute 24, 1
+/* The thumb2 encoding is reasonably complete. Unless suppressed, use it. */
+#ifdef NO_THUMB
+# undef __thumb__
+# undef __thumb2__
+ .arm
+#endif
+#ifdef __thumb2__
+ .syntax unified
+ .thumb
+#endif
+
/* We occasionally want to use the S form simply to achieve a smaller
instruction form in Thumb mode. Never set the flags in ARM mode. */
#ifdef __thumb__
--
1.8.1.2