Skip to content

Commit 63af3c0

Browse files
committed
[GlobalISel] Remove ConstantFoldingMIRBuilder
ConstantFoldingMIRBuilder was an experiment which is not used for anything. The constant folding functionality is now part of CSEMIRBuilder. Differential Revision: https://reviews.llvm.org/D101050
1 parent b1f463d commit 63af3c0

File tree

3 files changed

+4
-83
lines changed

3 files changed

+4
-83
lines changed

llvm/include/llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h

Lines changed: 0 additions & 78 deletions
This file was deleted.

llvm/unittests/CodeGen/GlobalISel/ConstantFoldingTest.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
//===----------------------------------------------------------------------===//
88

99
#include "GISelMITest.h"
10-
#include "llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h"
10+
#include "llvm/CodeGen/GlobalISel/CSEMIRBuilder.h"
1111
#include "llvm/CodeGen/GlobalISel/MachineIRBuilder.h"
1212
#include "llvm/CodeGen/GlobalISel/Utils.h"
1313
#include "llvm/CodeGen/MachineFunction.h"
@@ -22,7 +22,7 @@ TEST_F(AArch64GISelMITest, FoldWithBuilder) {
2222
if (!TM)
2323
return;
2424
// Try to use the FoldableInstructionsBuilder to build binary ops.
25-
ConstantFoldingMIRBuilder CFB(B.getState());
25+
CSEMIRBuilder CFB(B.getState());
2626
LLT s32 = LLT::scalar(32);
2727
int64_t Cst;
2828
auto MIBCAdd =
@@ -41,7 +41,7 @@ TEST_F(AArch64GISelMITest, FoldWithBuilder) {
4141

4242
// Try one of the other constructors of MachineIRBuilder to make sure it's
4343
// compatible.
44-
ConstantFoldingMIRBuilder CFB1(*MF);
44+
CSEMIRBuilder CFB1(*MF);
4545
CFB1.setInsertPt(*EntryMBB, EntryMBB->end());
4646
auto MIBCSub =
4747
CFB1.buildInstr(TargetOpcode::G_SUB, {s32},
@@ -236,4 +236,4 @@ TEST_F(AArch64GISelMITest, FoldBinOp) {
236236
EXPECT_EQ(16ULL, FoldGSremMix.getValue().getLimitedValue());
237237
}
238238

239-
} // namespace
239+
} // namespace

llvm/unittests/CodeGen/GlobalISel/PatternMatchTest.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
//===----------------------------------------------------------------------===//
88

99
#include "GISelMITest.h"
10-
#include "llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h"
1110
#include "llvm/CodeGen/GlobalISel/MIPatternMatch.h"
1211
#include "llvm/CodeGen/GlobalISel/MachineIRBuilder.h"
1312
#include "llvm/CodeGen/GlobalISel/Utils.h"

0 commit comments

Comments
 (0)