[PATCH] D107650: GlobalISel[RFC]: Avoid use of G_INSERT and G_EXTRACT in Legalizer
Amara Emerson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 20 16:11:23 PDT 2021
aemerson added a comment.
Haven't finished grokking this yet, some comments so far.
================
Comment at: llvm/include/llvm/CodeGen/GlobalISel/MachineIRBuilder.h:501
+ /// Build and insert a, b, ..., x = G_UNMERGE_VALUES \p Op0
+ /// Build and insert \p Res = G_BUILD_VECTOR a, b, ..., x, undef, ..., undef
+ ///
----------------
================
Comment at: llvm/include/llvm/CodeGen/GlobalISel/MachineIRBuilder.h:514
+ /// Build and insert a, b, ..., x, y, z = G_UNMERGE_VALUES \p Op0
+ /// Build and insert \p Res = G_BUILD_VECTOR a, b, ..., x
+ ///
----------------
ditto
================
Comment at: llvm/lib/CodeGen/GlobalISel/Legalizer.cpp:229-234
+ ++IterCount;
+ if (IterCount == 1000) {
+ llvm_unreachable(("infinite loop in " + MF.getName().str() +
+ " , TODO: fix mir tests\n\n")
+ .c_str());
+ }
----------------
?
================
Comment at: llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp:2876
+ if (MemTy.isVector() && DstTy.isVector()) {
+ LLT EltTy = MemTy.getScalarType();
----------------
Why is this code needed? Can this be a follow up change?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D107650/new/
https://reviews.llvm.org/D107650
More information about the llvm-commits
mailing list