summaryrefslogtreecommitdiff
path: root/lib/Target/PowerPC/PPCRegisterInfo.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-02-13 17:24:14 +0000
committerChris Lattner <sabre@nondot.org>2008-02-13 17:24:14 +0000
commita1998d1cbab495aad05c97b36836788809903b79 (patch)
tree481490f8b05f4316e7f6cc73d50c901ae00e5204 /lib/Target/PowerPC/PPCRegisterInfo.cpp
parenteedcf3fc4623ee9b40e3859fe6810895127f0c45 (diff)
downloadllvm-a1998d1cbab495aad05c97b36836788809903b79.tar.gz
llvm-a1998d1cbab495aad05c97b36836788809903b79.tar.bz2
llvm-a1998d1cbab495aad05c97b36836788809903b79.tar.xz
Fix the PPC JIT regressions by encoding zeroreg as 0 for BLR.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47067 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC/PPCRegisterInfo.cpp')
-rw-r--r--lib/Target/PowerPC/PPCRegisterInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Target/PowerPC/PPCRegisterInfo.cpp b/lib/Target/PowerPC/PPCRegisterInfo.cpp
index a21abe5810..28ac7fdabe 100644
--- a/lib/Target/PowerPC/PPCRegisterInfo.cpp
+++ b/lib/Target/PowerPC/PPCRegisterInfo.cpp
@@ -46,6 +46,7 @@ using namespace llvm;
unsigned PPCRegisterInfo::getRegisterNumbering(unsigned RegEnum) {
using namespace PPC;
switch (RegEnum) {
+ case 0: return 0;
case R0 : case X0 : case F0 : case V0 : case CR0: return 0;
case R1 : case X1 : case F1 : case V1 : case CR1: return 1;
case R2 : case X2 : case F2 : case V2 : case CR2: return 2;