Skip to content

Commit b2c46c7

Browse files
committed
fix: remove target hook
1 parent 24a7803 commit b2c46c7

File tree

4 files changed

+4
-19
lines changed

4 files changed

+4
-19
lines changed

llvm/include/llvm/CodeGen/TargetLowering.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5019,10 +5019,6 @@ class LLVM_ABI TargetLowering : public TargetLoweringBase {
50195019
return DL.isLittleEndian();
50205020
}
50215021

5022-
virtual bool shouldExpandVectorFCANONICALIZEInVectorLegalizer() const {
5023-
return false;
5024-
}
5025-
50265022
/// Returns a 0 terminated array of registers that can be safely used as
50275023
/// scratch registers.
50285024
virtual const MCPhysReg *getScratchRegisters(CallingConv::ID CC) const {

llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1311,12 +1311,10 @@ void VectorLegalizer::Expand(SDNode *Node, SmallVectorImpl<SDValue> &Results) {
13111311
break;
13121312
case ISD::FCANONICALIZE: {
13131313
const TargetLowering &TLI = DAG.getTargetLoweringInfo();
1314-
if (TLI.shouldExpandVectorFCANONICALIZEInVectorLegalizer()) {
1315-
SDLoc dl(Node);
1316-
SDValue Result = TLI.expandFCanonicalizeWithStrictFmul(Node, dl, DAG);
1317-
Results.push_back(Result);
1318-
return;
1319-
}
1314+
SDLoc dl(Node);
1315+
SDValue Result = TLI.expandFCanonicalizeWithStrictFmul(Node, dl, DAG);
1316+
Results.push_back(Result);
1317+
return;
13201318
}
13211319
}
13221320

llvm/lib/Target/X86/X86ISelLowering.cpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3313,13 +3313,6 @@ bool X86TargetLowering::shouldConvertConstantLoadToIntImm(const APInt &Imm,
33133313
return true;
33143314
}
33153315

3316-
// X86 prefers to defer vector FCANONICALIZE to DAG legalization
3317-
// to avoid scalarization during vector legalization.
3318-
bool X86TargetLowering::shouldExpandVectorFCANONICALIZEInVectorLegalizer()
3319-
const {
3320-
return true;
3321-
}
3322-
33233316
bool X86TargetLowering::reduceSelectOfFPConstantLoads(EVT CmpOpVT) const {
33243317
// If we are using XMM registers in the ABI and the condition of the select is
33253318
// a floating-point compare and we have blendv or conditional move, then it is

llvm/lib/Target/X86/X86ISelLowering.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1524,8 +1524,6 @@ namespace llvm {
15241524
bool shouldConvertConstantLoadToIntImm(const APInt &Imm,
15251525
Type *Ty) const override;
15261526

1527-
bool shouldExpandVectorFCANONICALIZEInVectorLegalizer() const override;
1528-
15291527
bool reduceSelectOfFPConstantLoads(EVT CmpOpVT) const override;
15301528

15311529
bool convertSelectOfConstantsToMath(EVT VT) const override;

0 commit comments

Comments
 (0)