summaryrefslogtreecommitdiffstats
path: root/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp
diff options
context:
space:
mode:
authorandrew <andrew@FreeBSD.org>2012-12-23 21:41:39 +0000
committerandrew <andrew@FreeBSD.org>2012-12-23 21:41:39 +0000
commitedc5efb0c38c751969af4edb3fb5d2e9067654de (patch)
tree5e6f98be05a2099832b5f7f2ffc2cad3f99cbc22 /contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp
parent76534720131b94d6a1c11f1d28c122a2bd86c924 (diff)
downloadFreeBSD-src-edc5efb0c38c751969af4edb3fb5d2e9067654de.zip
FreeBSD-src-edc5efb0c38c751969af4edb3fb5d2e9067654de.tar.gz
Pull in r170096 from upstream clang trunk:
Initial support for FreeBSD on ARM.
Diffstat (limited to 'contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp')
-rw-r--r--contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp b/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp
index 7d70cd5..c5460b2 100644
--- a/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp
+++ b/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp
@@ -1667,6 +1667,19 @@ Tool &FreeBSD::SelectTool(const Compilation &C, const JobAction &JA,
return *T;
}
+bool FreeBSD::UseSjLjExceptions() const {
+ // FreeBSD uses SjLj exceptions on ARM oabi.
+ switch (getTriple().getEnvironment()) {
+ case llvm::Triple::GNUEABI:
+ case llvm::Triple::EABI:
+ return false;
+
+ default:
+ return (getTriple().getArch() == llvm::Triple::arm ||
+ getTriple().getArch() == llvm::Triple::thumb);
+ }
+}
+
/// NetBSD - NetBSD tool chain which can call as(1) and ld(1) directly.
NetBSD::NetBSD(const Driver &D, const llvm::Triple& Triple, const ArgList &Args)
OpenPOWER on IntegriCloud