buildMerge may build a G_MERGE_VALUES, G_BUILD_VECTOR or
G_CONCAT_VECTORS. Rename it to buildMergeLikeOp.
This is a follow-up suggested in https://reviews.llvm.org/D140964
Paths
| Differential D141372
MachineIRBuilder: Rename buildMerge. NFC ClosedPublic Authored by rovka on Jan 10 2023, 4:24 AM.
Details
Summary buildMerge may build a G_MERGE_VALUES, G_BUILD_VECTOR or This is a follow-up suggested in https://reviews.llvm.org/D140964
Diff Detail
Event Timelinerovka added a child revision: D141373: MachineIRBuilder: Add buildMergeValues. NFC.Jan 10 2023, 4:25 AM This revision is now accepted and ready to land.Jan 10 2023, 4:32 AM Comment Actions Thanks for the quick review! I'm going to leave this around until tomorrow, in case anyone wants to bikeshed about the new name. Comment Actions Tiny driveby bikeshed (feel free to ignore): buildMergeLikeInstr? It is longer, but Op seems to more commonly mean "Operand" here (save for some stuff like buildAssertOp). Comment Actions
Sounds good, thanks :) Comment Actions
I'm not a huge fan of the "Op" part either, but there is a precedent for it in the GMergeLikeOp wrapper class. Comment Actions
There could be an argument made that both GMergeLikeOp and buildAssertOp should use Instr instead of Op, too... Should I just rename all of them? Comment Actions
I don't mind either way. Comment Actions
As a separate commit yes that seems fine to me. Comment Actions
+1 to renaming in a pre-patch Closed by commit rGf95a5fbe7ce1: MachineIRBuilder: Rename buildMerge. NFC (authored by rovka). · Explain WhyJan 13 2023, 12:45 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 487748 llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
llvm/include/llvm/CodeGen/GlobalISel/MachineIRBuilder.h
llvm/lib/CodeGen/GlobalISel/CallLowering.cpp
llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp
llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
llvm/lib/Target/AArch64/GISel/AArch64CallLowering.cpp
llvm/lib/Target/AArch64/GISel/AArch64LegalizerInfo.cpp
llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
llvm/lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp
llvm/lib/Target/ARM/ARMCallLowering.cpp
llvm/lib/Target/Mips/MipsCallLowering.cpp
llvm/lib/Target/Mips/MipsLegalizerInfo.cpp
llvm/lib/Target/X86/X86CallLowering.cpp
llvm/unittests/CodeGen/GlobalISel/LegalizerHelperTest.cpp
llvm/unittests/CodeGen/GlobalISel/MachineIRBuilderTest.cpp
|