[PATCH] D78191: [GlobalISel] Fix invalid combine of unmerge(merge) with intermediate cast
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 15 05:59:21 PDT 2020
arsenm added inline comments.
================
Comment at: llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h:528-530
+ // The following combine is only valid for vectors
+ if (!OpTy.isVector())
+ return false;
----------------
canFoldMergeOpcode should have done this legality check
================
Comment at: llvm/test/CodeGen/AMDGPU/GlobalISel/artifact-combiner-unmerge-values.mir:915
+ %0:_(s64) = COPY $vgpr0_vgpr1
+ %1:_(s64) = COPY $vgpr0_vgpr1
+ %2:_(s128) = G_MERGE_VALUES %0, %1
----------------
It doesn't really matter, but this should use different source registers for the two copies. The second should be $vgpr2_vgpr3
================
Comment at: llvm/test/CodeGen/AMDGPU/GlobalISel/artifact-combiner-unmerge-values.mir:938
+ %0:_(s32) = COPY $vgpr0
+ %1:_(s32) = COPY $vgpr0
+ %2:_(s64) = G_MERGE_VALUES %0, %1
----------------
$vgpr1
================
Comment at: llvm/test/CodeGen/AMDGPU/GlobalISel/cvt_f32_ubyte-xfail.ll:4
+
+; ERROR: Segmentation fault
+define <3 x float> @v_uitofp_v3i8_to_v3f32(i32 %arg0) nounwind {
----------------
This will only work on some linuxes sometimes, there’s not much point in checking the error though
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78191/new/
https://reviews.llvm.org/D78191
More information about the llvm-commits
mailing list