Config.h revision ce73d6f365394883dd23b1da97135e4002e784e0
1#ifndef BCC_CONFIG_CONFIG_H 2#define BCC_CONFIG_CONFIG_H 3 4//--------------------------------------------------------------------------- 5// Configuration for Disassembler 6//--------------------------------------------------------------------------- 7 8#if DEBUG_MC_DISASSEMBLER 9#define USE_DISASSEMBLER 1 10#else 11#define USE_DISASSEMBLER 0 12#endif 13 14#if defined(__HOST__) 15#define DEBUG_DISASSEMBLER_FILE "/tmp/mc-dis.s" 16#else 17#define DEBUG_DISASSEMBLER_FILE "/data/local/tmp/mc-dis.s" 18#endif // defined(__HOST__) 19 20//--------------------------------------------------------------------------- 21// Configuration for CodeGen and CompilerRT 22//--------------------------------------------------------------------------- 23 24#if defined(FORCE_ARM_CODEGEN) 25 #define PROVIDE_ARM_CODEGEN 26 #define DEFAULT_ARM_CODEGEN 27 28#elif defined(FORCE_ARM64_CODEGEN) 29 #define PROVIDE_ARM_CODEGEN 30 #define PROVIDE_ARM64_CODEGEN 31 #define DEFAULT_ARM64_CODEGEN 32 33#elif defined(FORCE_MIPS_CODEGEN) 34 #define PROVIDE_MIPS_CODEGEN 35 #define DEFAULT_MIPS_CODEGEN 36 37#elif defined(FORCE_X86_CODEGEN) 38 #define PROVIDE_X86_CODEGEN 39 40 #if defined(__i386__) 41 #define DEFAULT_X86_CODEGEN 42 #elif defined(__x86_64__) 43 #define DEFAULT_X86_64_CODEGEN 44 #endif 45 46#else 47 #define PROVIDE_ARM_CODEGEN 48 #define PROVIDE_ARM64_CODEGEN 49 #define PROVIDE_MIPS_CODEGEN 50 #define PROVIDE_X86_CODEGEN 51 52 #if defined(__arm__) 53 #define DEFAULT_ARM_CODEGEN 54 #elif defined(__arch64__) 55 #define DEFAULT_ARM64_CODEGEN 56 #elif defined(__mips__) 57 #define DEFAULT_MIPS_CODEGEN 58 #elif defined(__i386__) 59 #define DEFAULT_X86_CODEGEN 60 #elif defined(__x86_64__) 61 #define DEFAULT_X86_64_CODEGEN 62 #endif 63#endif 64 65#define DEFAULT_ARM_TRIPLE_STRING "armv7-none-linux-gnueabi" 66#define DEFAULT_THUMB_TRIPLE_STRING "thumbv7-none-linux-gnueabi" 67#define DEFAULT_ARM64_TRIPLE_STRING "aarch64-none-linux-gnueabi" 68#define DEFAULT_MIPS_TRIPLE_STRING "mipsel-none-linux-gnueabi" 69#define DEFAULT_X86_TRIPLE_STRING "i686-unknown-linux" 70#define DEFAULT_X86_64_TRIPLE_STRING "x86_64-unknown-linux" 71 72#if defined(DEFAULT_ARM_CODEGEN) 73 #define DEFAULT_TARGET_TRIPLE_STRING DEFAULT_ARM_TRIPLE_STRING 74#elif defined(DEFAULT_ARM64_CODEGEN) 75 #define DEFAULT_TARGET_TRIPLE_STRING DEFAULT_ARM64_TRIPLE_STRING 76#elif defined(DEFAULT_MIPS_CODEGEN) 77 #define DEFAULT_TARGET_TRIPLE_STRING DEFAULT_MIPS_TRIPLE_STRING 78#elif defined(DEFAULT_X86_CODEGEN) 79 #define DEFAULT_TARGET_TRIPLE_STRING DEFAULT_X86_TRIPLE_STRING 80#elif defined(DEFAULT_X86_64_CODEGEN) 81 #define DEFAULT_TARGET_TRIPLE_STRING DEFAULT_X86_64_TRIPLE_STRING 82#endif 83 84#if (defined(__VFP_FP__) && !defined(__SOFTFP__)) 85 #define ARM_USE_VFP 86#endif 87 88//--------------------------------------------------------------------------- 89 90#endif // BCC_CONFIG_CONFIG_H 91