Daniel Dunbar | 4467b65 | 2009-10-27 17:48:46 +0000 | [diff] [blame] | 1 | /* ===-- int_lib.h - configuration header for compiler-rt -----------------=== |
Edward O'Callaghan | 0e4ad9c | 2009-08-05 01:47:29 +0000 | [diff] [blame] | 2 | * |
| 3 | * The LLVM Compiler Infrastructure |
| 4 | * |
Howard Hinnant | 9ad441f | 2010-11-16 22:13:33 +0000 | [diff] [blame] | 5 | * This file is dual licensed under the MIT and the University of Illinois Open |
| 6 | * Source Licenses. See LICENSE.TXT for details. |
Edward O'Callaghan | 0e4ad9c | 2009-08-05 01:47:29 +0000 | [diff] [blame] | 7 | * |
| 8 | * ===----------------------------------------------------------------------=== |
| 9 | * |
Daniel Dunbar | 4467b65 | 2009-10-27 17:48:46 +0000 | [diff] [blame] | 10 | * This file is a configuration header for compiler-rt. |
Edward O'Callaghan | 0e4ad9c | 2009-08-05 01:47:29 +0000 | [diff] [blame] | 11 | * This file is not part of the interface of this library. |
| 12 | * |
| 13 | * ===----------------------------------------------------------------------=== |
| 14 | */ |
Daniel Dunbar | b3a6901 | 2009-06-26 16:47:03 +0000 | [diff] [blame] | 15 | |
| 16 | #ifndef INT_LIB_H |
| 17 | #define INT_LIB_H |
| 18 | |
Daniel Dunbar | 0a3e350 | 2011-11-15 18:56:21 +0000 | [diff] [blame] | 19 | /* Assumption: Signed integral is 2's complement. */ |
| 20 | /* Assumption: Right shift of signed negative is arithmetic shift. */ |
| 21 | /* Assumption: Endianness is little or big (not mixed). */ |
| 22 | |
Daniel Dunbar | 0ae9d25 | 2011-11-15 18:34:44 +0000 | [diff] [blame] | 23 | /* ABI macro definitions */ |
| 24 | |
| 25 | #if __ARM_EABI__ |
| 26 | # define ARM_EABI_FNALIAS(aeabi_name, name) \ |
| 27 | void __aeabi_##aeabi_name() __attribute__((alias("__" #name))); |
| 28 | # define COMPILER_RT_ABI __attribute__((pcs("aapcs"))) |
| 29 | #else |
| 30 | # define ARM_EABI_FNALIAS(aeabi_name, name) |
| 31 | # define COMPILER_RT_ABI |
| 32 | #endif |
| 33 | |
Daniel Dunbar | 2bf9340 | 2011-11-16 00:20:36 +0000 | [diff] [blame] | 34 | /* Include the standard compiler builtin headers we use functionality from. */ |
Daniel Dunbar | b3a6901 | 2009-06-26 16:47:03 +0000 | [diff] [blame] | 35 | #include <limits.h> |
Nick Kledzik | c31717b | 2011-01-07 19:09:06 +0000 | [diff] [blame] | 36 | #include <stdint.h> |
Daniel Dunbar | 23d1542 | 2011-11-15 19:02:22 +0000 | [diff] [blame] | 37 | #include <stdbool.h> |
Daniel Dunbar | 2bf9340 | 2011-11-16 00:20:36 +0000 | [diff] [blame] | 38 | #include <float.h> |
| 39 | |
Daniel Dunbar | 396a72f | 2011-11-15 18:56:13 +0000 | [diff] [blame] | 40 | /* Include the commonly used internal type definitions. */ |
| 41 | #include "int_types.h" |
Daniel Dunbar | b3a6901 | 2009-06-26 16:47:03 +0000 | [diff] [blame] | 42 | |
Daniel Dunbar | 401f693 | 2011-11-16 01:19:19 +0000 | [diff] [blame] | 43 | /* Include internal utility function declarations. */ |
| 44 | #include "int_util.h" |
| 45 | |
Edward O'Callaghan | 0898ee9 | 2009-08-05 19:57:20 +0000 | [diff] [blame] | 46 | #endif /* INT_LIB_H */ |