Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(327)

Unified Diff: lib/Target/ARM/ARMBaseRegisterInfo.cpp

Issue 1154253004: Use R0/R1 instead of R4/R5 for ARM eh_return return values (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | lib/Target/ARM/ARMCallingConv.td » ('j') | lib/Target/ARM/ARMCallingConv.td » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/Target/ARM/ARMBaseRegisterInfo.cpp
diff --git a/lib/Target/ARM/ARMBaseRegisterInfo.cpp b/lib/Target/ARM/ARMBaseRegisterInfo.cpp
index b673e9909ee43bcec457a5d0fa823d4645d57e8f..fce29e28b0c03b9c69317485fd4f60f23a5d97da 100644
--- a/lib/Target/ARM/ARMBaseRegisterInfo.cpp
+++ b/lib/Target/ARM/ARMBaseRegisterInfo.cpp
@@ -24,6 +24,7 @@
#include "llvm/CodeGen/MachineFrameInfo.h"
#include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
+#include "llvm/CodeGen/MachineModuleInfo.h" // @LOCALMOD
#include "llvm/CodeGen/MachineRegisterInfo.h"
#include "llvm/CodeGen/RegisterScavenging.h"
#include "llvm/CodeGen/VirtRegMap.h"
@@ -63,7 +64,13 @@ static unsigned getFramePointerReg(const ARMSubtarget &STI) {
const MCPhysReg*
ARMBaseRegisterInfo::getCalleeSavedRegs(const MachineFunction *MF) const {
const ARMSubtarget &STI = MF->getSubtarget<ARMSubtarget>();
- if (STI.isTargetNaCl()) return CSR_NaCl_SaveList; // @LOCALMOD
+ // @LOCALMOD-START
jvoung (off chromium) 2015/06/03 17:19:38 Leave a note that we aren't supporting the other C
Derek Schuff 2015/06/03 20:50:56 Done.
+ if (STI.isTargetNaCl()) {
+ if (MF->getMMI().callsEHReturn())
+ return CSR_NaCl_EHRet_SaveList;
+ return CSR_NaCl_SaveList;
+ }
+ // @LOCALMOD-END
const MCPhysReg *RegList =
STI.isTargetDarwin() ? CSR_iOS_SaveList : CSR_AAPCS_SaveList;
« no previous file with comments | « no previous file | lib/Target/ARM/ARMCallingConv.td » ('j') | lib/Target/ARM/ARMCallingConv.td » ('J')

Powered by Google App Engine
This is Rietveld 408576698