summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend
Commit message (Collapse)AuthorAgeFilesLines
...
* Introduce Driver::createInvocationFromArgs used to create a ↵Argyrios Kyrtzidis2011-04-041-52/+4
| | | | | | CompilerInvocation from command-line args. llvm-svn: 128848
* Remove a redundant isValid() checkMatt Beaumont-Gay2011-03-311-1/+1
| | | | llvm-svn: 128606
* Change Clang's __VERSION__ to include the same basic info as in clang -v.Daniel Dunbar2011-03-311-1/+6
| | | | | | - Please never ever ever ever write a tool that sniffs this. llvm-svn: 128599
* Integrated-As: Support -Wa,-L when using the integrated assembler.Daniel Dunbar2011-03-281-0/+3
| | | | llvm-svn: 128433
* Flip the default for showing include stacks on notes to false. ThisChandler Carruth2011-03-271-4/+4
| | | | | | | | | | | | | required modifying a few tests that specifically use note include stacks to check the source manager's view of include stacks. I've simply added the flag to these tests for now, they may have to be more substantially changed if we decide to remove support for note include stacks altogether. Also, add a test for include stacks on notes that was supposed to go in with the previous commit. llvm-svn: 128390
* Add an option to suppress include stack printing on note diagnostics.Chandler Carruth2011-03-272-10/+22
| | | | | | | | | | | | | | | | | | 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
* switch a few Driver APIs to use llvm::ArrayRef, cleaning up code.Chris Lattner2011-03-231-4/+2
| | | | llvm-svn: 128142
* std::vector::data() is not portable to VS. Use a gross hack instead.Ted Kremenek2011-03-231-1/+3
| | | | llvm-svn: 128138
* Frontend: Add a more explicit -backend-option flag for passing backend commandDaniel Dunbar2011-03-221-0/+5
| | | | | | | | 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
* Rework crash recovery cleanup in ASTUnit and CIndex to recover more memory ↵Ted Kremenek2011-03-221-25/+46
| | | | | | | | during a Sema crash (we have just a handful of leaks left) and to use the simplified cleanup registration API. llvm-svn: 128059
* Frontend: Change CC_PRINT_HEADERS to not print header depth markers, these don'tDaniel Dunbar2011-03-212-8/+15
| | | | | | really make any sense in this environment. llvm-svn: 128014
* Improve crash recovery cleanup to recovery CompilerInstances during crash ↵Ted Kremenek2011-03-213-95/+80
| | | | | | | | | | recovery. This was a huge resource "root" during crashes. This change requires making a bunch of fundamental Clang structures (optionally) reference counted to allow correct ownership semantics of these objects (e.g., ASTContext) to play out between an active ASTUnit and CompilerInstance object. llvm-svn: 128011
* Use CrashRecoveryContextCleanup objects to reclaim resources from ↵Ted Kremenek2011-03-211-72/+90
| | | | | | CompilerInstance objects. llvm-svn: 128009
* Preprocessor: Don't define __STDC__ in -traditional-cpp mode.Daniel Dunbar2011-03-191-1/+1
| | | | llvm-svn: 127933
* Add support for language-specific address spaces. On top of that,Peter Collingbourne2011-03-181-0/+3
| | | | | | | | | add support for the OpenCL __private, __local, __constant and __global address spaces, as well as the __read_only, _read_write and __write_only image access specifiers. Patch originally by ARM; language-specific address space support by myself. llvm-svn: 127915
* Lexer: Add extremely limited support for -traditional-cpp, ignoring BCPLDaniel Dunbar2011-03-181-0/+3
| | | | | | comments. llvm-svn: 127910
* Use the newly added FileManager::getNoncachedStatValue when trying to ↵Anders Carlsson2011-03-181-2/+2
| | | | | | determine if any files in the preamble have changed. llvm-svn: 127894
* Correctly store and keep track of the FileSystemOptions in ASTUnit and in ↵Anders Carlsson2011-03-181-4/+6
| | | | | | clang_codeCompleteAt. llvm-svn: 127890
* The Darwin kernel does not provide useful guard variable support.John McCall2011-03-181-0/+3
| | | | | | | | 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
* Use CrashRecoveryContextCleanup objects to recover an ASTUnit if we crash in ↵Ted Kremenek2011-03-181-0/+18
| | | | | | ASTUnit::LoadFromCommandLine() and ASTUnit::LoadFromCompilerInvocation(). llvm-svn: 127851
* Fix duplicate argument processingSandeep Patel2011-03-161-1/+1
| | | | llvm-svn: 127746
* lib/Frontend/InitHeaderSearch.cpp: Introduce AddMinGW64CXXPaths(Base) for ↵NAKAMURA Takumi2011-03-151-12/+24
| | | | | | x86_64-w64-mingw32. llvm-svn: 127652
* Add include paths for Gentoo Linux, from Marcin Mirosław!Douglas Gregor2011-03-141-2/+22
| | | | llvm-svn: 127582
* Get rid of the static FileManager::FixupRelativePath.Anders Carlsson2011-03-141-1/+1
| | | | llvm-svn: 127573
* Introduce '-chain-include' option to specify headers that will be converted ↵Argyrios Kyrtzidis2011-03-093-7/+49
| | | | | | | | | | to chained PCHs in memory without having to use multiple runs and intermediate files. Intended for testing & debugging of chained PCH. llvm-svn: 127339
* Add 'OverridenFilesKeepOriginalName' field in SourceManager which if true ↵Argyrios Kyrtzidis2011-03-082-11/+7
| | | | | | | | | | | the SourceManager should report the original file name for contents of files that were overriden by other files, otherwise it should report the name of the new file. Default is true. Also add similar field in PreprocessorOptions and pass similar parameter in ASTUnit::LoadFromCommandLine. llvm-svn: 127289
* Allow passing '-###' to ASTUnit::LoadFromCommandLine to print out the cc1 ↵Argyrios Kyrtzidis2011-03-071-0/+8
| | | | | | options. llvm-svn: 127183
* Remove the AST printer (-ast-print-xml), which is too incomplete andDouglas Gregor2011-03-078-854/+0
| | | | | | | | | | | | | | | too low-level to actually be useful but is just interesting enough for people to try to use it (which won't actually work beyond toy examples). To bring back the AST printer, it needs to be: - Complete, covering all of C/C++/Objective-C - Documented, with appropriate Schema against which we can validate the output - Designed for C/C++/Objective-C, not Clang's specific ASTs - Stable across Clang versions - Well-tested llvm-svn: 127141
* Convert FileManager::FixupRelativePath over to using PathV2.Anders Carlsson2011-03-061-9/+12
| | | | llvm-svn: 127133
* Add MinGW GCC 4.5.2 include paths, from Matthieu MonrocqDouglas Gregor2011-03-061-0/+3
| | | | llvm-svn: 127124
* Currently we can only remap a file by creating a MemoryBuffer and replacing ↵Argyrios Kyrtzidis2011-03-052-26/+76
| | | | | | | | | the file contents with it. Allow remapping a file by specifying another filename whose contents should be loaded if the original file gets loaded. This allows to override files without having to create & load buffers in advance. llvm-svn: 127052
* Introduce OwnsRemappedFileBuffers field in ASTUnit, indicating whether the ↵Argyrios Kyrtzidis2011-03-051-1/+2
| | | | | | ASTUnit should delete the remapped buffers. llvm-svn: 127051
* Apply sysroot to system c++ headers too. Fixes PR9372.Rafael Espindola2011-03-021-1/+1
| | | | llvm-svn: 126884
* On FreeBSD, make sure /usr/local/include is *not* in the default includeRoman Divacky2011-03-011-0/+1
| | | | | | | | path. This avoids accidentally including the wrong headers. Patch by Dimitry Andric! llvm-svn: 126761
* Implement -mrtd which sets the StdCall calling convention to be the defaultRoman Divacky2011-03-011-0/+1
| | | | | | one. llvm-svn: 126756
* [analyzer] Remove '-analyzer-check-objc-mem' flag, the nominee for best ↵Argyrios Kyrtzidis2011-02-281-17/+0
| | | | | | misnomer award. llvm-svn: 126676
* Kill 18 month old #if 0'd code in StmtXML.cppPeter Collingbourne2011-02-281-316/+0
| | | | llvm-svn: 126670
* Rename tok::eom to tok::eod.Peter Collingbourne2011-02-282-3/+3
| | | | | | | | The previous name was inaccurate as this token in fact appears at the end of every preprocessing directive, not just macro definitions. No functionality change, except for a diagnostic tweak. llvm-svn: 126631
* [analyzer] Migrate ArrayBoundCheckerV2 to CheckerV2.Argyrios Kyrtzidis2011-02-281-3/+0
| | | | | | Turns -analyzer-check-buffer-overflows into -analyzer-checker=core.experimental.Overflow llvm-svn: 126609
* [analyzer] Turn -analyzer-stats into -analyzer-checker=debug.StatsArgyrios Kyrtzidis2011-02-281-3/+0
| | | | llvm-svn: 126608
* [analyzer] Remove '-analyzer-experimental-checks' flag.Argyrios Kyrtzidis2011-02-281-3/+0
| | | | llvm-svn: 126607
* Teach objc-rewriter to pass -fobjc-exceptions along.Fariborz Jahanian2011-02-251-1/+4
| | | | llvm-svn: 126497
* Teach TextDiagnosticPrinter to print out '-Werror' in addition to the ↵Ted Kremenek2011-02-251-1/+13
| | | | | | | | | | warning flag for a warning mapped to an error. For example: t.c:7:9: error: using the result of an assignment as a condition without parentheses [-Werror,-Wparentheses] llvm-svn: 126466
* Intoduce '-analyzer-checker-help' flag which outputs a list of all available ↵Argyrios Kyrtzidis2011-02-251-0/+3
| | | | | | | | static analyzer checkers. This is pretty basic for now, eventually checkers should be grouped according to package, hidden checkers should be indicated etc. llvm-svn: 126454
* [analyzer] Remove '-analyzer-experimental-internal-checks' flag, it doesn't ↵Argyrios Kyrtzidis2011-02-241-4/+0
| | | | | | have any checkers associated with it anymore. llvm-svn: 126440
* Allow passing a list of comma separated checker names to -analyzer-checker, e.g:Argyrios Kyrtzidis2011-02-241-2/+7
| | | | | | -analyzer-checker=cocoa,unix llvm-svn: 126372
* Reimplement DefineTypeSize in terms of APInt. This eliminates someChris Lattner2011-02-241-9/+4
| | | | | | | magic integer arithmetic and allows it to work with types larger than 64 bits. llvm-svn: 126365
* Teach NestedNameSpecifier to keep track of namespace aliases the sameDouglas Gregor2011-02-241-0/+5
| | | | | | | | way it keeps track of namespaces. Previously, we would map from the namespace alias to its underlying namespace when building a nested-name-specifier, losing source information in the process. llvm-svn: 126358
* Preserve what the user passed to -include when emitting .d files. Fixes PR8974!Nick Lewycky2011-02-232-10/+17
| | | | llvm-svn: 126334
* Add a -fcxx-exceptions flag to clang -cc1. This controls the newly added ↵Anders Carlsson2011-02-231-4/+7
| | | | | | CXXExceptions flag. llvm-svn: 126300
OpenPOWER on IntegriCloud