From: Matt Arsenault Date: Sat, 26 Sep 2020 14:14:14 +0000 (-0400) Subject: GlobalISel: Assert if MoreElements uses a non-vector type X-Git-Tag: llvmorg-13-init~10506 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5aa1119537fe6569b54d0da4d9d649a6940decff;p=platform%2Fupstream%2Fllvm.git GlobalISel: Assert if MoreElements uses a non-vector type --- diff --git a/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp b/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp index d14682c..30acac1 100644 --- a/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp +++ b/llvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp @@ -148,7 +148,8 @@ static bool mutationIsSane(const LegalizeRule &Rule, if (NewTy.getNumElements() <= OldElts) return false; } - } + } else if (Rule.getAction() == MoreElements) + return false; // Make sure the element type didn't change. return NewTy.getScalarType() == OldTy.getScalarType();