Skip to content

Commit ef38799

Browse files
committed
[libc][math][c23] Add MPFR unit test for f16sqrtf
1 parent db9252b commit ef38799

File tree

2 files changed

+26
-0
lines changed

2 files changed

+26
-0
lines changed

libc/test/src/math/CMakeLists.txt

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2005,6 +2005,19 @@ add_fp_unittest(
20052005
libc.src.math.f16sqrt
20062006
)
20072007

2008+
add_fp_unittest(
2009+
f16sqrtf_test
2010+
NEED_MPFR
2011+
SUITE
2012+
libc-math-unittests
2013+
SRCS
2014+
f16sqrtf_test.cpp
2015+
HDRS
2016+
SqrtTest.h
2017+
DEPENDS
2018+
libc.src.math.f16sqrtf
2019+
)
2020+
20082021
add_fp_unittest(
20092022
f16sqrtl_test
20102023
NEED_MPFR

libc/test/src/math/f16sqrtf_test.cpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
//===-- Unittests for f16sqrtf --------------------------------------------===//
2+
//
3+
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+
// See https://llvm.org/LICENSE.txt for license information.
5+
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+
//
7+
//===----------------------------------------------------------------------===//
8+
9+
#include "SqrtTest.h"
10+
11+
#include "src/math/f16sqrtf.h"
12+
13+
LIST_NARROWING_SQRT_TESTS(float16, float, LIBC_NAMESPACE::f16sqrtf)

0 commit comments

Comments
 (0)