Skip to content

Commit e2ec9f6

Browse files
author
Thorsten Schütt
committed
fix rebase
1 parent c5cf97a commit e2ec9f6

File tree

2 files changed

+1
-8
lines changed

2 files changed

+1
-8
lines changed

llvm/include/llvm/Target/GlobalISel/Combine.td

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1499,6 +1499,7 @@ def extract_vector_element_freeze : GICombineRule<
14991499
(match (G_FREEZE $src, $input),
15001500
(G_EXTRACT_VECTOR_ELT $root, $src, $idx),
15011501
[{ return Helper.matchExtractVectorElementWithFreeze(${root}, ${matchinfo}); }]),
1502+
(apply [{ Helper.applyBuildFnMO(${root}, ${matchinfo}); }])>;
15021503

15031504
def sext_trunc : GICombineRule<
15041505
(defs root:$root, build_fn_matchinfo:$matchinfo),

llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4060,14 +4060,6 @@ void CombinerHelper::applyBuildFn(
40604060
MI.eraseFromParent();
40614061
}
40624062

4063-
void CombinerHelper::applyBuildFnMO(const MachineOperand &MO,
4064-
BuildFnTy &MatchInfo) {
4065-
MachineInstr *Root = getDefIgnoringCopies(MO.getReg(), MRI);
4066-
Builder.setInstrAndDebugLoc(*Root);
4067-
MatchInfo(Builder);
4068-
Root->eraseFromParent();
4069-
}
4070-
40714063
void CombinerHelper::applyBuildFnNoErase(
40724064
MachineInstr &MI, std::function<void(MachineIRBuilder &)> &MatchInfo) {
40734065
MatchInfo(Builder);

0 commit comments

Comments
 (0)