From 9966fd4eaea163439a63d63d044d0657df1908ea Mon Sep 17 00:00:00 2001 From: Thomas Preud'homme Date: Tue, 16 Oct 2012 00:31:56 +0200 Subject: Only use blx if available Introduce ARM version for the target architecture in order to determine if blx instruction can be used or not. Availability of blx instruction allows for more scenarii supported in R_ARM_CALL relocation. It should also be useful when introducing support for the R_ARM_THM_CALL relocation. --- tcc.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'tcc.h') diff --git a/tcc.h b/tcc.h index 8bca9ae..4e88782 100644 --- a/tcc.h +++ b/tcc.h @@ -105,6 +105,14 @@ #define TCC_TARGET_I386 #endif +#if defined (TCC_TARGET_ARM) && !defined(TCC_ARM_VERSION) + #ifdef TCC_ARM_HARDFLOAT + #define TCC_ARM_VERSION 7 + #else + #define TCC_ARM_VERSION 4 + #endif +#endif + #if !defined(TCC_UCLIBC) && !defined(TCC_TARGET_ARM) && \ !defined(TCC_TARGET_C67) && !defined(TCC_TARGET_X86_64) #define CONFIG_TCC_BCHECK /* enable bound checking code */ -- cgit v1.3.1