summaryrefslogtreecommitdiff
path: root/libc/test/src/math/smoke/scalbnbf16_test.cpp
diff options
context:
space:
mode:
authorKrishna Pandey <kpandey81930@gmail.com>2025-08-28 20:29:03 +0530
committerGitHub <noreply@github.com>2025-08-28 20:29:03 +0530
commita985be6fdfe3aa3453b351dcbc61453b6f78fab5 (patch)
tree89d594c5644b72fc845e2fc2f4477a5666ba0911 /libc/test/src/math/smoke/scalbnbf16_test.cpp
parent9cf8752ccfd194c3fa1cda641db2e3c77aa4915c (diff)
[libc][math][c++23] Add scalb{,l}nbf16 math functions (#155569)
This PR adds the following basic math functions for BFloat16 type along with the tests: - scalbnbf16 - scalblnbf16 --------- Signed-off-by: Krishna Pandey <kpandey81930@gmail.com>
Diffstat (limited to 'libc/test/src/math/smoke/scalbnbf16_test.cpp')
-rw-r--r--libc/test/src/math/smoke/scalbnbf16_test.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/libc/test/src/math/smoke/scalbnbf16_test.cpp b/libc/test/src/math/smoke/scalbnbf16_test.cpp
new file mode 100644
index 000000000000..855fd75e6e8f
--- /dev/null
+++ b/libc/test/src/math/smoke/scalbnbf16_test.cpp
@@ -0,0 +1,14 @@
+//===-- Unittests for scalbnbf16 ------------------------------------------===//
+//
+// 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 "ScalbnTest.h"
+
+#include "src/__support/FPUtil/bfloat16.h"
+#include "src/math/scalbnbf16.h"
+
+LIST_SCALBN_TESTS(bfloat16, int, LIBC_NAMESPACE::scalbnbf16)