mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-07 21:33:54 +00:00
chore(compiler-rt): update compiler-rt source files
Update the compiler-rt source files to the tip of llvm-project [1] on 9th May 2024, sha 673cfcd03b7b938b422fee07d8ca4a127d480b1f [1] https://github.com/llvm/llvm-project Signed-off-by: Manish Pandey <manish.pandey2@arm.com> Change-Id: I19f2b8ea6676d365780783f902003b0e95f0f606
This commit is contained in:
parent
69c4bf9ae3
commit
3a965bb372
3 changed files with 17 additions and 14 deletions
|
@ -260,9 +260,10 @@
|
|||
.globl name SEPARATOR \
|
||||
SYMBOL_IS_FUNC(name) SEPARATOR \
|
||||
DECLARE_SYMBOL_VISIBILITY_UNMANGLED(name) SEPARATOR \
|
||||
CFI_START SEPARATOR \
|
||||
DECLARE_FUNC_ENCODING \
|
||||
name: SEPARATOR BTI_C
|
||||
name: \
|
||||
SEPARATOR CFI_START \
|
||||
SEPARATOR BTI_C
|
||||
|
||||
#define DEFINE_COMPILERRT_FUNCTION_ALIAS(name, target) \
|
||||
.globl SYMBOL_NAME(name) SEPARATOR \
|
||||
|
|
|
@ -119,14 +119,14 @@ COMPILER_RT_ABI tu_int __udivmodti4(tu_int a, tu_int b, tu_int *rem);
|
|||
#if defined(_MSC_VER) && !defined(__clang__)
|
||||
#include <intrin.h>
|
||||
|
||||
int __inline __builtin_ctz(uint32_t value) {
|
||||
static int __inline __builtin_ctz(uint32_t value) {
|
||||
unsigned long trailing_zero = 0;
|
||||
if (_BitScanForward(&trailing_zero, value))
|
||||
return trailing_zero;
|
||||
return 32;
|
||||
}
|
||||
|
||||
int __inline __builtin_clz(uint32_t value) {
|
||||
static int __inline __builtin_clz(uint32_t value) {
|
||||
unsigned long leading_zero = 0;
|
||||
if (_BitScanReverse(&leading_zero, value))
|
||||
return 31 - leading_zero;
|
||||
|
@ -134,14 +134,14 @@ int __inline __builtin_clz(uint32_t value) {
|
|||
}
|
||||
|
||||
#if defined(_M_ARM) || defined(_M_X64)
|
||||
int __inline __builtin_clzll(uint64_t value) {
|
||||
static int __inline __builtin_clzll(uint64_t value) {
|
||||
unsigned long leading_zero = 0;
|
||||
if (_BitScanReverse64(&leading_zero, value))
|
||||
return 63 - leading_zero;
|
||||
return 64;
|
||||
}
|
||||
#else
|
||||
int __inline __builtin_clzll(uint64_t value) {
|
||||
static int __inline __builtin_clzll(uint64_t value) {
|
||||
if (value == 0)
|
||||
return 64;
|
||||
uint32_t msh = (uint32_t)(value >> 32);
|
||||
|
@ -154,7 +154,7 @@ int __inline __builtin_clzll(uint64_t value) {
|
|||
|
||||
#define __builtin_clzl __builtin_clzll
|
||||
|
||||
bool __inline __builtin_sadd_overflow(int x, int y, int *result) {
|
||||
static bool __inline __builtin_sadd_overflow(int x, int y, int *result) {
|
||||
if ((x < 0) != (y < 0)) {
|
||||
*result = x + y;
|
||||
return false;
|
||||
|
|
|
@ -107,8 +107,8 @@ typedef union {
|
|||
|
||||
static __inline ti_int make_ti(di_int h, di_int l) {
|
||||
twords r;
|
||||
r.s.high = h;
|
||||
r.s.low = l;
|
||||
r.s.high = (du_int)h;
|
||||
r.s.low = (du_int)l;
|
||||
return r.all;
|
||||
}
|
||||
|
||||
|
@ -139,7 +139,6 @@ typedef union {
|
|||
udwords u;
|
||||
double f;
|
||||
} double_bits;
|
||||
#endif
|
||||
|
||||
typedef struct {
|
||||
#if _YUGA_LITTLE_ENDIAN
|
||||
|
@ -190,12 +189,16 @@ typedef long double tf_float;
|
|||
#define CRT_LDBL_IEEE_F128
|
||||
#endif
|
||||
#define TF_C(x) x##L
|
||||
#elif __LDBL_MANT_DIG__ == 113
|
||||
// Use long double instead of __float128 if it matches the IEEE 128-bit format.
|
||||
#elif __LDBL_MANT_DIG__ == 113 || \
|
||||
(__FLT_RADIX__ == 16 && __LDBL_MANT_DIG__ == 28)
|
||||
// Use long double instead of __float128 if it matches the IEEE 128-bit format
|
||||
// or the IBM hexadecimal format.
|
||||
#define CRT_LDBL_128BIT
|
||||
#define CRT_HAS_F128
|
||||
#if __LDBL_MANT_DIG__ == 113
|
||||
#define CRT_HAS_IEEE_TF
|
||||
#define CRT_LDBL_IEEE_F128
|
||||
#endif
|
||||
typedef long double tf_float;
|
||||
#define TF_C(x) x##L
|
||||
#elif defined(__FLOAT128__) || defined(__SIZEOF_FLOAT128__)
|
||||
|
@ -220,7 +223,6 @@ typedef union {
|
|||
#define CRT_HAS_TF_MODE
|
||||
#endif
|
||||
|
||||
#if CRT_HAS_FLOATING_POINT
|
||||
#if __STDC_VERSION__ >= 199901L
|
||||
typedef float _Complex Fcomplex;
|
||||
typedef double _Complex Dcomplex;
|
||||
|
@ -270,5 +272,5 @@ typedef struct {
|
|||
#define COMPLEXTF_IMAGINARY(x) (x).imaginary
|
||||
#endif
|
||||
|
||||
#endif
|
||||
#endif // CRT_HAS_FLOATING_POINT
|
||||
#endif // INT_TYPES_H
|
||||
|
|
Loading…
Add table
Reference in a new issue