summaryrefslogtreecommitdiffstats
path: root/clang/lib/Driver/Tools.cpp
Commit message (Collapse)AuthorAgeFilesLines
* 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
* For linking on FreeBSD, don't add a hardcoded "-L/usr/lib", butRoman Divacky2011-03-011-7/+7
| | | | | | | | | | | retrieve the library paths from the ToolChain object instead. Copy the relevant code from linuxtools::Link::ConstructJob(), and replace the std::string stuff with llvm::StringRef, while we're here. Patch by Dimitry Andric! llvm-svn: 126757
* Implement -mrtd which sets the StdCall calling convention to be the defaultRoman Divacky2011-03-011-0/+3
| | | | | | one. llvm-svn: 126756
* Disable more warnings so that it is safe to useRafael Espindola2011-03-011-0/+8
| | | | | | | CC="clang -use-gold-plugin -emit-llvm" CXX="clang++ -use-gold-plugin -emit-llvm" llvm-svn: 126740
* Don't warn about "clang -use-gold-plugin -c ...". With this users can sayRafael Espindola2011-02-281-0/+2
| | | | | | | CC="clang -use-gold-plugin" CFLAGS=-emit-llvm ../configure... and not be hit with a warning for each .c file. llvm-svn: 126713
* [analyzer] Remove '-analyzer-check-objc-mem' flag, the nominee for best ↵Argyrios Kyrtzidis2011-02-281-4/+0
| | | | | | misnomer award. llvm-svn: 126676
* Make -fobjc-nonfragile-abi and -fgnu-runtime imply -fblocks (unless ↵David Chisnall2011-02-281-1/+4
| | | | | | -fno-blocks is specified), because this combination of flags defines an Objective-C runtime that includes a blocks runtime. llvm-svn: 126654
* Fix a tiny goof in the Driver's logic which caused the explicit presenceChandler Carruth2011-02-281-1/+1
| | | | | | | | of -fexceptions to disably C++ exceptions. The correct code was in the ObjC branch, this just mirrors that logic on the C++ side of things. Thanks to John Wiegley for pointing this out. llvm-svn: 126640
* Add a -fcxx-exceptions flag to the frontend, which can be used to enableAnders Carlsson2011-02-281-21/+74
| | | | | | | | | | C++ exceptions, even when exceptions have been turned off using -fno-exceptions. Make the -fobjc-exceptions flag do the same thing, but for Objective-C exceptions. C++ and Objective-C exceptions can also be disabled using -fno-cxx-excptions and -fno-objc-exceptions. llvm-svn: 126630
* [analyzer] Move the DeadStores checker out of the 'core' package.Argyrios Kyrtzidis2011-02-281-0/+2
| | | | | | | -Now it gets enabled with '-analyzer-checker=DeadStores'. -The driver passes the above flag by default. llvm-svn: 126612
* Factor code out into a helper function, ↵Anders Carlsson2011-02-281-11/+20
| | | | | | shouldUseExceptionTablesForObjCExceptions. llvm-svn: 126601
* Make clang -cc1 disable Objective-C exceptions by default, and add a ↵Anders Carlsson2011-02-221-4/+4
| | | | | | | | -fobjc-exceptions flag to turn them on. Update all tests accordingly. llvm-svn: 126177
* Pass the right linker flag in openbsd::Link::ConstructJob,Chris Lattner2011-02-211-1/+1
| | | | | | patch by Matthew Dempsky! llvm-svn: 126133
* Add a new ObjCExceptions member variable to LangOptions. This controls ↵Anders Carlsson2011-02-191-0/+5
| | | | | | whether Objective-C exceptions are enabled or not (they are by default). llvm-svn: 126061
* [analyzer] '-analyzer-check-objc-mem' can go through the llvm/clang codebase ↵Argyrios Kyrtzidis2011-02-191-7/+4
| | | | | | without crashing; enable it for C++. llvm-svn: 126026
* Driver/Darwin: Support -Wl, with -Xarch_. This doesn't work naturally because ofDaniel Dunbar2011-02-191-0/+4
| | | | | | the special way we model "linker input" arguments. llvm-svn: 126023
* [analyzer] Use the new registration mechanism on the ↵Argyrios Kyrtzidis2011-02-171-11/+0
| | | | | | | | | | | | | non-path-sensitive-checkers: DeadStoresChecker ObjCMethSigsChecker ObjCUnusedIvarsChecker SizeofPointerChecker ObjCDeallocChecker SecuritySyntaxChecker llvm-svn: 125779
* Triple::MinGW64 is deprecated and removed. We can use Triple::MinGW32 instead.NAKAMURA Takumi2011-02-171-2/+1
| | | | | | No one uses *-mingw64. mingw-w64 is represented as {i686|x86_64}-w64-mingw32. llvm-svn: 125742
* Fix whitespace.NAKAMURA Takumi2011-02-171-3/+3
| | | | llvm-svn: 125741
* [analyzer] Use the new registration mechanism on the IdempotentOperationChecker.Argyrios Kyrtzidis2011-02-151-1/+0
| | | | llvm-svn: 125611
* [analyzer] Use the new registration mechanism on some of the internal ↵Argyrios Kyrtzidis2011-02-151-0/+7
| | | | | | | | | | | | | checks. These are: StackAddrLeakChecker ObjCAtSyncChecker UnixAPIChecker MacOSXAPIChecker The rest have/create implicit dependencies between checkers and need to be handled differently. llvm-svn: 125559
OpenPOWER on IntegriCloud