]> granicus.if.org Git - llvm/commitdiff
[X86] SimplifyDemandedVectorEltsForTargetNode - fix shadow variable warning. NFCI.
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Sat, 6 Jul 2019 18:46:09 +0000 (18:46 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Sat, 6 Jul 2019 18:46:09 +0000 (18:46 +0000)
Fixes cppcheck warning.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@365271 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/X86ISelLowering.cpp

index 475731fc057c13d64c767516410d5f2b3f1da31a..d9eecaea7df0300189890cc84ba2f45c55ef34a5 100644 (file)
@@ -33908,9 +33908,9 @@ bool X86TargetLowering::SimplifyDemandedVectorEltsForTargetNode(
     // If we reuse the shift amount just for sse shift amounts then we know that
     // only the bottom 64-bits are only ever used.
     bool AssumeSingleUse = llvm::all_of(Amt->uses(), [&Amt](SDNode *Use) {
-      unsigned Opc = Use->getOpcode();
-      return (Opc == X86ISD::VSHL || Opc == X86ISD::VSRL ||
-              Opc == X86ISD::VSRA) &&
+      unsigned UseOpc = Use->getOpcode();
+      return (UseOpc == X86ISD::VSHL || UseOpc == X86ISD::VSRL ||
+              UseOpc == X86ISD::VSRA) &&
              Use->getOperand(0) != Amt;
     });