summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorAndrew Lenharth <andrewl@lenharth.org>2005-04-14 17:34:20 +0000
committerAndrew Lenharth <andrewl@lenharth.org>2005-04-14 17:34:20 +0000
commit00ce283b3ffdab5b23f4b4303667f1bab2d3f59c (patch)
tree9ba33a5f45d815d2f6d45a2ec8cabcc6c20fbc73 /llvm/lib
parent7ae3aba5aaca4c5cc3192a4e6dda5809121c1935 (diff)
downloadbcm5719-llvm-00ce283b3ffdab5b23f4b4303667f1bab2d3f59c.tar.gz
bcm5719-llvm-00ce283b3ffdab5b23f4b4303667f1bab2d3f59c.zip
fix calls
llvm-svn: 21303
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/Alpha/AlphaISelPattern.cpp1
-rw-r--r--llvm/lib/Target/Alpha/AlphaInstrInfo.td2
2 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Target/Alpha/AlphaISelPattern.cpp b/llvm/lib/Target/Alpha/AlphaISelPattern.cpp
index 18cc35a3569..d8459815fdf 100644
--- a/llvm/lib/Target/Alpha/AlphaISelPattern.cpp
+++ b/llvm/lib/Target/Alpha/AlphaISelPattern.cpp
@@ -1418,6 +1418,7 @@ unsigned ISel::SelectExpr(SDOperand N) {
BuildMI(BB, Alpha::CALL, 1).addGlobalAddress(GASD->getGlobal());
} else {
//use PC relative branch call
+ AlphaLowering.restoreGP(BB);
BuildMI(BB, Alpha::BSR, 1, Alpha::R26).addGlobalAddress(GASD->getGlobal(),true);
}
}
diff --git a/llvm/lib/Target/Alpha/AlphaInstrInfo.td b/llvm/lib/Target/Alpha/AlphaInstrInfo.td
index 72f21f0bf9b..e341e858cb7 100644
--- a/llvm/lib/Target/Alpha/AlphaInstrInfo.td
+++ b/llvm/lib/Target/Alpha/AlphaInstrInfo.td
@@ -330,7 +330,7 @@ let isCall = 1,
R20, R21, R22, R23, R24, R25, R27, R28, R29,
F0, F1,
F10, F11, F12, F13, F14, F15, F16, F17, F18, F19,
- F20, F21, F22, F23, F24, F25, F26, F27, F28, F29, F30] in {
+ F20, F21, F22, F23, F24, F25, F26, F27, F28, F29, F30], Uses = [R29] in {
def JSR : MForm< 0x1A, (ops GPRC:$RD, GPRC:$RS, s14imm:$DISP), "jsr $RD,($RS),$DISP">; //Jump to subroutine
def BSR : BForm<0x34, (ops GPRC:$RD, s21imm:$DISP), "bsr $RD,$DISP">; //Branch to subroutine
}
OpenPOWER on IntegriCloud