Fix bug recognizing moves: isMoveInstr should only treat ORs with %g0 as
moves, not all ORs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16576 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/Sparc/SparcInstrInfo.cpp b/lib/Target/Sparc/SparcInstrInfo.cpp
index 64e225f..7776b0b 100644
--- a/lib/Target/Sparc/SparcInstrInfo.cpp
+++ b/lib/Target/Sparc/SparcInstrInfo.cpp
@@ -30,8 +30,8 @@
     if (MI.getOperand(1).getReg() == V8::G0) {  // X = or G0, Y -> X = Y
       DstReg = MI.getOperand(0).getReg();
       SrcReg = MI.getOperand(2).getReg();
+      return true;
     }
-    return true;
   } else if (MI.getOpcode() == V8::FMOVS) {
     SrcReg = MI.getOperand(1).getReg();
     DstReg = MI.getOperand(0).getReg();