File tree 2 files changed +4
-3
lines changed 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 17
17
#include " src/__support/CPP/bit.h"
18
18
#include " src/__support/CPP/type_traits.h"
19
19
#include " src/__support/common.h"
20
+ #include " src/__support/macros/attributes.h"
20
21
21
22
#include < limits.h>
22
23
#include < math.h>
@@ -116,10 +117,10 @@ LIBC_INLINE T logb(T x) {
116
117
117
118
template <typename T, cpp::enable_if_t <cpp::is_floating_point_v<T>, int > = 0 >
118
119
LIBC_INLINE T ldexp (T x, int exp) {
119
- if (unlikely (exp == 0 ))
120
+ if (LIBC_UNLIKELY (exp == 0 ))
120
121
return x;
121
122
FPBits<T> bits (x);
122
- if (unlikely (bits.is_zero () || bits.is_inf_or_nan ()))
123
+ if (LIBC_UNLIKELY (bits.is_zero () || bits.is_inf_or_nan ()))
123
124
return x;
124
125
125
126
// NormalFloat uses int32_t to store the true exponent value. We should ensure
Original file line number Diff line number Diff line change 10
10
#define LLVM_LIBC_TEST_SRC_MATH_SCALBN_H
11
11
12
12
#include " LdExpTest.h"
13
- #include " utils /UnitTest/Test.h"
13
+ #include " test /UnitTest/Test.h"
14
14
15
15
#define LIST_SCALBN_TESTS (T, func ) \
16
16
using LlvmLibcScalbnTest = LdExpTestTemplate<T>; \
You can’t perform that action at this time.
0 commit comments