Skip to content

Commit 613a09d

Browse files
authored
[builtins][NFC] Avoid using CRT_LDBL_128BIT in tests (#66832)
https://reviews.llvm.org/D153812 removed this macro from implementations. Clean this up from tests as well.
1 parent b927490 commit 613a09d

File tree

5 files changed

+10
-10
lines changed

5 files changed

+10
-10
lines changed

compiler-rt/test/builtins/Unit/compiler_rt_fmaxl_test.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#include <stdio.h>
77
#include "fp_lib.h"
88

9-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
9+
#if defined(CRT_HAS_TF_MODE)
1010

1111
int test__compiler_rt_fmaxl(fp_t x, fp_t y) {
1212
fp_t crt_value = __compiler_rt_fmaxl(x, y);
@@ -43,7 +43,7 @@ fp_t cases[] = {
4343
#endif
4444

4545
int main() {
46-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
46+
#if defined(CRT_HAS_TF_MODE)
4747
const unsigned N = sizeof(cases) / sizeof(cases[0]);
4848
unsigned i, j;
4949
for (i = 0; i < N; ++i) {

compiler-rt/test/builtins/Unit/compiler_rt_logbl_test.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#include "fp_lib.h"
77
#include "int_lib.h"
88

9-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
9+
#if defined(CRT_HAS_TF_MODE)
1010

1111
int test__compiler_rt_logbl(fp_t x) {
1212
#if defined(__ve__)
@@ -42,7 +42,7 @@ double cases[] = {
4242
#endif
4343

4444
int main() {
45-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
45+
#if defined(CRT_HAS_TF_MODE)
4646
const unsigned N = sizeof(cases) / sizeof(cases[0]);
4747
unsigned i;
4848
for (i = 0; i < N; ++i) {

compiler-rt/test/builtins/Unit/compiler_rt_scalbnl_test.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#include <stdio.h>
99
#include "fp_lib.h"
1010

11-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
11+
#if defined(CRT_HAS_TF_MODE)
1212

1313
int test__compiler_rt_scalbnl(const char *mode, fp_t x, int y) {
1414
#if defined(__ve__)
@@ -67,7 +67,7 @@ int iterate_cases(const char *mode) {
6767
#endif
6868

6969
int main() {
70-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
70+
#if defined(CRT_HAS_TF_MODE)
7171
if (iterate_cases("default")) return 1;
7272

7373
// Skip rounding mode tests (fesetround) because compiler-rt's quad-precision

compiler-rt/test/builtins/Unit/floattitf_test.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#include <float.h>
88
#include <stdio.h>
99

10-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
10+
#if defined(CRT_HAS_TF_MODE)
1111

1212
/* Returns: convert a ti_int to a fp_t, rounding toward even. */
1313

@@ -39,7 +39,7 @@ char assumption_3[sizeof(fp_t) * CHAR_BIT == 128] = {0};
3939
#endif
4040

4141
int main() {
42-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
42+
#if defined(CRT_HAS_TF_MODE)
4343
if (test__floattitf(0, 0.0))
4444
return 1;
4545

compiler-rt/test/builtins/Unit/floatuntitf_test.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#include <float.h>
88
#include <stdio.h>
99

10-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
10+
#if defined(CRT_HAS_TF_MODE)
1111

1212
/* Returns: convert a tu_int to a fp_t, rounding toward even. */
1313

@@ -39,7 +39,7 @@ char assumption_3[sizeof(fp_t) * CHAR_BIT == 128] = {0};
3939
#endif
4040

4141
int main() {
42-
#if defined(CRT_HAS_128BIT) && defined(CRT_LDBL_128BIT)
42+
#if defined(CRT_HAS_TF_MODE)
4343
if (test__floatuntitf(0, 0.0))
4444
return 1;
4545

0 commit comments

Comments
 (0)