summaryrefslogtreecommitdiffstats
path: root/clang/lib/Driver/ToolChain.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Keep track of the original target the user specified beforeJoerg Sonnenberger2012-01-261-2/+3
| | | | | | | | | | normalization. This used to be captured in DefaultTargetTriple and is used for the (optional) $triple-$tool lookup for cross-compilation. Do this properly by making it an attribute of the toolchain and use it in combination with the computed triple as index for the toolchain lookup. llvm-svn: 149083
* Switch the ToolChain types to all store a Driver reference rather thanChandler Carruth2012-01-251-6/+5
| | | | | | | | | | a HostInfo reference. Nothing about the HostInfo was used by any toolchain except digging out the driver from it. This just makes that a lot more direct. The change was accomplished entirely mechanically. It's one step closer to removing the shim full of buggy copy/paste code that is HostInfo. llvm-svn: 148945
* Split the Windows toolchain definition into its own file. This isChandler Carruth2011-12-171-0/+34
| | | | | | | | | | | | | | | especially nice as the Windows toolchain needs the windows header files, and has lots of platform specific hooks in it. To facilitate the split, hoist a bunch of file-level static helpers into class-level static helpers. Spiff up their doxygen comments while there as they're now more likely to be looked up via docs. Hopefully, this will be followed by further breaking apart of the toolchain definitions. Most of the large and complex ones should likely live on their own. I'm looking at you Darwin. ;] llvm-svn: 146840
* Driver: Add a --rtlib={compiler-rt,libgcc} argument which I plan to use to allowDaniel Dunbar2011-12-071-0/+16
| | | | | | dual support for compiler-rt on Linux, during bringup. llvm-svn: 146094
* Switch the C++ include interface in the ToolChain to use the same namingChandler Carruth2011-11-041-3/+3
| | | | | | | as the system include interface before I start adding implementations of it to individual ToolChain implementations. llvm-svn: 143751
* Sink the strange '-stdlib=...' flag handling into the C++ includeChandler Carruth2011-11-041-1/+10
| | | | | | | | | | | | | | | | | | | | handling logic of the generic ToolChain. This flag, despite its name, has *nothing* to do with the GCC flag '-nostdlib' that relates (exclusively) to the linking behavior. It is a most unfortunate name in that regard... It is used to tell InitHeaderSearch.cpp *which* set of C++ standard library header search paths to use -- those for libstdc++ from GCC's installation, or those from a libc++ installation. As this logic is hoisted out of the Frontend, and into the Driver as part of this ToolChain, the generic method will be overridden for the platform, where it can implement this logic directly. As such, hiding the CC1 option passing in the generic space is a natural fit despite the odd naming. Also, expand on the comments to clarify whats going on, and tidy up the Tools.cpp code now that its simpler. llvm-svn: 143687
* Sink the handling of -fobjc-arc-cxxlib to live with the other -fobjc-arcChandler Carruth2011-11-041-16/+1
| | | | | | | | implementation in the driver. This cleans up the signature and semantics of the include flag adding component of the toolchain. Another step to ready it for holding all the InitHeaderSearch logic. llvm-svn: 143686
* Add a system include management interface to the toolchain, and call itChandler Carruth2011-11-041-1/+6
| | | | | | | | | | | and the C++ include management routine from the proper place when forming preprocessor options in the driver. This is the first step to teaching the driver to manage all of the header search paths. Currently, these methods remain just stubs in the abstract toolchain. Subsequent patches will flesh them out with implementations for various toolchains based on the current code in InitHeaderSearch.cpp. llvm-svn: 143684
* Use Triple.isOSDarwin() instead of comparing against Triple::Darwin.Bob Wilson2011-10-141-2/+1
| | | | | | | | | There are now separate Triple::MacOSX and Triple::IOS values for the OS so comparing against Triple::Darwin will fail to match those. Note that I changed the expected output for the Driver/rewrite-objc.m test, which had previously not been passing Darwin-specific options with the macosx triple. llvm-svn: 141944
* [driver] Default to arm mode when using the integrated assembler.Chad Rosier2011-09-201-4/+9
| | | | | | rdar://10125227 llvm-svn: 140179
* remove unneeded llvm:: namespace qualifiers on some core types now that ↵Chris Lattner2011-07-231-9/+9
| | | | | | | | LLVM.h imports them into the clang namespace. llvm-svn: 135852
* Call objc_terminate() instead of abort() when a cleanup throws anJohn McCall2011-07-061-0/+2
| | | | | | | exception in Objective-C; in Objective-C++ we still use std::terminate(). This is only available in very recent runtimes. llvm-svn: 134456
* Change the driver's logic about Objective-C runtimes: abstract out aJohn McCall2011-07-061-0/+19
| | | | | | | | | | | | structure to hold inferred information, then propagate each invididual bit down to -cc1. Separate the bits of "supports weak" and "has a native ARC runtime"; make the latter a CodeGenOption. The tool chain is still driving this decision, because it's the place that has the required deployment target information on Darwin, but at least it's better-factored now. llvm-svn: 134453
* Fix the default libc++ header search path to be sysrooted. Radar 9639692.Bob Wilson2011-06-211-6/+2
| | | | | | | | | The -cxx-isystem path is not prefixed with the sysroot directory, so it's not a good way for the driver to set the system default C++ search path. Instead, add -stdlib as a cc1 option and teach the frontend how to find the headers. The driver can then just pass -stdlib through to "cc1". llvm-svn: 133547
* Automatic Reference Counting.John McCall2011-06-151-1/+8
| | | | | | | | | | Language-design credit goes to a lot of people, but I particularly want to single out Blaine Garst and Patrick Beard for their contributions. Compiler implementation credit goes to Argyrios, Doug, Fariborz, and myself, in no particular order. llvm-svn: 133103
* Driver/Darwin: Sketch initial support for a -mios-simulator-version-min= flagDaniel Dunbar2011-04-301-3/+3
| | | | | | and associated deployment target environment variable. llvm-svn: 130591
* fix a bunch of comment typos found by codespell. Patch byChris Lattner2011-04-151-1/+1
| | | | | | Luis Felipe Strano Moraes! llvm-svn: 129559
* Add clang support for cortex-m0 cpus. Patch by James Orr.Bob Wilson2011-03-211-0/+8
| | | | llvm-svn: 128018
* Remove the storage for -cxx-system-include. Make libcxx toolchainJoerg Sonnenberger2011-02-221-1/+2
| | | | | | use -nostdinc++ and -cxx-isystem. llvm-svn: 126223
* Remove stray emacs mode markers in all these files that was causing emacs toNick Lewycky2010-12-311-1/+1
| | | | | | | open them in fundamental-mode instead of c++-mode. Also twiddle whitespace for consistency in ToolChains.cpp. llvm-svn: 122646
* Driver: implement driver automagic support for -lcc_kextShantonu Sen2010-09-171-0/+5
| | | | | | | | | Rewrite linker arguments to use libclang_rt.cc_kext.a instead of gcc-specific libcc_kext.a Resolves Radar 7808495 llvm-svn: 114193
* Driver: Fix spelling of AddCXXStdlibLibArgs, which I copy-n-pasto'd.Daniel Dunbar2010-09-171-2/+2
| | | | llvm-svn: 114147
* Driver: Add a toolchain hook for whether the system has native LLVM support.Daniel Dunbar2010-09-171-0/+4
| | | | llvm-svn: 114137
* Driver: Add a -stdlib= argument which can be used to select the C++ standardDaniel Dunbar2010-09-141-0/+19
| | | | | | | | | | | library to use. - This is currently useful for testing libc++; you can now use 'clang++ -stdlib=libc++ t.cpp' to compile using it if installed. - In the future could also be used to select other standard library choices if alternatives become available (for example, to use an alternate C library). llvm-svn: 113891
* Driver: Factor out some code for handling the C++ standard library.Daniel Dunbar2010-09-141-0/+25
| | | | llvm-svn: 113890
* Driver: Move Clang "triple" computation routines to method on theDaniel Dunbar2010-08-231-0/+136
| | | | | | | | | | | 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. llvm-svn: 111856
* Driver: Move HostInfo::lookupTypeForExtension to ↵Daniel Dunbar2010-08-021-0/+4
| | | | | | ToolChain::LookupTypeForExtension. llvm-svn: 110024
* Driver: Remove some unused arguments.Daniel Dunbar2010-07-141-5/+2
| | | | llvm-svn: 108345
* Add ToolChain::getDriver() and use it instead of going through the HostInfoDaniel Dunbar2009-12-211-0/+4
| | | | | | object. llvm-svn: 91830
* Change Get{File,Program}Path to return an std::string (instead of a sys::Path).Daniel Dunbar2009-09-091-5/+5
| | | | llvm-svn: 81389
* Remove tabs, and whitespace cleanups.Mike Stump2009-09-091-3/+3
| | | | llvm-svn: 81346
* (llvm up) Use llvm::Triple for storing target triples.Daniel Dunbar2009-05-221-3/+2
| | | | | | | - This commit has some messy stuff in it to extend string lifetimes, but that will go away once we switch to using the enum'd Triple interfaces. llvm-svn: 72243
* Fix searching for gcc, we only want executable files.Mike Stump2009-03-271-2/+3
| | | | llvm-svn: 67806
* Move ToolChain::ShouldUseClangCompiler toDaniel Dunbar2009-03-241-28/+0
| | | | | | | Driver::ShouldUseClangCompiler. - No functionality change. llvm-svn: 67639
* Driver: Move actions into Compilation, and construct the compilationDaniel Dunbar2009-03-181-2/+2
| | | | | | | | | | | earlier. - This gives us a simple ownership model, and allows clients access to more information should they ever want it. - We now free Actions correctly. llvm-svn: 67158
* Driver: Add test case for -ccc-clang-archs (which, it turns out, wasDaniel Dunbar2009-03-181-2/+2
| | | | | | inverted). llvm-svn: 67135
* Driver: Pass HostInfo reference into ToolChain.Daniel Dunbar2009-03-171-9/+10
| | | | llvm-svn: 67105
* Driver: Sketch Tool and ToolChain classes.Daniel Dunbar2009-03-161-0/+62
llvm-svn: 67036
OpenPOWER on IntegriCloud