This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[arm] libfuncs1 and armv6
- From: Paul Brook <paul at codesourcery dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: Richard Earnshaw <rearnsha at arm dot com>
- Date: Wed, 28 Apr 2004 01:06:36 +0100
- Subject: [arm] libfuncs1 and armv6
- Organization: CodeSourcery
The following patch teaches libfuncs1.asm about the armv5e, armv5tej and armv6
architectures. These are equivalent to armv5[t] for these purposes.
Tested with cross to arm-none-elf and corresponding -march=
Ok?
Paul
2004-04-28 Paul Brook <paul@codesourcery.com>
* config/arm/lib1funcs.asm: Recognize armv5tej and armv6.
Index: lib1funcs.asm
===================================================================
RCS file: /var/cvsroot/gcc-cvs/gcc/gcc/config/arm/lib1funcs.asm,v
retrieving revision 1.28
diff -u -p -r1.28 lib1funcs.asm
--- a/lib1funcs.asm 3 Feb 2004 14:44:11 -0000 1.28
+++ b/lib1funcs.asm 27 Apr 2004 22:06:32 -0000
@@ -74,11 +74,17 @@ Boston, MA 02111-1307, USA. */
#endif
#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) \
- || defined(__ARM_ARCH_5TE__)
+ || defined(__ARM_ARCH_5E__) || defined(__ARM_ARCH_5TE__) \
+ || defined(__ARM_ARCH_5TEJ__)
# undef __ARM_ARCH__
# define __ARM_ARCH__ 5
#endif
+#if defined(__ARM_ARCH_6J__)
+# undef __ARM_ARCH__
+# define __ARM_ARCH__ 6
+#endif
+
/* How to return from a function call depends on the architecture variant.
*/
#ifdef __APCS_26__
@@ -876,7 +882,11 @@ LSYM(Lover12):
/* Do not build the interworking functions when the target architecture does
not support Thumb instructions. (This can be a multilib option). */
-#if defined L_call_via_rX && (defined __ARM_ARCH_4T__ || defined
__ARM_ARCH_5T__ || defined __ARM_ARCH_5TE__)
+#if defined __ARM_ARCH_4T__ || defined __ARM_ARCH_5T__\
+ || defined __ARM_ARCH_5TE__ || defined __ARM_ARCH_5TEJ__ \
+ || __ARM_ARCH__ >= 6
+
+#if defined L_call_via_rX
/* These labels & instructions are used by the Arm/Thumb interworking code.
The address of function to be called is loaded into a register and then
@@ -914,10 +924,8 @@ LSYM(Lover12):
call_via lr
#endif /* L_call_via_rX */
-/* ------------------------------------------------------------------------
*/
-/* Do not build the interworking functions when the target architecture does
- not support Thumb instructions. (This can be a multilib option). */
-#if defined L_interwork_call_via_rX && (defined __ARM_ARCH_4T__ || defined
__ARM_ARCH_5T__ || defined __ARM_ARCH_5TE__)
+
+#if defined L_interwork_call_via_rX
/* These labels & instructions are used by the Arm/Thumb interworking code,
when the target address is in an unknown instruction set. The address
@@ -993,6 +1001,7 @@ LSYM(Lchange_\register):
SIZE (_interwork_call_via_lr)
#endif /* L_interwork_call_via_rX */
+#endif /* Arch supports thumb. */
#include "ieee754-df.S"
#include "ieee754-sf.S"