summaryrefslogtreecommitdiffstats
path: root/clang/lib/Driver/Tools.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Frontend: Add basic -H support.Daniel Dunbar2010-08-241-0/+1
| | | | | | | - I didn't implement the GCC "multiple include guard" detection parts, because it doesn't seem useful or obvious. llvm-svn: 111983
* Driver/Clang: Forward -Wa, and -Xassembler to clang -cc1 when using theDaniel Dunbar2010-08-241-3/+8
| | | | | | | integrated assembler. For now this mostly just means that we will error out if someone tries to use this mechanism to send an argument to the assembler. llvm-svn: 111921
* Driver: Move Clang "triple" computation routines to method on theDaniel Dunbar2010-08-231-81/+2
| | | | | | | | | | | 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
* Visual Studio tools used on win32 hosts when targeting win32.Michael J. Spencer2010-08-211-0/+41
| | | | llvm-svn: 111748
* Add machine-parseable Fix-It output as part of diagnostics, under theDouglas Gregor2010-08-191-0/+1
| | | | | | flag -fdiagnostics-parseable-fixits, from Eelis van der Weegen! llvm-svn: 111557
* Pass some things to the linker that gcc passes. -r is the only one of these ↵David Chisnall2010-08-151-0/+4
| | | | | | that I'm sure about, but the others seem to be listed on FreeBSD by gcc -dumpspecs, so I hope they're right. Apparently -r is also not passed on GNU/Linux (and should be), but I can't see where the toolchain definition for this platform live. llvm-svn: 111114
* Switch on PCH for C++. C++ fans all over the world rejoice.Argyrios Kyrtzidis2010-08-111-6/+2
| | | | llvm-svn: 110879
* Driver/Darwin: Pass -demangle when linking, if the linker supports it.Daniel Dunbar2010-08-111-0/+16
| | | | llvm-svn: 110873
* Driver: Add -mlinker-version=, which forwards to -target-linker-version.Daniel Dunbar2010-08-111-0/+6
| | | | llvm-svn: 110872
* Turn on idempotent operations checker when using --analyze.Ted Kremenek2010-08-101-0/+1
| | | | llvm-svn: 110695
* Run the assembler instead of gcc on Linux.Rafael Espindola2010-08-101-0/+37
| | | | llvm-svn: 110635
* Make -funroll-loops turn on loop unrolling in the optimizer insteadEric Christopher2010-08-071-0/+1
| | | | | | of just ignoring it. llvm-svn: 110525
* Driver: Don't forward any -g options to GCC, when using it to drive theDaniel Dunbar2010-08-031-0/+5
| | | | | | | assembler. - Fixes PR6218, hopefully. llvm-svn: 110111
* Driver: Add Compilation::addCommand and switch tools to using it, now that weDaniel Dunbar2010-08-021-47/+44
| | | | | | don't have to deal with nested jobs. llvm-svn: 110015
* Driver: Eliminate special InputInfo kind for pipes, it is now unused.Daniel Dunbar2010-08-021-121/+34
| | | | llvm-svn: 110013
* Driver/OpenBSD: Update toolchain for compiler changes / C++; patch by JonathanDaniel Dunbar2010-08-011-1/+11
| | | | | | Gray. llvm-svn: 109994
* Driver/Darwin: Set -force_cpusubtype_ALL only by default on x86.Daniel Dunbar2010-07-221-1/+3
| | | | llvm-svn: 109074
* Add -lstdc++ to DragonFly tools.Rafael Espindola2010-07-201-0/+5
| | | | | | Patch by Sascha Wildner. llvm-svn: 108830
* Driver: Make -fnext-runtime the default when rewriting Objective-C.Daniel Dunbar2010-07-191-2/+7
| | | | llvm-svn: 108741
* Driver: Fix a possible use after free.Daniel Dunbar2010-07-181-4/+4
| | | | llvm-svn: 108659
* Driver: When re'execing clang, use path to the main executable instead ofDaniel Dunbar2010-07-141-6/+4
| | | | | | | looking up Clang in the normal search paths (which may end up finding the wrong clang). llvm-svn: 108346
* Driver: Remove some unused arguments.Daniel Dunbar2010-07-141-49/+49
| | | | llvm-svn: 108345
* Driver/Darwin: Pass -pie/-no_pie to the linker when -fpie/-fno-pie and friendsDaniel Dunbar2010-07-131-2/+9
| | | | | | are explicitly given. llvm-svn: 108297
* Introduce -f{no-}spell-checking options to enable/disableDouglas Gregor2010-07-091-0/+4
| | | | | | | spell-checking. By default, spell-checking is enabled for Clang (obviously) but disabled in CIndex for performance reasons. llvm-svn: 107992
* add driver support for minix, patch by Kees van ReeuwijkChris Lattner2010-07-071-29/+157
| | | | | | from PR7583 llvm-svn: 107788
* Driver/IRgen: Add support for -momit-leaf-frame-pointer.Daniel Dunbar2010-07-011-0/+5
| | | | llvm-svn: 107367
* Set the default arch based on the triple.Rafael Espindola2010-06-281-46/+55
| | | | llvm-svn: 107021
* Use softfp for linux gnueabi, keep the warning for everything else.Rafael Espindola2010-06-271-2/+9
| | | | llvm-svn: 106984
* Implement support for -fwrapv, rdar://7221421Chris Lattner2010-06-261-0/+1
| | | | | | | | | | | | As part of this, pull together trapv handling into the same enum. This also add support for NSW multiplies. This also makes PCH disagreement on overflow behavior silent, since it really doesn't matter except for warnings and codegen (no macros get defined etc). llvm-svn: 106956
* Driver: Remove some dead code left around after a refactoring. Found by theDaniel Dunbar2010-06-221-10/+0
| | | | | | Clang static analyzer! llvm-svn: 106568
* implement support for -finstrument-functions, patch by NelsonChris Lattner2010-06-221-0/+2
| | | | | | Elhage! llvm-svn: 106507
* Change the test for which ABI/CC to use on ARM to be base on the environmentRafael Espindola2010-06-161-12/+5
| | | | | | (the last argument of the triple). llvm-svn: 106131
* Implement -fvisibility-inlines-hidden. <rdar://problem/7819834>Douglas Gregor2010-06-151-0/+2
| | | | llvm-svn: 106003
* Driver: Eliminate uses of Arg::getIndex.Daniel Dunbar2010-06-141-2/+3
| | | | | | Also, fix a memory leak. llvm-svn: 105963
* Driver: Fix arg_iterator typing to reflect that it is really an iterator ↵Daniel Dunbar2010-06-111-16/+16
| | | | | | over Arg*s. llvm-svn: 105838
* Add an option -fshow-overloads=best|all to limit the number of overloadJeffrey Yasskin2010-06-111-0/+3
| | | | | | | candidates printed. We default to 'all'. At the moment, 'best' prints only the first 4 overloads, but we'll improve that over time. llvm-svn: 105815
* Implement -fcaret-diagnostics to undo -fno-caret-diagnostics.Jeffrey Yasskin2010-06-081-1/+5
| | | | llvm-svn: 105597
* Driver: Support invoking Clang on .ll or .bc inputs.Daniel Dunbar2010-06-071-10/+20
| | | | | | | | | | | | | | | - We actually pretend that we have two separate types for LLVM assembly/bitcode because we need to use the standard suffixes with LTO ('clang -O4 -c t.c' should generate 't.o'). It is now possible to do something like: $ clang -emit-llvm -S t.c -o t.ll ... assorted other compile flags ... $ clang -c t.ll -o t.o ... assorted other compile flags ... and expect that the output will be almost* identical to: $ clang -c t.c -o t.o ... assorted other compile flags ... because all the target settings (default CPU, target features, etc.) will all be initialized properly by the driver/frontend. *: This isn't perfect yet, because in practice we will end up running the optimization passes twice. It's possible to get something equivalent out with a well placed -mllvm -disable-llvm-optzns, but I'm still thinking about the cleanest way to solve this problem more generally. llvm-svn: 105584
* Driver: Change -dwarf-debug-flags option to pass the original command lineDaniel Dunbar2010-06-041-2/+7
| | | | | | arguments after translation, instead of the -cc1 level arguments. llvm-svn: 105476
* Driver/Darwin: Model dsymutil properly, as a separate action/tool kind which isDaniel Dunbar2010-06-041-42/+0
| | | | | | | added as the last output step, instead of just hacking it into the link step. - Among other things, this fixes dSYM generation when using multiple -arch options. llvm-svn: 105475
* Driver: Add an explicit dsymutil action.Daniel Dunbar2010-06-041-0/+20
| | | | llvm-svn: 105474
* Driver: Spell -relax-all correctly when calling the cc1as tool.Daniel Dunbar2010-05-281-1/+1
| | | | llvm-svn: 104955
* Driver: Update -O -> -O2 replacement for addition of -O0 option.Daniel Dunbar2010-05-271-1/+2
| | | | llvm-svn: 104823
* Driver: Add support for -m[no-]relax-all, and make it the default at -O0.Daniel Dunbar2010-05-271-0/+18
| | | | llvm-svn: 104815
* Daniel re-educated me about what Alias does and does not do. Turn that off forChandler Carruth2010-05-221-0/+8
| | | | | | | | '-fasm' and explicitly map from that flag to -fgnu-keywords in the driver. Turn off the driver in the lexer test for this madness and add a test to the driver that the translation actually works. llvm-svn: 104428
* Driver: Add a tool definition for the Clang integrated assembler.Daniel Dunbar2010-05-201-0/+52
| | | | llvm-svn: 104280
* Expose -fobjc-nonfragile-abi2 as a top-level clang driver option. Fixes ↵Ted Kremenek2010-05-201-0/+5
| | | | | | <rdar://problem/8007063>. llvm-svn: 104205
* Driver: Make -fverbose-asm the default for platforms where the integratedDaniel Dunbar2010-05-141-1/+8
| | | | | | assembler defaults to on. llvm-svn: 103825
* Driver/Darwin/i386: Don't allow compiling C++ with -fapple-kext, we don't ↵Daniel Dunbar2010-05-121-1/+11
| | | | | | support the necessary ABI yet. llvm-svn: 103632
* Simplify.Daniel Dunbar2010-05-121-3/+3
| | | | llvm-svn: 103631
OpenPOWER on IntegriCloud