summaryrefslogtreecommitdiff
path: root/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-07-17 02:19:26 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-07-17 02:19:26 +0000
commit19c29f53f274870eb033389fd0ca98e6c98f03e0 (patch)
tree72277a98102fed5d80fbeffb332faf9cbe0fa805 /lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
parent923a579b55b5af1a4d131d9871a3645f01cb33a6 (diff)
downloadllvm-19c29f53f274870eb033389fd0ca98e6c98f03e0.tar.gz
llvm-19c29f53f274870eb033389fd0ca98e6c98f03e0.tar.bz2
llvm-19c29f53f274870eb033389fd0ca98e6c98f03e0.tar.xz
Fix 'may be used uninitialized' warning.
- Anton, please review. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76144 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/SystemZ/SystemZISelDAGToDAG.cpp')
-rw-r--r--lib/Target/SystemZ/SystemZISelDAGToDAG.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp b/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
index cc77c6f578..482d93448b 100644
--- a/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
+++ b/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
@@ -207,7 +207,7 @@ bool SystemZDAGToDAGISel::MatchAddress(SDValue N, SystemZRRIAddressMode &AM,
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 @@ bool SystemZDAGToDAGISel::MatchAddress(SDValue N, SystemZRRIAddressMode &AM,
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));