Граф коммитов

462 Коммитов

Автор SHA1 Сообщение Дата
Ted Kremenek 55bac53391 Revert r83443.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83451 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-07 03:21:11 +00:00
Mike Stump 44da821078 Fixup pathnames.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83443 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-07 01:11:54 +00:00
Rafael Espindola 6961fdd661 Add the -nostdclanginc option to clang (the driver).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83377 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-06 12:45:37 +00:00
Douglas Gregor b8d1191fde Provide a common set of routines in Version.h that return Subversion
branch/revision information. Use that information in the driver,
rather than one-off branch/revision computation. 



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83321 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-05 20:33:49 +00:00
Fariborz Jahanian 85caf03ee4 Set __EXCEPTIONS by checking on darwin's triple.
Patch by Rafael Espindola.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83209 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-01 20:30:46 +00:00
Rafael Espindola f759df06d9 Move the "needs exception support" logic to clang. This also fixes
-fno-exceptions in C++ code. We used to always define __EXCEPTIONS in
C++.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83199 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-01 13:33:33 +00:00
Daniel Dunbar a92ba278fd Fix truck sized thinko where Darwin/ARM toolchain didn't look for programs in
libexec, *blush*.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83086 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-29 18:52:10 +00:00
Ted Kremenek b8bb3e797c Turn on 'RegionStore' as the default store manager both for 'clang --analyze' and 'scan-build'. Leave 'BasicStore' as the default store manager in 'clang-cc'. While there are still known warts with RegionStore, it's ready to be tested by general users.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82752 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-25 05:55:59 +00:00
Daniel Dunbar f44c585632 Push "clang-is-production" logic up to tools/driver, and make it hittable by
defining the CLANG_IS_PRODUCTION Makefile variable.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82583 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-22 22:31:13 +00:00
Daniel Dunbar 1d4612b829 Split Darwin toolchain into Clang and GCC Darwin toolchains with a common base.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82213 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-18 08:15:13 +00:00
Daniel Dunbar 6cd4154b90 Lift AddLinkRuntimeLibArgs into Darwin tool chain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82212 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-18 08:15:03 +00:00
Daniel Dunbar 608d04cb7b Move isMacosxVersionLT helpers to Darwin tool chain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82211 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-18 08:14:55 +00:00
Daniel Dunbar 48d5aae438 Lift getMacosxVersionMin out into Darwin ToolChain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82210 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-18 08:14:46 +00:00
Daniel Dunbar 6b200b2b69 Lift AddLinkerSearchPaths() into Darwin tool chain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82209 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-18 08:14:36 +00:00
Daniel Dunbar ae54af2fdc Rename a variable to match its semantics.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82208 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-18 08:14:24 +00:00
Daniel Dunbar 20f0eacf16 Driver: Change -O to mean -O2, -O1 is meaningless.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82131 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-17 06:53:36 +00:00
Daniel Dunbar 634b24563b Improve driver error message when only running the preprocessor and an input is
already preprocessed.

--
ddunbar@giles:tmp$ touch t.i
ddunbar@giles:tmp$ gcc -E t.i
ddunbar@giles:tmp$ clang -E t.i
clang: warning: t.i: previously preprocessed input unused when '-E' is present
ddunbar@giles:tmp$ 
--

<rdar://problem/6813375> [driver] driver prints confusing message when running -E on preprocessed file

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82120 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-17 04:13:26 +00:00
Daniel Dunbar e3b8d07e02 We don't need a -compile-ast clang-cc action, we can just use -S.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82105 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-17 00:47:53 +00:00
Daniel Dunbar 6bea73b330 Incremental improvement to logic determining whether we emit unwind tables or
not.
 - PR4932.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82021 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-16 06:17:29 +00:00
