aboutsummaryrefslogtreecommitdiff
path: root/libc/test/src
diff options
context:
space:
mode:
Diffstat (limited to 'libc/test/src')
-rw-r--r--libc/test/src/math/smoke/CMakeLists.txt30
-rw-r--r--libc/test/src/math/smoke/fmaxbf16_test.cpp14
-rw-r--r--libc/test/src/math/smoke/fminbf16_test.cpp14
3 files changed, 58 insertions, 0 deletions
diff --git a/libc/test/src/math/smoke/CMakeLists.txt b/libc/test/src/math/smoke/CMakeLists.txt
index dc1850a..f060ef3 100644
--- a/libc/test/src/math/smoke/CMakeLists.txt
+++ b/libc/test/src/math/smoke/CMakeLists.txt
@@ -2347,6 +2347,21 @@ add_fp_unittest(
)
add_fp_unittest(
+ fminbf16_test
+ SUITE
+ libc-math-smoke-tests
+ SRCS
+ fminbf16_test.cpp
+ HDRS
+ FMinTest.h
+ DEPENDS
+ libc.src.math.fminbf16
+ libc.src.__support.CPP.algorithm
+ libc.src.__support.FPUtil.bfloat16
+ libc.src.__support.FPUtil.fp_bits
+)
+
+add_fp_unittest(
fmaxf_test
SUITE
libc-math-smoke-tests
@@ -2417,6 +2432,21 @@ add_fp_unittest(
)
add_fp_unittest(
+ fmaxbf16_test
+ SUITE
+ libc-math-smoke-tests
+ SRCS
+ fmaxbf16_test.cpp
+ HDRS
+ FMaxTest.h
+ DEPENDS
+ libc.src.math.fmaxbf16
+ libc.src.__support.CPP.algorithm
+ libc.src.__support.FPUtil.bfloat16
+ libc.src.__support.FPUtil.fp_bits
+)
+
+add_fp_unittest(
fmaximuml_test
SUITE
libc-math-smoke-tests
diff --git a/libc/test/src/math/smoke/fmaxbf16_test.cpp b/libc/test/src/math/smoke/fmaxbf16_test.cpp
new file mode 100644
index 0000000..8ff9313
--- /dev/null
+++ b/libc/test/src/math/smoke/fmaxbf16_test.cpp
@@ -0,0 +1,14 @@
+//===-- Unittests for fmaxbf16 --------------------------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+
+#include "FMaxTest.h"
+
+#include "src/__support/FPUtil/bfloat16.h"
+#include "src/math/fmaxbf16.h"
+
+LIST_FMAX_TESTS(bfloat16, LIBC_NAMESPACE::fmaxbf16)
diff --git a/libc/test/src/math/smoke/fminbf16_test.cpp b/libc/test/src/math/smoke/fminbf16_test.cpp
new file mode 100644
index 0000000..195a0ac
--- /dev/null
+++ b/libc/test/src/math/smoke/fminbf16_test.cpp
@@ -0,0 +1,14 @@
+//===-- Unittests for fminbf16 --------------------------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+
+#include "FMinTest.h"
+
+#include "src/__support/FPUtil/bfloat16.h"
+#include "src/math/fminbf16.h"
+
+LIST_FMIN_TESTS(bfloat16, LIBC_NAMESPACE::fminbf16)