diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-09-09 18:36:01 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-09-09 18:36:01 +0000 |
commit | 4954018954bbc97363eef02d0c83bea19ce9b329 (patch) | |
tree | 13dce0e9c1e1d4d0cf59426a4608f7234897527c /lib/Driver/Compilation.cpp | |
parent | 1eb4433ac451dc16f4133a88af2d002ac26c58ef (diff) |
Push bound architecture name into Compilation::getArgsForToolChain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81365 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/Compilation.cpp')
-rw-r--r-- | lib/Driver/Compilation.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/Driver/Compilation.cpp b/lib/Driver/Compilation.cpp index ad3cb8dbe1..f6e1885643 100644 --- a/lib/Driver/Compilation.cpp +++ b/lib/Driver/Compilation.cpp @@ -31,8 +31,9 @@ Compilation::~Compilation() { delete Args; // Free any derived arg lists. - for (llvm::DenseMap<const ToolChain*, DerivedArgList*>::iterator - it = TCArgs.begin(), ie = TCArgs.end(); it != ie; ++it) + for (llvm::DenseMap<std::pair<const ToolChain*, const char*>, + DerivedArgList*>::iterator it = TCArgs.begin(), + ie = TCArgs.end(); it != ie; ++it) delete it->second; // Free the actions, if built. @@ -41,11 +42,12 @@ Compilation::~Compilation() { delete *it; } -const DerivedArgList &Compilation::getArgsForToolChain(const ToolChain *TC) { +const DerivedArgList &Compilation::getArgsForToolChain(const ToolChain *TC, + const char *BoundArch) { if (!TC) TC = &DefaultToolChain; - DerivedArgList *&Entry = TCArgs[TC]; + DerivedArgList *&Entry = TCArgs[std::make_pair(TC, BoundArch)]; if (!Entry) Entry = TC->TranslateArgs(*Args); |