diff options
author | Martell Malone <martellmalone@gmail.com> | 2017-11-29 06:51:27 +0000 |
---|---|---|
committer | Martell Malone <martellmalone@gmail.com> | 2017-11-29 06:51:27 +0000 |
commit | e9d94f5b6cbfe39e131add4af58a899180a7102c (patch) | |
tree | 3f7265f5a0f293173ab388fefad3a8a11e586256 /lib/Driver/ToolChains/Darwin.cpp | |
parent | e7eb264ed0f3672350242daa351da0a2385bb762 (diff) |
Revert "Toolchain: Normalize dwarf, sjlj and seh eh"
This reverts rL319294.
The windows sanitizer does not like seh on x86.
Will re apply with None type for x86
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319295 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/ToolChains/Darwin.cpp')
-rw-r--r-- | lib/Driver/ToolChains/Darwin.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/lib/Driver/ToolChains/Darwin.cpp b/lib/Driver/ToolChains/Darwin.cpp index 7c401aa9dd..5dc8a91bcf 100644 --- a/lib/Driver/ToolChains/Darwin.cpp +++ b/lib/Driver/ToolChains/Darwin.cpp @@ -1881,7 +1881,7 @@ bool MachO::IsUnwindTablesDefault(const ArgList &Args) const { // Unwind tables are not emitted if -fno-exceptions is supplied (except when // targeting x86_64). return getArch() == llvm::Triple::x86_64 || - (GetExceptionModel(Args) != llvm::ExceptionHandling::SjLj && + (!UseSjLjExceptions(Args) && Args.hasFlag(options::OPT_fexceptions, options::OPT_fno_exceptions, true)); } @@ -1892,18 +1892,15 @@ bool MachO::UseDwarfDebugFlags() const { return false; } -llvm::ExceptionHandling Darwin::GetExceptionModel(const ArgList &Args) const { +bool Darwin::UseSjLjExceptions(const ArgList &Args) const { // Darwin uses SjLj exceptions on ARM. if (getTriple().getArch() != llvm::Triple::arm && getTriple().getArch() != llvm::Triple::thumb) - return llvm::ExceptionHandling::None; + return false; // Only watchOS uses the new DWARF/Compact unwinding method. llvm::Triple Triple(ComputeLLVMTriple(Args)); - if(Triple.isWatchABI()) - return llvm::ExceptionHandling::DwarfCFI; - - return llvm::ExceptionHandling::SjLj; + return !Triple.isWatchABI(); } bool Darwin::SupportsEmbeddedBitcode() const { |