[llvm] 1577c41 - [GlobalISel] Allow the ArtifactValueFinder to return the best available register on failure.

Amara Emerson via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 5 17:37:37 PDT 2021


Author: Amara Emerson
Date: 2021-08-05T17:37:30-07:00
New Revision: 1577c41090a0606432688a9a9cd1744cddcccbda

URL: https://github.com/llvm/llvm-project/commit/1577c41090a0606432688a9a9cd1744cddcccbda
DIFF: https://github.com/llvm/llvm-project/commit/1577c41090a0606432688a9a9cd1744cddcccbda.diff

LOG: [GlobalISel] Allow the ArtifactValueFinder to return the best available register on failure.

In some cases, like with inserts, we may have a matching size register already,
but still decide to try to look further. This change adds a CurrentBest
register to the value finder state, and any time a method fails to make progress,
returns that register (which may just be an empty Register).

To facilitate this, add a new entry point to the findValueFromDef() function
which initializes this state.

Also fix the build vector finder to return the current build_vector if all
sources are being requested.

Differential Revision: https://reviews.llvm.org/D107017

Added: 
    

Modified: 
    llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
    llvm/test/CodeGen/AArch64/GlobalISel/legalize-inserts.mir
    llvm/test/CodeGen/AMDGPU/GlobalISel/bug-legalization-artifact-combiner-dead-def.mir

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h b/llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
index c2d7a72c2c70a..06dbd9d93b25c 100644
--- a/llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
+++ b/llvm/include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
@@ -23,6 +23,7 @@
 #include "llvm/CodeGen/GlobalISel/MachineIRBuilder.h"
 #include "llvm/CodeGen/GlobalISel/Utils.h"
 #include "llvm/CodeGen/MachineRegisterInfo.h"
+#include "llvm/CodeGen/Register.h"
 #include "llvm/Support/Debug.h"
 
 #define DEBUG_TYPE "legalizer"
