hanchenye-llvm-project/clang/test/Driver
Benjamin Kramer ab88f62614 Fix an logic error in the clang driver preventing crtfastmath.o from linking when -Ofast is used without -ffast-math
In gcc using -Ofast forces linking of crtfastmath.o.
In the current clang crtfastmath.o is only linked when -ffast-math/-funsafe-math-optimizations passed. It can lead to performance issues, when using only -Ofast without explicit -ffast-math (I faced with it).
My patch fixes inconsistency with gcc behaviour and also introduces few tests on it.

Patch by Zinovy Nis!

Differential Revision: http://llvm-reviews.chandlerc.com/D3114

llvm-svn: 204742
2014-03-25 18:02:07 +00:00
..
Inputs [Mips] Check all MIPS toolchains to find the one that best meets command 2014-03-04 18:37:28 +00:00
B-opt.c Accept both / and \\ to fix the windows bots. 2013-06-24 22:07:15 +00:00
O.c Options: Use AliasArgs for -O -> -O2 translation. 2013-08-01 16:21:57 +00:00
Ofast.c [driver] Test that last option wins between -Ofast and -O2. 2013-04-24 18:43:57 +00:00
Wp-args.c Fix option typo. 2013-10-27 14:46:16 +00:00
Xarch.c Replace 'grep foo | count 0' with 'not grep foo'. 2013-07-04 15:22:16 +00:00
Xlinker-args.c Driver: Forward -Wl, and -Xlink arguments when using windows linker 2013-08-14 01:24:35 +00:00
aarch64-cpus.c AArch64_be specific clang target settings 2014-03-14 12:15:45 +00:00
aarch64-features.c Add support for AArch64 target. 2013-01-31 12:13:10 +00:00
aarch64-mfpu.c Enable AArch64 NEON by default. 2014-02-14 04:37:46 +00:00
aarch64-mgeneral_regs_only.c [AArch64] Replace underscores with dashes in -mgeneral_regs_only. 2014-01-24 15:15:27 +00:00
altivec-asm.S Provide test case for commit r185544. 2013-07-03 18:21:12 +00:00
analyze.c
android-standalone.cpp Implement Adnroid MIPS toolchain support: 2012-10-03 17:46:38 +00:00
apple-kext-mkernel.c [driver] -mkernel implies -mstrict-align; don't add the redundant option. 2012-11-29 00:42:06 +00:00
arc-exceptions.m
arc.c Add 'not' to commands that are expected to fail. 2013-07-04 16:16:58 +00:00
arch.c Add support for passing '-target armv8' through the Driver. 2013-06-26 17:19:48 +00:00
arclite-link.c
arm-alignment.c Fix gnueeabi typo in tests 2013-09-02 14:11:33 +00:00
arm-arch-darwin.c Refactor duplicate functions 2013-12-12 13:27:11 +00:00
arm-cortex-cpus.c Revert "Cortex-M3 and Cortex-M4 should not enable hwdiv-arm" 2014-01-27 19:26:39 +00:00
arm-darwin-builtin.c Remove the -ccc-no-clang option. 2012-10-31 01:21:20 +00:00
arm-fixed-r9.c Tests for ARM aligned access + reserved R9 2013-08-25 13:01:50 +00:00
arm-hwdiv.c Add the __ARM_ARCH_EXT_IDIV__ predefine. It is set to 1 if we have hardware divide in the mode that we are compiling in (depending on the target features), not defined if we don't. Should be compatible with the GCC conterpart. Also adding a -hwdiv option to overide the default behavior. 2013-10-21 10:54:53 +00:00
arm-mfpu.c Add support for FPv4-SP to the clang driver 2014-02-21 10:39:15 +00:00
arm-restrict-it.c Add test case for r194593 2013-11-13 21:40:17 +00:00
armv8-crc.c ARM: Add -m[no-]crc to dis/enable CRC subtargetfeature from clang 2013-10-29 09:47:51 +00:00
asan.c Kill -faddress-sanitizer, -fthread-sanitizer and -fcatch-undefined-behavior flags. 2014-03-20 10:48:29 +00:00
ast.c
at_file.c Expand test/Driver/at_file.c test to check that PR16209 is fixed. 2013-07-23 17:26:56 +00:00
at_file.c.args Expand test/Driver/at_file.c test to check that PR16209 is fixed. 2013-07-23 17:26:56 +00:00
at_file.c.args.utf16le Expand test/Driver/at_file.c test to check that PR16209 is fixed. 2013-07-23 17:26:56 +00:00
at_file_missing.c test/Driver: Check that @ arguments that aren't files are handled 2013-12-06 22:57:13 +00:00
autolink_integrated_as.c [Modules] Convert module specific -fno-modules-autolink into -fno-autolink. 2013-04-16 18:21:19 +00:00
bindings.c Make the integrated assembler the default for cygwin/mingw too. 2013-11-25 18:50:53 +00:00
bitrig.c Handle -pthread, -pg and -shared correctly on bitrig. 2012-10-23 17:07:31 +00:00
cc-log-diagnostics.c
cc-print-options.c
ccc-as-cpp.c Turn Driver::CCCIsCXX and CCCIsCPP into a single Mode enum, 2013-07-18 20:29:38 +00:00
ccc-host-triple-no-integrated-as.c
cfi.c
cl-fallback.c clang-cl: Forward /Gy or /Gy- when falling back to cl.exe 2014-03-25 14:48:54 +00:00
cl-inputs.c clang-cl: Better error message when trying to compile stdin (PR18640) 2014-01-29 01:04:40 +00:00
cl-link.c Fix the ASan dll_thunk path 2013-09-11 11:45:31 +00:00
cl-options.c clang-cl: make /Gy imply -fdata-sections in addition to -ffunction-sections 2014-03-25 17:50:25 +00:00
cl-outputs.c clang-cl: Support /P and /E (preprocess to file or stdout) 2013-12-20 18:40:46 +00:00
cl-runtime-flags.c clang-cl: Don't warn about overriding /MD with /MT, /Fo with another /Fo, etc. 2013-09-18 22:26:39 +00:00
cl.c Remove the -cxx-abi command-line flag. 2014-01-14 19:35:09 +00:00
claim-unused.c [driver] If we're just linking, don't report --param X as unused option. 2013-03-08 00:05:21 +00:00
clang-c-as-cxx.c
clang-exception-flags.cpp
clang-g-opts.c Revert "Debug info: Make DWARF4 the default for Darwin, too." 2014-02-17 17:40:52 +00:00
clang-translation.c Make x86 Android default target CPUs compatible with GCC (http://llvm-reviews.chandlerc.com/D2655) 2014-01-31 04:07:13 +00:00
clang_cpp.c FileCheck-ify some clang grep tests that use double quotes 2013-04-10 21:10:39 +00:00
clang_f_opts.c Suppress clang/test/Driver/clang_f_opts.c for targeting cygming since r202058 is incompatible to gcc driver. 2014-02-25 00:30:04 +00:00
clang_f_opts.h
clang_wrapv_opts.c
color-diagnostics.c Add -fansi-escape-codes option 2013-09-11 00:38:02 +00:00
constructors.c Enable -fuse-init-array for all AArch64 ELF targets by default, not just linux. 2014-01-10 13:44:34 +00:00
coverage-ld.c Get rid of obsolete addProfileRT(), generalize the relevant addProfileRTLinux() to all OS 2014-02-20 13:57:37 +00:00
cpath.c [driver] Older versions of ld expect '-L<dir>' not '-L <dir>'. In Xcode4 and 2012-10-30 21:42:09 +00:00
cpp-precomp.c
crash-report.c Use -Xclang to pass -internal-isystem and -internal-externc-isystem to -cc1. 2013-09-25 15:47:05 +00:00
cross-linux.c Revert "Support cross linking to arm on ubuntu." 2013-10-28 23:14:34 +00:00
darwin-arch-default.c Driver/Darwin: The -arch argument values aren't exactly the arch names from a 2012-11-08 03:38:26 +00:00
darwin-as.c darwin asm driver: suppress -Q for -no-integrated-as on darwin<11 2013-12-10 22:51:25 +00:00
darwin-asan-nofortify.c Kill -faddress-sanitizer, -fthread-sanitizer and -fcatch-undefined-behavior flags. 2014-03-20 10:48:29 +00:00
darwin-debug-flags.c We want the dwarf AT_producer for assembly source files to match clang's 2013-01-17 21:38:06 +00:00
darwin-dsymutil.c Fix an assertion failure when invoking dsymutil. 2014-02-21 00:20:07 +00:00
darwin-embedded.c MachO embedded: default to soft float without issuing warning 2014-01-23 15:00:01 +00:00
darwin-iphone-defaults.m Add more of the command line options as attribute flags. 2013-02-28 22:49:57 +00:00
darwin-ld.c Fix an assertion failure when building for the iOS simulator. rdar://15959009 2014-02-01 21:06:21 +00:00
darwin-objc-defaults.m Objective-C driver. Do not use legacy dispatch for 2014-02-05 17:13:42 +00:00
darwin-objc-gc.m
darwin-objc-options.m Fix assertion failure left over from changes to move away from "darwin" triples. 2013-12-05 19:38:42 +00:00
darwin-sanitizer-ld.c [ASan] Fix darwin-sanitizer-ld.c for iossim, which seems to use -lc++ instead of -lstdc++. 2013-11-15 16:57:57 +00:00
darwin-sdkroot.c clang/test/Driver/darwin-sdkroot.c: Suppress this on msys bash, to introduce the feature "shell-preserves-root". 2013-01-16 06:10:16 +00:00
darwin-verify-debug.c Move -verify-pch to use VerifyJobAction 2014-02-06 18:53:25 +00:00
darwin-version.c
darwin-xarch.c
debug-comp-dir.S [driver] Implement the -fdebug-compilation-dir in a way that is compatible with 2013-04-26 20:49:50 +00:00
debug-main-file.S clang/test/Driver: Remove the feature "clang-driver" in three tests since they might work as expected since their first commit. 2013-08-20 12:16:35 +00:00
debug-options-as.c clang/test/Driver: Remove the feature "clang-driver" since gcc-as has not been used with -integrated-as since r177360. 2013-08-20 12:16:42 +00:00
debug-options.c Driver: Support -gmlt as an alias for -gline-tables-only 2014-03-11 21:05:26 +00:00
debug-unsupported.c Add 'not' to commands that are expected to fail. 2013-07-04 16:16:58 +00:00
debug.c [driver] Implement the -fdebug-compilation-dir in a way that is compatible with 2013-04-26 20:49:50 +00:00
default-toolchain.c
diagnostics.c
dragonfly.c Flail at trying to appease various linuxy buildbots. 2013-04-11 23:25:27 +00:00
dwarf2-cfi-asm.c
dyld-prefix.c clang/test/Driver/dyld-prefix.c: Exclude MSYS bash. 2013-05-28 12:18:56 +00:00
exceptions.m
fast-math.c Add a missing pipe in the test from r197896 2013-12-23 08:50:43 +00:00
fcomment-block-commands.c Comment parsing: add CommentOptions to allow specifying custom comment block commands 2013-02-22 14:21:27 +00:00
flags.c Add a new -mimplicit-float option for symmetry with -mno-implicit-float. 2013-04-11 18:53:25 +00:00
fpack-struct.c Fix FileCheck --check-prefix lines. 2013-08-12 12:51:05 +00:00
fparse-all-comments.c Add testcases for -fparse-all-comments 2013-04-10 16:31:58 +00:00
frame-pointer-elim.c Move this file into the correct directory. 2013-04-03 01:58:56 +00:00
frame-pointer.c [mips] Enable frame-pointer elimination for -O1 and above. 2013-10-16 17:13:08 +00:00
freebsd-mips-as.c [Mips] Change default CPU for MIPS 32/64 targets. Now they are mips32r2/mips64r2 respectively. 2014-01-27 13:59:04 +00:00
freebsd.c Pass the sparc architecture variant to the assembler. 2014-02-25 18:45:49 +00:00
freebsd.cc FreeBSD 10 ships with only libc++, make sure it's the default when compiling 2013-11-09 15:03:56 +00:00
fsanitize-blacklist.c Re-apply r188666 2013-08-19 13:59:22 +00:00
fsanitize.c Kill deprecated -fbounds-checking flag 2014-03-21 07:15:47 +00:00
function-sections.c Fix handling of -fno-function-sections, -fno-data-sections in clang driver. 2014-02-03 11:11:37 +00:00
gcc-toolchain.cpp Accept both / and \\ to fix the windows bots. 2013-06-24 22:07:15 +00:00
gcc-version-debug.c Relax testcase for r188400 to not test for forward-slashes as path separators. 2013-08-14 22:10:17 +00:00
gcc_forward.c Don't use the gcc driver for assembling. 2013-11-23 16:40:57 +00:00
gfortran.f90 Add support to the Clang driver for forwarding all of gfortran's flags 2013-10-17 03:28:24 +00:00
gnu-runtime.m
gold-lto.c Refactor the x86 CPU name logic in the driver and pass -march and -mcpu 2013-01-13 11:46:33 +00:00
hexagon-toolchain-elf.c Fix option spelling. 2013-10-27 14:11:19 +00:00
hexagon-toolchain.c Fix option spelling. 2013-10-27 14:11:19 +00:00
ident_md.c Emit a .ident saying that clang produced this file. 2013-10-16 19:28:50 +00:00
immediate-options.c Turn Driver::CCCIsCXX and CCCIsCPP into a single Mode enum, 2013-07-18 20:29:38 +00:00
index-header-map.c
inhibit-downstream-commands.c Add 'not' to commands that are expected to fail. 2013-07-04 16:16:58 +00:00
integrated-as.c clang: add -f{no-,}integrate-as as consistent parameters 2014-02-23 00:40:30 +00:00
integrated-as.s Driver: Suppression support for -Wa,--compress-debug-sections 2014-01-22 19:22:21 +00:00
ios-simulator-arcruntime.c Remove old driver code to grab the iOS simulator version from the -D option. 2012-11-09 01:59:30 +00:00
krait-cpu.c Added support for mcpu krait 2013-12-06 22:43:17 +00:00
le32-toolchain.c Pass -fno-math-builtin from the Clang driver to -cc1 for the l32 arch. 2013-07-24 18:20:14 +00:00
le32-unknown-nacl.cpp Convert another test to -###. 2013-07-23 15:57:21 +00:00
linker-opts.c LIBRARY_PATH environment variable should only be supported on a native compiler. 2013-12-17 11:11:25 +00:00
linux-as.c MIPS and SPARC assemblers both take the -KPIC flag. 2014-01-12 04:53:36 +00:00
linux-header-search.cpp Update tests for addition of patch level to LLVM version 2014-03-03 15:22:14 +00:00
linux-ld.c Fix an logic error in the clang driver preventing crtfastmath.o from linking when -Ofast is used without -ffast-math 2014-03-25 18:02:07 +00:00
lit.local.cfg Move remaining %clang_cc1 tests out of test/Driver 2013-11-16 06:20:17 +00:00
lto.c Produce an error when trying to link with -emit-llvm. 2013-08-25 14:27:09 +00:00
m_and_mm.c Replace 'grep foo | count 0' with 'not grep foo'. 2013-07-04 15:22:16 +00:00
macho-embedded.c MachO: use *-*-*-macho for MachO embedded targets. 2014-01-16 08:48:16 +00:00
mg.c
mips-abi.c [Mips] Convert a GNU style Mips ABI name to the name accepted by LLVM 2013-04-21 13:30:10 +00:00
mips-as.c test: fix MIPS driver tests 2014-02-22 23:37:54 +00:00
mips-cs.cpp [Mips] Reduce number of FileCheck variables used in the tests. 2013-11-26 11:57:53 +00:00
mips-eleb.c [Mips] Change default CPU for MIPS 32/64 targets. Now they are mips32r2/mips64r2 respectively. 2014-01-27 13:59:04 +00:00
mips-features.c [mips] Added -mfp64 and -mfp32 options. 2013-10-17 14:55:58 +00:00
mips-float.c [Mips] Do not adjust float-abi flags in case of MIPS16 mode. This code 2013-11-19 12:22:38 +00:00
mips-fsf.cpp [Mips] Reduce number of FileCheck variables used in the tests. 2013-11-26 11:57:53 +00:00
mips-reduced-toolchain.cpp [Mips] Check all MIPS toolchains to find the one that best meets command 2014-03-04 18:37:28 +00:00
mipsel-nacl-defines.cpp [Mips] Allocate NaClTargetInfo for MIPSEL NaCl 2013-09-21 01:27:01 +00:00
mno-global-merge.c
modules.m Add an option -fmodules-validate-system-headers 2014-03-12 00:06:17 +00:00
modules.mm
montavista-gcc-toolchain.c Accept both / and \\ to fix the windows bots. 2013-06-24 22:07:15 +00:00
ms-inline-asm.c [driver, ms-inline asm] MS-Style inline assembly is controlled by the 2012-12-05 21:08:21 +00:00
msvc_forward.c
netbsd.c Always use --eh-frame-hdr on NetBSD, even for -static. 2014-03-13 00:42:01 +00:00
netbsd.cpp Hook up NetBSD/sparc and NetBSD/sparc64 as and ld invocations. 2014-02-19 22:40:18 +00:00
no-integrated-as-win.c Tidy up the no-external-assembler diag 2013-11-22 08:27:46 +00:00
no-integrated-as.c clang: forward -no-integrated-as from the driver 2014-02-22 23:37:58 +00:00
no-objc-arr.m Prior to adding the new "expected-no-diagnostics" directive to VerifyDiagnosticConsumer, make the necessary adjustment to 580 test-cases which will henceforth require this new directive. 2012-10-19 12:44:48 +00:00
no-objc-default-synthesize-properties.m Produce an error for unknown -f options. 2013-09-25 19:07:08 +00:00
no-sibling-calls.c
nodefaultlib.c Insulate this test from the whims of the random number generator. 2012-12-21 22:43:20 +00:00
noexecstack.c Use -target instead of triple and use FileCheck. 2013-10-27 13:59:51 +00:00
noinline.c
nostdincxx.cpp check-clang: Introduce the feature "non-ms-sdk" to suppress Driver/nostdincxx.cpp on msvc. 2014-02-16 10:15:57 +00:00
nostdlib.c
nostdlibinc.c
objc++-cpp-output.mm Use -emit-llvm for the following tests to stop them from failing for Hexagon: 2013-04-16 15:55:41 +00:00
objc-cpp-output.m Use -emit-llvm for the following tests to stop them from failing for Hexagon: 2013-04-16 15:55:41 +00:00
openbsd.c Add support for OpenBSD SPARC assembler. 2014-02-28 01:55:21 +00:00
option-aliases.c Use -### instead of -ccc-print-options. 2013-09-03 13:26:49 +00:00
output-file-cleanup.c [driver] Refactor the driver so that a failing commands doesn't prevent 2013-01-29 20:15:05 +00:00
output-file-is-dir.c Simplify test so that it is more portable. 2013-04-13 22:26:02 +00:00
pch-deps.c [Modules] Emit the module file paths as dependencies of the PCH when we are building one. 2014-03-14 03:07:38 +00:00
phases.c
pic.c Turn on PIC by default on Android (http://llvm-reviews.chandlerc.com/D2603) 2014-01-28 06:30:35 +00:00
ppc-features.cpp Update the parameters passed to the assembler and linker for 2014-03-24 17:10:37 +00:00
prefixed-tools.c
preprocess-multiple.c Add driver test for multiple preprocessor inputs 2014-02-24 08:17:02 +00:00
preprocessor.c
pth.c clang/test/Driver/pth.c: Fix r184942, a regexp like "\\\\" is redundant here. Should be matched to single \ with '\\'. 2013-06-26 15:03:20 +00:00
qa_override.c Remove support for the QA_OVERRIDE_GCC3_OPTIONS environment variable. 2014-02-23 00:11:56 +00:00
r600-mcpu.cl R600: Add processor type for Hawaii 2013-11-14 23:45:53 +00:00
redundant-args.c
redzone.c
retain-comments-from-system-headers.c Add tests for r163778. 2012-09-13 17:25:51 +00:00
rewrite-legacy-objc.m ObjectiveC. availability of Array/Dictionary subscripting 2013-11-12 20:50:26 +00:00
rewrite-objc.m ObjectiveC driver. Scrap -fno-objc-legacy-dispatch for NeXT 2013-10-15 17:16:30 +00:00
sanitize_unwind_tables.c Enable generation of unwind tables when building with sanitizers. 2014-02-14 08:56:25 +00:00
sanitizer-ld.c clang/test/Driver/sanitizer-ld.c: Tweak to accept dos path. 2014-03-18 10:47:10 +00:00
save-temps.c [driver] Allow multiple -arch options with -save-temps by adding the arch name 2013-04-30 22:01:21 +00:00
split-debug.c If we're splitting the dwarf for fission and don't want to use the 2013-06-05 23:58:15 +00:00
split-debug.s For split dwarf we should also run the objcopy action if we're 2013-04-10 21:30:40 +00:00
stack-protector.c [stackprotector] Add command line option -fstack-protector-strong 2014-02-11 01:35:14 +00:00
stackrealign.c
std.c
std.cpp Add 'not' to commands that are expected to fail. 2013-07-04 16:16:58 +00:00
sysroot-flags.c
sysroot.c
systemz-march.c Fix test to actually check things. 2013-07-19 17:49:21 +00:00
target-as.s clang/test/Driver: Remove the feature "clang-driver" in three tests since they might work as expected since their first commit. 2013-08-20 12:16:35 +00:00
target-triple-deployment.c Darwin: update clang test to new iOS default version (5.0) 2013-12-10 11:53:25 +00:00
target.c Don't use the gcc driver for assembling. 2013-11-23 16:40:57 +00:00
tsan.c SanitizerArgs: add ability to filter/diagnose unsupported sanitizers. 2013-11-01 18:16:25 +00:00
unknown-arg.c Produce an error for unknown -f options. 2013-09-25 19:07:08 +00:00
unknown-gcc-arch.c Fix broken RUN lines 2014-02-16 07:28:32 +00:00
verify_pch.m Add a CC1 option -verify-pch 2014-02-05 22:21:15 +00:00
vfsoverlay.c Add a driver option -ivfsoverlay 2014-02-25 18:23:47 +00:00
via-file-asm.c Fix via-file-asm test failure on windows 2013-12-10 00:54:30 +00:00
visibility.cpp Fix broken CHECK lines 2014-02-16 07:29:41 +00:00
warning-options.cpp Revert "Revert r166370 and r166540 now that Xcode 4.6 has been available for a while." 2013-03-12 20:00:34 +00:00
warning-options_pedantic.cpp clang/test/Driver: Introduce the feature "clang-driver", set if gcc driver is not used. 2012-12-11 07:06:09 +00:00
working-directory-and-abs.c [driver] Before applying the working directory check if the input path 2012-10-26 20:09:24 +00:00
working-directory.c clang/test/Driver/working-directory.c: Exclude msys bash rather than tweaking expressions. 2013-09-04 09:37:12 +00:00
x86_64-nacl-defines.cpp Add missing quotes for -###. 2013-07-23 15:20:22 +00:00
x86_features.c Fix test. 2013-10-03 19:18:22 +00:00
x86_m16.c Add -m16 option for using x86-*-*-code16 triple 2014-01-21 17:19:44 +00:00
xcore-opts.c Fix broken CHECK lines 2014-02-16 07:29:41 +00:00