Skip to content

Commit 49c39ef

Browse files
authored
[llvm] FloatingPointPredicateUtils declare template specializations (#141368)
1 parent c0506a1 commit 49c39ef

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

llvm/include/llvm/Analysis/FloatingPointPredicateUtils.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,18 @@ namespace llvm {
1717
using FloatingPointPredicateUtils =
1818
GenericFloatingPointPredicateUtils<SSAContext>;
1919

20+
template <>
21+
DenormalMode FloatingPointPredicateUtils::queryDenormalMode(const Function &F,
22+
Value *Val);
23+
24+
template <>
25+
bool FloatingPointPredicateUtils::lookThroughFAbs(const Function &F, Value *LHS,
26+
Value *&Src);
27+
28+
template <>
29+
std::optional<APFloat>
30+
FloatingPointPredicateUtils::matchConstantFloat(const Function &F, Value *Val);
31+
2032
/// Returns a pair of values, which if passed to llvm.is.fpclass, returns the
2133
/// same result as an fcmp with the given operands.
2234
///

llvm/include/llvm/CodeGen/GlobalISel/MachineFloatingPointPredicateUtils.h

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,19 @@ namespace llvm {
1717
using MachineFloatingPointPredicateUtils =
1818
GenericFloatingPointPredicateUtils<MachineSSAContext>;
1919

20+
template <>
21+
DenormalMode
22+
MachineFloatingPointPredicateUtils::queryDenormalMode(const MachineFunction &MF,
23+
Register Val);
24+
25+
template <>
26+
bool MachineFloatingPointPredicateUtils::lookThroughFAbs(
27+
const MachineFunction &MF, Register LHS, Register &Src);
28+
29+
template <>
30+
std::optional<APFloat> MachineFloatingPointPredicateUtils::matchConstantFloat(
31+
const MachineFunction &MF, Register Val);
32+
2033
/// Compute the possible floating-point classes that \p LHS could be based on
2134
/// fcmp \Pred \p LHS, \p RHS.
2235
///

0 commit comments

Comments
 (0)