[compiler-rt] [builtins] Guard the divtc3_test.c test with CRT_HAS_TF_MODE (PR #71876)

Amara Emerson via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 9 15:13:01 PST 2023


https://github.com/aemerson created https://github.com/llvm/llvm-project/pull/71876

The bots on https://green.lab.llvm.org/green/job/clang-stage1-RA/ were
failing this test.


>From b073e46a185cabbd82fe595a0c4928fe6df5a263 Mon Sep 17 00:00:00 2001
From: Amara Emerson <amara at apple.com>
Date: Thu, 9 Nov 2023 15:10:29 -0800
Subject: [PATCH] [builtins] Guard the divtc3_test.c test with CRT_HAS_TF_MODE

The bots on https://green.lab.llvm.org/green/job/clang-stage1-RA/ were
failing this test.
---
 compiler-rt/test/builtins/Unit/divtc3_test.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/compiler-rt/test/builtins/Unit/divtc3_test.c b/compiler-rt/test/builtins/Unit/divtc3_test.c
index 9ba4880f4a11027..33a7f869432f352 100644
--- a/compiler-rt/test/builtins/Unit/divtc3_test.c
+++ b/compiler-rt/test/builtins/Unit/divtc3_test.c
@@ -14,6 +14,7 @@
 #include <math.h>
 
 // Returns: the quotient of (a + ib) / (c + id)
+#if defined(CRT_HAS_TF_MODE)
 
 COMPILER_RT_ABI Qcomplex __divtc3(tf_float __a, tf_float __b, tf_float __c,
                                   tf_float __d);
@@ -363,3 +364,12 @@ int main() {
   fprintf(stderr, "No errors found.\n");
   return 0;
 }
+
+#else
+
+int main() {
+  printf("skipped\n");
+  return 0;
+}
+
+#endif // CRT_HAS_TF_MODE



More information about the llvm-commits mailing list