[llvm] r249091 - AMDGPU: Fix unused variable warning in release build

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 1 15:40:36 PDT 2015


Author: arsenm
Date: Thu Oct  1 17:40:35 2015
New Revision: 249091

URL: http://llvm.org/viewvc/llvm-project?rev=249091&view=rev
Log:
AMDGPU: Fix unused variable warning in release build

Modified:
    llvm/trunk/lib/Target/AMDGPU/SIInsertWaits.cpp

Modified: llvm/trunk/lib/Target/AMDGPU/SIInsertWaits.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/SIInsertWaits.cpp?rev=249091&r1=249090&r2=249091&view=diff
==============================================================================
--- llvm/trunk/lib/Target/AMDGPU/SIInsertWaits.cpp (original)
+++ llvm/trunk/lib/Target/AMDGPU/SIInsertWaits.cpp Thu Oct  1 17:40:35 2015
@@ -158,8 +158,8 @@ Counters SIInsertWaits::getHwCounts(Mach
     if (TII->isSMRD(MI.getOpcode())) {
 
       if (MI.getNumOperands() != 0) {
-        MachineOperand &Op = MI.getOperand(0);
-        assert(Op.isReg() && "First LGKM operand must be a register!");
+        assert(MI.getOperand(0).isReg() &&
+               "First LGKM operand must be a register!");
 
         // XXX - What if this is a write into a super register?
         const TargetRegisterClass *RC = TII->getOpRegClass(MI, 0);




More information about the llvm-commits mailing list