[PATCH] D94264: [GlobalISel] Add MachineInstNumbering to CSEInfo and propagate CSE throughout AArch64 pipeline.
Amara Emerson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 7 13:52:49 PST 2021
aemerson created this revision.
aemerson added reviewers: aditya_nandakumar, qcolombet, paquette, volkan, arsenm, dsanders, foad.
aemerson added a project: LLVM.
Herald added subscribers: nikic, danielkiss, hiraditya, kristof.beyls, rovka.
aemerson requested review of this revision.
Herald added a subscriber: wdng.
MachineInstNumbering is a wrapper around SlotIndexes, which exposes an API to allow fast dominance checks in the CSEMIRBuilder, and to speed up intra-block instruction sinking in the Localizer.
The numbering is stored within the CSEInfo analysis. This change also sets the AArch64 and generic GlobalISel passes to preserve the CSEInfo, and therefore use the CSEMIRBuilder within the RegBankSelect and other combiner passes.
Overall this seems to impact compile time negatively by about ~0.5% on -O0 and -Os but prevents us from having unreasonably long compile times in the worst cases.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D94264
Files:
llvm/include/llvm/CodeGen/GlobalISel/CSEInfo.h
llvm/include/llvm/CodeGen/GlobalISel/CSEMIRBuilder.h
llvm/include/llvm/CodeGen/GlobalISel/Legalizer.h
llvm/include/llvm/CodeGen/GlobalISel/Localizer.h
llvm/include/llvm/CodeGen/GlobalISel/MachineIRBuilder.h
llvm/include/llvm/CodeGen/GlobalISel/RegBankSelect.h
llvm/lib/CodeGen/GlobalISel/CSEInfo.cpp
llvm/lib/CodeGen/GlobalISel/CSEMIRBuilder.cpp
llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp
llvm/lib/CodeGen/GlobalISel/Legalizer.cpp
llvm/lib/CodeGen/GlobalISel/Localizer.cpp
llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp
llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerCombiner.cpp
llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerLowering.cpp
llvm/lib/Target/AArch64/GISel/AArch64PreLegalizerCombiner.cpp
llvm/test/CodeGen/AArch64/GlobalISel/combine-shift-immed-mismatch-crash.mir
llvm/test/CodeGen/AArch64/GlobalISel/gisel-commandline-option.ll
llvm/test/CodeGen/AArch64/O0-pipeline.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D94264.315232.patch
Type: text/x-patch
Size: 31357 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210107/658b633d/attachment.bin>
More information about the llvm-commits
mailing list