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

Unified Diff: lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp

Issue 738143002: Add flag to enable Dwarf exception handling on ARM (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@merge_35
Patch Set: also !isTargetEHABICompatible for SFI NaCl Created 6 years, 1 month 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 | « lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.h ('k') | lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp
diff --git a/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp b/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp
index 7a19208cffc722b4e77492576a9eacd05575e6d9..da85359c78f681776d45f82c967816c97475aece 100644
--- a/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp
+++ b/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp
@@ -17,6 +17,15 @@
using namespace llvm;
+// @LOCALMOD-BEGIN
+namespace llvm {
+cl::opt<bool>
+EnableARMDwarfEH("arm-enable-dwarf-eh",
+ cl::desc("Use DWARF EH instead of EABI EH on ARM"),
+ cl::init(false));
+}
+// @LOCALMOD-END
+
void ARMMCAsmInfoDarwin::anchor() { }
ARMMCAsmInfoDarwin::ARMMCAsmInfoDarwin(StringRef TT) {
@@ -61,12 +70,16 @@ ARMELFMCAsmInfo::ARMELFMCAsmInfo(StringRef TT) {
// Exceptions handling
switch (TheTriple.getOS()) {
case Triple::NetBSD:
+ case Triple::NaCl: // @LOCALMOD: NaCl uses DWARF EH
ExceptionsType = ExceptionHandling::DwarfCFI;
break;
default:
ExceptionsType = ExceptionHandling::ARM;
break;
}
+ // @LOCALMOD: NonSFI mode uses DWARF EH
+ if (EnableARMDwarfEH)
+ ExceptionsType = ExceptionHandling::DwarfCFI;
// foo(plt) instead of foo@plt
UseParensForSymbolVariant = true;
@@ -111,4 +124,3 @@ ARMCOFFMCAsmInfoGNU::ARMCOFFMCAsmInfoGNU() {
UseIntegratedAssembler = false;
DwarfRegNumForCFI = true;
}
-
« no previous file with comments | « lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.h ('k') | lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698