aboutsummaryrefslogtreecommitdiff
path: root/lib/Driver/ToolChains.h
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2010-08-23 22:35:37 +0000
committerDaniel Dunbar <daniel@zuster.org>2010-08-23 22:35:37 +0000
commit00577ada44c889fbe311d61c51a8da89e65c7c9a (patch)
tree1f970108c64c2539607ad88a33bc1546d6ed433b /lib/Driver/ToolChains.h
parent60a4543d42b6b8564a5650345de7beb7e99c60f3 (diff)
Driver: Move Clang "triple" computation routines to method on the
ToolChain. This fixes a potenial bad cast when running Clang on PPC code, since the tool chain in effect is not a subclass of the Darwin one, but we were treating it like it was. - This introduces some gross code duplication, but the right fix for it is to just move the Driver to start depending on the targets in libBasic, so I am not planning on fixing it immediately. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111856 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/ToolChains.h')
-rw-r--r--lib/Driver/ToolChains.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Driver/ToolChains.h b/lib/Driver/ToolChains.h
index 742daadab8..d1f15565e6 100644
--- a/lib/Driver/ToolChains.h
+++ b/lib/Driver/ToolChains.h
@@ -73,6 +73,8 @@ public:
Darwin(const HostInfo &Host, const llvm::Triple& Triple);
~Darwin();
+ std::string ComputeEffectiveClangTriple(const ArgList &Args) const;
+
/// @name Darwin Specific Toolchain API
/// {
@@ -251,6 +253,8 @@ public:
Darwin_Generic_GCC(const HostInfo &Host, const llvm::Triple& Triple)
: Generic_GCC(Host, Triple) {}
+ std::string ComputeEffectiveClangTriple(const ArgList &Args) const;
+
virtual const char *GetDefaultRelocationModel() const { return "pic"; }
};