Skip to content

Commit

Permalink
[PowerPC] Exclude frexp(long double) on linux
Browse files Browse the repository at this point in the history
PowerPC on linux currently don't have support for lowering long double for
frexp().  Removing the tests until implementation is provided.

Reviewed By: #libc, amyk, Mordante

Differential Revision: https://reviews.llvm.org/D158547
  • Loading branch information
lei137 committed Aug 25, 2023
1 parent 04e6178 commit 5adac8b
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,15 @@ int main(int, char**) {

ASSERT_NOT_CONSTEXPR_CXX23(std::frexp(0.0f, &DummyInt) == 0.0f);
ASSERT_NOT_CONSTEXPR_CXX23(std::frexp(0.0, &DummyInt) == 0.0);
//FIXME: currently linux powerpc does not support this expansion
// since 0.0L lowers to ppcf128 and special handling is required.
#if !defined(__LONG_DOUBLE_IBM128__)
ASSERT_NOT_CONSTEXPR_CXX23(std::frexp(0.0L, &DummyInt) == 0.0L);
#endif
ASSERT_NOT_CONSTEXPR_CXX23(std::frexpf(0.0f, &DummyInt) == 0.0f);
#if !defined(__LONG_DOUBLE_IBM128__)
ASSERT_NOT_CONSTEXPR_CXX23(std::frexpl(0.0L, &DummyInt) == 0.0L);
#endif

ASSERT_NOT_CONSTEXPR_CXX23(std::ilogb(1.0f) == 0);
ASSERT_NOT_CONSTEXPR_CXX23(std::ilogb(1.0) == 0);
Expand Down

0 comments on commit 5adac8b

Please sign in to comment.