Daniel Dunbar 2030d8f46b Support -mabi= for clang/ARM.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81734 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-14 00:34:46 +00:00
Daniel Dunbar f4aa4f61de Swizzle the target triple based on -mthumb, and update clang-cc to recognize
thumb-foo-bar as an ARM target.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81497 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-11 01:14:50 +00:00
Daniel Dunbar cbd1933f83 Initial handling of -m{soft-float,hard-float,float-abi=} for ARM.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81471 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 23:00:09 +00:00
Daniel Dunbar e6ad3f9fce Move X86 handling of -m[no-]soft-float and -m[no-]red-zone into AddX86TargetArgs.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81470 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 22:59:57 +00:00
Daniel Dunbar 1d65e4be6f Change getLLVMArchNameForARM to just get the suffix.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81469 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 22:59:51 +00:00
Daniel Dunbar 728a512753 Add code to mangle the triple for LLVM on ARM.
- I think we should get rid of this distinction though, but I need to discuss with the interested parties.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81435 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 06:49:20 +00:00
Daniel Dunbar f84a4a469d Don't pass -fno-builtin-str{cat,cpy} to clang-cc, I forget we don't support that yet. PR4941.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81430 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 04:57:27 +00:00
Daniel Dunbar b163ef7e7a ARM: Pass -mcpu to clang-cc based on -march= and -mcpu=.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81429 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 04:57:17 +00:00
Daniel Dunbar 2ba9157590 Implement Darwin/ARM behavior for defaulting to -fno-builtin-str{cat,cpy}.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81425 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 03:37:02 +00:00
Daniel Dunbar e2fd66418e Add a check that -static is not used with -dynamic or -mdynamic-no-pic.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81421 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 01:21:12 +00:00
Daniel Dunbar 88a3d6cf5e Factor out CheckPreprocessing options to share between Clang/CC1 tools.
Also, fix forwarding of -C/-CC to cc1.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81420 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 01:21:05 +00:00
Daniel Dunbar 84ec96c8a8 Improve Darwin argument translation to match what the driver driver does.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81391 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:33:15 +00:00
Daniel Dunbar 6acda16e9c Move Clang X86 cpu/feature argument translation into AddX86TargetArgs.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81390 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:33:08 +00:00
Daniel Dunbar 5ed34f4c58 Change Get{File,Program}Path to return an std::string (instead of a sys::Path).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81389 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:33:00 +00:00
Daniel Dunbar 881376467c Remove gratuitous use of c_str().
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81388 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:32:48 +00:00
Daniel Dunbar 302e2eacf6 Use Twine concatenation instead of llvm::format.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81387 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:32:41 +00:00
Daniel Dunbar 5b750fe618 Simplify.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81386 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:32:34 +00:00
Daniel Dunbar 16484afe5c StringRefize ArgList construction of ArgStrings.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81385 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 22:32:26 +00:00
Daniel Dunbar cc6f803f98 Use AddDarwinArch for passing arch name to assembler.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81368 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:36:27 +00:00
Daniel Dunbar fbefe6bd6f Add DarwinTool base class for all Darwin tools, and move AddDarwin[Sub]Arch there.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81367 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:36:20 +00:00
Daniel Dunbar 0dcb9a3705 Push bound architecture name into TranslateArgs.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81366 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:36:12 +00:00
Daniel Dunbar 4954018954 Push bound architecture name into Compilation::getArgsForToolChain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81365 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 18:36:01 +00:00
Mike Stump 1eb4433ac4 Remove tabs, and whitespace cleanups.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81346 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-09 15:08:12 +00:00
Daniel Dunbar 7ef7f133de Change Darwin toolchain lookup to use llvm::Triple.
- -2+1 FIXMEs.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81282 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:37:36 +00:00
Daniel Dunbar 36df290435 Validate arguments to -arch.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81281 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:37:30 +00:00
Daniel Dunbar d7502d0a66 Rename HostInfo::getToolChain to HostInfo::CreateToolChain, and don't recreate
the default tool chain when binding the default architecture.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81279 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:37:19 +00:00
Daniel Dunbar fe8aa47fb6 Delete trailing whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81278 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:37:08 +00:00
Daniel Dunbar 3f30ddf680 Simplify.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81277 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:37:02 +00:00
Daniel Dunbar a6046bec7f Fix ShouldUseClangCompiler to use llvm::Triple.
- -1 FIXME, and fixes 'clang -arch armv4t ...', for example.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81276 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:36:55 +00:00
Daniel Dunbar a82318332c Tweak & reflow comments, and delete trailing whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81275 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 23:36:43 +00:00
Daniel Dunbar e0be8b1729 Remove FIXMEs for pedantically-gcc-bug-compatible behavior.
- We aren't going to fix these since they haven't caused problems in practice.

 - Similarly, don't forward -object to Darwin ld.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81224 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-08 16:39:16 +00:00