summaryrefslogtreecommitdiffstats
path: root/clang/lib/Driver/Tools.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Add the -mstackrealign option which just communicates the need toEric Christopher2011-05-021-0/+6
| | | | | | | | force align the stack to the backend. Fixes rdar://9289631 llvm-svn: 130725
* Driver/Darwin: Honor --sysroot= when invoking the linker, on Darwin.Daniel Dunbar2011-05-021-6/+11
| | | | llvm-svn: 130723
* Disable CFI if not using the integrated assembler. We should probably do ↵Rafael Espindola2011-05-021-5/+21
| | | | | | | | this only for OS X, but it is probably not all that important. llvm-svn: 130697
* Implement -fno-dwarf2-cfi-asm.Rafael Espindola2011-04-301-0/+6
| | | | llvm-svn: 130616
* Driver/Darwin: When using -mios-simulator-version-min, explicitly pass this onDaniel Dunbar2011-04-301-2/+14
| | | | | | | | to the linker. - Only do this explicitly with the argument for now, the linker will need to explicitly add support for this. llvm-svn: 130594
* Add -Oz option and use it to set the inline threshold to 25.Bob Wilson2011-04-291-4/+0
| | | | | | Radar 9333566. Patch by Chad Rosier! llvm-svn: 130554
* Driver/cc1as: Forward -mllvm arguments when compiling assembly files.Daniel Dunbar2011-04-291-0/+1
| | | | llvm-svn: 130516
* Driver/Darwin/ld: Set the deployment target following the version information inDaniel Dunbar2011-04-281-15/+12
| | | | | | the tool chain, instead of based on the translated arguments. llvm-svn: 130440
* Make the top-level driver ignore -fobjc-default-synthesize-properties while ↵Ted Kremenek2011-04-281-0/+6
| | | | | | this feature undergoes more review and development. This is still available as a -cc1 option for testing. llvm-svn: 130424
* Move all of the logic for __DEPRECATED to the driver based on commentsChandler Carruth2011-04-231-8/+6
| | | | | | from dgregor. llvm-svn: 130066
* Fix Clang's __DEPRECATED define to be controled by -Wdeprecated. ThisChandler Carruth2011-04-231-0/+11
| | | | | | | | | | | | | | | | | | matches GCC behavior which libstdc++ uses to limit #warning-based messages about deprecation. The machinery involves threading this through a new '-fdeprecated-macro' flag for CC1. The flag defaults to "on", similarly to -Wdeprecated. We turn the flag off in the driver when the warning is turned off (modulo matching some GCC bugs). We record this as a language option, and key the preprocessor on the option when introducing the define. A separate flag rather than a '-D' flag allows us to properly represent the difference between C and C++ builds (only C++ receives the define), and it allows the specific behavior of following -Wdeprecated without potentially impacting the set of user-provided macro flags. llvm-svn: 130055
* There were some frustrating problems with the implementation ofChandler Carruth2011-04-231-0/+9
| | | | | | | | | | | | | | | | | | | | -Wwrite-strings. First and foremost, once the positive form of the flag was passed, it could never be disabled by passing -Wno-write-strings. Also, the diagnostic engine couldn't in turn use -Wwrite-strings to control diagnostics (as GCC does) because it was essentially hijacked to drive the language semantics. Fix this by giving CC1 a clean '-fconst-strings' flag to enable const-qualified strings in C and ObjC compilations. Corresponding '-fno-const-strings' is also added. Then the driver is taught to introduce '-fconst-strings' in the CC1 command when '-Wwrite-strings' dominates. This entire flag is basically GCC-bug-compatibility driven, so we also match GCC's bug where '-w' doesn't actually disable -Wwrite-strings. I'm open to changing this though as it seems insane. llvm-svn: 130051
* Add -fdelayed-template-parsing option. Using this option all templated ↵Francois Pichet2011-04-221-0/+6
| | | | | | | | | function definitions are parsed at the end of the translation unit only if it is required by an actual instantiation. As such all the symbols of the TU are available during name lookup. Using this flag is necessary for compatibility with Microsoft template code. This also provides some parsing speed improvement. llvm-svn: 130022
* Wire up the -ftest-coverage and -fprofile-arcs flags to .gcno file emission (atNick Lewycky2011-04-211-0/+7
| | | | | | | | | compile time) and .gcda emission (at runtime). --coverage enables both. This does not yet add the profile_rt library to the link step if -fprofile-arcs is enabled when linking. llvm-svn: 129956
* Fix indentation. No functional change.Nick Lewycky2011-04-211-2/+2
| | | | llvm-svn: 129954
* Driver/Darwin: Disable movw/movt with -mkernel or -fapple-kext.Daniel Dunbar2011-04-181-0/+6
| | | | llvm-svn: 129721
* Initial work to improve documentation for Clang's diagnostics, from Matthieu ↵Douglas Gregor2011-04-151-0/+5
| | | | | | Monrocq llvm-svn: 129614
* fix a bunch of comment typos found by codespell. Patch byChris Lattner2011-04-151-1/+1
| | | | | | Luis Felipe Strano Moraes! llvm-svn: 129559
* Driver/no-integrated-as: Fix forwarding of -g flag to assembler, when .s inputDaniel Dunbar2011-04-121-5/+10
| | | | | | undergoes preprocessing. llvm-svn: 129414
* fix the path to ld.so for darwin/ppc, resolving PR9677. PatchChris Lattner2011-04-111-2/+2
| | | | | | by Jeremy Huddleston! llvm-svn: 129299
* refactor -ccc-gcc-name codeDylan Noblesmith2011-04-091-1/+21
| | | | | | | | | | | | Put the logic for deciding the default name for gcc/g++ in the only place that actually cares about it. This also pushes an ifdef out of the generic driver code to a little further down, when the target is actually known. Hopefully it can be changed into just a runtime check in the future. llvm-svn: 129212
* Rename -mtrap_function= to -ftrap_function= since it's now a target neutral ↵Evan Cheng2011-04-081-11/+7
| | | | | | options. llvm-svn: 129153
* Add -mtrap_function=<> option. rdar://9257465Evan Cheng2011-04-081-0/+11
| | | | llvm-svn: 129145
* fix a typo, patch by PaX team.Chris Lattner2011-04-081-1/+1
| | | | llvm-svn: 129141
* Driver: Don't attempt to forward some Clang-only options to cc1.Daniel Dunbar2011-04-071-0/+6
| | | | llvm-svn: 129108
* Driver: Sketch driver support for a CC_LOG_DIAGNOSTICS options, similar to theDaniel Dunbar2011-04-071-0/+6
| | | | | | | existing CC_PRINT_OPTIONS and CC_PRINT_HEADERS, which can be used to transparently capture the compiler diagnostics from a build. llvm-svn: 129082
* Add ToolChain support to get Clang to recognize Ubuntu/ppc and Gentoo/ppc64.Ted Kremenek2011-04-051-0/+8
| | | | llvm-svn: 128944
* Driver/Darwin: Tweak simulator link logic a bit more to be closer to GCC.Daniel Dunbar2011-04-011-2/+8
| | | | llvm-svn: 128738
* Driver/Darwin: Tweak link logic for simulator.Daniel Dunbar2011-03-311-1/+4
| | | | llvm-svn: 128641
* Integrated-As: Support -Wa,-L when using the integrated assembler.Daniel Dunbar2011-03-281-4/+1
| | | | llvm-svn: 128433
* Add an option to suppress include stack printing on note diagnostics.Chandler Carruth2011-03-271-0/+10
| | | | | | | | | | | | | | | | | | These stacks are often less important than those on primary diagnostics. As the number of notes grows, this becomes increasingly important. The include stack printing is clever and doesn't print stacks for adjacent diagnostics from the same file, but when a note is in between a sequence of errors in a header file, and the notes all refer to some other file, we end up getting a worst-case ping-pong of include stacks that take up a great deal of vertical space. Still, for now, the default behavior isn't changed. We can evaluate user feedback with the flag. Patch by Richard Trieu, a couple of style tweaks from me. llvm-svn: 128371
* Add -f[no-]strict-overflow to the Clang driver. Use it to set theChandler Carruth2011-03-271-1/+11
| | | | | | | | | default for -fwrapv if that flag isn't specified explicitly. We always prefer an explict setting of -fwrapv when present. Also adds support for -fno-wrapv to allow disabling -fwrapv even when -fno-strict-overflow is passed. llvm-svn: 128353
* Rework checker "packages" and groups to be more hierarchical.Ted Kremenek2011-03-241-16/+7
| | | | llvm-svn: 128187
* Frontend: Add a more explicit -backend-option flag for passing backend commandDaniel Dunbar2011-03-221-3/+3
| | | | | | | | line options, instead of leveraging the blanket -mllvm option. - This allows using the frontend itself without requiring the backend have those options available (i.e., if the target wasn't built). llvm-svn: 128087
* Add clang support for cortex-m0 cpus. Patch by James Orr.Bob Wilson2011-03-211-0/+2
| | | | llvm-svn: 128018
* Introduce FindTargetProgramPath to check for a target-specific helperJoerg Sonnenberger2011-03-211-4/+15
| | | | | | | | program and fallback to plain version otherwise. Use this for the NetBSD target to make it try e.g. i486--netbsdelf-as and -ld for target i486--netbsdelf. llvm-svn: 127996
* Remember sysroot in Driver. Pass it down to ld for NetBSD, FreeBSDJoerg Sonnenberger2011-03-211-4/+11
| | | | | | | and DragonFly. Use the --sysroot= form for Linux. Fix handling of = prefix for -B. llvm-svn: 127994
* Driver: Forward -traditional and -traditional-cpp in preprocessing modes.Daniel Dunbar2011-03-181-2/+7
| | | | | | | | | - We don't really support the majority of the horrible -traditional-cpp behavior, but it is unlikely that we ever will either. This allows us to start trying to use clang as a /usr/bin/cpp replacement and see what pieces of -traditional-cpp mode people actually care about. llvm-svn: 127911
* The Darwin kernel does not provide useful guard variable support.John McCall2011-03-181-0/+6
| | | | | | | | Issue this as an IR-gen error; it's not really worthwhile doing this "right", i.e. in Sema, because IR gen knows a lot of tricks beyond what the constant evaluator knows. llvm-svn: 127854
* Driver/Obj-C: Be compatible with GCC behavior in that -fno-exceptions *does not*Daniel Dunbar2011-03-171-19/+10
| | | | | | disable Obj-C exceptions. llvm-svn: 127836
* Driver/Darwin: These are command line options, not target features.Daniel Dunbar2011-03-171-2/+2
| | | | llvm-svn: 127820
* Driver/Darwin: Suppress spurious warning about -force_cpusubtype_ALL.Daniel Dunbar2011-03-171-1/+2
| | | | llvm-svn: 127819
* Driver/Darwin/ARM: Kernel/kext code has more strict alignment requirements.Daniel Dunbar2011-03-171-4/+14
| | | | llvm-svn: 127815
* Driver/ARM: Match GCC behavior in that -msoft-float disables NEON, despite thisDaniel Dunbar2011-03-171-0/+7
| | | | | | not being consistent at all with other parts of the GCC implementation. llvm-svn: 127777
* Re-enable the IdempotentOperations checker for --analyze, and put it and the ↵Ted Kremenek2011-03-121-1/+2
| | | | | | DeadStores checker into the "deadcode" group. llvm-svn: 127531
* If called as *cpp or *cpp-[^-]*, run only the preprocessor. If noJoerg Sonnenberger2011-03-061-2/+2
| | | | | | | input is specified, use stdin implicitly. Based on a patch from Roman Divacky. llvm-svn: 127137
* Fix driver for thumb-capable ARM hosts, from Mikko Lehtonen!Douglas Gregor2011-03-061-3/+7
| | | | llvm-svn: 127128
* build: Allow disabling movt/movw from build, for testing purposes.Daniel Dunbar2011-03-021-0/+6
| | | | llvm-svn: 126810
* Driver/Darwin: Be bug compatible with GCC and ignore -pg on ARM.Daniel Dunbar2011-03-011-3/+6
| | | | llvm-svn: 126767
* The default CPU on FreeBSD for i386 should be i486, not pentium4.Roman Divacky2011-03-011-0/+5
| | | | | | Patch by Dimitry Andric! llvm-svn: 126763
OpenPOWER on IntegriCloud