diff options
author | Andrew Lenharth <andrewl@lenharth.org> | 2005-06-27 15:36:48 +0000 |
---|---|---|
committer | Andrew Lenharth <andrewl@lenharth.org> | 2005-06-27 15:36:48 +0000 |
commit | 53bb83bc43fb8441a30db90b0df21713e73f72e0 (patch) | |
tree | d39de49b04463f62b724d57c0eff6e23a07ef3a9 /llvm/lib/Target/Alpha/AlphaISelPattern.cpp | |
parent | 10594206f4b0ab54b1f441340bb582e3733bd872 (diff) | |
download | bcm5719-llvm-53bb83bc43fb8441a30db90b0df21713e73f72e0.tar.gz bcm5719-llvm-53bb83bc43fb8441a30db90b0df21713e73f72e0.zip |
who said we had to use the return address in the return address register. Might save a move in many cases
llvm-svn: 22293
Diffstat (limited to 'llvm/lib/Target/Alpha/AlphaISelPattern.cpp')
-rw-r--r-- | llvm/lib/Target/Alpha/AlphaISelPattern.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/llvm/lib/Target/Alpha/AlphaISelPattern.cpp b/llvm/lib/Target/Alpha/AlphaISelPattern.cpp index e2610c44064..9c9b3d6db08 100644 --- a/llvm/lib/Target/Alpha/AlphaISelPattern.cpp +++ b/llvm/lib/Target/Alpha/AlphaISelPattern.cpp @@ -179,6 +179,10 @@ namespace { { BuildMI(BB, Alpha::BIS, 2, Alpha::R26).addReg(RA).addReg(RA); } + unsigned getRA() + { + return RA; + } }; } @@ -2310,8 +2314,7 @@ void AlphaISel::Select(SDOperand N) { Select(N.getOperand(0)); break; } - AlphaLowering.restoreRA(BB); - BuildMI(BB, Alpha::RET, 1, Alpha::R31).addReg(Alpha::R26); // Just emit a 'ret' instruction + BuildMI(BB, Alpha::RET, 1, Alpha::R31).addReg(AlphaLowering.getRA()); // Just emit a 'ret' instruction return; case ISD::TRUNCSTORE: |