[PATCH] D109241: [GlobalISel] Build_vector artifact combine into unmerge_values
Petar Avramovic via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 8 04:16:51 PDT 2021
Petar.Avramovic added inline comments.
================
Comment at: llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h:1065
+ static bool isMergeOrUnmergeCompatible(LLT LargeTy, LLT SmallTy) {
+ if (!LargeTy.isVector() || !SmallTy.isVector())
----------------
arsenm wrote:
> Needs a comment. Also is misleading. What does it mean by merge exactly? Is this supposed to cover G_CONCAT_VECTORS?
I thought that this combine could also work for scalar types but that can be added later (I did not consider how useful would it be for code that comes from llvm-ir, and it could introduce infinite loops if se do some legalization on merge/unmerge_values). "Merge" is any of the opcodes we could get when using buildMerge. Changing name since this patch and the next one only consider vectors.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D109241/new/
https://reviews.llvm.org/D109241
More information about the llvm-commits
mailing list