@@ -545,12 +546,14 @@ class LegalizationArtifactCombiner {
     MachineIRBuilder &MIB;
     const LegalizerInfo &LI;
 
-  private:
+    // Stores the best register found in the current query so far.
+    Register CurrentBest = Register();
+
     /// Given an concat_vector op \p Concat and a start bit and size, try to
     /// find the origin of the value defined by that start position and size.
     ///
-    /// \returns A register if a value can be found, otherwise an empty
-    /// Register.
+    /// \returns a register with the requested size, or the current best
+    /// register found during the current query.
     Register findValueFromConcat(GConcatVectors &Concat, unsigned StartBit,
                                  unsigned Size) {
       assert(Size > 0);
@@ -567,22 +570,22 @@ class LegalizationArtifactCombiner {
       // FIXME: we might be able return multiple sources? Or create an
       // appropriate concat to make it fit.
       if (InRegOffset + Size > SrcSize)
-        return Register();
+        return CurrentBest;
 
-      // If the bits exactly cover a single source, then return the operand as
-      // our value reg.
       Register SrcReg = Concat.getReg(StartSrcIdx);
-      if (InRegOffset == 0 && Size == SrcSize)
-        return SrcReg; // A source operand matches exactly.
+      if (InRegOffset == 0 && Size == SrcSize) {
+        CurrentBest = SrcReg;
+        return findValueFromDefImpl(SrcReg, 0, Size);
+      }
 
-      return findValueFromDef(SrcReg, InRegOffset, Size);
+      return findValueFromDefImpl(SrcReg, InRegOffset, Size);
     }
 
     /// Given an build_vector op \p BV and a start bit and size, try to find
     /// the origin of the value defined by that start position and size.
     ///
-    /// \returns A register if a value can be found, otherwise an empty
-    /// Register.
+    /// \returns a register with the requested size, or the current best
+    /// register found during the current query.
     Register findValueFromBuildVector(GBuildVector &BV, unsigned StartBit,
                                       unsigned Size) {
       assert(Size > 0);
@@ -597,17 +600,21 @@ class LegalizationArtifactCombiner {
       unsigned InRegOffset = StartBit % SrcSize;
 
       if (InRegOffset != 0)
-        return Register(); // Give up, bits don't start at a scalar source.
+        return CurrentBest; // Give up, bits don't start at a scalar source.
       if (Size < SrcSize)
-        return Register(); // Scalar source is too large for requested bits.
+        return CurrentBest; // Scalar source is too large for requested bits.
 
       // If the bits cover multiple sources evenly, then create a new
       // build_vector to synthesize the required size, if that's been requested.
       if (Size > SrcSize) {
         if (Size % SrcSize > 0)
-          return Register(); // Isn't covered exactly by sources.
+          return CurrentBest; // Isn't covered exactly by sources.
 
         unsigned NumSrcsUsed = Size / SrcSize;
+        // If we're requesting all of the sources, just return this def.
+        if (NumSrcsUsed == BV.getNumSources())
+          return BV.getReg(0);
+
         LLT SrcTy = MRI.getType(Src1Reg);
         LLT NewBVTy = LLT::fixed_vector(NumSrcsUsed, SrcTy);
 
@@ -615,7 +622,7 @@ class LegalizationArtifactCombiner {
         LegalizeActionStep ActionStep =
             LI.getAction({TargetOpcode::G_BUILD_VECTOR, {NewBVTy, SrcTy}});
         if (ActionStep.Action != LegalizeActions::Legal)
-          return Register();
+          return CurrentBest;
 
         SmallVector<Register> NewSrcs;
         for (unsigned SrcIdx = StartSrcIdx; SrcIdx < StartSrcIdx + NumSrcsUsed;
@@ -631,8 +638,8 @@ class LegalizationArtifactCombiner {
     /// Given an G_INSERT op \p MI and a start bit and size, try to find
     /// the origin of the value defined by that start position and size.
     ///
-    /// \returns A register if a value can be found, otherwise an empty
-    /// Register.
+    /// \returns a register with the requested size, or the current best
+    /// register found during the current query.
     Register findValueFromInsert(MachineInstr &MI, unsigned StartBit,
                                  unsigned Size) {
       assert(MI.getOpcode() == TargetOpcode::G_INSERT);
@@ -686,28 +693,25 @@ class LegalizationArtifactCombiner {
       if (EndBit <= InsertOffset || InsertedEndBit <= StartBit) {
         SrcRegToUse = ContainerSrcReg;
         NewStartBit = StartBit;
-        return findValueFromDef(SrcRegToUse, NewStartBit, Size);
+        return findValueFromDefImpl(SrcRegToUse, NewStartBit, Size);
       }
       if (InsertOffset <= StartBit && EndBit <= InsertedEndBit) {
         SrcRegToUse = InsertedReg;
         NewStartBit = StartBit - InsertOffset;
-        return findValueFromDef(SrcRegToUse, NewStartBit, Size);
+        if (NewStartBit == 0 &&
+            Size == MRI.getType(SrcRegToUse).getSizeInBits())
+          CurrentBest = SrcRegToUse;
+        return findValueFromDefImpl(SrcRegToUse, NewStartBit, Size);
       }
       // The bit range spans both the inserted and container regions.
       return Register();
     }
 
-  public:
-    ArtifactValueFinder(MachineRegisterInfo &Mri, MachineIRBuilder &Builder,
-                        const LegalizerInfo &Info)
-        : MRI(Mri), MIB(Builder), LI(Info) {}
-
-    /// Try to find a source of the value defined in the def \p DefReg, starting
-    /// at position \p StartBit with size \p Size.
-    /// \returns an empty Register if no value could be found, or \p DefReg if
-    /// if that was the best we could do.
-    Register findValueFromDef(Register DefReg, unsigned StartBit,
-                              unsigned Size) {
+    /// Internal implementation for findValueFromDef(). findValueFromDef()
+    /// initializes some data like the CurrentBest register, which this method
+    /// and its callees rely upon.
+    Register findValueFromDefImpl(Register DefReg, unsigned StartBit,
+                                  unsigned Size) {
       MachineInstr *Def = getDefIgnoringCopies(DefReg, MRI);
       // If the instruction has a single def, then simply delegate the search.
       // For unmerge however with multiple defs, we need to compute the offset
@@ -725,7 +729,7 @@ class LegalizationArtifactCombiner {
         }
         Register SrcReg = Def->getOperand(Def->getNumOperands() - 1).getReg();
         Register SrcOriginReg =
-            findValueFromDef(SrcReg, StartBit + DefStartBit, Size);
+            findValueFromDefImpl(SrcReg, StartBit + DefStartBit, Size);
         if (SrcOriginReg)
           return SrcOriginReg;
         // Failed to find a further value. If the StartBit and Size perfectly
@@ -733,7 +737,7 @@ class LegalizationArtifactCombiner {
         // nothing.
         if (StartBit == 0 && Size == DefSize)
           return DefReg;
-        return Register();
+        return CurrentBest;
       }
       case TargetOpcode::G_BUILD_VECTOR:
         return findValueFromBuildVector(cast<GBuildVector>(*Def), StartBit,
@@ -741,10 +745,26 @@ class LegalizationArtifactCombiner {
       case TargetOpcode::G_INSERT:
         return findValueFromInsert(*Def, StartBit, Size);
       default:
-        return Register();
+        return CurrentBest;
       }
     }
 
+  public:
+    ArtifactValueFinder(MachineRegisterInfo &Mri, MachineIRBuilder &Builder,
+                        const LegalizerInfo &Info)
+        : MRI(Mri), MIB(Builder), LI(Info) {}
+
+    /// Try to find a source of the value defined in the def \p DefReg, starting
+    /// at position \p StartBit with size \p Size.
+    /// \returns a register with the requested size, or an empty Register if no
+    /// better value could be found.
+    Register findValueFromDef(Register DefReg, unsigned StartBit,
+                              unsigned Size) {
+      CurrentBest = Register();
+      Register FoundReg = findValueFromDefImpl(DefReg, StartBit, Size);
+      return FoundReg != DefReg ? FoundReg : Register();
+    }
+
     /// Try to combine the defs of an unmerge \p MI by attempting to find
     /// values that provides the bits for each def reg.
     /// \returns true if all the defs of the unmerge have been made dead.
@@ -760,9 +780,8 @@ class LegalizationArtifactCombiner {
           DeadDefs[DefIdx] = true;
           continue;
         }
-        Register FoundVal =
-            findValueFromDef(DefReg, 0, DestTy.getSizeInBits());
-        if (!FoundVal || FoundVal == DefReg)
+        Register FoundVal = findValueFromDef(DefReg, 0, DestTy.getSizeInBits());
+        if (!FoundVal)
           continue;
         if (MRI.getType(FoundVal) != DestTy)
           continue;

diff  --git a/llvm/test/CodeGen/AArch64/GlobalISel/legalize-inserts.mir b/llvm/test/CodeGen/AArch64/GlobalISel/legalize-inserts.mir
index 61fa71ec476dd..5d08bb548bc9e 100644
--- a/llvm/test/CodeGen/AArch64/GlobalISel/legalize-inserts.mir
+++ b/llvm/test/CodeGen/AArch64/GlobalISel/legalize-inserts.mir
@@ -37,14 +37,10 @@ body: |
     ; CHECK: [[COPY2:%[0-9]+]]:_(s64) = COPY $x2
     ; CHECK: [[TRUNC:%[0-9]+]]:_(s32) = G_TRUNC [[COPY2]](s64)
     ; CHECK: [[COPY3:%[0-9]+]]:_(s64) = COPY [[COPY]](s64)
-    ; CHECK: [[EXTRACT:%[0-9]+]]:_(s32) = G_EXTRACT [[COPY1]](s64), 0
-    ; CHECK: [[ANYEXT:%[0-9]+]]:_(s64) = G_ANYEXT [[EXTRACT]](s32)
-    ; CHECK: [[INSERT:%[0-9]+]]:_(s64) = G_INSERT [[ANYEXT]], [[TRUNC]](s32), 0
     ; CHECK: [[UV:%[0-9]+]]:_(s32), [[UV1:%[0-9]+]]:_(s32) = G_UNMERGE_VALUES [[COPY3]](s64)
-    ; CHECK: [[UV2:%[0-9]+]]:_(s32), [[UV3:%[0-9]+]]:_(s32) = G_UNMERGE_VALUES [[INSERT]](s64)
     ; CHECK: [[DEF:%[0-9]+]]:_(s32) = G_IMPLICIT_DEF
     ; CHECK: [[MV:%[0-9]+]]:_(s64) = G_MERGE_VALUES [[UV]](s32), [[UV1]](s32)
-    ; CHECK: [[MV1:%[0-9]+]]:_(s64) = G_MERGE_VALUES [[UV2]](s32), [[DEF]](s32)
+    ; CHECK: [[MV1:%[0-9]+]]:_(s64) = G_MERGE_VALUES [[TRUNC]](s32), [[DEF]](s32)
     ; CHECK: $x0 = COPY [[MV]](s64)
     ; CHECK: $x1 = COPY [[MV1]](s64)
     %0:_(s64) = COPY $x0
@@ -69,10 +65,7 @@ body: |
     ; CHECK: [[COPY:%[0-9]+]]:_(s64) = COPY $x0
     ; CHECK: [[COPY1:%[0-9]+]]:_(s64) = COPY $x1
     ; CHECK: [[COPY2:%[0-9]+]]:_(s64) = COPY $x2
-    ; CHECK: [[TRUNC:%[0-9]+]]:_(s1) = G_TRUNC [[COPY2]](s64)
     ; CHECK: [[COPY3:%[0-9]+]]:_(s64) = COPY [[COPY]](s64)
-    ; CHECK: [[COPY4:%[0-9]+]]:_(s64) = COPY [[COPY1]](s64)
-    ; CHECK: [[INSERT:%[0-9]+]]:_(s64) = G_INSERT [[COPY4]], [[TRUNC]](s1), 0
     ; CHECK: [[UV:%[0-9]+]]:_(s8), [[UV1:%[0-9]+]]:_(s8), [[UV2:%[0-9]+]]:_(s8), [[UV3:%[0-9]+]]:_(s8), [[UV4:%[0-9]+]]:_(s8), [[UV5:%[0-9]+]]:_(s8), [[UV6:%[0-9]+]]:_(s8), [[UV7:%[0-9]+]]:_(s8) = G_UNMERGE_VALUES [[COPY3]](s64)
     ; CHECK: [[C:%[0-9]+]]:_(s8) = G_CONSTANT i8 1
     ; CHECK: [[ZEXT:%[0-9]+]]:_(s32) = G_ZEXT [[UV]](s8)
@@ -200,663 +193,648 @@ body: |
     ; CHECK: [[LSHR54:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT54]], [[C11]](s64)
     ; CHECK: [[ZEXT55:%[0-9]+]]:_(s32) = G_ZEXT [[UV7]](s8)
     ; CHECK: [[LSHR55:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT55]], [[C13]](s64)
-    ; CHECK: [[UV8:%[0-9]+]]:_(s8), [[UV9:%[0-9]+]]:_(s8), [[UV10:%[0-9]+]]:_(s8), [[UV11:%[0-9]+]]:_(s8), [[UV12:%[0-9]+]]:_(s8), [[UV13:%[0-9]+]]:_(s8), [[UV14:%[0-9]+]]:_(s8), [[UV15:%[0-9]+]]:_(s8) = G_UNMERGE_VALUES [[INSERT]](s64)
-    ; CHECK: [[ZEXT56:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR56:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT56]], [[C1]](s64)
-    ; CHECK: [[ZEXT57:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR57:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT57]], [[C3]](s64)
-    ; CHECK: [[ZEXT58:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR58:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT58]], [[C5]](s64)
-    ; CHECK: [[ZEXT59:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR59:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT59]], [[C7]](s64)
-    ; CHECK: [[ZEXT60:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR60:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT60]], [[C9]](s64)
-    ; CHECK: [[ZEXT61:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR61:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT61]], [[C11]](s64)
-    ; CHECK: [[ZEXT62:%[0-9]+]]:_(s32) = G_ZEXT [[UV8]](s8)
-    ; CHECK: [[LSHR62:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT62]], [[C13]](s64)
     ; CHECK: [[C14:%[0-9]+]]:_(s32) = G_CONSTANT i32 1
-    ; CHECK: [[COPY5:%[0-9]+]]:_(s32) = COPY [[LSHR]](s32)
-    ; CHECK: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY5]], [[C14]]
+    ; CHECK: [[COPY4:%[0-9]+]]:_(s32) = COPY [[LSHR]](s32)
+    ; CHECK: [[AND:%[0-9]+]]:_(s32) = G_AND [[COPY4]], [[C14]]
     ; CHECK: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[AND]], [[C1]](s64)
     ; CHECK: [[ANYEXT:%[0-9]+]]:_(s32) = G_ANYEXT [[UV]](s8)
     ; CHECK: [[AND1:%[0-9]+]]:_(s32) = G_AND [[ANYEXT]], [[C14]]
-    ; CHECK: [[COPY6:%[0-9]+]]:_(s32) = COPY [[SHL]](s32)
-    ; CHECK: [[OR:%[0-9]+]]:_(s32) = G_OR [[AND1]], [[COPY6]]
-    ; CHECK: [[COPY7:%[0-9]+]]:_(s32) = COPY [[LSHR1]](s32)
-    ; CHECK: [[AND2:%[0-9]+]]:_(s32) = G_AND [[COPY7]], [[C14]]
+    ; CHECK: [[COPY5:%[0-9]+]]:_(s32) = COPY [[SHL]](s32)
+    ; CHECK: [[OR:%[0-9]+]]:_(s32) = G_OR [[AND1]], [[COPY5]]
+    ; CHECK: [[COPY6:%[0-9]+]]:_(s32) = COPY [[LSHR1]](s32)
+    ; CHECK: [[AND2:%[0-9]+]]:_(s32) = G_AND [[COPY6]], [[C14]]
     ; CHECK: [[SHL1:%[0-9]+]]:_(s32) = G_SHL [[AND2]], [[C3]](s64)
-    ; CHECK: [[COPY8:%[0-9]+]]:_(s32) = COPY [[OR]](s32)
-    ; CHECK: [[COPY9:%[0-9]+]]:_(s32) = COPY [[SHL1]](s32)
-    ; CHECK: [[OR1:%[0-9]+]]:_(s32) = G_OR [[COPY8]], [[COPY9]]
-    ; CHECK: [[COPY10:%[0-9]+]]:_(s32) = COPY [[LSHR2]](s32)
-    ; CHECK: [[AND3:%[0-9]+]]:_(s32) = G_AND [[COPY10]], [[C14]]
+    ; CHECK: [[COPY7:%[0-9]+]]:_(s32) = COPY [[OR]](s32)
+    ; CHECK: [[COPY8:%[0-9]+]]:_(s32) = COPY [[SHL1]](s32)
+    ; CHECK: [[OR1:%[0-9]+]]:_(s32) = G_OR [[COPY7]], [[COPY8]]
+    ; CHECK: [[COPY9:%[0-9]+]]:_(s32) = COPY [[LSHR2]](s32)
+    ; CHECK: [[AND3:%[0-9]+]]:_(s32) = G_AND [[COPY9]], [[C14]]
     ; CHECK: [[SHL2:%[0-9]+]]:_(s32) = G_SHL [[AND3]], [[C5]](s64)
-    ; CHECK: [[COPY11:%[0-9]+]]:_(s32) = COPY [[OR1]](s32)
-    ; CHECK: [[COPY12:%[0-9]+]]:_(s32) = COPY [[SHL2]](s32)
-    ; CHECK: [[OR2:%[0-9]+]]:_(s32) = G_OR [[COPY11]], [[COPY12]]
-    ; CHECK: [[COPY13:%[0-9]+]]:_(s32) = COPY [[LSHR3]](s32)
-    ; CHECK: [[AND4:%[0-9]+]]:_(s32) = G_AND [[COPY13]], [[C14]]
+    ; CHECK: [[COPY10:%[0-9]+]]:_(s32) = COPY [[OR1]](s32)
+    ; CHECK: [[COPY11:%[0-9]+]]:_(s32) = COPY [[SHL2]](s32)
+    ; CHECK: [[OR2:%[0-9]+]]:_(s32) = G_OR [[COPY10]], [[COPY11]]
+    ; CHECK: [[COPY12:%[0-9]+]]:_(s32) = COPY [[LSHR3]](s32)
+    ; CHECK: [[AND4:%[0-9]+]]:_(s32) = G_AND [[COPY12]], [[C14]]
     ; CHECK: [[SHL3:%[0-9]+]]:_(s32) = G_SHL [[AND4]], [[C7]](s64)
-    ; CHECK: [[COPY14:%[0-9]+]]:_(s32) = COPY [[OR2]](s32)
-    ; CHECK: [[COPY15:%[0-9]+]]:_(s32) = COPY [[SHL3]](s32)
-    ; CHECK: [[OR3:%[0-9]+]]:_(s32) = G_OR [[COPY14]], [[COPY15]]
-    ; CHECK: [[COPY16:%[0-9]+]]:_(s32) = COPY [[LSHR4]](s32)
-    ; CHECK: [[AND5:%[0-9]+]]:_(s32) = G_AND [[COPY16]], [[C14]]
+    ; CHECK: [[COPY13:%[0-9]+]]:_(s32) = COPY [[OR2]](s32)
+    ; CHECK: [[COPY14:%[0-9]+]]:_(s32) = COPY [[SHL3]](s32)
+    ; CHECK: [[OR3:%[0-9]+]]:_(s32) = G_OR [[COPY13]], [[COPY14]]
+    ; CHECK: [[COPY15:%[0-9]+]]:_(s32) = COPY [[LSHR4]](s32)
+    ; CHECK: [[AND5:%[0-9]+]]:_(s32) = G_AND [[COPY15]], [[C14]]
     ; CHECK: [[SHL4:%[0-9]+]]:_(s32) = G_SHL [[AND5]], [[C9]](s64)
-    ; CHECK: [[COPY17:%[0-9]+]]:_(s32) = COPY [[OR3]](s32)
-    ; CHECK: [[COPY18:%[0-9]+]]:_(s32) = COPY [[SHL4]](s32)
-    ; CHECK: [[OR4:%[0-9]+]]:_(s32) = G_OR [[COPY17]], [[COPY18]]
-    ; CHECK: [[COPY19:%[0-9]+]]:_(s32) = COPY [[LSHR5]](s32)
-    ; CHECK: [[AND6:%[0-9]+]]:_(s32) = G_AND [[COPY19]], [[C14]]
+    ; CHECK: [[COPY16:%[0-9]+]]:_(s32) = COPY [[OR3]](s32)
+    ; CHECK: [[COPY17:%[0-9]+]]:_(s32) = COPY [[SHL4]](s32)
+    ; CHECK: [[OR4:%[0-9]+]]:_(s32) = G_OR [[COPY16]], [[COPY17]]
+    ; CHECK: [[COPY18:%[0-9]+]]:_(s32) = COPY [[LSHR5]](s32)
+    ; CHECK: [[AND6:%[0-9]+]]:_(s32) = G_AND [[COPY18]], [[C14]]
     ; CHECK: [[SHL5:%[0-9]+]]:_(s32) = G_SHL [[AND6]], [[C11]](s64)
-    ; CHECK: [[COPY20:%[0-9]+]]:_(s32) = COPY [[OR4]](s32)
-    ; CHECK: [[COPY21:%[0-9]+]]:_(s32) = COPY [[SHL5]](s32)
-    ; CHECK: [[OR5:%[0-9]+]]:_(s32) = G_OR [[COPY20]], [[COPY21]]
-    ; CHECK: [[COPY22:%[0-9]+]]:_(s32) = COPY [[LSHR6]](s32)
-    ; CHECK: [[AND7:%[0-9]+]]:_(s32) = G_AND [[COPY22]], [[C14]]
+    ; CHECK: [[COPY19:%[0-9]+]]:_(s32) = COPY [[OR4]](s32)
+    ; CHECK: [[COPY20:%[0-9]+]]:_(s32) = COPY [[SHL5]](s32)
+    ; CHECK: [[OR5:%[0-9]+]]:_(s32) = G_OR [[COPY19]], [[COPY20]]
+    ; CHECK: [[COPY21:%[0-9]+]]:_(s32) = COPY [[LSHR6]](s32)
+    ; CHECK: [[AND7:%[0-9]+]]:_(s32) = G_AND [[COPY21]], [[C14]]
     ; CHECK: [[SHL6:%[0-9]+]]:_(s32) = G_SHL [[AND7]], [[C13]](s64)
-    ; CHECK: [[COPY23:%[0-9]+]]:_(s32) = COPY [[OR5]](s32)
-    ; CHECK: [[COPY24:%[0-9]+]]:_(s32) = COPY [[SHL6]](s32)
-    ; CHECK: [[OR6:%[0-9]+]]:_(s32) = G_OR [[COPY23]], [[COPY24]]
-    ; CHECK: [[TRUNC1:%[0-9]+]]:_(s8) = G_TRUNC [[OR6]](s32)
-    ; CHECK: [[COPY25:%[0-9]+]]:_(s32) = COPY [[LSHR7]](s32)
-    ; CHECK: [[AND8:%[0-9]+]]:_(s32) = G_AND [[COPY25]], [[C14]]
+    ; CHECK: [[COPY22:%[0-9]+]]:_(s32) = COPY [[OR5]](s32)
+    ; CHECK: [[COPY23:%[0-9]+]]:_(s32) = COPY [[SHL6]](s32)
+    ; CHECK: [[OR6:%[0-9]+]]:_(s32) = G_OR [[COPY22]], [[COPY23]]
+    ; CHECK: [[TRUNC:%[0-9]+]]:_(s8) = G_TRUNC [[OR6]](s32)
+    ; CHECK: [[COPY24:%[0-9]+]]:_(s32) = COPY [[LSHR7]](s32)
+    ; CHECK: [[AND8:%[0-9]+]]:_(s32) = G_AND [[COPY24]], [[C14]]
     ; CHECK: [[SHL7:%[0-9]+]]:_(s32) = G_SHL [[AND8]], [[C1]](s64)
     ; CHECK: [[ANYEXT1:%[0-9]+]]:_(s32) = G_ANYEXT [[UV1]](s8)
     ; CHECK: [[AND9:%[0-9]+]]:_(s32) = G_AND [[ANYEXT1]], [[C14]]
-    ; CHECK: [[COPY26:%[0-9]+]]:_(s32) = COPY [[SHL7]](s32)
-    ; CHECK: [[OR7:%[0-9]+]]:_(s32) = G_OR [[AND9]], [[COPY26]]
-    ; CHECK: [[COPY27:%[0-9]+]]:_(s32) = COPY [[LSHR8]](s32)
-    ; CHECK: [[AND10:%[0-9]+]]:_(s32) = G_AND [[COPY27]], [[C14]]
+    ; CHECK: [[COPY25:%[0-9]+]]:_(s32) = COPY [[SHL7]](s32)
+    ; CHECK: [[OR7:%[0-9]+]]:_(s32) = G_OR [[AND9]], [[COPY25]]
+    ; CHECK: [[COPY26:%[0-9]+]]:_(s32) = COPY [[LSHR8]](s32)
+    ; CHECK: [[AND10:%[0-9]+]]:_(s32) = G_AND [[COPY26]], [[C14]]
     ; CHECK: [[SHL8:%[0-9]+]]:_(s32) = G_SHL [[AND10]], [[C3]](s64)
-    ; CHECK: [[COPY28:%[0-9]+]]:_(s32) = COPY [[OR7]](s32)
-    ; CHECK: [[COPY29:%[0-9]+]]:_(s32) = COPY [[SHL8]](s32)
-    ; CHECK: [[OR8:%[0-9]+]]:_(s32) = G_OR [[COPY28]], [[COPY29]]
-    ; CHECK: [[COPY30:%[0-9]+]]:_(s32) = COPY [[LSHR9]](s32)
-    ; CHECK: [[AND11:%[0-9]+]]:_(s32) = G_AND [[COPY30]], [[C14]]
+    ; CHECK: [[COPY27:%[0-9]+]]:_(s32) = COPY [[OR7]](s32)
+    ; CHECK: [[COPY28:%[0-9]+]]:_(s32) = COPY [[SHL8]](s32)
+    ; CHECK: [[OR8:%[0-9]+]]:_(s32) = G_OR [[COPY27]], [[COPY28]]
+    ; CHECK: [[COPY29:%[0-9]+]]:_(s32) = COPY [[LSHR9]](s32)
+    ; CHECK: [[AND11:%[0-9]+]]:_(s32) = G_AND [[COPY29]], [[C14]]
     ; CHECK: [[SHL9:%[0-9]+]]:_(s32) = G_SHL [[AND11]], [[C5]](s64)
-    ; CHECK: [[COPY31:%[0-9]+]]:_(s32) = COPY [[OR8]](s32)
-    ; CHECK: [[COPY32:%[0-9]+]]:_(s32) = COPY [[SHL9]](s32)
-    ; CHECK: [[OR9:%[0-9]+]]:_(s32) = G_OR [[COPY31]], [[COPY32]]
-    ; CHECK: [[COPY33:%[0-9]+]]:_(s32) = COPY [[LSHR10]](s32)
-    ; CHECK: [[AND12:%[0-9]+]]:_(s32) = G_AND [[COPY33]], [[C14]]
+    ; CHECK: [[COPY30:%[0-9]+]]:_(s32) = COPY [[OR8]](s32)
+    ; CHECK: [[COPY31:%[0-9]+]]:_(s32) = COPY [[SHL9]](s32)
+    ; CHECK: [[OR9:%[0-9]+]]:_(s32) = G_OR [[COPY30]], [[COPY31]]
+    ; CHECK: [[COPY32:%[0-9]+]]:_(s32) = COPY [[LSHR10]](s32)
+    ; CHECK: [[AND12:%[0-9]+]]:_(s32) = G_AND [[COPY32]], [[C14]]
     ; CHECK: [[SHL10:%[0-9]+]]:_(s32) = G_SHL [[AND12]], [[C7]](s64)
-    ; CHECK: [[COPY34:%[0-9]+]]:_(s32) = COPY [[OR9]](s32)
-    ; CHECK: [[COPY35:%[0-9]+]]:_(s32) = COPY [[SHL10]](s32)
-    ; CHECK: [[OR10:%[0-9]+]]:_(s32) = G_OR [[COPY34]], [[COPY35]]
-    ; CHECK: [[COPY36:%[0-9]+]]:_(s32) = COPY [[LSHR11]](s32)
-    ; CHECK: [[AND13:%[0-9]+]]:_(s32) = G_AND [[COPY36]], [[C14]]
+    ; CHECK: [[COPY33:%[0-9]+]]:_(s32) = COPY [[OR9]](s32)
+    ; CHECK: [[COPY34:%[0-9]+]]:_(s32) = COPY [[SHL10]](s32)
+    ; CHECK: [[OR10:%[0-9]+]]:_(s32) = G_OR [[COPY33]], [[COPY34]]
+    ; CHECK: [[COPY35:%[0-9]+]]:_(s32) = COPY [[LSHR11]](s32)
+    ; CHECK: [[AND13:%[0-9]+]]:_(s32) = G_AND [[COPY35]], [[C14]]
     ; CHECK: [[SHL11:%[0-9]+]]:_(s32) = G_SHL [[AND13]], [[C9]](s64)
-    ; CHECK: [[COPY37:%[0-9]+]]:_(s32) = COPY [[OR10]](s32)
-    ; CHECK: [[COPY38:%[0-9]+]]:_(s32) = COPY [[SHL11]](s32)
-    ; CHECK: [[OR11:%[0-9]+]]:_(s32) = G_OR [[COPY37]], [[COPY38]]
-    ; CHECK: [[COPY39:%[0-9]+]]:_(s32) = COPY [[LSHR12]](s32)
-    ; CHECK: [[AND14:%[0-9]+]]:_(s32) = G_AND [[COPY39]], [[C14]]
+    ; CHECK: [[COPY36:%[0-9]+]]:_(s32) = COPY [[OR10]](s32)
+    ; CHECK: [[COPY37:%[0-9]+]]:_(s32) = COPY [[SHL11]](s32)
+    ; CHECK: [[OR11:%[0-9]+]]:_(s32) = G_OR [[COPY36]], [[COPY37]]
+    ; CHECK: [[COPY38:%[0-9]+]]:_(s32) = COPY [[LSHR12]](s32)
+    ; CHECK: [[AND14:%[0-9]+]]:_(s32) = G_AND [[COPY38]], [[C14]]
     ; CHECK: [[SHL12:%[0-9]+]]:_(s32) = G_SHL [[AND14]], [[C11]](s64)
-    ; CHECK: [[COPY40:%[0-9]+]]:_(s32) = COPY [[OR11]](s32)
-    ; CHECK: [[COPY41:%[0-9]+]]:_(s32) = COPY [[SHL12]](s32)
-    ; CHECK: [[OR12:%[0-9]+]]:_(s32) = G_OR [[COPY40]], [[COPY41]]
-    ; CHECK: [[COPY42:%[0-9]+]]:_(s32) = COPY [[LSHR13]](s32)
-    ; CHECK: [[AND15:%[0-9]+]]:_(s32) = G_AND [[COPY42]], [[C14]]
+    ; CHECK: [[COPY39:%[0-9]+]]:_(s32) = COPY [[OR11]](s32)
+    ; CHECK: [[COPY40:%[0-9]+]]:_(s32) = COPY [[SHL12]](s32)
+    ; CHECK: [[OR12:%[0-9]+]]:_(s32) = G_OR [[COPY39]], [[COPY40]]
+    ; CHECK: [[COPY41:%[0-9]+]]:_(s32) = COPY [[LSHR13]](s32)
+    ; CHECK: [[AND15:%[0-9]+]]:_(s32) = G_AND [[COPY41]], [[C14]]
     ; CHECK: [[SHL13:%[0-9]+]]:_(s32) = G_SHL [[AND15]], [[C13]](s64)
-    ; CHECK: [[COPY43:%[0-9]+]]:_(s32) = COPY [[OR12]](s32)
-    ; CHECK: [[COPY44:%[0-9]+]]:_(s32) = COPY [[SHL13]](s32)
-    ; CHECK: [[OR13:%[0-9]+]]:_(s32) = G_OR [[COPY43]], [[COPY44]]
-    ; CHECK: [[TRUNC2:%[0-9]+]]:_(s8) = G_TRUNC [[OR13]](s32)
-    ; CHECK: [[COPY45:%[0-9]+]]:_(s32) = COPY [[LSHR14]](s32)
-    ; CHECK: [[AND16:%[0-9]+]]:_(s32) = G_AND [[COPY45]], [[C14]]
+    ; CHECK: [[COPY42:%[0-9]+]]:_(s32) = COPY [[OR12]](s32)
+    ; CHECK: [[COPY43:%[0-9]+]]:_(s32) = COPY [[SHL13]](s32)
+    ; CHECK: [[OR13:%[0-9]+]]:_(s32) = G_OR [[COPY42]], [[COPY43]]
+    ; CHECK: [[TRUNC1:%[0-9]+]]:_(s8) = G_TRUNC [[OR13]](s32)
+    ; CHECK: [[COPY44:%[0-9]+]]:_(s32) = COPY [[LSHR14]](s32)
+    ; CHECK: [[AND16:%[0-9]+]]:_(s32) = G_AND [[COPY44]], [[C14]]
     ; CHECK: [[SHL14:%[0-9]+]]:_(s32) = G_SHL [[AND16]], [[C1]](s64)
     ; CHECK: [[ANYEXT2:%[0-9]+]]:_(s32) = G_ANYEXT [[UV2]](s8)
     ; CHECK: [[AND17:%[0-9]+]]:_(s32) = G_AND [[ANYEXT2]], [[C14]]
-    ; CHECK: [[COPY46:%[0-9]+]]:_(s32) = COPY [[SHL14]](s32)
-    ; CHECK: [[OR14:%[0-9]+]]:_(s32) = G_OR [[AND17]], [[COPY46]]
-    ; CHECK: [[COPY47:%[0-9]+]]:_(s32) = COPY [[LSHR15]](s32)
-    ; CHECK: [[AND18:%[0-9]+]]:_(s32) = G_AND [[COPY47]], [[C14]]
+    ; CHECK: [[COPY45:%[0-9]+]]:_(s32) = COPY [[SHL14]](s32)
+    ; CHECK: [[OR14:%[0-9]+]]:_(s32) = G_OR [[AND17]], [[COPY45]]
+    ; CHECK: [[COPY46:%[0-9]+]]:_(s32) = COPY [[LSHR15]](s32)
+    ; CHECK: [[AND18:%[0-9]+]]:_(s32) = G_AND [[COPY46]], [[C14]]
     ; CHECK: [[SHL15:%[0-9]+]]:_(s32) = G_SHL [[AND18]], [[C3]](s64)
-    ; CHECK: [[COPY48:%[0-9]+]]:_(s32) = COPY [[OR14]](s32)
-    ; CHECK: [[COPY49:%[0-9]+]]:_(s32) = COPY [[SHL15]](s32)
-    ; CHECK: [[OR15:%[0-9]+]]:_(s32) = G_OR [[COPY48]], [[COPY49]]
-    ; CHECK: [[COPY50:%[0-9]+]]:_(s32) = COPY [[LSHR16]](s32)
-    ; CHECK: [[AND19:%[0-9]+]]:_(s32) = G_AND [[COPY50]], [[C14]]
+    ; CHECK: [[COPY47:%[0-9]+]]:_(s32) = COPY [[OR14]](s32)
+    ; CHECK: [[COPY48:%[0-9]+]]:_(s32) = COPY [[SHL15]](s32)
+    ; CHECK: [[OR15:%[0-9]+]]:_(s32) = G_OR [[COPY47]], [[COPY48]]
+    ; CHECK: [[COPY49:%[0-9]+]]:_(s32) = COPY [[LSHR16]](s32)
+    ; CHECK: [[AND19:%[0-9]+]]:_(s32) = G_AND [[COPY49]], [[C14]]
     ; CHECK: [[SHL16:%[0-9]+]]:_(s32) = G_SHL [[AND19]], [[C5]](s64)
-    ; CHECK: [[COPY51:%[0-9]+]]:_(s32) = COPY [[OR15]](s32)
-    ; CHECK: [[COPY52:%[0-9]+]]:_(s32) = COPY [[SHL16]](s32)
-    ; CHECK: [[OR16:%[0-9]+]]:_(s32) = G_OR [[COPY51]], [[COPY52]]
-    ; CHECK: [[COPY53:%[0-9]+]]:_(s32) = COPY [[LSHR17]](s32)
-    ; CHECK: [[AND20:%[0-9]+]]:_(s32) = G_AND [[COPY53]], [[C14]]
+    ; CHECK: [[COPY50:%[0-9]+]]:_(s32) = COPY [[OR15]](s32)
+    ; CHECK: [[COPY51:%[0-9]+]]:_(s32) = COPY [[SHL16]](s32)
+    ; CHECK: [[OR16:%[0-9]+]]:_(s32) = G_OR [[COPY50]], [[COPY51]]
+    ; CHECK: [[COPY52:%[0-9]+]]:_(s32) = COPY [[LSHR17]](s32)
+    ; CHECK: [[AND20:%[0-9]+]]:_(s32) = G_AND [[COPY52]], [[C14]]
     ; CHECK: [[SHL17:%[0-9]+]]:_(s32) = G_SHL [[AND20]], [[C7]](s64)
-    ; CHECK: [[COPY54:%[0-9]+]]:_(s32) = COPY [[OR16]](s32)
-    ; CHECK: [[COPY55:%[0-9]+]]:_(s32) = COPY [[SHL17]](s32)
-    ; CHECK: [[OR17:%[0-9]+]]:_(s32) = G_OR [[COPY54]], [[COPY55]]
-    ; CHECK: [[COPY56:%[0-9]+]]:_(s32) = COPY [[LSHR18]](s32)
-    ; CHECK: [[AND21:%[0-9]+]]:_(s32) = G_AND [[COPY56]], [[C14]]
+    ; CHECK: [[COPY53:%[0-9]+]]:_(s32) = COPY [[OR16]](s32)
+    ; CHECK: [[COPY54:%[0-9]+]]:_(s32) = COPY [[SHL17]](s32)
+    ; CHECK: [[OR17:%[0-9]+]]:_(s32) = G_OR [[COPY53]], [[COPY54]]
+    ; CHECK: [[COPY55:%[0-9]+]]:_(s32) = COPY [[LSHR18]](s32)
+    ; CHECK: [[AND21:%[0-9]+]]:_(s32) = G_AND [[COPY55]], [[C14]]
     ; CHECK: [[SHL18:%[0-9]+]]:_(s32) = G_SHL [[AND21]], [[C9]](s64)
-    ; CHECK: [[COPY57:%[0-9]+]]:_(s32) = COPY [[OR17]](s32)
-    ; CHECK: [[COPY58:%[0-9]+]]:_(s32) = COPY [[SHL18]](s32)
-    ; CHECK: [[OR18:%[0-9]+]]:_(s32) = G_OR [[COPY57]], [[COPY58]]
-    ; CHECK: [[COPY59:%[0-9]+]]:_(s32) = COPY [[LSHR19]](s32)
-    ; CHECK: [[AND22:%[0-9]+]]:_(s32) = G_AND [[COPY59]], [[C14]]
+    ; CHECK: [[COPY56:%[0-9]+]]:_(s32) = COPY [[OR17]](s32)
+    ; CHECK: [[COPY57:%[0-9]+]]:_(s32) = COPY [[SHL18]](s32)
+    ; CHECK: [[OR18:%[0-9]+]]:_(s32) = G_OR [[COPY56]], [[COPY57]]
+    ; CHECK: [[COPY58:%[0-9]+]]:_(s32) = COPY [[LSHR19]](s32)
+    ; CHECK: [[AND22:%[0-9]+]]:_(s32) = G_AND [[COPY58]], [[C14]]
     ; CHECK: [[SHL19:%[0-9]+]]:_(s32) = G_SHL [[AND22]], [[C11]](s64)
-    ; CHECK: [[COPY60:%[0-9]+]]:_(s32) = COPY [[OR18]](s32)
-    ; CHECK: [[COPY61:%[0-9]+]]:_(s32) = COPY [[SHL19]](s32)
-    ; CHECK: [[OR19:%[0-9]+]]:_(s32) = G_OR [[COPY60]], [[COPY61]]
-    ; CHECK: [[COPY62:%[0-9]+]]:_(s32) = COPY [[LSHR20]](s32)
-    ; CHECK: [[AND23:%[0-9]+]]:_(s32) = G_AND [[COPY62]], [[C14]]
+    ; CHECK: [[COPY59:%[0-9]+]]:_(s32) = COPY [[OR18]](s32)
+    ; CHECK: [[COPY60:%[0-9]+]]:_(s32) = COPY [[SHL19]](s32)
+    ; CHECK: [[OR19:%[0-9]+]]:_(s32) = G_OR [[COPY59]], [[COPY60]]
+    ; CHECK: [[COPY61:%[0-9]+]]:_(s32) = COPY [[LSHR20]](s32)
+    ; CHECK: [[AND23:%[0-9]+]]:_(s32) = G_AND [[COPY61]], [[C14]]
     ; CHECK: [[SHL20:%[0-9]+]]:_(s32) = G_SHL [[AND23]], [[C13]](s64)
-    ; CHECK: [[COPY63:%[0-9]+]]:_(s32) = COPY [[OR19]](s32)
-    ; CHECK: [[COPY64:%[0-9]+]]:_(s32) = COPY [[SHL20]](s32)
-    ; CHECK: [[OR20:%[0-9]+]]:_(s32) = G_OR [[COPY63]], [[COPY64]]
-    ; CHECK: [[TRUNC3:%[0-9]+]]:_(s8) = G_TRUNC [[OR20]](s32)
-    ; CHECK: [[COPY65:%[0-9]+]]:_(s32) = COPY [[LSHR21]](s32)
-    ; CHECK: [[AND24:%[0-9]+]]:_(s32) = G_AND [[COPY65]], [[C14]]
+    ; CHECK: [[COPY62:%[0-9]+]]:_(s32) = COPY [[OR19]](s32)
+    ; CHECK: [[COPY63:%[0-9]+]]:_(s32) = COPY [[SHL20]](s32)
+    ; CHECK: [[OR20:%[0-9]+]]:_(s32) = G_OR [[COPY62]], [[COPY63]]
+    ; CHECK: [[TRUNC2:%[0-9]+]]:_(s8) = G_TRUNC [[OR20]](s32)
+    ; CHECK: [[COPY64:%[0-9]+]]:_(s32) = COPY [[LSHR21]](s32)
+    ; CHECK: [[AND24:%[0-9]+]]:_(s32) = G_AND [[COPY64]], [[C14]]
     ; CHECK: [[SHL21:%[0-9]+]]:_(s32) = G_SHL [[AND24]], [[C1]](s64)
     ; CHECK: [[ANYEXT3:%[0-9]+]]:_(s32) = G_ANYEXT [[UV3]](s8)
     ; CHECK: [[AND25:%[0-9]+]]:_(s32) = G_AND [[ANYEXT3]], [[C14]]
-    ; CHECK: [[COPY66:%[0-9]+]]:_(s32) = COPY [[SHL21]](s32)
-    ; CHECK: [[OR21:%[0-9]+]]:_(s32) = G_OR [[AND25]], [[COPY66]]
-    ; CHECK: [[COPY67:%[0-9]+]]:_(s32) = COPY [[LSHR22]](s32)
-    ; CHECK: [[AND26:%[0-9]+]]:_(s32) = G_AND [[COPY67]], [[C14]]
+    ; CHECK: [[COPY65:%[0-9]+]]:_(s32) = COPY [[SHL21]](s32)
+    ; CHECK: [[OR21:%[0-9]+]]:_(s32) = G_OR [[AND25]], [[COPY65]]
+    ; CHECK: [[COPY66:%[0-9]+]]:_(s32) = COPY [[LSHR22]](s32)
+    ; CHECK: [[AND26:%[0-9]+]]:_(s32) = G_AND [[COPY66]], [[C14]]
     ; CHECK: [[SHL22:%[0-9]+]]:_(s32) = G_SHL [[AND26]], [[C3]](s64)
-    ; CHECK: [[COPY68:%[0-9]+]]:_(s32) = COPY [[OR21]](s32)
-    ; CHECK: [[COPY69:%[0-9]+]]:_(s32) = COPY [[SHL22]](s32)
-    ; CHECK: [[OR22:%[0-9]+]]:_(s32) = G_OR [[COPY68]], [[COPY69]]
-    ; CHECK: [[COPY70:%[0-9]+]]:_(s32) = COPY [[LSHR23]](s32)
-    ; CHECK: [[AND27:%[0-9]+]]:_(s32) = G_AND [[COPY70]], [[C14]]
+    ; CHECK: [[COPY67:%[0-9]+]]:_(s32) = COPY [[OR21]](s32)
+    ; CHECK: [[COPY68:%[0-9]+]]:_(s32) = COPY [[SHL22]](s32)
+    ; CHECK: [[OR22:%[0-9]+]]:_(s32) = G_OR [[COPY67]], [[COPY68]]
+    ; CHECK: [[COPY69:%[0-9]+]]:_(s32) = COPY [[LSHR23]](s32)
+    ; CHECK: [[AND27:%[0-9]+]]:_(s32) = G_AND [[COPY69]], [[C14]]
     ; CHECK: [[SHL23:%[0-9]+]]:_(s32) = G_SHL [[AND27]], [[C5]](s64)
-    ; CHECK: [[COPY71:%[0-9]+]]:_(s32) = COPY [[OR22]](s32)
-    ; CHECK: [[COPY72:%[0-9]+]]:_(s32) = COPY [[SHL23]](s32)
-    ; CHECK: [[OR23:%[0-9]+]]:_(s32) = G_OR [[COPY71]], [[COPY72]]
-    ; CHECK: [[COPY73:%[0-9]+]]:_(s32) = COPY [[LSHR24]](s32)
-    ; CHECK: [[AND28:%[0-9]+]]:_(s32) = G_AND [[COPY73]], [[C14]]
+    ; CHECK: [[COPY70:%[0-9]+]]:_(s32) = COPY [[OR22]](s32)
+    ; CHECK: [[COPY71:%[0-9]+]]:_(s32) = COPY [[SHL23]](s32)
+    ; CHECK: [[OR23:%[0-9]+]]:_(s32) = G_OR [[COPY70]], [[COPY71]]
+    ; CHECK: [[COPY72:%[0-9]+]]:_(s32) = COPY [[LSHR24]](s32)
+    ; CHECK: [[AND28:%[0-9]+]]:_(s32) = G_AND [[COPY72]], [[C14]]
     ; CHECK: [[SHL24:%[0-9]+]]:_(s32) = G_SHL [[AND28]], [[C7]](s64)
-    ; CHECK: [[COPY74:%[0-9]+]]:_(s32) = COPY [[OR23]](s32)
-    ; CHECK: [[COPY75:%[0-9]+]]:_(s32) = COPY [[SHL24]](s32)
-    ; CHECK: [[OR24:%[0-9]+]]:_(s32) = G_OR [[COPY74]], [[COPY75]]
-    ; CHECK: [[COPY76:%[0-9]+]]:_(s32) = COPY [[LSHR25]](s32)
-    ; CHECK: [[AND29:%[0-9]+]]:_(s32) = G_AND [[COPY76]], [[C14]]
+    ; CHECK: [[COPY73:%[0-9]+]]:_(s32) = COPY [[OR23]](s32)
+    ; CHECK: [[COPY74:%[0-9]+]]:_(s32) = COPY [[SHL24]](s32)
+    ; CHECK: [[OR24:%[0-9]+]]:_(s32) = G_OR [[COPY73]], [[COPY74]]
+    ; CHECK: [[COPY75:%[0-9]+]]:_(s32) = COPY [[LSHR25]](s32)
+    ; CHECK: [[AND29:%[0-9]+]]:_(s32) = G_AND [[COPY75]], [[C14]]
     ; CHECK: [[SHL25:%[0-9]+]]:_(s32) = G_SHL [[AND29]], [[C9]](s64)
-    ; CHECK: [[COPY77:%[0-9]+]]:_(s32) = COPY [[OR24]](s32)
-    ; CHECK: [[COPY78:%[0-9]+]]:_(s32) = COPY [[SHL25]](s32)
-    ; CHECK: [[OR25:%[0-9]+]]:_(s32) = G_OR [[COPY77]], [[COPY78]]
-    ; CHECK: [[COPY79:%[0-9]+]]:_(s32) = COPY [[LSHR26]](s32)
-    ; CHECK: [[AND30:%[0-9]+]]:_(s32) = G_AND [[COPY79]], [[C14]]
+    ; CHECK: [[COPY76:%[0-9]+]]:_(s32) = COPY [[OR24]](s32)
+    ; CHECK: [[COPY77:%[0-9]+]]:_(s32) = COPY [[SHL25]](s32)
+    ; CHECK: [[OR25:%[0-9]+]]:_(s32) = G_OR [[COPY76]], [[COPY77]]
+    ; CHECK: [[COPY78:%[0-9]+]]:_(s32) = COPY [[LSHR26]](s32)
+    ; CHECK: [[AND30:%[0-9]+]]:_(s32) = G_AND [[COPY78]], [[C14]]
     ; CHECK: [[SHL26:%[0-9]+]]:_(s32) = G_SHL [[AND30]], [[C11]](s64)
-    ; CHECK: [[COPY80:%[0-9]+]]:_(s32) = COPY [[OR25]](s32)
-    ; CHECK: [[COPY81:%[0-9]+]]:_(s32) = COPY [[SHL26]](s32)
-    ; CHECK: [[OR26:%[0-9]+]]:_(s32) = G_OR [[COPY80]], [[COPY81]]
-    ; CHECK: [[COPY82:%[0-9]+]]:_(s32) = COPY [[LSHR27]](s32)
-    ; CHECK: [[AND31:%[0-9]+]]:_(s32) = G_AND [[COPY82]], [[C14]]
+    ; CHECK: [[COPY79:%[0-9]+]]:_(s32) = COPY [[OR25]](s32)
+    ; CHECK: [[COPY80:%[0-9]+]]:_(s32) = COPY [[SHL26]](s32)
+    ; CHECK: [[OR26:%[0-9]+]]:_(s32) = G_OR [[COPY79]], [[COPY80]]
+    ; CHECK: [[COPY81:%[0-9]+]]:_(s32) = COPY [[LSHR27]](s32)
+    ; CHECK: [[AND31:%[0-9]+]]:_(s32) = G_AND [[COPY81]], [[C14]]
     ; CHECK: [[SHL27:%[0-9]+]]:_(s32) = G_SHL [[AND31]], [[C13]](s64)
-    ; CHECK: [[COPY83:%[0-9]+]]:_(s32) = COPY [[OR26]](s32)
-    ; CHECK: [[COPY84:%[0-9]+]]:_(s32) = COPY [[SHL27]](s32)
-    ; CHECK: [[OR27:%[0-9]+]]:_(s32) = G_OR [[COPY83]], [[COPY84]]
-    ; CHECK: [[TRUNC4:%[0-9]+]]:_(s8) = G_TRUNC [[OR27]](s32)
-    ; CHECK: [[COPY85:%[0-9]+]]:_(s32) = COPY [[LSHR28]](s32)
-    ; CHECK: [[AND32:%[0-9]+]]:_(s32) = G_AND [[COPY85]], [[C14]]
+    ; CHECK: [[COPY82:%[0-9]+]]:_(s32) = COPY [[OR26]](s32)
+    ; CHECK: [[COPY83:%[0-9]+]]:_(s32) = COPY [[SHL27]](s32)
+    ; CHECK: [[OR27:%[0-9]+]]:_(s32) = G_OR [[COPY82]], [[COPY83]]
+    ; CHECK: [[TRUNC3:%[0-9]+]]:_(s8) = G_TRUNC [[OR27]](s32)
+    ; CHECK: [[COPY84:%[0-9]+]]:_(s32) = COPY [[LSHR28]](s32)
+    ; CHECK: [[AND32:%[0-9]+]]:_(s32) = G_AND [[COPY84]], [[C14]]
     ; CHECK: [[SHL28:%[0-9]+]]:_(s32) = G_SHL [[AND32]], [[C1]](s64)
     ; CHECK: [[ANYEXT4:%[0-9]+]]:_(s32) = G_ANYEXT [[UV4]](s8)
     ; CHECK: [[AND33:%[0-9]+]]:_(s32) = G_AND [[ANYEXT4]], [[C14]]
-    ; CHECK: [[COPY86:%[0-9]+]]:_(s32) = COPY [[SHL28]](s32)
-    ; CHECK: [[OR28:%[0-9]+]]:_(s32) = G_OR [[AND33]], [[COPY86]]
-    ; CHECK: [[COPY87:%[0-9]+]]:_(s32) = COPY [[LSHR29]](s32)
-    ; CHECK: [[AND34:%[0-9]+]]:_(s32) = G_AND [[COPY87]], [[C14]]
+    ; CHECK: [[COPY85:%[0-9]+]]:_(s32) = COPY [[SHL28]](s32)
+    ; CHECK: [[OR28:%[0-9]+]]:_(s32) = G_OR [[AND33]], [[COPY85]]
+    ; CHECK: [[COPY86:%[0-9]+]]:_(s32) = COPY [[LSHR29]](s32)
+    ; CHECK: [[AND34:%[0-9]+]]:_(s32) = G_AND [[COPY86]], [[C14]]
     ; CHECK: [[SHL29:%[0-9]+]]:_(s32) = G_SHL [[AND34]], [[C3]](s64)
-    ; CHECK: [[COPY88:%[0-9]+]]:_(s32) = COPY [[OR28]](s32)
-    ; CHECK: [[COPY89:%[0-9]+]]:_(s32) = COPY [[SHL29]](s32)
-    ; CHECK: [[OR29:%[0-9]+]]:_(s32) = G_OR [[COPY88]], [[COPY89]]
-    ; CHECK: [[COPY90:%[0-9]+]]:_(s32) = COPY [[LSHR30]](s32)
-    ; CHECK: [[AND35:%[0-9]+]]:_(s32) = G_AND [[COPY90]], [[C14]]
+    ; CHECK: [[COPY87:%[0-9]+]]:_(s32) = COPY [[OR28]](s32)
+    ; CHECK: [[COPY88:%[0-9]+]]:_(s32) = COPY [[SHL29]](s32)
+    ; CHECK: [[OR29:%[0-9]+]]:_(s32) = G_OR [[COPY87]], [[COPY88]]
+    ; CHECK: [[COPY89:%[0-9]+]]:_(s32) = COPY [[LSHR30]](s32)
+    ; CHECK: [[AND35:%[0-9]+]]:_(s32) = G_AND [[COPY89]], [[C14]]
     ; CHECK: [[SHL30:%[0-9]+]]:_(s32) = G_SHL [[AND35]], [[C5]](s64)
-    ; CHECK: [[COPY91:%[0-9]+]]:_(s32) = COPY [[OR29]](s32)
-    ; CHECK: [[COPY92:%[0-9]+]]:_(s32) = COPY [[SHL30]](s32)
-    ; CHECK: [[OR30:%[0-9]+]]:_(s32) = G_OR [[COPY91]], [[COPY92]]
-    ; CHECK: [[COPY93:%[0-9]+]]:_(s32) = COPY [[LSHR31]](s32)
-    ; CHECK: [[AND36:%[0-9]+]]:_(s32) = G_AND [[COPY93]], [[C14]]
+    ; CHECK: [[COPY90:%[0-9]+]]:_(s32) = COPY [[OR29]](s32)
+    ; CHECK: [[COPY91:%[0-9]+]]:_(s32) = COPY [[SHL30]](s32)
+    ; CHECK: [[OR30:%[0-9]+]]:_(s32) = G_OR [[COPY90]], [[COPY91]]
+    ; CHECK: [[COPY92:%[0-9]+]]:_(s32) = COPY [[LSHR31]](s32)
+    ; CHECK: [[AND36:%[0-9]+]]:_(s32) = G_AND [[COPY92]], [[C14]]
     ; CHECK: [[SHL31:%[0-9]+]]:_(s32) = G_SHL [[AND36]], [[C7]](s64)
-    ; CHECK: [[COPY94:%[0-9]+]]:_(s32) = COPY [[OR30]](s32)
-    ; CHECK: [[COPY95:%[0-9]+]]:_(s32) = COPY [[SHL31]](s32)
-    ; CHECK: [[OR31:%[0-9]+]]:_(s32) = G_OR [[COPY94]], [[COPY95]]
-    ; CHECK: [[COPY96:%[0-9]+]]:_(s32) = COPY [[LSHR32]](s32)
-    ; CHECK: [[AND37:%[0-9]+]]:_(s32) = G_AND [[COPY96]], [[C14]]
+    ; CHECK: [[COPY93:%[0-9]+]]:_(s32) = COPY [[OR30]](s32)
+    ; CHECK: [[COPY94:%[0-9]+]]:_(s32) = COPY [[SHL31]](s32)
+    ; CHECK: [[OR31:%[0-9]+]]:_(s32) = G_OR [[COPY93]], [[COPY94]]
+    ; CHECK: [[COPY95:%[0-9]+]]:_(s32) = COPY [[LSHR32]](s32)
+    ; CHECK: [[AND37:%[0-9]+]]:_(s32) = G_AND [[COPY95]], [[C14]]
     ; CHECK: [[SHL32:%[0-9]+]]:_(s32) = G_SHL [[AND37]], [[C9]](s64)
-    ; CHECK: [[COPY97:%[0-9]+]]:_(s32) = COPY [[OR31]](s32)
-    ; CHECK: [[COPY98:%[0-9]+]]:_(s32) = COPY [[SHL32]](s32)
-    ; CHECK: [[OR32:%[0-9]+]]:_(s32) = G_OR [[COPY97]], [[COPY98]]
-    ; CHECK: [[COPY99:%[0-9]+]]:_(s32) = COPY [[LSHR33]](s32)
-    ; CHECK: [[AND38:%[0-9]+]]:_(s32) = G_AND [[COPY99]], [[C14]]
+    ; CHECK: [[COPY96:%[0-9]+]]:_(s32) = COPY [[OR31]](s32)
+    ; CHECK: [[COPY97:%[0-9]+]]:_(s32) = COPY [[SHL32]](s32)
+    ; CHECK: [[OR32:%[0-9]+]]:_(s32) = G_OR [[COPY96]], [[COPY97]]
+    ; CHECK: [[COPY98:%[0-9]+]]:_(s32) = COPY [[LSHR33]](s32)
+    ; CHECK: [[AND38:%[0-9]+]]:_(s32) = G_AND [[COPY98]], [[C14]]
     ; CHECK: [[SHL33:%[0-9]+]]:_(s32) = G_SHL [[AND38]], [[C11]](s64)
-    ; CHECK: [[COPY100:%[0-9]+]]:_(s32) = COPY [[OR32]](s32)
-    ; CHECK: [[COPY101:%[0-9]+]]:_(s32) = COPY [[SHL33]](s32)
-    ; CHECK: [[OR33:%[0-9]+]]:_(s32) = G_OR [[COPY100]], [[COPY101]]
-    ; CHECK: [[COPY102:%[0-9]+]]:_(s32) = COPY [[LSHR34]](s32)
-    ; CHECK: [[AND39:%[0-9]+]]:_(s32) = G_AND [[COPY102]], [[C14]]
+    ; CHECK: [[COPY99:%[0-9]+]]:_(s32) = COPY [[OR32]](s32)
+    ; CHECK: [[COPY100:%[0-9]+]]:_(s32) = COPY [[SHL33]](s32)
+    ; CHECK: [[OR33:%[0-9]+]]:_(s32) = G_OR [[COPY99]], [[COPY100]]
+    ; CHECK: [[COPY101:%[0-9]+]]:_(s32) = COPY [[LSHR34]](s32)
+    ; CHECK: [[AND39:%[0-9]+]]:_(s32) = G_AND [[COPY101]], [[C14]]
     ; CHECK: [[SHL34:%[0-9]+]]:_(s32) = G_SHL [[AND39]], [[C13]](s64)
-    ; CHECK: [[COPY103:%[0-9]+]]:_(s32) = COPY [[OR33]](s32)
-    ; CHECK: [[COPY104:%[0-9]+]]:_(s32) = COPY [[SHL34]](s32)
-    ; CHECK: [[OR34:%[0-9]+]]:_(s32) = G_OR [[COPY103]], [[COPY104]]
-    ; CHECK: [[TRUNC5:%[0-9]+]]:_(s8) = G_TRUNC [[OR34]](s32)
-    ; CHECK: [[COPY105:%[0-9]+]]:_(s32) = COPY [[LSHR35]](s32)
-    ; CHECK: [[AND40:%[0-9]+]]:_(s32) = G_AND [[COPY105]], [[C14]]
+    ; CHECK: [[COPY102:%[0-9]+]]:_(s32) = COPY [[OR33]](s32)
+    ; CHECK: [[COPY103:%[0-9]+]]:_(s32) = COPY [[SHL34]](s32)
+    ; CHECK: [[OR34:%[0-9]+]]:_(s32) = G_OR [[COPY102]], [[COPY103]]
+    ; CHECK: [[TRUNC4:%[0-9]+]]:_(s8) = G_TRUNC [[OR34]](s32)
+    ; CHECK: [[COPY104:%[0-9]+]]:_(s32) = COPY [[LSHR35]](s32)
+    ; CHECK: [[AND40:%[0-9]+]]:_(s32) = G_AND [[COPY104]], [[C14]]
     ; CHECK: [[SHL35:%[0-9]+]]:_(s32) = G_SHL [[AND40]], [[C1]](s64)
     ; CHECK: [[ANYEXT5:%[0-9]+]]:_(s32) = G_ANYEXT [[UV5]](s8)
     ; CHECK: [[AND41:%[0-9]+]]:_(s32) = G_AND [[ANYEXT5]], [[C14]]
-    ; CHECK: [[COPY106:%[0-9]+]]:_(s32) = COPY [[SHL35]](s32)
-    ; CHECK: [[OR35:%[0-9]+]]:_(s32) = G_OR [[AND41]], [[COPY106]]
-    ; CHECK: [[COPY107:%[0-9]+]]:_(s32) = COPY [[LSHR36]](s32)
-    ; CHECK: [[AND42:%[0-9]+]]:_(s32) = G_AND [[COPY107]], [[C14]]
+    ; CHECK: [[COPY105:%[0-9]+]]:_(s32) = COPY [[SHL35]](s32)
+    ; CHECK: [[OR35:%[0-9]+]]:_(s32) = G_OR [[AND41]], [[COPY105]]
+    ; CHECK: [[COPY106:%[0-9]+]]:_(s32) = COPY [[LSHR36]](s32)
+    ; CHECK: [[AND42:%[0-9]+]]:_(s32) = G_AND [[COPY106]], [[C14]]
     ; CHECK: [[SHL36:%[0-9]+]]:_(s32) = G_SHL [[AND42]], [[C3]](s64)
-    ; CHECK: [[COPY108:%[0-9]+]]:_(s32) = COPY [[OR35]](s32)
-    ; CHECK: [[COPY109:%[0-9]+]]:_(s32) = COPY [[SHL36]](s32)
-    ; CHECK: [[OR36:%[0-9]+]]:_(s32) = G_OR [[COPY108]], [[COPY109]]
-    ; CHECK: [[COPY110:%[0-9]+]]:_(s32) = COPY [[LSHR37]](s32)
-    ; CHECK: [[AND43:%[0-9]+]]:_(s32) = G_AND [[COPY110]], [[C14]]
+    ; CHECK: [[COPY107:%[0-9]+]]:_(s32) = COPY [[OR35]](s32)
+    ; CHECK: [[COPY108:%[0-9]+]]:_(s32) = COPY [[SHL36]](s32)
+    ; CHECK: [[OR36:%[0-9]+]]:_(s32) = G_OR [[COPY107]], [[COPY108]]
+    ; CHECK: [[COPY109:%[0-9]+]]:_(s32) = COPY [[LSHR37]](s32)
+    ; CHECK: [[AND43:%[0-9]+]]:_(s32) = G_AND [[COPY109]], [[C14]]
     ; CHECK: [[SHL37:%[0-9]+]]:_(s32) = G_SHL [[AND43]], [[C5]](s64)
-    ; CHECK: [[COPY111:%[0-9]+]]:_(s32) = COPY [[OR36]](s32)
-    ; CHECK: [[COPY112:%[0-9]+]]:_(s32) = COPY [[SHL37]](s32)
-    ; CHECK: [[OR37:%[0-9]+]]:_(s32) = G_OR [[COPY111]], [[COPY112]]
-    ; CHECK: [[COPY113:%[0-9]+]]:_(s32) = COPY [[LSHR38]](s32)
-    ; CHECK: [[AND44:%[0-9]+]]:_(s32) = G_AND [[COPY113]], [[C14]]
+    ; CHECK: [[COPY110:%[0-9]+]]:_(s32) = COPY [[OR36]](s32)
+    ; CHECK: [[COPY111:%[0-9]+]]:_(s32) = COPY [[SHL37]](s32)
+    ; CHECK: [[OR37:%[0-9]+]]:_(s32) = G_OR [[COPY110]], [[COPY111]]
+    ; CHECK: [[COPY112:%[0-9]+]]:_(s32) = COPY [[LSHR38]](s32)
+    ; CHECK: [[AND44:%[0-9]+]]:_(s32) = G_AND [[COPY112]], [[C14]]
     ; CHECK: [[SHL38:%[0-9]+]]:_(s32) = G_SHL [[AND44]], [[C7]](s64)
-    ; CHECK: [[COPY114:%[0-9]+]]:_(s32) = COPY [[OR37]](s32)
-    ; CHECK: [[COPY115:%[0-9]+]]:_(s32) = COPY [[SHL38]](s32)
-    ; CHECK: [[OR38:%[0-9]+]]:_(s32) = G_OR [[COPY114]], [[COPY115]]
-    ; CHECK: [[COPY116:%[0-9]+]]:_(s32) = COPY [[LSHR39]](s32)
-    ; CHECK: [[AND45:%[0-9]+]]:_(s32) = G_AND [[COPY116]], [[C14]]
+    ; CHECK: [[COPY113:%[0-9]+]]:_(s32) = COPY [[OR37]](s32)
+    ; CHECK: [[COPY114:%[0-9]+]]:_(s32) = COPY [[SHL38]](s32)
+    ; CHECK: [[OR38:%[0-9]+]]:_(s32) = G_OR [[COPY113]], [[COPY114]]
+    ; CHECK: [[COPY115:%[0-9]+]]:_(s32) = COPY [[LSHR39]](s32)
+    ; CHECK: [[AND45:%[0-9]+]]:_(s32) = G_AND [[COPY115]], [[C14]]
     ; CHECK: [[SHL39:%[0-9]+]]:_(s32) = G_SHL [[AND45]], [[C9]](s64)
-    ; CHECK: [[COPY117:%[0-9]+]]:_(s32) = COPY [[OR38]](s32)
-    ; CHECK: [[COPY118:%[0-9]+]]:_(s32) = COPY [[SHL39]](s32)
-    ; CHECK: [[OR39:%[0-9]+]]:_(s32) = G_OR [[COPY117]], [[COPY118]]
-    ; CHECK: [[COPY119:%[0-9]+]]:_(s32) = COPY [[LSHR40]](s32)
-    ; CHECK: [[AND46:%[0-9]+]]:_(s32) = G_AND [[COPY119]], [[C14]]
+    ; CHECK: [[COPY116:%[0-9]+]]:_(s32) = COPY [[OR38]](s32)
+    ; CHECK: [[COPY117:%[0-9]+]]:_(s32) = COPY [[SHL39]](s32)
+    ; CHECK: [[OR39:%[0-9]+]]:_(s32) = G_OR [[COPY116]], [[COPY117]]
+    ; CHECK: [[COPY118:%[0-9]+]]:_(s32) = COPY [[LSHR40]](s32)
+    ; CHECK: [[AND46:%[0-9]+]]:_(s32) = G_AND [[COPY118]], [[C14]]
     ; CHECK: [[SHL40:%[0-9]+]]:_(s32) = G_SHL [[AND46]], [[C11]](s64)
-    ; CHECK: [[COPY120:%[0-9]+]]:_(s32) = COPY [[OR39]](s32)
-    ; CHECK: [[COPY121:%[0-9]+]]:_(s32) = COPY [[SHL40]](s32)
-    ; CHECK: [[OR40:%[0-9]+]]:_(s32) = G_OR [[COPY120]], [[COPY121]]
-    ; CHECK: [[COPY122:%[0-9]+]]:_(s32) = COPY [[LSHR41]](s32)
-    ; CHECK: [[AND47:%[0-9]+]]:_(s32) = G_AND [[COPY122]], [[C14]]
+    ; CHECK: [[COPY119:%[0-9]+]]:_(s32) = COPY [[OR39]](s32)
+    ; CHECK: [[COPY120:%[0-9]+]]:_(s32) = COPY [[SHL40]](s32)
+    ; CHECK: [[OR40:%[0-9]+]]:_(s32) = G_OR [[COPY119]], [[COPY120]]
+    ; CHECK: [[COPY121:%[0-9]+]]:_(s32) = COPY [[LSHR41]](s32)
+    ; CHECK: [[AND47:%[0-9]+]]:_(s32) = G_AND [[COPY121]], [[C14]]
     ; CHECK: [[SHL41:%[0-9]+]]:_(s32) = G_SHL [[AND47]], [[C13]](s64)
-    ; CHECK: [[COPY123:%[0-9]+]]:_(s32) = COPY [[OR40]](s32)
-    ; CHECK: [[COPY124:%[0-9]+]]:_(s32) = COPY [[SHL41]](s32)
-    ; CHECK: [[OR41:%[0-9]+]]:_(s32) = G_OR [[COPY123]], [[COPY124]]
-    ; CHECK: [[TRUNC6:%[0-9]+]]:_(s8) = G_TRUNC [[OR41]](s32)
-    ; CHECK: [[COPY125:%[0-9]+]]:_(s32) = COPY [[LSHR42]](s32)
-    ; CHECK: [[AND48:%[0-9]+]]:_(s32) = G_AND [[COPY125]], [[C14]]
+    ; CHECK: [[COPY122:%[0-9]+]]:_(s32) = COPY [[OR40]](s32)
+    ; CHECK: [[COPY123:%[0-9]+]]:_(s32) = COPY [[SHL41]](s32)
+    ; CHECK: [[OR41:%[0-9]+]]:_(s32) = G_OR [[COPY122]], [[COPY123]]
+    ; CHECK: [[TRUNC5:%[0-9]+]]:_(s8) = G_TRUNC [[OR41]](s32)
+    ; CHECK: [[COPY124:%[0-9]+]]:_(s32) = COPY [[LSHR42]](s32)
+    ; CHECK: [[AND48:%[0-9]+]]:_(s32) = G_AND [[COPY124]], [[C14]]
     ; CHECK: [[SHL42:%[0-9]+]]:_(s32) = G_SHL [[AND48]], [[C1]](s64)
     ; CHECK: [[ANYEXT6:%[0-9]+]]:_(s32) = G_ANYEXT [[UV6]](s8)
     ; CHECK: [[AND49:%[0-9]+]]:_(s32) = G_AND [[ANYEXT6]], [[C14]]
-    ; CHECK: [[COPY126:%[0-9]+]]:_(s32) = COPY [[SHL42]](s32)
-    ; CHECK: [[OR42:%[0-9]+]]:_(s32) = G_OR [[AND49]], [[COPY126]]
-    ; CHECK: [[COPY127:%[0-9]+]]:_(s32) = COPY [[LSHR43]](s32)
-    ; CHECK: [[AND50:%[0-9]+]]:_(s32) = G_AND [[COPY127]], [[C14]]
+    ; CHECK: [[COPY125:%[0-9]+]]:_(s32) = COPY [[SHL42]](s32)
+    ; CHECK: [[OR42:%[0-9]+]]:_(s32) = G_OR [[AND49]], [[COPY125]]
+    ; CHECK: [[COPY126:%[0-9]+]]:_(s32) = COPY [[LSHR43]](s32)
+    ; CHECK: [[AND50:%[0-9]+]]:_(s32) = G_AND [[COPY126]], [[C14]]
     ; CHECK: [[SHL43:%[0-9]+]]:_(s32) = G_SHL [[AND50]], [[C3]](s64)
-    ; CHECK: [[COPY128:%[0-9]+]]:_(s32) = COPY [[OR42]](s32)
-    ; CHECK: [[COPY129:%[0-9]+]]:_(s32) = COPY [[SHL43]](s32)
-    ; CHECK: [[OR43:%[0-9]+]]:_(s32) = G_OR [[COPY128]], [[COPY129]]
-    ; CHECK: [[COPY130:%[0-9]+]]:_(s32) = COPY [[LSHR44]](s32)
-    ; CHECK: [[AND51:%[0-9]+]]:_(s32) = G_AND [[COPY130]], [[C14]]
+    ; CHECK: [[COPY127:%[0-9]+]]:_(s32) = COPY [[OR42]](s32)
+    ; CHECK: [[COPY128:%[0-9]+]]:_(s32) = COPY [[SHL43]](s32)
+    ; CHECK: [[OR43:%[0-9]+]]:_(s32) = G_OR [[COPY127]], [[COPY128]]
+    ; CHECK: [[COPY129:%[0-9]+]]:_(s32) = COPY [[LSHR44]](s32)
+    ; CHECK: [[AND51:%[0-9]+]]:_(s32) = G_AND [[COPY129]], [[C14]]
     ; CHECK: [[SHL44:%[0-9]+]]:_(s32) = G_SHL [[AND51]], [[C5]](s64)
-    ; CHECK: [[COPY131:%[0-9]+]]:_(s32) = COPY [[OR43]](s32)
-    ; CHECK: [[COPY132:%[0-9]+]]:_(s32) = COPY [[SHL44]](s32)
-    ; CHECK: [[OR44:%[0-9]+]]:_(s32) = G_OR [[COPY131]], [[COPY132]]
-    ; CHECK: [[COPY133:%[0-9]+]]:_(s32) = COPY [[LSHR45]](s32)
-    ; CHECK: [[AND52:%[0-9]+]]:_(s32) = G_AND [[COPY133]], [[C14]]
+    ; CHECK: [[COPY130:%[0-9]+]]:_(s32) = COPY [[OR43]](s32)
+    ; CHECK: [[COPY131:%[0-9]+]]:_(s32) = COPY [[SHL44]](s32)
+    ; CHECK: [[OR44:%[0-9]+]]:_(s32) = G_OR [[COPY130]], [[COPY131]]
+    ; CHECK: [[COPY132:%[0-9]+]]:_(s32) = COPY [[LSHR45]](s32)
+    ; CHECK: [[AND52:%[0-9]+]]:_(s32) = G_AND [[COPY132]], [[C14]]
     ; CHECK: [[SHL45:%[0-9]+]]:_(s32) = G_SHL [[AND52]], [[C7]](s64)
-    ; CHECK: [[COPY134:%[0-9]+]]:_(s32) = COPY [[OR44]](s32)
-    ; CHECK: [[COPY135:%[0-9]+]]:_(s32) = COPY [[SHL45]](s32)
-    ; CHECK: [[OR45:%[0-9]+]]:_(s32) = G_OR [[COPY134]], [[COPY135]]
-    ; CHECK: [[COPY136:%[0-9]+]]:_(s32) = COPY [[LSHR46]](s32)
-    ; CHECK: [[AND53:%[0-9]+]]:_(s32) = G_AND [[COPY136]], [[C14]]
+    ; CHECK: [[COPY133:%[0-9]+]]:_(s32) = COPY [[OR44]](s32)
+    ; CHECK: [[COPY134:%[0-9]+]]:_(s32) = COPY [[SHL45]](s32)
+    ; CHECK: [[OR45:%[0-9]+]]:_(s32) = G_OR [[COPY133]], [[COPY134]]
+    ; CHECK: [[COPY135:%[0-9]+]]:_(s32) = COPY [[LSHR46]](s32)
+    ; CHECK: [[AND53:%[0-9]+]]:_(s32) = G_AND [[COPY135]], [[C14]]
     ; CHECK: [[SHL46:%[0-9]+]]:_(s32) = G_SHL [[AND53]], [[C9]](s64)
-    ; CHECK: [[COPY137:%[0-9]+]]:_(s32) = COPY [[OR45]](s32)
-    ; CHECK: [[COPY138:%[0-9]+]]:_(s32) = COPY [[SHL46]](s32)
-    ; CHECK: [[OR46:%[0-9]+]]:_(s32) = G_OR [[COPY137]], [[COPY138]]
-    ; CHECK: [[COPY139:%[0-9]+]]:_(s32) = COPY [[LSHR47]](s32)
-    ; CHECK: [[AND54:%[0-9]+]]:_(s32) = G_AND [[COPY139]], [[C14]]
+    ; CHECK: [[COPY136:%[0-9]+]]:_(s32) = COPY [[OR45]](s32)
+    ; CHECK: [[COPY137:%[0-9]+]]:_(s32) = COPY [[SHL46]](s32)
+    ; CHECK: [[OR46:%[0-9]+]]:_(s32) = G_OR [[COPY136]], [[COPY137]]
+    ; CHECK: [[COPY138:%[0-9]+]]:_(s32) = COPY [[LSHR47]](s32)
+    ; CHECK: [[AND54:%[0-9]+]]:_(s32) = G_AND [[COPY138]], [[C14]]
     ; CHECK: [[SHL47:%[0-9]+]]:_(s32) = G_SHL [[AND54]], [[C11]](s64)
-    ; CHECK: [[COPY140:%[0-9]+]]:_(s32) = COPY [[OR46]](s32)
-    ; CHECK: [[COPY141:%[0-9]+]]:_(s32) = COPY [[SHL47]](s32)
-    ; CHECK: [[OR47:%[0-9]+]]:_(s32) = G_OR [[COPY140]], [[COPY141]]
-    ; CHECK: [[COPY142:%[0-9]+]]:_(s32) = COPY [[LSHR48]](s32)
-    ; CHECK: [[AND55:%[0-9]+]]:_(s32) = G_AND [[COPY142]], [[C14]]
+    ; CHECK: [[COPY139:%[0-9]+]]:_(s32) = COPY [[OR46]](s32)
+    ; CHECK: [[COPY140:%[0-9]+]]:_(s32) = COPY [[SHL47]](s32)
+    ; CHECK: [[OR47:%[0-9]+]]:_(s32) = G_OR [[COPY139]], [[COPY140]]
+    ; CHECK: [[COPY141:%[0-9]+]]:_(s32) = COPY [[LSHR48]](s32)
+    ; CHECK: [[AND55:%[0-9]+]]:_(s32) = G_AND [[COPY141]], [[C14]]
     ; CHECK: [[SHL48:%[0-9]+]]:_(s32) = G_SHL [[AND55]], [[C13]](s64)
-    ; CHECK: [[COPY143:%[0-9]+]]:_(s32) = COPY [[OR47]](s32)
-    ; CHECK: [[COPY144:%[0-9]+]]:_(s32) = COPY [[SHL48]](s32)
-    ; CHECK: [[OR48:%[0-9]+]]:_(s32) = G_OR [[COPY143]], [[COPY144]]
-    ; CHECK: [[TRUNC7:%[0-9]+]]:_(s8) = G_TRUNC [[OR48]](s32)
-    ; CHECK: [[COPY145:%[0-9]+]]:_(s32) = COPY [[LSHR49]](s32)
-    ; CHECK: [[AND56:%[0-9]+]]:_(s32) = G_AND [[COPY145]], [[C14]]
+    ; CHECK: [[COPY142:%[0-9]+]]:_(s32) = COPY [[OR47]](s32)
+    ; CHECK: [[COPY143:%[0-9]+]]:_(s32) = COPY [[SHL48]](s32)
+    ; CHECK: [[OR48:%[0-9]+]]:_(s32) = G_OR [[COPY142]], [[COPY143]]
+    ; CHECK: [[TRUNC6:%[0-9]+]]:_(s8) = G_TRUNC [[OR48]](s32)
+    ; CHECK: [[COPY144:%[0-9]+]]:_(s32) = COPY [[LSHR49]](s32)
+    ; CHECK: [[AND56:%[0-9]+]]:_(s32) = G_AND [[COPY144]], [[C14]]
     ; CHECK: [[SHL49:%[0-9]+]]:_(s32) = G_SHL [[AND56]], [[C1]](s64)
     ; CHECK: [[ANYEXT7:%[0-9]+]]:_(s32) = G_ANYEXT [[UV7]](s8)
     ; CHECK: [[AND57:%[0-9]+]]:_(s32) = G_AND [[ANYEXT7]], [[C14]]
-    ; CHECK: [[COPY146:%[0-9]+]]:_(s32) = COPY [[SHL49]](s32)
-    ; CHECK: [[OR49:%[0-9]+]]:_(s32) = G_OR [[AND57]], [[COPY146]]
-    ; CHECK: [[COPY147:%[0-9]+]]:_(s32) = COPY [[LSHR50]](s32)
-    ; CHECK: [[AND58:%[0-9]+]]:_(s32) = G_AND [[COPY147]], [[C14]]
+    ; CHECK: [[COPY145:%[0-9]+]]:_(s32) = COPY [[SHL49]](s32)
+    ; CHECK: [[OR49:%[0-9]+]]:_(s32) = G_OR [[AND57]], [[COPY145]]
+    ; CHECK: [[COPY146:%[0-9]+]]:_(s32) = COPY [[LSHR50]](s32)
+    ; CHECK: [[AND58:%[0-9]+]]:_(s32) = G_AND [[COPY146]], [[C14]]
     ; CHECK: [[SHL50:%[0-9]+]]:_(s32) = G_SHL [[AND58]], [[C3]](s64)
-    ; CHECK: [[COPY148:%[0-9]+]]:_(s32) = COPY [[OR49]](s32)
-    ; CHECK: [[COPY149:%[0-9]+]]:_(s32) = COPY [[SHL50]](s32)
-    ; CHECK: [[OR50:%[0-9]+]]:_(s32) = G_OR [[COPY148]], [[COPY149]]
-    ; CHECK: [[COPY150:%[0-9]+]]:_(s32) = COPY [[LSHR51]](s32)
-    ; CHECK: [[AND59:%[0-9]+]]:_(s32) = G_AND [[COPY150]], [[C14]]
+    ; CHECK: [[COPY147:%[0-9]+]]:_(s32) = COPY [[OR49]](s32)
+    ; CHECK: [[COPY148:%[0-9]+]]:_(s32) = COPY [[SHL50]](s32)
+    ; CHECK: [[OR50:%[0-9]+]]:_(s32) = G_OR [[COPY147]], [[COPY148]]
+    ; CHECK: [[COPY149:%[0-9]+]]:_(s32) = COPY [[LSHR51]](s32)
+    ; CHECK: [[AND59:%[0-9]+]]:_(s32) = G_AND [[COPY149]], [[C14]]
     ; CHECK: [[SHL51:%[0-9]+]]:_(s32) = G_SHL [[AND59]], [[C5]](s64)
-    ; CHECK: [[COPY151:%[0-9]+]]:_(s32) = COPY [[OR50]](s32)
-    ; CHECK: [[COPY152:%[0-9]+]]:_(s32) = COPY [[SHL51]](s32)
-    ; CHECK: [[OR51:%[0-9]+]]:_(s32) = G_OR [[COPY151]], [[COPY152]]
-    ; CHECK: [[COPY153:%[0-9]+]]:_(s32) = COPY [[LSHR52]](s32)
-    ; CHECK: [[AND60:%[0-9]+]]:_(s32) = G_AND [[COPY153]], [[C14]]
+    ; CHECK: [[COPY150:%[0-9]+]]:_(s32) = COPY [[OR50]](s32)
+    ; CHECK: [[COPY151:%[0-9]+]]:_(s32) = COPY [[SHL51]](s32)
+    ; CHECK: [[OR51:%[0-9]+]]:_(s32) = G_OR [[COPY150]], [[COPY151]]
+    ; CHECK: [[COPY152:%[0-9]+]]:_(s32) = COPY [[LSHR52]](s32)
+    ; CHECK: [[AND60:%[0-9]+]]:_(s32) = G_AND [[COPY152]], [[C14]]
     ; CHECK: [[SHL52:%[0-9]+]]:_(s32) = G_SHL [[AND60]], [[C7]](s64)
-    ; CHECK: [[COPY154:%[0-9]+]]:_(s32) = COPY [[OR51]](s32)
-    ; CHECK: [[COPY155:%[0-9]+]]:_(s32) = COPY [[SHL52]](s32)
-    ; CHECK: [[OR52:%[0-9]+]]:_(s32) = G_OR [[COPY154]], [[COPY155]]
-    ; CHECK: [[COPY156:%[0-9]+]]:_(s32) = COPY [[LSHR53]](s32)
-    ; CHECK: [[AND61:%[0-9]+]]:_(s32) = G_AND [[COPY156]], [[C14]]
+    ; CHECK: [[COPY153:%[0-9]+]]:_(s32) = COPY [[OR51]](s32)
+    ; CHECK: [[COPY154:%[0-9]+]]:_(s32) = COPY [[SHL52]](s32)
+    ; CHECK: [[OR52:%[0-9]+]]:_(s32) = G_OR [[COPY153]], [[COPY154]]
+    ; CHECK: [[COPY155:%[0-9]+]]:_(s32) = COPY [[LSHR53]](s32)
+    ; CHECK: [[AND61:%[0-9]+]]:_(s32) = G_AND [[COPY155]], [[C14]]
     ; CHECK: [[SHL53:%[0-9]+]]:_(s32) = G_SHL [[AND61]], [[C9]](s64)
-    ; CHECK: [[COPY157:%[0-9]+]]:_(s32) = COPY [[OR52]](s32)
-    ; CHECK: [[COPY158:%[0-9]+]]:_(s32) = COPY [[SHL53]](s32)
-    ; CHECK: [[OR53:%[0-9]+]]:_(s32) = G_OR [[COPY157]], [[COPY158]]
-    ; CHECK: [[COPY159:%[0-9]+]]:_(s32) = COPY [[LSHR54]](s32)
-    ; CHECK: [[AND62:%[0-9]+]]:_(s32) = G_AND [[COPY159]], [[C14]]
+    ; CHECK: [[COPY156:%[0-9]+]]:_(s32) = COPY [[OR52]](s32)
+    ; CHECK: [[COPY157:%[0-9]+]]:_(s32) = COPY [[SHL53]](s32)
+    ; CHECK: [[OR53:%[0-9]+]]:_(s32) = G_OR [[COPY156]], [[COPY157]]
+    ; CHECK: [[COPY158:%[0-9]+]]:_(s32) = COPY [[LSHR54]](s32)
+    ; CHECK: [[AND62:%[0-9]+]]:_(s32) = G_AND [[COPY158]], [[C14]]
     ; CHECK: [[SHL54:%[0-9]+]]:_(s32) = G_SHL [[AND62]], [[C11]](s64)
-    ; CHECK: [[COPY160:%[0-9]+]]:_(s32) = COPY [[OR53]](s32)
-    ; CHECK: [[COPY161:%[0-9]+]]:_(s32) = COPY [[SHL54]](s32)
-    ; CHECK: [[OR54:%[0-9]+]]:_(s32) = G_OR [[COPY160]], [[COPY161]]
-    ; CHECK: [[COPY162:%[0-9]+]]:_(s32) = COPY [[LSHR55]](s32)
-    ; CHECK: [[AND63:%[0-9]+]]:_(s32) = G_AND [[COPY162]], [[C14]]
+    ; CHECK: [[COPY159:%[0-9]+]]:_(s32) = COPY [[OR53]](s32)
+    ; CHECK: [[COPY160:%[0-9]+]]:_(s32) = COPY [[SHL54]](s32)
+    ; CHECK: [[OR54:%[0-9]+]]:_(s32) = G_OR [[COPY159]], [[COPY160]]
+    ; CHECK: [[COPY161:%[0-9]+]]:_(s32) = COPY [[LSHR55]](s32)
+    ; CHECK: [[AND63:%[0-9]+]]:_(s32) = G_AND [[COPY161]], [[C14]]
     ; CHECK: [[SHL55:%[0-9]+]]:_(s32) = G_SHL [[AND63]], [[C13]](s64)
-    ; CHECK: [[COPY163:%[0-9]+]]:_(s32) = COPY [[OR54]](s32)
-    ; CHECK: [[COPY164:%[0-9]+]]:_(s32) = COPY [[SHL55]](s32)
-    ; CHECK: [[OR55:%[0-9]+]]:_(s32) = G_OR [[COPY163]], [[COPY164]]
-    ; CHECK: [[TRUNC8:%[0-9]+]]:_(s8) = G_TRUNC [[OR55]](s32)
-    ; CHECK: [[MV:%[0-9]+]]:_(s64) = G_MERGE_VALUES [[TRUNC1]](s8), [[TRUNC2]](s8), [[TRUNC3]](s8), [[TRUNC4]](s8), [[TRUNC5]](s8), [[TRUNC6]](s8), [[TRUNC7]](s8), [[TRUNC8]](s8)
+    ; CHECK: [[COPY162:%[0-9]+]]:_(s32) = COPY [[OR54]](s32)
+    ; CHECK: [[COPY163:%[0-9]+]]:_(s32) = COPY [[SHL55]](s32)
+    ; CHECK: [[OR55:%[0-9]+]]:_(s32) = G_OR [[COPY162]], [[COPY163]]
+    ; CHECK: [[TRUNC7:%[0-9]+]]:_(s8) = G_TRUNC [[OR55]](s32)
+    ; CHECK: [[MV:%[0-9]+]]:_(s64) = G_MERGE_VALUES [[TRUNC]](s8), [[TRUNC1]](s8), [[TRUNC2]](s8), [[TRUNC3]](s8), [[TRUNC4]](s8), [[TRUNC5]](s8), [[TRUNC6]](s8), [[TRUNC7]](s8)
     ; CHECK: [[C15:%[0-9]+]]:_(s32) = G_CONSTANT i32 0
-    ; CHECK: [[COPY165:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL56:%[0-9]+]]:_(s32) = G_SHL [[COPY165]], [[C1]](s64)
-    ; CHECK: [[ANYEXT8:%[0-9]+]]:_(s32) = G_ANYEXT [[UV8]](s8)
-    ; CHECK: [[AND64:%[0-9]+]]:_(s32) = G_AND [[ANYEXT8]], [[C14]]
-    ; CHECK: [[COPY166:%[0-9]+]]:_(s32) = COPY [[SHL56]](s32)
-    ; CHECK: [[OR56:%[0-9]+]]:_(s32) = G_OR [[AND64]], [[COPY166]]
-    ; CHECK: [[COPY167:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL57:%[0-9]+]]:_(s32) = G_SHL [[COPY167]], [[C3]](s64)
-    ; CHECK: [[COPY168:%[0-9]+]]:_(s32) = COPY [[OR56]](s32)
-    ; CHECK: [[COPY169:%[0-9]+]]:_(s32) = COPY [[SHL57]](s32)
-    ; CHECK: [[OR57:%[0-9]+]]:_(s32) = G_OR [[COPY168]], [[COPY169]]
-    ; CHECK: [[COPY170:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL58:%[0-9]+]]:_(s32) = G_SHL [[COPY170]], [[C5]](s64)
-    ; CHECK: [[COPY171:%[0-9]+]]:_(s32) = COPY [[OR57]](s32)
-    ; CHECK: [[COPY172:%[0-9]+]]:_(s32) = COPY [[SHL58]](s32)
-    ; CHECK: [[OR58:%[0-9]+]]:_(s32) = G_OR [[COPY171]], [[COPY172]]
-    ; CHECK: [[COPY173:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL59:%[0-9]+]]:_(s32) = G_SHL [[COPY173]], [[C7]](s64)
-    ; CHECK: [[COPY174:%[0-9]+]]:_(s32) = COPY [[OR58]](s32)
-    ; CHECK: [[COPY175:%[0-9]+]]:_(s32) = COPY [[SHL59]](s32)
-    ; CHECK: [[OR59:%[0-9]+]]:_(s32) = G_OR [[COPY174]], [[COPY175]]
-    ; CHECK: [[COPY176:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL60:%[0-9]+]]:_(s32) = G_SHL [[COPY176]], [[C9]](s64)
-    ; CHECK: [[COPY177:%[0-9]+]]:_(s32) = COPY [[OR59]](s32)
-    ; CHECK: [[COPY178:%[0-9]+]]:_(s32) = COPY [[SHL60]](s32)
-    ; CHECK: [[OR60:%[0-9]+]]:_(s32) = G_OR [[COPY177]], [[COPY178]]
-    ; CHECK: [[COPY179:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL61:%[0-9]+]]:_(s32) = G_SHL [[COPY179]], [[C11]](s64)
-    ; CHECK: [[COPY180:%[0-9]+]]:_(s32) = COPY [[OR60]](s32)
-    ; CHECK: [[COPY181:%[0-9]+]]:_(s32) = COPY [[SHL61]](s32)
-    ; CHECK: [[OR61:%[0-9]+]]:_(s32) = G_OR [[COPY180]], [[COPY181]]
-    ; CHECK: [[COPY182:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL62:%[0-9]+]]:_(s32) = G_SHL [[COPY182]], [[C13]](s64)
-    ; CHECK: [[COPY183:%[0-9]+]]:_(s32) = COPY [[OR61]](s32)
-    ; CHECK: [[COPY184:%[0-9]+]]:_(s32) = COPY [[SHL62]](s32)
-    ; CHECK: [[OR62:%[0-9]+]]:_(s32) = G_OR [[COPY183]], [[COPY184]]
+    ; CHECK: [[COPY164:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL56:%[0-9]+]]:_(s32) = G_SHL [[COPY164]], [[C1]](s64)
+    ; CHECK: [[TRUNC8:%[0-9]+]]:_(s32) = G_TRUNC [[COPY2]](s64)
+    ; CHECK: [[AND64:%[0-9]+]]:_(s32) = G_AND [[TRUNC8]], [[C14]]
+    ; CHECK: [[COPY165:%[0-9]+]]:_(s32) = COPY [[SHL56]](s32)
+    ; CHECK: [[OR56:%[0-9]+]]:_(s32) = G_OR [[AND64]], [[COPY165]]
+    ; CHECK: [[COPY166:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL57:%[0-9]+]]:_(s32) = G_SHL [[COPY166]], [[C3]](s64)
+    ; CHECK: [[COPY167:%[0-9]+]]:_(s32) = COPY [[OR56]](s32)
+    ; CHECK: [[COPY168:%[0-9]+]]:_(s32) = COPY [[SHL57]](s32)
+    ; CHECK: [[OR57:%[0-9]+]]:_(s32) = G_OR [[COPY167]], [[COPY168]]
+    ; CHECK: [[COPY169:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL58:%[0-9]+]]:_(s32) = G_SHL [[COPY169]], [[C5]](s64)
+    ; CHECK: [[COPY170:%[0-9]+]]:_(s32) = COPY [[OR57]](s32)
+    ; CHECK: [[COPY171:%[0-9]+]]:_(s32) = COPY [[SHL58]](s32)
+    ; CHECK: [[OR58:%[0-9]+]]:_(s32) = G_OR [[COPY170]], [[COPY171]]
+    ; CHECK: [[COPY172:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL59:%[0-9]+]]:_(s32) = G_SHL [[COPY172]], [[C7]](s64)
+    ; CHECK: [[COPY173:%[0-9]+]]:_(s32) = COPY [[OR58]](s32)
+    ; CHECK: [[COPY174:%[0-9]+]]:_(s32) = COPY [[SHL59]](s32)
+    ; CHECK: [[OR59:%[0-9]+]]:_(s32) = G_OR [[COPY173]], [[COPY174]]
+    ; CHECK: [[COPY175:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL60:%[0-9]+]]:_(s32) = G_SHL [[COPY175]], [[C9]](s64)
+    ; CHECK: [[COPY176:%[0-9]+]]:_(s32) = COPY [[OR59]](s32)
+    ; CHECK: [[COPY177:%[0-9]+]]:_(s32) = COPY [[SHL60]](s32)
+    ; CHECK: [[OR60:%[0-9]+]]:_(s32) = G_OR [[COPY176]], [[COPY177]]
+    ; CHECK: [[COPY178:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL61:%[0-9]+]]:_(s32) = G_SHL [[COPY178]], [[C11]](s64)
+    ; CHECK: [[COPY179:%[0-9]+]]:_(s32) = COPY [[OR60]](s32)
+    ; CHECK: [[COPY180:%[0-9]+]]:_(s32) = COPY [[SHL61]](s32)
+    ; CHECK: [[OR61:%[0-9]+]]:_(s32) = G_OR [[COPY179]], [[COPY180]]
+    ; CHECK: [[COPY181:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL62:%[0-9]+]]:_(s32) = G_SHL [[COPY181]], [[C13]](s64)
+    ; CHECK: [[COPY182:%[0-9]+]]:_(s32) = COPY [[OR61]](s32)
+    ; CHECK: [[COPY183:%[0-9]+]]:_(s32) = COPY [[SHL62]](s32)
+    ; CHECK: [[OR62:%[0-9]+]]:_(s32) = G_OR [[COPY182]], [[COPY183]]
     ; CHECK: [[TRUNC9:%[0-9]+]]:_(s8) = G_TRUNC [[OR62]](s32)
+    ; CHECK: [[COPY184:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL63:%[0-9]+]]:_(s32) = G_SHL [[COPY184]], [[C1]](s64)
     ; CHECK: [[COPY185:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL63:%[0-9]+]]:_(s32) = G_SHL [[COPY185]], [[C1]](s64)
-    ; CHECK: [[COPY186:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY187:%[0-9]+]]:_(s32) = COPY [[SHL63]](s32)
-    ; CHECK: [[OR63:%[0-9]+]]:_(s32) = G_OR [[COPY186]], [[COPY187]]
-    ; CHECK: [[COPY188:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL64:%[0-9]+]]:_(s32) = G_SHL [[COPY188]], [[C3]](s64)
-    ; CHECK: [[COPY189:%[0-9]+]]:_(s32) = COPY [[OR63]](s32)
-    ; CHECK: [[COPY190:%[0-9]+]]:_(s32) = COPY [[SHL64]](s32)
-    ; CHECK: [[OR64:%[0-9]+]]:_(s32) = G_OR [[COPY189]], [[COPY190]]
-    ; CHECK: [[COPY191:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL65:%[0-9]+]]:_(s32) = G_SHL [[COPY191]], [[C5]](s64)
-    ; CHECK: [[COPY192:%[0-9]+]]:_(s32) = COPY [[OR64]](s32)
-    ; CHECK: [[COPY193:%[0-9]+]]:_(s32) = COPY [[SHL65]](s32)
-    ; CHECK: [[OR65:%[0-9]+]]:_(s32) = G_OR [[COPY192]], [[COPY193]]
-    ; CHECK: [[COPY194:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL66:%[0-9]+]]:_(s32) = G_SHL [[COPY194]], [[C7]](s64)
-    ; CHECK: [[COPY195:%[0-9]+]]:_(s32) = COPY [[OR65]](s32)
-    ; CHECK: [[COPY196:%[0-9]+]]:_(s32) = COPY [[SHL66]](s32)
-    ; CHECK: [[OR66:%[0-9]+]]:_(s32) = G_OR [[COPY195]], [[COPY196]]
-    ; CHECK: [[COPY197:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL67:%[0-9]+]]:_(s32) = G_SHL [[COPY197]], [[C9]](s64)
-    ; CHECK: [[COPY198:%[0-9]+]]:_(s32) = COPY [[OR66]](s32)
-    ; CHECK: [[COPY199:%[0-9]+]]:_(s32) = COPY [[SHL67]](s32)
-    ; CHECK: [[OR67:%[0-9]+]]:_(s32) = G_OR [[COPY198]], [[COPY199]]
-    ; CHECK: [[COPY200:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL68:%[0-9]+]]:_(s32) = G_SHL [[COPY200]], [[C11]](s64)
-    ; CHECK: [[COPY201:%[0-9]+]]:_(s32) = COPY [[OR67]](s32)
-    ; CHECK: [[COPY202:%[0-9]+]]:_(s32) = COPY [[SHL68]](s32)
-    ; CHECK: [[OR68:%[0-9]+]]:_(s32) = G_OR [[COPY201]], [[COPY202]]
-    ; CHECK: [[COPY203:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL69:%[0-9]+]]:_(s32) = G_SHL [[COPY203]], [[C13]](s64)
-    ; CHECK: [[COPY204:%[0-9]+]]:_(s32) = COPY [[OR68]](s32)
-    ; CHECK: [[COPY205:%[0-9]+]]:_(s32) = COPY [[SHL69]](s32)
-    ; CHECK: [[OR69:%[0-9]+]]:_(s32) = G_OR [[COPY204]], [[COPY205]]
+    ; CHECK: [[COPY186:%[0-9]+]]:_(s32) = COPY [[SHL63]](s32)
+    ; CHECK: [[OR63:%[0-9]+]]:_(s32) = G_OR [[COPY185]], [[COPY186]]
+    ; CHECK: [[COPY187:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL64:%[0-9]+]]:_(s32) = G_SHL [[COPY187]], [[C3]](s64)
+    ; CHECK: [[COPY188:%[0-9]+]]:_(s32) = COPY [[OR63]](s32)
+    ; CHECK: [[COPY189:%[0-9]+]]:_(s32) = COPY [[SHL64]](s32)
+    ; CHECK: [[OR64:%[0-9]+]]:_(s32) = G_OR [[COPY188]], [[COPY189]]
+    ; CHECK: [[COPY190:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL65:%[0-9]+]]:_(s32) = G_SHL [[COPY190]], [[C5]](s64)
+    ; CHECK: [[COPY191:%[0-9]+]]:_(s32) = COPY [[OR64]](s32)
+    ; CHECK: [[COPY192:%[0-9]+]]:_(s32) = COPY [[SHL65]](s32)
+    ; CHECK: [[OR65:%[0-9]+]]:_(s32) = G_OR [[COPY191]], [[COPY192]]
+    ; CHECK: [[COPY193:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL66:%[0-9]+]]:_(s32) = G_SHL [[COPY193]], [[C7]](s64)
+    ; CHECK: [[COPY194:%[0-9]+]]:_(s32) = COPY [[OR65]](s32)
+    ; CHECK: [[COPY195:%[0-9]+]]:_(s32) = COPY [[SHL66]](s32)
+    ; CHECK: [[OR66:%[0-9]+]]:_(s32) = G_OR [[COPY194]], [[COPY195]]
+    ; CHECK: [[COPY196:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL67:%[0-9]+]]:_(s32) = G_SHL [[COPY196]], [[C9]](s64)
+    ; CHECK: [[COPY197:%[0-9]+]]:_(s32) = COPY [[OR66]](s32)
+    ; CHECK: [[COPY198:%[0-9]+]]:_(s32) = COPY [[SHL67]](s32)
+    ; CHECK: [[OR67:%[0-9]+]]:_(s32) = G_OR [[COPY197]], [[COPY198]]
+    ; CHECK: [[COPY199:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL68:%[0-9]+]]:_(s32) = G_SHL [[COPY199]], [[C11]](s64)
+    ; CHECK: [[COPY200:%[0-9]+]]:_(s32) = COPY [[OR67]](s32)
+    ; CHECK: [[COPY201:%[0-9]+]]:_(s32) = COPY [[SHL68]](s32)
+    ; CHECK: [[OR68:%[0-9]+]]:_(s32) = G_OR [[COPY200]], [[COPY201]]
+    ; CHECK: [[COPY202:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL69:%[0-9]+]]:_(s32) = G_SHL [[COPY202]], [[C13]](s64)
+    ; CHECK: [[COPY203:%[0-9]+]]:_(s32) = COPY [[OR68]](s32)
+    ; CHECK: [[COPY204:%[0-9]+]]:_(s32) = COPY [[SHL69]](s32)
+    ; CHECK: [[OR69:%[0-9]+]]:_(s32) = G_OR [[COPY203]], [[COPY204]]
     ; CHECK: [[TRUNC10:%[0-9]+]]:_(s8) = G_TRUNC [[OR69]](s32)
+    ; CHECK: [[COPY205:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL70:%[0-9]+]]:_(s32) = G_SHL [[COPY205]], [[C1]](s64)
     ; CHECK: [[COPY206:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL70:%[0-9]+]]:_(s32) = G_SHL [[COPY206]], [[C1]](s64)
-    ; CHECK: [[COPY207:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY208:%[0-9]+]]:_(s32) = COPY [[SHL70]](s32)
-    ; CHECK: [[OR70:%[0-9]+]]:_(s32) = G_OR [[COPY207]], [[COPY208]]
-    ; CHECK: [[COPY209:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL71:%[0-9]+]]:_(s32) = G_SHL [[COPY209]], [[C3]](s64)
-    ; CHECK: [[COPY210:%[0-9]+]]:_(s32) = COPY [[OR70]](s32)
-    ; CHECK: [[COPY211:%[0-9]+]]:_(s32) = COPY [[SHL71]](s32)
-    ; CHECK: [[OR71:%[0-9]+]]:_(s32) = G_OR [[COPY210]], [[COPY211]]
-    ; CHECK: [[COPY212:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL72:%[0-9]+]]:_(s32) = G_SHL [[COPY212]], [[C5]](s64)
-    ; CHECK: [[COPY213:%[0-9]+]]:_(s32) = COPY [[OR71]](s32)
-    ; CHECK: [[COPY214:%[0-9]+]]:_(s32) = COPY [[SHL72]](s32)
-    ; CHECK: [[OR72:%[0-9]+]]:_(s32) = G_OR [[COPY213]], [[COPY214]]
-    ; CHECK: [[COPY215:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL73:%[0-9]+]]:_(s32) = G_SHL [[COPY215]], [[C7]](s64)
-    ; CHECK: [[COPY216:%[0-9]+]]:_(s32) = COPY [[OR72]](s32)
-    ; CHECK: [[COPY217:%[0-9]+]]:_(s32) = COPY [[SHL73]](s32)
-    ; CHECK: [[OR73:%[0-9]+]]:_(s32) = G_OR [[COPY216]], [[COPY217]]
-    ; CHECK: [[COPY218:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL74:%[0-9]+]]:_(s32) = G_SHL [[COPY218]], [[C9]](s64)
-    ; CHECK: [[COPY219:%[0-9]+]]:_(s32) = COPY [[OR73]](s32)
-    ; CHECK: [[COPY220:%[0-9]+]]:_(s32) = COPY [[SHL74]](s32)
-    ; CHECK: [[OR74:%[0-9]+]]:_(s32) = G_OR [[COPY219]], [[COPY220]]
-    ; CHECK: [[COPY221:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL75:%[0-9]+]]:_(s32) = G_SHL [[COPY221]], [[C11]](s64)
-    ; CHECK: [[COPY222:%[0-9]+]]:_(s32) = COPY [[OR74]](s32)
-    ; CHECK: [[COPY223:%[0-9]+]]:_(s32) = COPY [[SHL75]](s32)
-    ; CHECK: [[OR75:%[0-9]+]]:_(s32) = G_OR [[COPY222]], [[COPY223]]
-    ; CHECK: [[COPY224:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL76:%[0-9]+]]:_(s32) = G_SHL [[COPY224]], [[C13]](s64)
-    ; CHECK: [[COPY225:%[0-9]+]]:_(s32) = COPY [[OR75]](s32)
-    ; CHECK: [[COPY226:%[0-9]+]]:_(s32) = COPY [[SHL76]](s32)
-    ; CHECK: [[OR76:%[0-9]+]]:_(s32) = G_OR [[COPY225]], [[COPY226]]
+    ; CHECK: [[COPY207:%[0-9]+]]:_(s32) = COPY [[SHL70]](s32)
+    ; CHECK: [[OR70:%[0-9]+]]:_(s32) = G_OR [[COPY206]], [[COPY207]]
+    ; CHECK: [[COPY208:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL71:%[0-9]+]]:_(s32) = G_SHL [[COPY208]], [[C3]](s64)
+    ; CHECK: [[COPY209:%[0-9]+]]:_(s32) = COPY [[OR70]](s32)
+    ; CHECK: [[COPY210:%[0-9]+]]:_(s32) = COPY [[SHL71]](s32)
+    ; CHECK: [[OR71:%[0-9]+]]:_(s32) = G_OR [[COPY209]], [[COPY210]]
+    ; CHECK: [[COPY211:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL72:%[0-9]+]]:_(s32) = G_SHL [[COPY211]], [[C5]](s64)
+    ; CHECK: [[COPY212:%[0-9]+]]:_(s32) = COPY [[OR71]](s32)
+    ; CHECK: [[COPY213:%[0-9]+]]:_(s32) = COPY [[SHL72]](s32)
+    ; CHECK: [[OR72:%[0-9]+]]:_(s32) = G_OR [[COPY212]], [[COPY213]]
+    ; CHECK: [[COPY214:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL73:%[0-9]+]]:_(s32) = G_SHL [[COPY214]], [[C7]](s64)
+    ; CHECK: [[COPY215:%[0-9]+]]:_(s32) = COPY [[OR72]](s32)
+    ; CHECK: [[COPY216:%[0-9]+]]:_(s32) = COPY [[SHL73]](s32)
+    ; CHECK: [[OR73:%[0-9]+]]:_(s32) = G_OR [[COPY215]], [[COPY216]]
+    ; CHECK: [[COPY217:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL74:%[0-9]+]]:_(s32) = G_SHL [[COPY217]], [[C9]](s64)
+    ; CHECK: [[COPY218:%[0-9]+]]:_(s32) = COPY [[OR73]](s32)
+    ; CHECK: [[COPY219:%[0-9]+]]:_(s32) = COPY [[SHL74]](s32)
+    ; CHECK: [[OR74:%[0-9]+]]:_(s32) = G_OR [[COPY218]], [[COPY219]]
+    ; CHECK: [[COPY220:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL75:%[0-9]+]]:_(s32) = G_SHL [[COPY220]], [[C11]](s64)
+    ; CHECK: [[COPY221:%[0-9]+]]:_(s32) = COPY [[OR74]](s32)
+    ; CHECK: [[COPY222:%[0-9]+]]:_(s32) = COPY [[SHL75]](s32)
+    ; CHECK: [[OR75:%[0-9]+]]:_(s32) = G_OR [[COPY221]], [[COPY222]]
+    ; CHECK: [[COPY223:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL76:%[0-9]+]]:_(s32) = G_SHL [[COPY223]], [[C13]](s64)
+    ; CHECK: [[COPY224:%[0-9]+]]:_(s32) = COPY [[OR75]](s32)
+    ; CHECK: [[COPY225:%[0-9]+]]:_(s32) = COPY [[SHL76]](s32)
+    ; CHECK: [[OR76:%[0-9]+]]:_(s32) = G_OR [[COPY224]], [[COPY225]]
     ; CHECK: [[TRUNC11:%[0-9]+]]:_(s8) = G_TRUNC [[OR76]](s32)
+    ; CHECK: [[COPY226:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL77:%[0-9]+]]:_(s32) = G_SHL [[COPY226]], [[C1]](s64)
     ; CHECK: [[COPY227:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL77:%[0-9]+]]:_(s32) = G_SHL [[COPY227]], [[C1]](s64)
-    ; CHECK: [[COPY228:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY229:%[0-9]+]]:_(s32) = COPY [[SHL77]](s32)
-    ; CHECK: [[OR77:%[0-9]+]]:_(s32) = G_OR [[COPY228]], [[COPY229]]
-    ; CHECK: [[COPY230:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL78:%[0-9]+]]:_(s32) = G_SHL [[COPY230]], [[C3]](s64)
-    ; CHECK: [[COPY231:%[0-9]+]]:_(s32) = COPY [[OR77]](s32)
-    ; CHECK: [[COPY232:%[0-9]+]]:_(s32) = COPY [[SHL78]](s32)
-    ; CHECK: [[OR78:%[0-9]+]]:_(s32) = G_OR [[COPY231]], [[COPY232]]
-    ; CHECK: [[COPY233:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL79:%[0-9]+]]:_(s32) = G_SHL [[COPY233]], [[C5]](s64)
-    ; CHECK: [[COPY234:%[0-9]+]]:_(s32) = COPY [[OR78]](s32)
-    ; CHECK: [[COPY235:%[0-9]+]]:_(s32) = COPY [[SHL79]](s32)
-    ; CHECK: [[OR79:%[0-9]+]]:_(s32) = G_OR [[COPY234]], [[COPY235]]
-    ; CHECK: [[COPY236:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL80:%[0-9]+]]:_(s32) = G_SHL [[COPY236]], [[C7]](s64)
-    ; CHECK: [[COPY237:%[0-9]+]]:_(s32) = COPY [[OR79]](s32)
-    ; CHECK: [[COPY238:%[0-9]+]]:_(s32) = COPY [[SHL80]](s32)
-    ; CHECK: [[OR80:%[0-9]+]]:_(s32) = G_OR [[COPY237]], [[COPY238]]
-    ; CHECK: [[COPY239:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL81:%[0-9]+]]:_(s32) = G_SHL [[COPY239]], [[C9]](s64)
-    ; CHECK: [[COPY240:%[0-9]+]]:_(s32) = COPY [[OR80]](s32)
-    ; CHECK: [[COPY241:%[0-9]+]]:_(s32) = COPY [[SHL81]](s32)
-    ; CHECK: [[OR81:%[0-9]+]]:_(s32) = G_OR [[COPY240]], [[COPY241]]
-    ; CHECK: [[COPY242:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL82:%[0-9]+]]:_(s32) = G_SHL [[COPY242]], [[C11]](s64)
-    ; CHECK: [[COPY243:%[0-9]+]]:_(s32) = COPY [[OR81]](s32)
-    ; CHECK: [[COPY244:%[0-9]+]]:_(s32) = COPY [[SHL82]](s32)
-    ; CHECK: [[OR82:%[0-9]+]]:_(s32) = G_OR [[COPY243]], [[COPY244]]
-    ; CHECK: [[COPY245:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL83:%[0-9]+]]:_(s32) = G_SHL [[COPY245]], [[C13]](s64)
-    ; CHECK: [[COPY246:%[0-9]+]]:_(s32) = COPY [[OR82]](s32)
-    ; CHECK: [[COPY247:%[0-9]+]]:_(s32) = COPY [[SHL83]](s32)
-    ; CHECK: [[OR83:%[0-9]+]]:_(s32) = G_OR [[COPY246]], [[COPY247]]
+    ; CHECK: [[COPY228:%[0-9]+]]:_(s32) = COPY [[SHL77]](s32)
+    ; CHECK: [[OR77:%[0-9]+]]:_(s32) = G_OR [[COPY227]], [[COPY228]]
+    ; CHECK: [[COPY229:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL78:%[0-9]+]]:_(s32) = G_SHL [[COPY229]], [[C3]](s64)
+    ; CHECK: [[COPY230:%[0-9]+]]:_(s32) = COPY [[OR77]](s32)
+    ; CHECK: [[COPY231:%[0-9]+]]:_(s32) = COPY [[SHL78]](s32)
+    ; CHECK: [[OR78:%[0-9]+]]:_(s32) = G_OR [[COPY230]], [[COPY231]]
+    ; CHECK: [[COPY232:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL79:%[0-9]+]]:_(s32) = G_SHL [[COPY232]], [[C5]](s64)
+    ; CHECK: [[COPY233:%[0-9]+]]:_(s32) = COPY [[OR78]](s32)
+    ; CHECK: [[COPY234:%[0-9]+]]:_(s32) = COPY [[SHL79]](s32)
+    ; CHECK: [[OR79:%[0-9]+]]:_(s32) = G_OR [[COPY233]], [[COPY234]]
+    ; CHECK: [[COPY235:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL80:%[0-9]+]]:_(s32) = G_SHL [[COPY235]], [[C7]](s64)
+    ; CHECK: [[COPY236:%[0-9]+]]:_(s32) = COPY [[OR79]](s32)
+    ; CHECK: [[COPY237:%[0-9]+]]:_(s32) = COPY [[SHL80]](s32)
+    ; CHECK: [[OR80:%[0-9]+]]:_(s32) = G_OR [[COPY236]], [[COPY237]]
+    ; CHECK: [[COPY238:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL81:%[0-9]+]]:_(s32) = G_SHL [[COPY238]], [[C9]](s64)
+    ; CHECK: [[COPY239:%[0-9]+]]:_(s32) = COPY [[OR80]](s32)
+    ; CHECK: [[COPY240:%[0-9]+]]:_(s32) = COPY [[SHL81]](s32)
+    ; CHECK: [[OR81:%[0-9]+]]:_(s32) = G_OR [[COPY239]], [[COPY240]]
+    ; CHECK: [[COPY241:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL82:%[0-9]+]]:_(s32) = G_SHL [[COPY241]], [[C11]](s64)
+    ; CHECK: [[COPY242:%[0-9]+]]:_(s32) = COPY [[OR81]](s32)
+    ; CHECK: [[COPY243:%[0-9]+]]:_(s32) = COPY [[SHL82]](s32)
+    ; CHECK: [[OR82:%[0-9]+]]:_(s32) = G_OR [[COPY242]], [[COPY243]]
+    ; CHECK: [[COPY244:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL83:%[0-9]+]]:_(s32) = G_SHL [[COPY244]], [[C13]](s64)
+    ; CHECK: [[COPY245:%[0-9]+]]:_(s32) = COPY [[OR82]](s32)
+    ; CHECK: [[COPY246:%[0-9]+]]:_(s32) = COPY [[SHL83]](s32)
+    ; CHECK: [[OR83:%[0-9]+]]:_(s32) = G_OR [[COPY245]], [[COPY246]]
     ; CHECK: [[TRUNC12:%[0-9]+]]:_(s8) = G_TRUNC [[OR83]](s32)
+    ; CHECK: [[COPY247:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL84:%[0-9]+]]:_(s32) = G_SHL [[COPY247]], [[C1]](s64)
     ; CHECK: [[COPY248:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL84:%[0-9]+]]:_(s32) = G_SHL [[COPY248]], [[C1]](s64)
-    ; CHECK: [[COPY249:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY250:%[0-9]+]]:_(s32) = COPY [[SHL84]](s32)
-    ; CHECK: [[OR84:%[0-9]+]]:_(s32) = G_OR [[COPY249]], [[COPY250]]
-    ; CHECK: [[COPY251:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL85:%[0-9]+]]:_(s32) = G_SHL [[COPY251]], [[C3]](s64)
-    ; CHECK: [[COPY252:%[0-9]+]]:_(s32) = COPY [[OR84]](s32)
-    ; CHECK: [[COPY253:%[0-9]+]]:_(s32) = COPY [[SHL85]](s32)
-    ; CHECK: [[OR85:%[0-9]+]]:_(s32) = G_OR [[COPY252]], [[COPY253]]
-    ; CHECK: [[COPY254:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL86:%[0-9]+]]:_(s32) = G_SHL [[COPY254]], [[C5]](s64)
-    ; CHECK: [[COPY255:%[0-9]+]]:_(s32) = COPY [[OR85]](s32)
-    ; CHECK: [[COPY256:%[0-9]+]]:_(s32) = COPY [[SHL86]](s32)
-    ; CHECK: [[OR86:%[0-9]+]]:_(s32) = G_OR [[COPY255]], [[COPY256]]
-    ; CHECK: [[COPY257:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL87:%[0-9]+]]:_(s32) = G_SHL [[COPY257]], [[C7]](s64)
-    ; CHECK: [[COPY258:%[0-9]+]]:_(s32) = COPY [[OR86]](s32)
-    ; CHECK: [[COPY259:%[0-9]+]]:_(s32) = COPY [[SHL87]](s32)
-    ; CHECK: [[OR87:%[0-9]+]]:_(s32) = G_OR [[COPY258]], [[COPY259]]
-    ; CHECK: [[COPY260:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL88:%[0-9]+]]:_(s32) = G_SHL [[COPY260]], [[C9]](s64)
-    ; CHECK: [[COPY261:%[0-9]+]]:_(s32) = COPY [[OR87]](s32)
-    ; CHECK: [[COPY262:%[0-9]+]]:_(s32) = COPY [[SHL88]](s32)
-    ; CHECK: [[OR88:%[0-9]+]]:_(s32) = G_OR [[COPY261]], [[COPY262]]
-    ; CHECK: [[COPY263:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL89:%[0-9]+]]:_(s32) = G_SHL [[COPY263]], [[C11]](s64)
-    ; CHECK: [[COPY264:%[0-9]+]]:_(s32) = COPY [[OR88]](s32)
-    ; CHECK: [[COPY265:%[0-9]+]]:_(s32) = COPY [[SHL89]](s32)
-    ; CHECK: [[OR89:%[0-9]+]]:_(s32) = G_OR [[COPY264]], [[COPY265]]
-    ; CHECK: [[COPY266:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL90:%[0-9]+]]:_(s32) = G_SHL [[COPY266]], [[C13]](s64)
-    ; CHECK: [[COPY267:%[0-9]+]]:_(s32) = COPY [[OR89]](s32)
-    ; CHECK: [[COPY268:%[0-9]+]]:_(s32) = COPY [[SHL90]](s32)
-    ; CHECK: [[OR90:%[0-9]+]]:_(s32) = G_OR [[COPY267]], [[COPY268]]
+    ; CHECK: [[COPY249:%[0-9]+]]:_(s32) = COPY [[SHL84]](s32)
+    ; CHECK: [[OR84:%[0-9]+]]:_(s32) = G_OR [[COPY248]], [[COPY249]]
+    ; CHECK: [[COPY250:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL85:%[0-9]+]]:_(s32) = G_SHL [[COPY250]], [[C3]](s64)
+    ; CHECK: [[COPY251:%[0-9]+]]:_(s32) = COPY [[OR84]](s32)
+    ; CHECK: [[COPY252:%[0-9]+]]:_(s32) = COPY [[SHL85]](s32)
+    ; CHECK: [[OR85:%[0-9]+]]:_(s32) = G_OR [[COPY251]], [[COPY252]]
+    ; CHECK: [[COPY253:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL86:%[0-9]+]]:_(s32) = G_SHL [[COPY253]], [[C5]](s64)
+    ; CHECK: [[COPY254:%[0-9]+]]:_(s32) = COPY [[OR85]](s32)
+    ; CHECK: [[COPY255:%[0-9]+]]:_(s32) = COPY [[SHL86]](s32)
+    ; CHECK: [[OR86:%[0-9]+]]:_(s32) = G_OR [[COPY254]], [[COPY255]]
+    ; CHECK: [[COPY256:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL87:%[0-9]+]]:_(s32) = G_SHL [[COPY256]], [[C7]](s64)
+    ; CHECK: [[COPY257:%[0-9]+]]:_(s32) = COPY [[OR86]](s32)
+    ; CHECK: [[COPY258:%[0-9]+]]:_(s32) = COPY [[SHL87]](s32)
+    ; CHECK: [[OR87:%[0-9]+]]:_(s32) = G_OR [[COPY257]], [[COPY258]]
+    ; CHECK: [[COPY259:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL88:%[0-9]+]]:_(s32) = G_SHL [[COPY259]], [[C9]](s64)
+    ; CHECK: [[COPY260:%[0-9]+]]:_(s32) = COPY [[OR87]](s32)
+    ; CHECK: [[COPY261:%[0-9]+]]:_(s32) = COPY [[SHL88]](s32)
+    ; CHECK: [[OR88:%[0-9]+]]:_(s32) = G_OR [[COPY260]], [[COPY261]]
+    ; CHECK: [[COPY262:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL89:%[0-9]+]]:_(s32) = G_SHL [[COPY262]], [[C11]](s64)
+    ; CHECK: [[COPY263:%[0-9]+]]:_(s32) = COPY [[OR88]](s32)
+    ; CHECK: [[COPY264:%[0-9]+]]:_(s32) = COPY [[SHL89]](s32)
+    ; CHECK: [[OR89:%[0-9]+]]:_(s32) = G_OR [[COPY263]], [[COPY264]]
+    ; CHECK: [[COPY265:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL90:%[0-9]+]]:_(s32) = G_SHL [[COPY265]], [[C13]](s64)
+    ; CHECK: [[COPY266:%[0-9]+]]:_(s32) = COPY [[OR89]](s32)
+    ; CHECK: [[COPY267:%[0-9]+]]:_(s32) = COPY [[SHL90]](s32)
+    ; CHECK: [[OR90:%[0-9]+]]:_(s32) = G_OR [[COPY266]], [[COPY267]]
     ; CHECK: [[TRUNC13:%[0-9]+]]:_(s8) = G_TRUNC [[OR90]](s32)
+    ; CHECK: [[COPY268:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL91:%[0-9]+]]:_(s32) = G_SHL [[COPY268]], [[C1]](s64)
     ; CHECK: [[COPY269:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL91:%[0-9]+]]:_(s32) = G_SHL [[COPY269]], [[C1]](s64)
-    ; CHECK: [[COPY270:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY271:%[0-9]+]]:_(s32) = COPY [[SHL91]](s32)
-    ; CHECK: [[OR91:%[0-9]+]]:_(s32) = G_OR [[COPY270]], [[COPY271]]
-    ; CHECK: [[COPY272:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL92:%[0-9]+]]:_(s32) = G_SHL [[COPY272]], [[C3]](s64)
-    ; CHECK: [[COPY273:%[0-9]+]]:_(s32) = COPY [[OR91]](s32)
-    ; CHECK: [[COPY274:%[0-9]+]]:_(s32) = COPY [[SHL92]](s32)
-    ; CHECK: [[OR92:%[0-9]+]]:_(s32) = G_OR [[COPY273]], [[COPY274]]
-    ; CHECK: [[COPY275:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL93:%[0-9]+]]:_(s32) = G_SHL [[COPY275]], [[C5]](s64)
-    ; CHECK: [[COPY276:%[0-9]+]]:_(s32) = COPY [[OR92]](s32)
-    ; CHECK: [[COPY277:%[0-9]+]]:_(s32) = COPY [[SHL93]](s32)
-    ; CHECK: [[OR93:%[0-9]+]]:_(s32) = G_OR [[COPY276]], [[COPY277]]
-    ; CHECK: [[COPY278:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL94:%[0-9]+]]:_(s32) = G_SHL [[COPY278]], [[C7]](s64)
-    ; CHECK: [[COPY279:%[0-9]+]]:_(s32) = COPY [[OR93]](s32)
-    ; CHECK: [[COPY280:%[0-9]+]]:_(s32) = COPY [[SHL94]](s32)
-    ; CHECK: [[OR94:%[0-9]+]]:_(s32) = G_OR [[COPY279]], [[COPY280]]
-    ; CHECK: [[COPY281:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL95:%[0-9]+]]:_(s32) = G_SHL [[COPY281]], [[C9]](s64)
-    ; CHECK: [[COPY282:%[0-9]+]]:_(s32) = COPY [[OR94]](s32)
-    ; CHECK: [[COPY283:%[0-9]+]]:_(s32) = COPY [[SHL95]](s32)
-    ; CHECK: [[OR95:%[0-9]+]]:_(s32) = G_OR [[COPY282]], [[COPY283]]
-    ; CHECK: [[COPY284:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL96:%[0-9]+]]:_(s32) = G_SHL [[COPY284]], [[C11]](s64)
-    ; CHECK: [[COPY285:%[0-9]+]]:_(s32) = COPY [[OR95]](s32)
-    ; CHECK: [[COPY286:%[0-9]+]]:_(s32) = COPY [[SHL96]](s32)
-    ; CHECK: [[OR96:%[0-9]+]]:_(s32) = G_OR [[COPY285]], [[COPY286]]
-    ; CHECK: [[COPY287:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL97:%[0-9]+]]:_(s32) = G_SHL [[COPY287]], [[C13]](s64)
-    ; CHECK: [[COPY288:%[0-9]+]]:_(s32) = COPY [[OR96]](s32)
-    ; CHECK: [[COPY289:%[0-9]+]]:_(s32) = COPY [[SHL97]](s32)
-    ; CHECK: [[OR97:%[0-9]+]]:_(s32) = G_OR [[COPY288]], [[COPY289]]
+    ; CHECK: [[COPY270:%[0-9]+]]:_(s32) = COPY [[SHL91]](s32)
+    ; CHECK: [[OR91:%[0-9]+]]:_(s32) = G_OR [[COPY269]], [[COPY270]]
+    ; CHECK: [[COPY271:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL92:%[0-9]+]]:_(s32) = G_SHL [[COPY271]], [[C3]](s64)
+    ; CHECK: [[COPY272:%[0-9]+]]:_(s32) = COPY [[OR91]](s32)
+    ; CHECK: [[COPY273:%[0-9]+]]:_(s32) = COPY [[SHL92]](s32)
+    ; CHECK: [[OR92:%[0-9]+]]:_(s32) = G_OR [[COPY272]], [[COPY273]]
+    ; CHECK: [[COPY274:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL93:%[0-9]+]]:_(s32) = G_SHL [[COPY274]], [[C5]](s64)
+    ; CHECK: [[COPY275:%[0-9]+]]:_(s32) = COPY [[OR92]](s32)
+    ; CHECK: [[COPY276:%[0-9]+]]:_(s32) = COPY [[SHL93]](s32)
+    ; CHECK: [[OR93:%[0-9]+]]:_(s32) = G_OR [[COPY275]], [[COPY276]]
+    ; CHECK: [[COPY277:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL94:%[0-9]+]]:_(s32) = G_SHL [[COPY277]], [[C7]](s64)
+    ; CHECK: [[COPY278:%[0-9]+]]:_(s32) = COPY [[OR93]](s32)
+    ; CHECK: [[COPY279:%[0-9]+]]:_(s32) = COPY [[SHL94]](s32)
+    ; CHECK: [[OR94:%[0-9]+]]:_(s32) = G_OR [[COPY278]], [[COPY279]]
+    ; CHECK: [[COPY280:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL95:%[0-9]+]]:_(s32) = G_SHL [[COPY280]], [[C9]](s64)
+    ; CHECK: [[COPY281:%[0-9]+]]:_(s32) = COPY [[OR94]](s32)
+    ; CHECK: [[COPY282:%[0-9]+]]:_(s32) = COPY [[SHL95]](s32)
+    ; CHECK: [[OR95:%[0-9]+]]:_(s32) = G_OR [[COPY281]], [[COPY282]]
+    ; CHECK: [[COPY283:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL96:%[0-9]+]]:_(s32) = G_SHL [[COPY283]], [[C11]](s64)
+    ; CHECK: [[COPY284:%[0-9]+]]:_(s32) = COPY [[OR95]](s32)
+    ; CHECK: [[COPY285:%[0-9]+]]:_(s32) = COPY [[SHL96]](s32)
+    ; CHECK: [[OR96:%[0-9]+]]:_(s32) = G_OR [[COPY284]], [[COPY285]]
+    ; CHECK: [[COPY286:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL97:%[0-9]+]]:_(s32) = G_SHL [[COPY286]], [[C13]](s64)
+    ; CHECK: [[COPY287:%[0-9]+]]:_(s32) = COPY [[OR96]](s32)
+    ; CHECK: [[COPY288:%[0-9]+]]:_(s32) = COPY [[SHL97]](s32)
+    ; CHECK: [[OR97:%[0-9]+]]:_(s32) = G_OR [[COPY287]], [[COPY288]]
     ; CHECK: [[TRUNC14:%[0-9]+]]:_(s8) = G_TRUNC [[OR97]](s32)
+    ; CHECK: [[COPY289:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL98:%[0-9]+]]:_(s32) = G_SHL [[COPY289]], [[C1]](s64)
     ; CHECK: [[COPY290:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL98:%[0-9]+]]:_(s32) = G_SHL [[COPY290]], [[C1]](s64)
-    ; CHECK: [[COPY291:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY292:%[0-9]+]]:_(s32) = COPY [[SHL98]](s32)
-    ; CHECK: [[OR98:%[0-9]+]]:_(s32) = G_OR [[COPY291]], [[COPY292]]
-    ; CHECK: [[COPY293:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL99:%[0-9]+]]:_(s32) = G_SHL [[COPY293]], [[C3]](s64)
-    ; CHECK: [[COPY294:%[0-9]+]]:_(s32) = COPY [[OR98]](s32)
-    ; CHECK: [[COPY295:%[0-9]+]]:_(s32) = COPY [[SHL99]](s32)
-    ; CHECK: [[OR99:%[0-9]+]]:_(s32) = G_OR [[COPY294]], [[COPY295]]
-    ; CHECK: [[COPY296:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL100:%[0-9]+]]:_(s32) = G_SHL [[COPY296]], [[C5]](s64)
-    ; CHECK: [[COPY297:%[0-9]+]]:_(s32) = COPY [[OR99]](s32)
-    ; CHECK: [[COPY298:%[0-9]+]]:_(s32) = COPY [[SHL100]](s32)
-    ; CHECK: [[OR100:%[0-9]+]]:_(s32) = G_OR [[COPY297]], [[COPY298]]
-    ; CHECK: [[COPY299:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL101:%[0-9]+]]:_(s32) = G_SHL [[COPY299]], [[C7]](s64)
-    ; CHECK: [[COPY300:%[0-9]+]]:_(s32) = COPY [[OR100]](s32)
-    ; CHECK: [[COPY301:%[0-9]+]]:_(s32) = COPY [[SHL101]](s32)
-    ; CHECK: [[OR101:%[0-9]+]]:_(s32) = G_OR [[COPY300]], [[COPY301]]
-    ; CHECK: [[COPY302:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL102:%[0-9]+]]:_(s32) = G_SHL [[COPY302]], [[C9]](s64)
-    ; CHECK: [[COPY303:%[0-9]+]]:_(s32) = COPY [[OR101]](s32)
-    ; CHECK: [[COPY304:%[0-9]+]]:_(s32) = COPY [[SHL102]](s32)
-    ; CHECK: [[OR102:%[0-9]+]]:_(s32) = G_OR [[COPY303]], [[COPY304]]
-    ; CHECK: [[COPY305:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL103:%[0-9]+]]:_(s32) = G_SHL [[COPY305]], [[C11]](s64)
-    ; CHECK: [[COPY306:%[0-9]+]]:_(s32) = COPY [[OR102]](s32)
-    ; CHECK: [[COPY307:%[0-9]+]]:_(s32) = COPY [[SHL103]](s32)
-    ; CHECK: [[OR103:%[0-9]+]]:_(s32) = G_OR [[COPY306]], [[COPY307]]
-    ; CHECK: [[COPY308:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL104:%[0-9]+]]:_(s32) = G_SHL [[COPY308]], [[C13]](s64)
-    ; CHECK: [[COPY309:%[0-9]+]]:_(s32) = COPY [[OR103]](s32)
-    ; CHECK: [[COPY310:%[0-9]+]]:_(s32) = COPY [[SHL104]](s32)
-    ; CHECK: [[OR104:%[0-9]+]]:_(s32) = G_OR [[COPY309]], [[COPY310]]
+    ; CHECK: [[COPY291:%[0-9]+]]:_(s32) = COPY [[SHL98]](s32)
+    ; CHECK: [[OR98:%[0-9]+]]:_(s32) = G_OR [[COPY290]], [[COPY291]]
+    ; CHECK: [[COPY292:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL99:%[0-9]+]]:_(s32) = G_SHL [[COPY292]], [[C3]](s64)
+    ; CHECK: [[COPY293:%[0-9]+]]:_(s32) = COPY [[OR98]](s32)
+    ; CHECK: [[COPY294:%[0-9]+]]:_(s32) = COPY [[SHL99]](s32)
+    ; CHECK: [[OR99:%[0-9]+]]:_(s32) = G_OR [[COPY293]], [[COPY294]]
+    ; CHECK: [[COPY295:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL100:%[0-9]+]]:_(s32) = G_SHL [[COPY295]], [[C5]](s64)
+    ; CHECK: [[COPY296:%[0-9]+]]:_(s32) = COPY [[OR99]](s32)
+    ; CHECK: [[COPY297:%[0-9]+]]:_(s32) = COPY [[SHL100]](s32)
+    ; CHECK: [[OR100:%[0-9]+]]:_(s32) = G_OR [[COPY296]], [[COPY297]]
+    ; CHECK: [[COPY298:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL101:%[0-9]+]]:_(s32) = G_SHL [[COPY298]], [[C7]](s64)
+    ; CHECK: [[COPY299:%[0-9]+]]:_(s32) = COPY [[OR100]](s32)
+    ; CHECK: [[COPY300:%[0-9]+]]:_(s32) = COPY [[SHL101]](s32)
+    ; CHECK: [[OR101:%[0-9]+]]:_(s32) = G_OR [[COPY299]], [[COPY300]]
+    ; CHECK: [[COPY301:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL102:%[0-9]+]]:_(s32) = G_SHL [[COPY301]], [[C9]](s64)
+    ; CHECK: [[COPY302:%[0-9]+]]:_(s32) = COPY [[OR101]](s32)
+    ; CHECK: [[COPY303:%[0-9]+]]:_(s32) = COPY [[SHL102]](s32)
+    ; CHECK: [[OR102:%[0-9]+]]:_(s32) = G_OR [[COPY302]], [[COPY303]]
+    ; CHECK: [[COPY304:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL103:%[0-9]+]]:_(s32) = G_SHL [[COPY304]], [[C11]](s64)
+    ; CHECK: [[COPY305:%[0-9]+]]:_(s32) = COPY [[OR102]](s32)
+    ; CHECK: [[COPY306:%[0-9]+]]:_(s32) = COPY [[SHL103]](s32)
+    ; CHECK: [[OR103:%[0-9]+]]:_(s32) = G_OR [[COPY305]], [[COPY306]]
+    ; CHECK: [[COPY307:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL104:%[0-9]+]]:_(s32) = G_SHL [[COPY307]], [[C13]](s64)
+    ; CHECK: [[COPY308:%[0-9]+]]:_(s32) = COPY [[OR103]](s32)
+    ; CHECK: [[COPY309:%[0-9]+]]:_(s32) = COPY [[SHL104]](s32)
+    ; CHECK: [[OR104:%[0-9]+]]:_(s32) = G_OR [[COPY308]], [[COPY309]]
     ; CHECK: [[TRUNC15:%[0-9]+]]:_(s8) = G_TRUNC [[OR104]](s32)
     ; CHECK: [[SHL105:%[0-9]+]]:_(s32) = G_SHL [[C15]], [[C1]](s64)
-    ; CHECK: [[COPY311:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[COPY312:%[0-9]+]]:_(s32) = COPY [[SHL105]](s32)
-    ; CHECK: [[OR105:%[0-9]+]]:_(s32) = G_OR [[COPY311]], [[COPY312]]
-    ; CHECK: [[COPY313:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL106:%[0-9]+]]:_(s32) = G_SHL [[COPY313]], [[C3]](s64)
-    ; CHECK: [[COPY314:%[0-9]+]]:_(s32) = COPY [[OR105]](s32)
-    ; CHECK: [[COPY315:%[0-9]+]]:_(s32) = COPY [[SHL106]](s32)
-    ; CHECK: [[OR106:%[0-9]+]]:_(s32) = G_OR [[COPY314]], [[COPY315]]
-    ; CHECK: [[COPY316:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL107:%[0-9]+]]:_(s32) = G_SHL [[COPY316]], [[C5]](s64)
-    ; CHECK: [[COPY317:%[0-9]+]]:_(s32) = COPY [[OR106]](s32)
-    ; CHECK: [[COPY318:%[0-9]+]]:_(s32) = COPY [[SHL107]](s32)
-    ; CHECK: [[OR107:%[0-9]+]]:_(s32) = G_OR [[COPY317]], [[COPY318]]
-    ; CHECK: [[COPY319:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL108:%[0-9]+]]:_(s32) = G_SHL [[COPY319]], [[C7]](s64)
-    ; CHECK: [[COPY320:%[0-9]+]]:_(s32) = COPY [[OR107]](s32)
-    ; CHECK: [[COPY321:%[0-9]+]]:_(s32) = COPY [[SHL108]](s32)
-    ; CHECK: [[OR108:%[0-9]+]]:_(s32) = G_OR [[COPY320]], [[COPY321]]
-    ; CHECK: [[COPY322:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL109:%[0-9]+]]:_(s32) = G_SHL [[COPY322]], [[C9]](s64)
-    ; CHECK: [[COPY323:%[0-9]+]]:_(s32) = COPY [[OR108]](s32)
-    ; CHECK: [[COPY324:%[0-9]+]]:_(s32) = COPY [[SHL109]](s32)
-    ; CHECK: [[OR109:%[0-9]+]]:_(s32) = G_OR [[COPY323]], [[COPY324]]
-    ; CHECK: [[COPY325:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL110:%[0-9]+]]:_(s32) = G_SHL [[COPY325]], [[C11]](s64)
-    ; CHECK: [[COPY326:%[0-9]+]]:_(s32) = COPY [[OR109]](s32)
-    ; CHECK: [[COPY327:%[0-9]+]]:_(s32) = COPY [[SHL110]](s32)
-    ; CHECK: [[OR110:%[0-9]+]]:_(s32) = G_OR [[COPY326]], [[COPY327]]
-    ; CHECK: [[COPY328:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
-    ; CHECK: [[SHL111:%[0-9]+]]:_(s32) = G_SHL [[COPY328]], [[C13]](s64)
-    ; CHECK: [[COPY329:%[0-9]+]]:_(s32) = COPY [[OR110]](s32)
-    ; CHECK: [[COPY330:%[0-9]+]]:_(s32) = COPY [[SHL111]](s32)
-    ; CHECK: [[OR111:%[0-9]+]]:_(s32) = G_OR [[COPY329]], [[COPY330]]
+    ; CHECK: [[COPY310:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[COPY311:%[0-9]+]]:_(s32) = COPY [[SHL105]](s32)
+    ; CHECK: [[OR105:%[0-9]+]]:_(s32) = G_OR [[COPY310]], [[COPY311]]
+    ; CHECK: [[COPY312:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL106:%[0-9]+]]:_(s32) = G_SHL [[COPY312]], [[C3]](s64)
+    ; CHECK: [[COPY313:%[0-9]+]]:_(s32) = COPY [[OR105]](s32)
+    ; CHECK: [[COPY314:%[0-9]+]]:_(s32) = COPY [[SHL106]](s32)
+    ; CHECK: [[OR106:%[0-9]+]]:_(s32) = G_OR [[COPY313]], [[COPY314]]
+    ; CHECK: [[COPY315:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL107:%[0-9]+]]:_(s32) = G_SHL [[COPY315]], [[C5]](s64)
+    ; CHECK: [[COPY316:%[0-9]+]]:_(s32) = COPY [[OR106]](s32)
+    ; CHECK: [[COPY317:%[0-9]+]]:_(s32) = COPY [[SHL107]](s32)
+    ; CHECK: [[OR107:%[0-9]+]]:_(s32) = G_OR [[COPY316]], [[COPY317]]
+    ; CHECK: [[COPY318:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL108:%[0-9]+]]:_(s32) = G_SHL [[COPY318]], [[C7]](s64)
+    ; CHECK: [[COPY319:%[0-9]+]]:_(s32) = COPY [[OR107]](s32)
+    ; CHECK: [[COPY320:%[0-9]+]]:_(s32) = COPY [[SHL108]](s32)
+    ; CHECK: [[OR108:%[0-9]+]]:_(s32) = G_OR [[COPY319]], [[COPY320]]
+    ; CHECK: [[COPY321:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL109:%[0-9]+]]:_(s32) = G_SHL [[COPY321]], [[C9]](s64)
+    ; CHECK: [[COPY322:%[0-9]+]]:_(s32) = COPY [[OR108]](s32)
+    ; CHECK: [[COPY323:%[0-9]+]]:_(s32) = COPY [[SHL109]](s32)
+    ; CHECK: [[OR109:%[0-9]+]]:_(s32) = G_OR [[COPY322]], [[COPY323]]
+    ; CHECK: [[COPY324:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL110:%[0-9]+]]:_(s32) = G_SHL [[COPY324]], [[C11]](s64)
+    ; CHECK: [[COPY325:%[0-9]+]]:_(s32) = COPY [[OR109]](s32)
+    ; CHECK: [[COPY326:%[0-9]+]]:_(s32) = COPY [[SHL110]](s32)
+    ; CHECK: [[OR110:%[0-9]+]]:_(s32) = G_OR [[COPY325]], [[COPY326]]
+    ; CHECK: [[COPY327:%[0-9]+]]:_(s32) = COPY [[C15]](s32)
+    ; CHECK: [[SHL111:%[0-9]+]]:_(s32) = G_SHL [[COPY327]], [[C13]](s64)
+    ; CHECK: [[COPY328:%[0-9]+]]:_(s32) = COPY [[OR110]](s32)
+    ; CHECK: [[COPY329:%[0-9]+]]:_(s32) = COPY [[SHL111]](s32)
+    ; CHECK: [[OR111:%[0-9]+]]:_(s32) = G_OR [[COPY328]], [[COPY329]]
     ; CHECK: [[TRUNC16:%[0-9]+]]:_(s8) = G_TRUNC [[OR111]](s32)
     ; CHECK: [[MV1:%[0-9]+]]:_(s64) = G_MERGE_VALUES [[TRUNC9]](s8), [[TRUNC10]](s8), [[TRUNC11]](s8), [[TRUNC12]](s8), [[TRUNC13]](s8), [[TRUNC14]](s8), [[TRUNC15]](s8), [[TRUNC16]](s8)
     ; CHECK: $x0 = COPY [[MV]](s64)

diff  --git a/llvm/test/CodeGen/AMDGPU/GlobalISel/bug-legalization-artifact-combiner-dead-def.mir b/llvm/test/CodeGen/AMDGPU/GlobalISel/bug-legalization-artifact-combiner-dead-def.mir
index eb37e464279e0..18c3162e9370a 100644
--- a/llvm/test/CodeGen/AMDGPU/GlobalISel/bug-legalization-artifact-combiner-dead-def.mir
+++ b/llvm/test/CodeGen/AMDGPU/GlobalISel/bug-legalization-artifact-combiner-dead-def.mir
@@ -34,13 +34,10 @@ body: |
     ; GFX10: [[EXTRACT:%[0-9]+]]:_(s32) = G_EXTRACT [[LOAD]](<4 x s32>), 96
     ; GFX10: [[EXTRACT1:%[0-9]+]]:_(s32) = G_EXTRACT [[LOAD]](<4 x s32>), 64
     ; GFX10: [[DEF:%[0-9]+]]:_(s32) = G_IMPLICIT_DEF
-    ; GFX10: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x s32>) = G_BUILD_VECTOR [[EXTRACT1]](s32), [[DEF]](s32)
-    ; GFX10: [[INSERT:%[0-9]+]]:_(<2 x s32>) = G_INSERT [[BUILD_VECTOR]], [[EXTRACT]](s32), 32
-    ; GFX10: [[UV:%[0-9]+]]:_(s32), [[UV1:%[0-9]+]]:_(s32) = G_UNMERGE_VALUES [[INSERT]](<2 x s32>)
     ; GFX10: G_STORE [[EXTRACT1]](s32), [[COPY]](p5) :: (store (s32), align 8, addrspace 5)
     ; GFX10: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 4
     ; GFX10: [[PTR_ADD:%[0-9]+]]:_(p5) = G_PTR_ADD [[COPY]], [[C]](s32)
-    ; GFX10: G_STORE [[UV1]](s32), [[PTR_ADD]](p5) :: (store (s32) into unknown-address + 4, addrspace 5)
+    ; GFX10: G_STORE [[EXTRACT]](s32), [[PTR_ADD]](p5) :: (store (s32) into unknown-address + 4, addrspace 5)
     %0:_(p5) = COPY $vgpr0
     %1:_(s32) = COPY $vgpr1
     %2:_(s32) = COPY $vgpr2
@@ -70,13 +67,10 @@ body: |
     ; GFX10: [[EXTRACT:%[0-9]+]]:_(s32) = G_EXTRACT [[LOAD]](<4 x s32>), 96
     ; GFX10: [[EXTRACT1:%[0-9]+]]:_(s32) = G_EXTRACT [[LOAD]](<4 x s32>), 64
     ; GFX10: [[DEF:%[0-9]+]]:_(s32) = G_IMPLICIT_DEF
-    ; GFX10: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x s32>) = G_BUILD_VECTOR [[EXTRACT1]](s32), [[DEF]](s32)
-    ; GFX10: [[INSERT:%[0-9]+]]:_(<2 x s32>) = G_INSERT [[BUILD_VECTOR]], [[EXTRACT]](s32), 32
-    ; GFX10: %deaf_def:_(s32), %11:_(s32) = G_UNMERGE_VALUES [[INSERT]](<2 x s32>)
     ; GFX10: G_STORE [[EXTRACT1]](s32), [[COPY]](p5) :: (store (s32), align 8, addrspace 5)
     ; GFX10: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 4
     ; GFX10: [[PTR_ADD:%[0-9]+]]:_(p5) = G_PTR_ADD [[COPY]], [[C]](s32)
-    ; GFX10: G_STORE %11(s32), [[PTR_ADD]](p5) :: (store (s32) into unknown-address + 4, addrspace 5)
+    ; GFX10: G_STORE [[EXTRACT]](s32), [[PTR_ADD]](p5) :: (store (s32) into unknown-address + 4, addrspace 5)
     %0:_(p5) = COPY $vgpr0
     %1:_(s32) = COPY $vgpr1
     %2:_(s32) = COPY $vgpr2
@@ -110,14 +104,11 @@ body: |
     ; GFX10: [[EXTRACT:%[0-9]+]]:_(s32) = G_EXTRACT [[LOAD]](<4 x s32>), 96
     ; GFX10: [[EXTRACT1:%[0-9]+]]:_(s32) = G_EXTRACT [[LOAD]](<4 x s32>), 64
     ; GFX10: [[DEF:%[0-9]+]]:_(s32) = G_IMPLICIT_DEF
-    ; GFX10: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x s32>) = G_BUILD_VECTOR [[EXTRACT1]](s32), [[DEF]](s32)
-    ; GFX10: [[INSERT:%[0-9]+]]:_(<2 x s32>) = G_INSERT [[BUILD_VECTOR]], [[EXTRACT]](s32), 32
-    ; GFX10: %dbg_use:_(s32), %11:_(s32) = G_UNMERGE_VALUES [[INSERT]](<2 x s32>)
-    ; GFX10: DBG_VALUE %dbg_use(s32), $noreg
+    ; GFX10: DBG_VALUE $noreg, $noreg, {{.*}}, !DIExpression(), debug-location !DILocation(line: 1, column: 1
     ; GFX10: G_STORE [[EXTRACT1]](s32), [[COPY]](p5) :: (store (s32), align 8, addrspace 5)
     ; GFX10: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 4
     ; GFX10: [[PTR_ADD:%[0-9]+]]:_(p5) = G_PTR_ADD [[COPY]], [[C]](s32)
-    ; GFX10: G_STORE %11(s32), [[PTR_ADD]](p5) :: (store (s32) into unknown-address + 4, addrspace 5)
+    ; GFX10: G_STORE [[EXTRACT]](s32), [[PTR_ADD]](p5) :: (store (s32) into unknown-address + 4, addrspace 5)
     %0:_(p5) = COPY $vgpr0
     %1:_(s32) = COPY $vgpr1
     %2:_(s32) = COPY $vgpr2


        


More information about the llvm-commits mailing list