[llvm-commits] [llvm] r76144 - /llvm/trunk/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
Daniel Dunbar
daniel at zuster.org
Thu Jul 16 19:19:33 PDT 2009
Author: ddunbar
Date: Thu Jul 16 21:19:26 2009
New Revision: 76144
URL: http://llvm.org/viewvc/llvm-project?rev=76144&view=rev
Log:
Fix 'may be used uninitialized' warning.
- Anton, please review.
Modified:
llvm/trunk/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
Modified: llvm/trunk/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp?rev=76144&r1=76143&r2=76144&view=diff
==============================================================================
--- llvm/trunk/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp (original)
+++ llvm/trunk/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp Thu Jul 16 21:19:26 2009
@@ -207,7 +207,7 @@
default: break;
case ISD::Constant: {
int64_t Val = cast<ConstantSDNode>(N)->getSExtValue();
- int64_t Imm;
+ int64_t Imm = 0;
bool Match = (is12Bit ?
isImmZExt12(AM.Disp + Val, Imm) :
isImmSExt20(AM.Disp + Val, Imm));
@@ -304,7 +304,7 @@
if (ConstantSDNode *CN = dyn_cast<ConstantSDNode>(N.getOperand(1))) {
SystemZRRIAddressMode Backup = AM;
int64_t Offset = CN->getSExtValue();
- int64_t Imm;
+ int64_t Imm = 0;
bool MatchOffset = (is12Bit ?
isImmZExt12(AM.Disp + Offset, Imm) :
isImmSExt20(AM.Disp + Offset, Imm));
More information about the llvm-commits
mailing list