| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,148 @@ | ||
| //==- BuiltinsRISCV.td - RISC-V Builtin function database ---*- tablegen -*-==// | ||
| // | ||
| // 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 | ||
| // | ||
| //===----------------------------------------------------------------------===// | ||
| // | ||
| // This file defines the RISC-V-specific builtin function database. | ||
| // | ||
| //===----------------------------------------------------------------------===// | ||
|
|
||
| include "clang/Basic/BuiltinsBase.td" | ||
|
|
||
| class RISCVBuiltin<string prototype, string features = ""> : TargetBuiltin { | ||
| let Spellings = ["__builtin_riscv_" # NAME]; | ||
| let Prototype = prototype; | ||
| let Features = features; | ||
| } | ||
|
|
||
| let Attributes = [NoThrow, Const] in { | ||
| //===----------------------------------------------------------------------===// | ||
| // Zbb extension. | ||
| //===----------------------------------------------------------------------===// | ||
| def orc_b_32 : RISCVBuiltin<"unsigned int(unsigned int)", "zbb">; | ||
| def orc_b_64 : RISCVBuiltin<"uint64_t(uint64_t)", "zbb,64bit">; | ||
| def clz_32 : RISCVBuiltin<"unsigned int(unsigned int)", "zbb|xtheadbb">; | ||
| def clz_64 : RISCVBuiltin<"unsigned int(uint64_t)", "zbb|xtheadbb,64bit">; | ||
| def ctz_32 : RISCVBuiltin<"unsigned int(unsigned int)", "zbb">; | ||
| def ctz_64 : RISCVBuiltin<"unsigned int(uint64_t)", "zbb,64bit">; | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zbc or Zbkc extension. | ||
| //===----------------------------------------------------------------------===// | ||
| def clmul_32 : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)", "zbc|zbkc">; | ||
| def clmul_64 : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)", "zbc|zbkc,64bit">; | ||
| def clmulh_32 : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)", "zbc|zbkc,32bit">; | ||
| def clmulh_64 : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)", "zbc|zbkc,64bit">; | ||
| def clmulr_32 : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)", "zbc,32bit">; | ||
| def clmulr_64 : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)", "zbc,64bit">; | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zbkx extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zbkx,32bit" in { | ||
| def xperm4_32 : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| def xperm8_32 : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| } // Features = "zbkx,32bit" | ||
|
|
||
| let Features = "zbkx,64bit" in { | ||
| def xperm4_64 : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| def xperm8_64 : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| } // Features = "zbkx,64bit" | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zbkb extension. | ||
| //===----------------------------------------------------------------------===// | ||
| def brev8_32 : RISCVBuiltin<"unsigned int(unsigned int)", "zbkb">; | ||
| def brev8_64 : RISCVBuiltin<"uint64_t(uint64_t)", "zbkb,64bit">; | ||
| def zip_32 : RISCVBuiltin<"unsigned int(unsigned int)", "zbkb,32bit">; | ||
| def unzip_32 : RISCVBuiltin<"unsigned int(unsigned int)", "zbkb,32bit">; | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zknd extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zknd,32bit" in { | ||
| def aes32dsi : RISCVBuiltin<"unsigned int(unsigned int, unsigned int, _Constant unsigned int)">; | ||
| def aes32dsmi : RISCVBuiltin<"unsigned int(unsigned int, unsigned int, _Constant unsigned int)">; | ||
| } // Features = "zknd,32bit" | ||
|
|
||
| let Features = "zknd,64bit" in { | ||
| def aes64ds : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| def aes64dsm : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| def aes64im : RISCVBuiltin<"uint64_t(uint64_t)">; | ||
| } // Features = "zknd,64bit" | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zknd & Zkne extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zknd|zkne,64bit" in { | ||
| def aes64ks1i : RISCVBuiltin<"uint64_t(uint64_t, _Constant unsigned int)">; | ||
| def aes64ks2 : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| } // Features = "zknd|zkne,64bit" | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zkne extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zkne,32bit" in { | ||
| def aes32esi : RISCVBuiltin<"unsigned int(unsigned int, unsigned int, _Constant unsigned int)">; | ||
| def aes32esmi : RISCVBuiltin<"unsigned int(unsigned int, unsigned int, _Constant unsigned int)">; | ||
| } // Features = "zkne,32bit" | ||
|
|
||
| let Features = "zkne,64bit" in { | ||
| def aes64es : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| def aes64esm : RISCVBuiltin<"uint64_t(uint64_t, uint64_t)">; | ||
| } // Features = "zkne,64bit" | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zknh extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zknh" in { | ||
| def sha256sig0 : RISCVBuiltin<"unsigned int(unsigned int)">; | ||
| def sha256sig1 : RISCVBuiltin<"unsigned int(unsigned int)">; | ||
| def sha256sum0 : RISCVBuiltin<"unsigned int(unsigned int)">; | ||
| def sha256sum1 : RISCVBuiltin<"unsigned int(unsigned int)">; | ||
| } // Features = "zknh" | ||
|
|
||
| let Features = "zknh,32bit" in { | ||
| def sha512sig0h : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| def sha512sig0l : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| def sha512sig1h : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| def sha512sig1l : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| def sha512sum0r : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| def sha512sum1r : RISCVBuiltin<"unsigned int(unsigned int, unsigned int)">; | ||
| } // Features = "zknh,32bit" | ||
|
|
||
| let Features = "zknh,64bit" in { | ||
| def sha512sig0 : RISCVBuiltin<"uint64_t(uint64_t)">; | ||
| def sha512sig1 : RISCVBuiltin<"uint64_t(uint64_t)">; | ||
| def sha512sum0 : RISCVBuiltin<"uint64_t(uint64_t)">; | ||
| def sha512sum1 : RISCVBuiltin<"uint64_t(uint64_t)">; | ||
| } // Features = "zknh,64bit" | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zksed extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zksed" in { | ||
| def sm4ed : RISCVBuiltin<"unsigned int(unsigned int, unsigned int, _Constant unsigned int )">; | ||
| def sm4ks : RISCVBuiltin<"unsigned int(unsigned int, unsigned int, _Constant unsigned int)">; | ||
| } // Features = "zksed" | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zksh extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zksh" in { | ||
| def sm3p0 : RISCVBuiltin<"unsigned int(unsigned int)">; | ||
| def sm3p1 : RISCVBuiltin<"unsigned int(unsigned int)">; | ||
| } // Features = "zksh" | ||
|
|
||
| } // Attributes = [Const, NoThrow] | ||
|
|
||
| //===----------------------------------------------------------------------===// | ||
| // Zihintntl extension. | ||
| //===----------------------------------------------------------------------===// | ||
| let Features = "zihintntl", Attributes = [CustomTypeChecking] in { | ||
| def ntl_load : RISCVBuiltin<"void(...)">; | ||
| def ntl_store : RISCVBuiltin<"void(...)">; | ||
| } // Features = "zihintntl", Attributes = [CustomTypeChecking] |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -70,3 +70,5 @@ namespace dr1113 { // dr1113: partial | |
| } | ||
| void g() { f(); } | ||
| } | ||
|
|
||
| // dr1150: na | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| // RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK | ||
| // RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK,SINCE-CXX11 | ||
| // RUN: %clang_cc1 -std=c++14 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK,SINCE-CXX11 | ||
| // RUN: %clang_cc1 -std=c++17 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK,SINCE-CXX11 | ||
| // RUN: %clang_cc1 -std=c++20 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK,SINCE-CXX11 | ||
| // RUN: %clang_cc1 -std=c++23 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK,SINCE-CXX11 | ||
| // RUN: %clang_cc1 -std=c++2c %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt -n | FileCheck %s --check-prefixes CHECK,SINCE-CXX11 | ||
|
|
||
| namespace dr2504 { // dr2504: no | ||
| #if __cplusplus >= 201103L | ||
| struct V { V() = default; V(int); }; | ||
| struct Q { Q(); }; | ||
| struct A : virtual V, Q { | ||
| using V::V; | ||
| A() = delete; | ||
| }; | ||
| int bar() { return 42; } | ||
| struct B : A { | ||
| B() : A(bar()) {} // ok | ||
| }; | ||
| struct C : B {}; | ||
| void foo() { C c; } // bar is not invoked, because the V subobject is not initialized as part of B | ||
| #endif | ||
| } | ||
|
|
||
| // FIXME: As specified in the comment above (which comes from an example in the Standard), | ||
| // we are not supposed to unconditionally call `bar()` and call a constructor | ||
| // inherited from `V`. | ||
|
|
||
| // SINCE-CXX11-LABEL: define linkonce_odr void @dr2504::B::B() | ||
| // SINCE-CXX11-NOT: br | ||
| // SINCE-CXX11: call noundef i32 @dr2504::bar() | ||
| // SINCE-CXX11-NOT: br | ||
| // SINCE-CXX11: call void @dr2504::A::A(int) | ||
| // SINCE-CXX11-LABEL: } | ||
|
|
||
| // CHECK: {{.*}} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // REQUIRES: system-darwin | ||
|
|
||
| // RUN: env XROS_DEPLOYMENT_TARGET=1.0 %clang -arch arm64 -c -### %s 2>&1 | FileCheck %s | ||
|
|
||
| // RUN: rm -rf %t.dir | ||
| // RUN: mkdir -p %t.dir/XROS1.0.sdk | ||
| // RUN: %clang -arch arm64 -isysroot %t.dir/XROS1.0.sdk -c -### %s 2>&1 | FileCheck %s | ||
| // RUN: mkdir -p %t.dir/XRSimulator1.0.sdk | ||
| // RUN: %clang -arch arm64 -isysroot %t.dir/XRSimulator1.0.sdk -c -### %s 2>&1 | FileCheck --check-prefix=CHECK_SIM %s | ||
|
|
||
|
|
||
| // CHECK: "-cc1"{{.*}} "-triple" "arm64-apple-xros1.0.0" | ||
| // CHECK_SIM: "-cc1"{{.*}} "-triple" "arm64-apple-xros1.0.0-simulator" |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| // RUN: %clang_cc1 -verify -std=c++98 %s | ||
| // RUN: %clang_cc1 -verify -std=c++11 %s | ||
| // RUN: %clang_cc1 -verify -std=c++14 %s | ||
| // RUN: %clang_cc1 -verify -std=c++17 %s | ||
| // RUN: %clang_cc1 -verify -std=c++20 %s | ||
| // RUN: %clang_cc1 -verify -std=c++23 %s | ||
| // RUN: %clang_cc1 -verify -std=c++2c %s | ||
|
|
||
| // https://github.com/llvm/llvm-project/issues/10518 | ||
|
|
||
| template <class T> | ||
| class A : public T { | ||
| }; | ||
|
|
||
| template <class T> | ||
| class B : public A<T> { | ||
| }; | ||
|
|
||
| template <class T> | ||
| class B<int> : public A<T> { // expected-error 0-1 {{}} | ||
| B(T *t) {} | ||
| }; |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // RUN: %clang_cc1 -verify -std=c++98 %s | ||
| // RUN: %clang_cc1 -verify -std=c++11 %s | ||
| // RUN: %clang_cc1 -verify -std=c++14 %s | ||
| // RUN: %clang_cc1 -verify -std=c++17 %s | ||
| // RUN: %clang_cc1 -verify -std=c++20 %s | ||
| // RUN: %clang_cc1 -verify -std=c++23 %s | ||
| // RUN: %clang_cc1 -verify -std=c++2c %s | ||
|
|
||
| // https://github.com/llvm/llvm-project/issues/49103 | ||
|
|
||
| template<class> struct A; // expected-note 0+ {{}} | ||
| struct S : __make_integer_seq<A, int, 42> { }; // expected-error 0+ {{}} | ||
| S s; |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,78 @@ | ||
| // RUN: %clang_cc1 -verify -std=c++98 %s | ||
| // RUN: %clang_cc1 -verify -std=c++11 %s | ||
| // RUN: %clang_cc1 -verify -std=c++14 %s | ||
| // RUN: %clang_cc1 -verify -std=c++17 %s | ||
| // RUN: %clang_cc1 -verify -std=c++20 %s | ||
| // RUN: %clang_cc1 -verify -std=c++23 %s | ||
| // RUN: %clang_cc1 -verify -std=c++2c %s | ||
|
|
||
| // https://github.com/llvm/llvm-project/issues/67914 | ||
|
|
||
| template < typename, int > | ||
| struct Mask; | ||
|
|
||
| template < int, class > | ||
| struct conditional { | ||
| using type = Mask< int, 16 >; // expected-warning 0+ {{}} | ||
| }; | ||
|
|
||
| template < class _Then > | ||
| struct conditional< 0, _Then > { | ||
| using type = _Then; // expected-warning 0+ {{}} | ||
| }; | ||
|
|
||
| template < int _Bp, class, class _Then > | ||
| using conditional_t = typename conditional< _Bp, _Then >::type; // expected-warning 0+ {{}} | ||
|
|
||
| template < typename, int > | ||
| struct Array; | ||
|
|
||
| template < typename, int, bool, typename > | ||
| struct StaticArrayImpl; | ||
|
|
||
| template < typename Value_, int Size_ > | ||
| struct Mask : StaticArrayImpl< Value_, Size_, 1, Mask< Value_, Size_ > > { // expected-note 0+ {{}} | ||
| template < typename T1 > | ||
| Mask(T1) {} // expected-note 0+ {{}} | ||
| }; | ||
|
|
||
| template < typename T > | ||
| void load(typename T::MaskType mask) { | ||
| T::load_(mask); // expected-note 0+ {{}} | ||
| } | ||
|
|
||
| template < typename Value_, int IsMask_, typename Derived_ > | ||
| struct StaticArrayImpl< Value_, 32, IsMask_, Derived_ > { | ||
| using Array1 = conditional_t< IsMask_, void, Array< Value_, 16 > >; // expected-warning 0+ {{}} | ||
|
|
||
| template < typename Mask > | ||
| static Derived_ load_(Mask mask) { | ||
| return Derived_{load< Array1 >(mask.a1), Mask{}}; // expected-error 0+ {{}} | ||
| } | ||
|
|
||
| Array1 a1; | ||
| }; | ||
|
|
||
| template < typename Derived_ > | ||
| struct KMaskBase; | ||
|
|
||
| template < typename Derived_ > | ||
| struct StaticArrayImpl< float, 16, 0, Derived_ > { | ||
| template < typename Mask > | ||
| static Derived_ load_(Mask mask); | ||
| }; | ||
|
|
||
| template < typename Derived_ > | ||
| struct StaticArrayImpl< float, 16, 1, Mask< float, 16 > > : KMaskBase< Derived_ > {}; // expected-error 0+ {{}} | ||
|
|
||
| template < typename Derived_ > | ||
| struct StaticArrayImpl< int, 16, 1, Derived_ > {}; | ||
|
|
||
| template < typename Value_, int Size_ > | ||
| struct Array : StaticArrayImpl< Value_, Size_, 0, Array< Value_, Size_ > > { | ||
| using MaskType = Mask< Value_, Size_ >; // expected-warning 0+ {{}} | ||
| }; | ||
|
|
||
| void test11_load_masked() { | ||
| load< Array< float, 32 > >{} == 0; // expected-error 0+ {{}} expected-warning 0+ {{}} expected-note 0+ {{}} | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| // RUN: %clang_cc1 -verify -std=c++98 %s | ||
| // RUN: %clang_cc1 -verify -std=c++11 %s | ||
| // RUN: %clang_cc1 -verify -std=c++14 %s | ||
| // RUN: %clang_cc1 -verify -std=c++17 %s | ||
| // RUN: %clang_cc1 -verify -std=c++20 %s | ||
| // RUN: %clang_cc1 -verify -std=c++23 %s | ||
| // RUN: %clang_cc1 -verify -std=c++2c %s | ||
|
|
||
| // https://github.com/llvm/llvm-project/issues/78388 | ||
|
|
||
| typedef mbstate_t; // expected-error 0+ {{}} expected-note 0+ {{}} | ||
| template < typename , typename , typename > | ||
| class a // expected-error 0+ {{}} | ||
| class b { // expected-error 0+ {{}} | ||
| namespace { // expected-note 0+ {{}} expected-note 0+ {{}} | ||
| template < typename c > b::operator=() { // expected-error 0+ {{}} expected-note 0+ {{}} | ||
| struct :a< c, char, stdmbstate_t > d // expected-error 0+ {{}} expected-warning 0+ {{}} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| // RUN: %clang_cc1 -triple arm64-apple-darwin -fsyntax-only -verify -Wunused -std=c++98 %s | ||
| // RUN: %clang_cc1 -triple arm64-apple-darwin -fsyntax-only -verify -Wunused -std=c++14 %s | ||
|
|
||
| __attribute__((target_version("fp16"))) | ||
| static int not_used_fmv(void) { return 1; } | ||
| __attribute__((target_version("fp16fml"))) | ||
| static int not_used_fmv(void) { return 2; } | ||
| __attribute__((target_version("default"))) | ||
| static int not_used_fmv(void) { return 0; } // expected-warning {{unused function 'not_used_fmv'}} | ||
|
|
||
|
|
||
| __attribute__((target_version("fp16"))) | ||
| static int definitely_used_fmv(void) { return 1; } | ||
| __attribute__((target_version("fp16fml"))) | ||
| static int definitely_used_fmv(void) { return 2; } | ||
| __attribute__((target_version("default"))) | ||
| static int definitely_used_fmv(void) { return 0; } | ||
| int definite_user(void) { return definitely_used_fmv(); } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| !RUN: bbc --dump-symbols %s | FileCheck %s | ||
| !RUN: %flang_fc1 -fdebug-dump-symbols %s | FileCheck %s | ||
| ! test setting of isargdescriptorset in the runtime type info. | ||
|
|
||
| module m | ||
| type :: sometype | ||
| contains | ||
| procedure :: copy => copy_impl | ||
| generic :: assignment(=) => copy | ||
| end type | ||
| interface | ||
| subroutine copy_impl(this, x) | ||
| import | ||
| class(sometype), intent(out) :: this | ||
| type(sometype), target, intent(in) :: x | ||
| end subroutine | ||
| end interface | ||
| end module | ||
|
|
||
| !CHECK: .s.sometype, SAVE, TARGET (CompilerCreated, ReadOnly): ObjectEntity type: TYPE(specialbinding) shape: 0_8:0_8 init:[specialbinding::specialbinding(which=1_1,isargdescriptorset=1_1,istypebound=1_1,isargcontiguousset=0_1,proc=copy_impl)] |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| //===-- Implementation header for fdimf128 ----------------------*- C++ -*-===// | ||
| // | ||
| // 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 | ||
| // | ||
| //===----------------------------------------------------------------------===// | ||
|
|
||
| #ifndef LLVM_LIBC_SRC_MATH_FDIMF128_H | ||
| #define LLVM_LIBC_SRC_MATH_FDIMF128_H | ||
|
|
||
| #include "src/__support/macros/properties/float.h" | ||
|
|
||
| namespace LIBC_NAMESPACE { | ||
|
|
||
| float128 fdimf128(float128 x, float128 y); | ||
|
|
||
| } // namespace LIBC_NAMESPACE | ||
|
|
||
| #endif // LLVM_LIBC_SRC_MATH_FDIMF128_H |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| //===-- Implementation of fdimf128 function -------------------------------===// | ||
| // | ||
| // 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 "src/math/fdimf128.h" | ||
| #include "src/__support/FPUtil/BasicOperations.h" | ||
| #include "src/__support/common.h" | ||
|
|
||
| namespace LIBC_NAMESPACE { | ||
|
|
||
| LLVM_LIBC_FUNCTION(float128, fdimf128, (float128 x, float128 y)) { | ||
| return fputil::fdim(x, y); | ||
| } | ||
|
|
||
| } // namespace LIBC_NAMESPACE |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,26 +8,6 @@ | |
|
|
||
| #include "FDimTest.h" | ||
|
|
||
| #include "src/math/fdim.h" | ||
|
|
||
| LIST_FDIM_TESTS(double, LIBC_NAMESPACE::fdim); | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| //===-- Unittests for fdimf128 --------------------------------------------===// | ||
| // | ||
| // 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 "FDimTest.h" | ||
|
|
||
| #include "src/math/fdimf128.h" | ||
|
|
||
| LIST_FDIM_TESTS(float128, LIBC_NAMESPACE::fdimf128); |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,28 +8,6 @@ | |
|
|
||
| #include "FDimTest.h" | ||
|
|
||
| #include "src/math/fdimf.h" | ||
|
|
||
| LIST_FDIM_TESTS(float, LIBC_NAMESPACE::fdimf); | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,28 +8,6 @@ | |
|
|
||
| #include "FDimTest.h" | ||
|
|
||
| #include "src/math/fdiml.h" | ||
|
|
||
| LIST_FDIM_TESTS(long double, LIBC_NAMESPACE::fdiml); | ||