summaryrefslogtreecommitdiff
path: root/lib/Driver/Tools.cpp
Commit message (Collapse)AuthorAge
...
* Give sparcv9 the ability to set the target cpu. Change it from acceptingRoman Divacky2014-02-25
| | | | | | | | -march which doesnt exist on sparc gcc to -mcpu. While here adjust a few tests to not write an unused temporary file. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202177 91177308-0d34-0410-b5e6-96231b3b80d8
* Add AArch64 big endian Target (aarch64_be)Christian Pirker2014-02-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202151 91177308-0d34-0410-b5e6-96231b3b80d8
* Respect ToolChain::isPIEDefault() in constructing link job on Linux and FreeBSD.Alexey Samsonov2014-02-25
| | | | | | | Partially based on http://llvm-reviews.chandlerc.com/D2644 by Viktor Kutuzov. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202150 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor adding sanitizer linker flags into a separate function and make it ↵Alexey Samsonov2014-02-25
| | | | | | less OS-specific git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202148 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement -fno-short-wcharRichard Barton2014-02-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202058 91177308-0d34-0410-b5e6-96231b3b80d8
* clang: add -f{no-,}integrate-as as consistent parametersSaleem Abdulrasool2014-02-23
| | | | | | | | The integrated assembler is a feature. This makes the new flags the default option, and the previous versions aliases. Ideally, at some point the aliases would be entirely removed. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201963 91177308-0d34-0410-b5e6-96231b3b80d8
* clang: forward -no-integrated-as from the driverSaleem Abdulrasool2014-02-22
| | | | | | | | | | | | | | Forward the -no-integrated-as option to -cc1 rather than simply invoking the appropriate tool. This is useful since this option has been overloaded to permit disabling of parsing inline assembly at the MC layer. This re-applies the previous version of the patch with a renaming of the driver option to the public name rather than the internal name (-target vs -triple). The actual failure is fixed separately of an overly aggressive negative pattern match in the MIPS driver tests. It also fixes the incorrect test for targets that have the integrated assembler disabled by default. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201960 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "clang: forward -no-integrated-as from the driver"Saleem Abdulrasool2014-02-22
| | | | | | This seems to break a MIPS test. Revert until I figure out the root cause. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201954 91177308-0d34-0410-b5e6-96231b3b80d8
* clang: forward -no-integrated-as from the driverSaleem Abdulrasool2014-02-22
| | | | | | | | Forward the -no-integrated-as option to -cc1 rather than simply invoking the appropriate tool. This is useful since this option has been overloaded to permit disabling of parsing inline assembly at the MC layer. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201952 91177308-0d34-0410-b5e6-96231b3b80d8
* Default to ARMv5e for NetBSD/EABI, ARMv4 for APCS.Joerg Sonnenberger2014-02-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201894 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for FPv4-SP to the clang driverOliver Stannard2014-02-21
| | | | | | | | | | | | | | | Added two new options for -mfpu when targetting ARM: * fpv4-sp-d16 * fp4-sp-d16 The first is the same spelling as gcc. The lack of a leading `v' is correct, this is consistent with ARM's documentation and gcc's spelling of the option. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201846 91177308-0d34-0410-b5e6-96231b3b80d8
* Get rid of obsolete addProfileRT(), generalize the relevant ↵Alexey Samsonov2014-02-20
| | | | | | addProfileRTLinux() to all OS git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201789 91177308-0d34-0410-b5e6-96231b3b80d8
* Hook up NetBSD/sparc and NetBSD/sparc64 as and ld invocations.Joerg Sonnenberger2014-02-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201730 91177308-0d34-0410-b5e6-96231b3b80d8
* GC now unused variable.Joerg Sonnenberger2014-02-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201728 91177308-0d34-0410-b5e6-96231b3b80d8
* Use a switch for the architecture specific logic inJoerg Sonnenberger2014-02-19
| | | | | | | netbsd::Assemble::ConstructJob. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201725 91177308-0d34-0410-b5e6-96231b3b80d8
* clang-cl: Pass /Z7 when we fallback to cl with debug info enabledReid Kleckner2014-02-19
| | | | | | | Clang itself only emits CodeView line tables, so it seems more consistent to ask cl.exe for the same format. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201721 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor -KPIC handling for as invocation.Joerg Sonnenberger2014-02-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201719 91177308-0d34-0410-b5e6-96231b3b80d8
* Add FreeBSD ARM EABI hard-float supportRenato Golin2014-02-19
| | | | | | Patch by Andrew Turner. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201662 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "Debug info: Make DWARF4 the default for Darwin, too."Adrian Prantl2014-02-17
| | | | | | | | | I'm holding this change to give maintainers of Darwin buildbots more time to update their toolchains. This reverts commit r201375. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201520 91177308-0d34-0410-b5e6-96231b3b80d8
* Enable generation of unwind tables when building with sanitizers.Evgeniy Stepanov2014-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201391 91177308-0d34-0410-b5e6-96231b3b80d8
* Enable AArch64 NEON by default.Jiangning Liu2014-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201384 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a command line option -gdwarf-aranges that will turn on emittingEric Christopher2014-02-14
| | | | | | the dwarf .debug_aranges section. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201379 91177308-0d34-0410-b5e6-96231b3b80d8
* Debug info: Make DWARF4 the default for Darwin, too.Adrian Prantl2014-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201375 91177308-0d34-0410-b5e6-96231b3b80d8
* XCore target pass -v flag to assembler & linkerRobert Lytton2014-02-13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201312 91177308-0d34-0410-b5e6-96231b3b80d8
* add comment explaining previous commitRobert Lytton2014-02-13
| | | | | | see 'XCore target -fexceptions flag handling' git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201311 91177308-0d34-0410-b5e6-96231b3b80d8
* XCore target -fexceptions flag handlingRobert Lytton2014-02-13
| | | | | | | XCore target has -fno-exception as the default option Pass on "-fexceptions" flag to xcc (linker) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201310 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove spurious default case to silent sanitizerRenato Golin2014-02-13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201309 91177308-0d34-0410-b5e6-96231b3b80d8
* Add EXPERIMENTAL --rtlib=compiler-rt to GNU ClangRenato Golin2014-02-13
| | | | | | | | | | | | | | | | | | This commit is not strictly correct nor accounts for all uses (shared objects, for example), but it allows one to test the compiler-rt library on GNU targets. Using this patch to run the test-suite has already shown me problems on ARM. Since this is a Darwin-only flag, nobody is using it, so it shouldn't be a problem. I will need extension to deal with the shared cases, but since we're not compiling libclang_rt.so, that's not yet applicable. Many other problems will have to be fixed first in compiler-rt (such as removing the 'arch' name from it and making it trully multi-arch, moving it to the default lib directory, make both .a and .so variants, etc). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201307 91177308-0d34-0410-b5e6-96231b3b80d8
* MS ABI: Implement #pragma vtordisp() and clang-cl /vdNReid Kleckner2014-02-12
| | | | | | | | | | | | | | | | | These features are new in VS 2013 and are necessary in order to layout std::ostream correctly. Currently we have an ABI incompatibility when self-hosting with the 2013 stdlib in our convertible_fwd_ostream wrapper in gtest. This change adds another implicit attribute, MSVtorDispAttr, because implicit attributes are currently the best way to make sure the information stays on class templates through instantiation. Reviewers: majnemer Differential Revision: http://llvm-reviews.chandlerc.com/D2746 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201274 91177308-0d34-0410-b5e6-96231b3b80d8
* Add an option to allow Clang verify source files for a module only once duringDmitri Gribenko2014-02-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | the build When Clang loads the module, it verifies the user source files that the module was built from. If any file was changed, the module is rebuilt. There are two problems with this: 1. correctness: we don't verify system files (there are too many of them, and stat'ing all of them would take a lot of time); 2. performance: the same module file is verified again and again during a single build. This change allows the build system to optimize source file verification. The idea is based on the fact that while the project is being built, the source files don't change. This allows us to verify the module only once during a single build session. The build system passes a flag, -fbuild-session-timestamp=, to inform Clang of the time when the build started. The build system also requests to enable this feature by passing -fmodules-validate-once-per-build-session. If these flags are not passed, the behavior is not changed. When Clang verifies the module the first time, it writes out a timestamp file. Then, when Clang loads the module the second time, it finds a timestamp file, so it can compare the verification timestamp of the module with the time when the build started. If the verification timestamp is too old, the module is verified again, and the timestamp file is updated. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201224 91177308-0d34-0410-b5e6-96231b3b80d8
* [ARM] Fix NEON wrongly being enabled with soft-float when targeting ↵Amara Emerson2014-02-12
| | | | | | | | | armv8/Cortex-A53/A57. This was caused by r200708 which enabled the crypto feature for these cores. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201223 91177308-0d34-0410-b5e6-96231b3b80d8
* Add Multilib selection machineryJonathan Roelofs2014-02-12
| | | | | | | | | | | | | | This patch improves the support for picking Multilibs from gcc installations. It also provides a better approximation for the flags '-print-multi-directory' and '-print-multi-lib'. This reverts r201203 (i.e. re-applying r201202 with small fixes in unittests/CMakeLists.txtto make the build bots happy). review: http://llvm-reviews.chandlerc.com/D2538 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201205 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert 201202Jonathan Roelofs2014-02-12
| | | | | | | Breaks cmake configure of new unit tests directory git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201203 91177308-0d34-0410-b5e6-96231b3b80d8
* Add Multilib selection machineryJonathan Roelofs2014-02-12
| | | | | | | | | | | This patch improves the support for picking Multilibs from gcc installations. It also provides a better approximation for the flags '-print-multi-directory' and '-print-multi-lib'. review: http://llvm-reviews.chandlerc.com/D2538 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201202 91177308-0d34-0410-b5e6-96231b3b80d8
* MS ABI: Add support for the -vm{b,g,s,m,v} flagsDavid Majnemer2014-02-11
| | | | | | | | | | These flags control the inheritance model initially used by the translation unit. Differential Revision: http://llvm-reviews.chandlerc.com/D2741 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201175 91177308-0d34-0410-b5e6-96231b3b80d8
* XCore target: Pass through "-fverbose-asm" flag to xcc assembler.Robert Lytton2014-02-11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201141 91177308-0d34-0410-b5e6-96231b3b80d8
* [stackprotector] Add command line option -fstack-protector-strongJosh Magee2014-02-11
| | | | | | | | | | | This option has the following effects: * It adds the sspstrong IR attribute to each function within the CU. * It defines the macro __SSP_STRONG__ with the value of 2. Differential Revision: http://llvm-reviews.chandlerc.com/D2717 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201120 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r194097: "With this patch -Wwrite-strings is still implemented with ↵Argyrios Kyrtzidis2014-02-07
| | | | | | | | | | | | | the terrible hack of passing -fconst-strings to -cc1" Passing or not a language option based on diagnostic settings is a bad idea, it breaks using a PCH that was compiled with different diagnostic settings. Also add a test case to make sure we don't regress. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200964 91177308-0d34-0410-b5e6-96231b3b80d8
* Use correct ld emulation for EABI hardware float triple on NetBSD.Joerg Sonnenberger2014-02-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200946 91177308-0d34-0410-b5e6-96231b3b80d8
* Move -verify-pch to use VerifyJobActionBen Langmuir2014-02-06
| | | | | | | | | Use the verify hook rather than the compile hook to represent the -verify-pch action, and move the exising --verify-debug-info action into its own subclass of VerifyJobAction. Incidentally change the name printed by -ccc-print-phases for --verify-debug-info. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200938 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a CC1 option -verify-pchBen Langmuir2014-02-05
| | | | | | | | | This option will: - load the given pch file - verify it is not out of date by stat'ing dependencies, and - return 0 on success and non-zero on error git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200884 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix handling of -fno-function-sections, -fno-data-sections in clang driver.Evgeniy Stepanov2014-02-03
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200685 91177308-0d34-0410-b5e6-96231b3b80d8
* Handle O32/N64 ABIs for NetBSD/MIPS64. From Matt Thomas.Joerg Sonnenberger2014-02-02
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200668 91177308-0d34-0410-b5e6-96231b3b80d8
* Use a switch for the emulation handling.Joerg Sonnenberger2014-02-02
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200666 91177308-0d34-0410-b5e6-96231b3b80d8
* Handle compat support for EABI/old APCS compatibility on NetBSD/ARM.Joerg Sonnenberger2014-02-02
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200665 91177308-0d34-0410-b5e6-96231b3b80d8
* Replace hasMipsN32ABIArg by hasMipsABIArg to make it easier to addJoerg Sonnenberger2014-02-02
| | | | | | | support for o32 and n64. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200662 91177308-0d34-0410-b5e6-96231b3b80d8
* Pass down -mcpu for external assembler in thumb mode, too. From Matt Thomas.Joerg Sonnenberger2014-02-02
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200661 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor formatting improvement.Joerg Sonnenberger2014-02-02
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200659 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r200555, r200545.Evgeniy Stepanov2014-02-02
| | | | | | | | These changes make it impossible to use ARM EHABI for stack unwinding without enabling exceptions and break AddressSanitizer on ARM. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200627 91177308-0d34-0410-b5e6-96231b3b80d8
* Last option on -fexception for arm-disable-ehabiRenato Golin2014-01-31
| | | | | | | Previous commit would have a following flag overriding the behaviour and not taken care of. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200555 91177308-0d34-0410-b5e6-96231b3b80d8