aboutsummaryrefslogtreecommitdiff
path: root/lib/Target/PowerPC
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-10-22 19:46:19 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-10-22 19:46:19 +0000
commit3311876c3c3147688b08f64c441e5bfaaa3412b3 (patch)
tree39af37627ef59548ab1a0844fc3b99a901b05c85 /lib/Target/PowerPC
parent76500d52be67e5dbdf9b7fb2843d286f26f37e3b (diff)
Use ptr type in the immediate field of a BxA instruction so we don't end up selecting 32-bit call instruction for ppc64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43228 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC')
-rw-r--r--lib/Target/PowerPC/PPCISelLowering.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/PowerPC/PPCISelLowering.cpp b/lib/Target/PowerPC/PPCISelLowering.cpp
index bf0f46784a..e3610f8994 100644
--- a/lib/Target/PowerPC/PPCISelLowering.cpp
+++ b/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -1537,7 +1537,8 @@ static SDNode *isBLACompatibleAddress(SDOperand Op, SelectionDAG &DAG) {
(Addr << 6 >> 6) != Addr)
return 0; // Top 6 bits have to be sext of immediate.
- return DAG.getConstant((int)C->getValue() >> 2, MVT::i32).Val;
+ return DAG.getConstant((int)C->getValue() >> 2,
+ DAG.getTargetLoweringInfo().getPointerTy()).Val;
}