History log of /external/clang/lib/Frontend/CompilerInstance.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
d99ef536b241071b6f4c01db6525dc03242ac30b 02-Jul-2012 Dmitri Gribenko <gribozavr@gmail.com> Add a new libclang completion API to get brief documentation comment that is
attached to a declaration in the completion string.

Since extracting comments isn't free, a new code completion option is
introduced.

A new code completion option that enables including brief comments
into CodeCompletionString should be a, err, code completion option.
But because ASTUnit caches global declarations during parsing before
even completion consumer is created, the option is duplicated as a
translation unit option (in both libclang and ASTUnit, like the option
to cache code completion results).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159539 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
832a2aac5766dd78f113e0f03a0c62fd0eacbc97 16-May-2012 Manuel Klimek <klimek@google.com> Pulls diagnostics for temp file handling into the common diagnostic kinds.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156947 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
7d9ae25d93554bdb238da83f9bb3e0b05475c16c 11-May-2012 Eric Christopher <echristo@apple.com> For final output files create them with mode 0664 to match other
compilers and expected defaults.

Part of rdar://11325849

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156592 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f720a2bd5ac2130852a67b4ec1d79ed8f4d7f43e 01-May-2012 David Blaikie <dblaikie@gmail.com> Remove variables made dead by r155923

This makes Clang's build warning free again.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155928 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1b9a688fbaae610398676186dcd1f3a596a46571 01-May-2012 Ted Kremenek <kremenek@apple.com> Remove dead code found by static analyzer.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155923 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
93a49944e0e68e32bc22d45d44ee136b34beffb3 16-Apr-2012 Fariborz Jahanian <fjahanian@apple.com> objective-c modern translator: buildit objc bool
type for rewriter project will be BoolTy.
// rdar://11231426.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154861 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
9bc0c290a79a6aca46367626e3463077147e7e76 12-Apr-2012 Erik Verbruggen <erikjv@me.com> Changed all direct calls to CompletionConsumer.reset(..) to go call
CompilerInstance::setCodeCompletionConsumer instead, in order to change
the SkipFunctionBodies flag accordingly. Also fixed
setCodeCompletionConsumer to take a reset() to null into account.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154585 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6a91d385618ea4d28236c496f540a26877c95525 12-Apr-2012 Erik Verbruggen <erikjv@me.com> Added a flag to the parser to skip method bodies.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154584 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
bef35c91b594f66216f4aab303b71a6c5ab7abcf 07-Mar-2012 Argyrios Kyrtzidis <akyrtzi@gmail.com> [PCH] Mark a PCH file with a flag to indicate if the serialized AST had
compiler errors or not.

-Control whether ASTReader should reject such a PCH by a boolean flag at ASTReader's creation time.
By default, such a PCH file will be rejected with an error when trying to load it.

[libclang] Allow clang_saveTranslationUnit to create a PCH file even if compiler errors
occurred.
-Have libclang API calls accept a PCH that had compiler errors.

The general idea is that we want libclang to stay functional even if a PCH had a compiler error.
rdar://10976363.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152192 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c6c54521f95760a5eaf29b668d4bf41fe2af49d7 05-Mar-2012 Argyrios Kyrtzidis <akyrtzi@gmail.com> [preprocessor] Enhance PreprocessingRecord to keep track of locations of conditional directives.

Introduce PreprocessingRecord::rangeIntersectsConditionalDirective() which returns
true if a given range intersects with a conditional directive block.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152018 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e21dd284d8209a89137a03a0d63f2bd57be9e660 03-Mar-2012 Daniel Dunbar <daniel@zuster.org> Frontend: Default to creating output files using temporary files + rename.
- This is a more reliable default, as it behaves better on failure and also
ensures that we create *new* files (instead of reusing existing inodes). This
is useful for other applications (like lldb) which want to cache inode's to
know when a file has been rewritten.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151961 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
12f28ab8a53d7743081d607617309891fa8156f3 03-Mar-2012 Daniel Dunbar <daniel@zuster.org> Frontend: Don't automatically create missing directories when using temporary files with createOutputFile()
- This would otherwise happen as a side effect of llvm::sys::fs::unique_file creating parent directories.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151960 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e1d4330adaaa7faf093e725c9c993207eb2d778a 25-Feb-2012 Argyrios Kyrtzidis <akyrtzi@gmail.com> Don't record nested macro expansions in the preprocessing record,
it can only bring pain when dealing with preprocessor abuse (see: boost).

rdar://10898986

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151427 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c93dc7889644293e318e19d82830ea2acc45b678 20-Feb-2012 Dylan Noblesmith <nobled@dreamwidth.org> Basic: import IntrusiveRefCntPtr<> into clang namespace

The class name is long enough without the llvm:: added.
Also bring in RefCountedBase and RefCountedBaseVPTR.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150958 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f7ccbad5d9949e7ddd1cbef43d482553b811e026 05-Feb-2012 Dylan Noblesmith <nobled@dreamwidth.org> Basic: import SmallString<> into clang namespace

(I was going to fix the TODO about DenseMap too, but
that would break self-host right now. See PR11922.)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149799 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6f42b62b6194f53bcbc349f5d17388e1936535d7 05-Feb-2012 Dylan Noblesmith <nobled@dreamwidth.org> Basic: import OwningPtr<> into clang namespace

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149798 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
773303a505c23d73da624f1e6abcf41a393dad2b 03-Feb-2012 Douglas Gregor <dgregor@apple.com> Rename -dependency-graphviz to -dependencncy-dot

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149645 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c69a181049ab52da29f8f69316a34c90c3ea3b8e 02-Feb-2012 Douglas Gregor <dgregor@apple.com> Introduce a -cc1 option "-dependency-graphviz" that determines header
dependencies and outputs them in GraphViz format.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149575 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
dc58aa71026cce539ca9b5c2c52cc4efc7bd77fe 30-Jan-2012 Douglas Gregor <dgregor@apple.com> Thread a TargetInfo through to the module map; we'll need it for
target-specific module requirements.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149224 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
52f127297c9dca0f8fbb3a28144de4db1d1db9e2 29-Jan-2012 Douglas Gregor <dgregor@apple.com> Switch over to LLVM's file-level locking facility

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149204 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
85ae12db3bbc60b920c086f1cb23cc94ad4802ae 29-Jan-2012 Douglas Gregor <dgregor@apple.com> Ensure that we clean up after a failed module build and cope with the
results in libclang.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149200 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c5b2e58840748145d1706c1d1481369d1863fabf 29-Jan-2012 Douglas Gregor <dgregor@apple.com> Implement code completion support for module import declarations, e.g.,

@import <complete with module names here>

or

@import std.<complete with submodule names here>

Addresses <rdar://problem/10710117>.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149199 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e434ec71fccfe078906403affd641f709702d598 29-Jan-2012 Douglas Gregor <dgregor@apple.com> Rework HeaderSearch's interface for getting a module from a name and
for getting the name of the module file, unifying the code for
searching for a module with a given name (into lookupModule()) and
separating out the mapping to a module file (into
getModuleFileName()). No functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149197 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a1f1fad8b60e1cb9d21a40a37f2e03150bcbeb6f 27-Jan-2012 Douglas Gregor <dgregor@apple.com> Introduce module attributes into the module map grammar, along with a
single attribute ("system") that allows us to mark a module as being a
"system" module. Each of the headers that makes up a system module is
considered to be a system header, so that we (for example) suppress
warnings there.

If a module is being inferred for a framework, and that framework
directory is within a system frameworks directory, infer it as a
system framework.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149143 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1f6b2b5c82b2d2d3935b0db76352a04e9877b73f 20-Jan-2012 Douglas Gregor <dgregor@apple.com> Extract the (InputKind, std::string) pair used to describe inputs to
the front end into its own class, FrontendInputFile, to make it easier
to introduce new per-input data. No functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148546 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b7a7819473709c01ea024a2dc15e99d38f0f8760 05-Jan-2012 Douglas Gregor <dgregor@apple.com> Store the submodules of a module in source order, as they are stored
in the module map. This provides a bit more predictability for the
user, as well as eliminating the need to sort the submodules when
serializing them.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147564 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
51f564f80d9f71e175635b452ffeeeff899e9bf1 31-Dec-2011 Douglas Gregor <dgregor@apple.com> Implement support for module requirements, which indicate the language
features needed for a particular module to be available. This allows
mixed-language modules, where certain headers only work under some
language variants (e.g., in C++, std.tuple might only be available in
C++11 mode).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147387 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
305dc3ebaa0bea5f3b789e4b54afc79c25907615 20-Dec-2011 Douglas Gregor <dgregor@apple.com> Detect when mapping a #include/#import over to a submodule ends up
hitting a submodule that was never actually created, e.g., because
that header wasn't parsed. In such cases, complain (because the
module's umbrella headers don't cover everything) and fall back to
including the header.

Later, we'll add a warning at module-build time to catch all such
cases. However, this fallback is important to eliminate assertions in
the ASTWriter when this happens.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146933 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2a76410c0a23a6feb98d0f13e9c8bfa0638d3adf 17-Dec-2011 Ted Kremenek <kremenek@apple.com> Refactor SerializeDiagnosticsPrinter to using DiagnosticRenderer. This gives us comparative diagnostics
to TextDiagnosticPrinter.

This certainly can be cleaned up a bit.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146820 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
53ba95612c023ecbcf142b9aaa90e4082fc1b480 15-Dec-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> Revert r146646 that was a mistake, and make the intended change in the right file.

Log:
[libclang] Try to unbreak mingw build.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146647 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f5a684d7742df5b57e70bb4dac327f2ef0333f71 15-Dec-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> [libclang] Try to unbreak mingw build.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146646 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
5e3f9223db88227d6d21679c613b139d8160186d 08-Dec-2011 Douglas Gregor <dgregor@apple.com> Keep track of import dependencies between submodules within the module
that's currently being built. This is important for supporting
transitive dependencies ("export *" in the module map) completely.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146156 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
29f2787b6da552018a7716f18f5bd8f67bd6edb5 07-Dec-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> Make changes to SDiagsWriter to make it work in combination with the ARC migrator:

-Allow it to be used with multiple BeginSourceFile/EndSourceFile calls; for this introduce
a "finish" callback method in the DiagnosticConsumer. SDiagsWriter finishes up the serialization
file inside this method.
-Make it independent of any particular DiagnosticsEngine; make it use the SourceManager of the
Diagnostic object.
-Ignore null source ranges.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146020 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f64114b2aa611a66fc97e6bd8f35b0b039a4500a 07-Dec-2011 Douglas Gregor <dgregor@apple.com> If we can't write the temporary module map file when compiling a
module, at least have the decency to complain about it.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146002 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e912029b914f263ec22cba6f1fb41ebebcdd844f 07-Dec-2011 Douglas Gregor <dgregor@apple.com> Add a FIXME to provide a sensible error message here

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145983 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1e821e9eba7c48f375c7cb5c9e19c489e17ec58a 06-Dec-2011 Douglas Gregor <dgregor@apple.com> Use absolute paths for temporary module map files

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145973 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
93ebfa6139bbca4d446c7343e3afc8e5ec777484 03-Dec-2011 Douglas Gregor <dgregor@apple.com> When we treat an #include or #import as a module import, create an
implicit ImportDecl in the translation unit to record the presence of
the import.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145727 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
5e35693721364673f8196e4f5a370f56b92e6053 01-Dec-2011 Douglas Gregor <dgregor@apple.com> Introduce the notion of name visibility into modules. For a given
(sub)module, all of the names may be hidden, just the macro names may
be exposed (for example, after the preprocessor has seen the import of
the module but the parser has not), or all of the names may be
exposed. Importing a module makes its names, and the names in any of
its non-explicit submodules, visible to name lookup (transitively).

This commit only introduces the notion of name visible and marks
modules and submodules as visible when they are imported. The actual
name-hiding logic in the AST reader will follow (along with test cases).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145586 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1a4761edca58c6b559de825b9abfb66f7f1ba94a 01-Dec-2011 Douglas Gregor <dgregor@apple.com> Promote ModuleMap::Module to a namespace-scope class in the Basic
library, since modules cut across all of the libraries. Rename
serialization::Module to serialization::ModuleFile to side-step the
annoying naming conflict. Prune a bunch of ModuleMap.h includes that
are no longer needed (most files only needed the Module type).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145538 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e25633f777cfcaa564b4ed36cec37d6e6e1ecb04 30-Nov-2011 Matt Beaumont-Gay <matthewbg@google.com> Don't collide loop variable names (to appease GCC)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145515 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
392ed2b717d86ebdd202cb9bb58d18d8b3b4cd87 30-Nov-2011 Douglas Gregor <dgregor@apple.com> Implement (de-)serialization of the description of a module and its
submodules. This information will eventually be used for name hiding
when dealing with submodules. For now, we only use it to ensure that
the module "key" returned when loading a module will always be a
module (rather than occasionally being a FileEntry).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145497 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b514c792821a8f053027d88444e13bfaa8efef76 30-Nov-2011 Douglas Gregor <dgregor@apple.com> Teach the preprocessor how to handle module import declarations that
involve submodules (e.g., importing std.vector), rather than always
importing the top-level module.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145478 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
49009ec701feb3009450e57e40c656e2ad7c1f41 30-Nov-2011 Douglas Gregor <dgregor@apple.com> When loading a module that involves submodules (e.g., std.vector),
check whether the named submodules themselves are actually
valid, and drill down to the named submodule (although we don't do
anything with it yet). Perform typo correction on the submodule names
when possible.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145477 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
3d3589db579f7695667b913c5043dd264ebe546f 30-Nov-2011 Douglas Gregor <dgregor@apple.com> Switch the module-loading interfaces and parser from a simple
top-level module name to a module path (e.g., std.vector). We're still
missing a number of pieces for this actually to do something.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145462 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
18ee547b6926cacefa15eed8ca60ff73d22e279b 29-Nov-2011 Douglas Gregor <dgregor@apple.com> Switch on-demand module building over to use module maps, always. When
we infer the module map, we'll just print the module map to a
temporary file and generate the module using that.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145436 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f9e357d8a66c606a86a6e1aef678898b8843bd30 29-Nov-2011 Douglas Gregor <dgregor@apple.com> Teach the module import mechanism how to rebuild modules expressed via
module map, rather than assuming that there is an umbrella
header. This allows us to automatically build umbrella-less modules.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145415 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
933e7a61da12400d8971890719cb03d68c1b02eb 29-Nov-2011 Douglas Gregor <dgregor@apple.com> Start refactoring to use module maps when rebuilding a module
on-the-fly. No functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145414 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a4d36a6dd00c1495cfe3b64f949d70ba9f778391 29-Nov-2011 Douglas Gregor <dgregor@apple.com> When attempting to load a module that is not in the module cache,
return the module itself (in the module map) rather than returning the
umbrella header used to build the module. While doing this, make sure
that we're inferring modules for frameworks to build that module.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145310 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d3b74d9ca4f239a7a90ad193378c494306c57352 18-Nov-2011 Ted Kremenek <kremenek@apple.com> Make 'LangOptions' in CompilerInvocation a heap-allocated, reference counted object. I discovered that llvm::RefCountedBase<T> has
a bug where the reference count is copied in the copy constructor, which means that there were cases when the CompilerInvocation
objects created by ASTUnit were actually leaked. When I fixed that bug locally, it showed that a whole bunch of code assumed
that the LangOptions object that was part of CompilerInvocation was still alive. By making it heap-allocated and reference counted,
we can keep it around after the CompilerInvocation object goes away.

As part of this change, change CompilerInvocation:getLangOptions() to return a pointer, acting as another clue that this
object may outlive the CompilerInvocation object.

This commit doesn't fix the CompilerInvocation leak itself. That will come when I commit the fix to llvm::RefCountedBase<T> to
mainline LLVM.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@144930 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d2536a604f59a3cca491f175bf1e49eeca49163b 15-Nov-2011 Douglas Gregor <dgregor@apple.com> Revert r144703. It was a dumb idea anyway; will add the new bits more
incrementally with a new frontend action.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@144723 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b8691df825c99b0fc989fcd92a008d2500ff2e37 15-Nov-2011 Douglas Gregor <dgregor@apple.com> Split GenerateModuleAction into its own action, which will start
differing from GeneratePCHAction fairly soon.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@144703 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b86b8dc7ef89405205f94635c1073cdb1a7093eb 15-Nov-2011 Douglas Gregor <dgregor@apple.com> Add a -cc1-level option -fmodule-name=<name>, which will be used when
building modules.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@144680 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
8e23806863721495f9e1f84aed614f7afba774a3 11-Nov-2011 Douglas Gregor <dgregor@apple.com> I predict that HeaderSearch will need the ability to generate
diagnostics in the future. Make it so.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@144347 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
5d8b9548420e67f1bf45b7bbc1cf9fb86e9e4505 01-Nov-2011 Sebastian Pop <spop@codeaurora.org> rename getHostTriple into getDefaultTargetTriple in clang



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143503 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
7800212ef29be314d55814e8dcc568ff8beed106 29-Oct-2011 Ted Kremenek <kremenek@apple.com> Start work on SerializedDiagnosticPrinter, a new DiagnosticConsumer that serializes out the diagnostics for a given translation unit to a bit code file. This is a WIP.

The motivation for this new DiagnosticConsumer is to provide a way for tools invoking the compiler
to get its diagnostics via a libclang interface, rather than textually parsing the compiler output.
This gives us flexibility to change the compiler's textual output, but have a structured data format
for clients to use to get the diagnostics via a stable API.

I have no tests for this, but llvm-bcanalyzer so far shows that the emitted file is well-formed.

More work to follow.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143259 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
0caed281f7f47713ae8be61ed75bac03596e1add 08-Oct-2011 NAKAMURA Takumi <geek4civic@gmail.com> lib/Frontend/CompilerInstance.cpp: Suppress a "Comparision of unsigned and signed" warning on Cygwin gcc-4.3.4.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141488 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a789ca9b967abe47b84df83bcf4afb150856a8d9 08-Oct-2011 NAKAMURA Takumi <geek4civic@gmail.com> Whitespace

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141486 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2572849d5ee3e5729a89ca934e1b04199eec5a5b 05-Oct-2011 Douglas Gregor <dgregor@apple.com> Seriously ugly hack, part 2

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141181 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1872e7916ce14a0a0b697eed534e27cb4d2b9ec2 05-Oct-2011 Douglas Gregor <dgregor@apple.com> Seriously ugly hack to try to get the Windows builders back online

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141180 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2bc750700487163e31e4f67cd0e0886868209e3c 05-Oct-2011 Douglas Gregor <dgregor@apple.com> Introduce a simple file-based locking protocol for on-demand module
creation, so that only a single Clang instance will rebuild a given
module at once (and the others will wait).

We still don't clean up the lock files when we crash, which is a
rather unfortunate problem. I'll handle that next, and there is
certainly a *lot* of room for further improvements.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141179 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
0ced799878d1beb8f0fa1cc31fa6d2e4229c217c 04-Oct-2011 Douglas Gregor <dgregor@apple.com> When build a module on demand, run the module-building job on a
separate thread with the "suitably large" stack, so we don't blow the
stack when building modules recursively.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141051 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
08d6acf6e5efa6df57345922d412476127f856fc 29-Sep-2011 Douglas Gregor <dgregor@apple.com> Introduce an opt-in warning when a module is being implicitly built
from sources.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140746 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
aee526e77657afd1600276450e9c346953ad51d7 29-Sep-2011 Douglas Gregor <dgregor@apple.com> Introduce a pure virtual clone() method to DiagnosticConsumer, so that
we have the ability to create a new, distict diagnostic consumer when
we go off and build a module. This avoids the currently horribleness
where the same diagnostic consumer sees diagnostics for multiple
translation units (and multiple SourceManagers!) causing all sorts of havok.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140743 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
621bc69624599da62abd9bc9e5edd8a63ac99fe6 26-Sep-2011 David Blaikie <dblaikie@gmail.com> Rename VerifyDiagnosticsClient to VerifyDiagnosticConsumer as per issue 5397


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140489 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
4e85b8ae413fa00fa42aa3e625c2db3b1932f8d3 26-Sep-2011 David Blaikie <dblaikie@gmail.com> Rename ChainedDiagnosticClient to ChainedDiagnosticConsumer as per issue 5397


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140485 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
78ad0b98848c17a0a11847fa1d456e2dfec8aa2f 26-Sep-2011 David Blaikie <dblaikie@gmail.com> Rename DiagnosticClient to DiagnosticConsumer as per issue 5397


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140479 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d6471f7c1921c7802804ce3ff6fe9768310f72b9 26-Sep-2011 David Blaikie <dblaikie@gmail.com> Rename Diagnostic to DiagnosticsEngine as per issue 5397


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140478 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
507097ec40105ed927cb5a744fad98f5875aacac 19-Sep-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> [libclang] When getting a source location from a file:line:col triplet
check whether the requested location points inside the precompiled preamble,
in which case the returned source location will be a "loaded" one.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140060 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
fba18aa8f2cd1994dc65e8cb9f4be201c560dc0b 16-Sep-2011 Douglas Gregor <dgregor@apple.com> Add an experimental flag -fauto-module-import that automatically turns
#include or #import direcctives of framework headers into module
imports of the corresponding framework module.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139860 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b2d39c217b2cfe87cbe69f25df83869940d8adcd 15-Sep-2011 Douglas Gregor <dgregor@apple.com> Comment what's going on when we compile a module

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139837 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
4ebd45f4279d84416568ada6adf56044bdf391b7 15-Sep-2011 Douglas Gregor <dgregor@apple.com> Detect cyclic module dependencies in a manner that is rather more
graceful than running out of stack space.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139833 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1a995ddaa53a20dcd063ea47eb1f533ecb0d243a 15-Sep-2011 Douglas Gregor <dgregor@apple.com> When we load the first module, make sure that we wire up the ASTConsumer to the newly-created ASTReader. This makes sure that CodeGen sees the declarations it is interested in

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139824 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
de8a9050d79d66325a18168a0994fed125a7790d 15-Sep-2011 Douglas Gregor <dgregor@apple.com> Make -E work with module imports

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139750 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
76d991ec6c5cd247ee18fe65c35d43c2d47cf094 14-Sep-2011 Douglas Gregor <dgregor@apple.com> Assert that the module hash produced after stripping away non-modular options is the same as the module hash before stripping those options.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139663 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6e975c4517958bcc11c834336d340797356058db 14-Sep-2011 Douglas Gregor <dgregor@apple.com> For modules, use a hash of the compiler version, language options, and
target triple to separate modules built under different
conditions. The hash is used to create a subdirectory in the module
cache path where other invocations of the compiler (with the same
version, language options, etc.) can find the precompiled modules.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139662 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1c7e0472f5683a8ade62285f366637050cf113e5 13-Sep-2011 Douglas Gregor <dgregor@apple.com> When building a module on-demand, clear out the "non-modular" language
and preprocessor options (such as macro definitions) first.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139638 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
78243658c533168d51fd076fba328437932ba6f1 13-Sep-2011 Douglas Gregor <dgregor@apple.com> When compiling a module on-demand, re-use the diagnostics client
already provided. This required a little bit of clean-up in the way
that VerifyDiagnosticsClient managed ownership of its underlying
"primary" client, because now it will no longer always take ownership.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139570 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
21cae2059a06f7d89eee169409c9266def1b1aca 13-Sep-2011 Douglas Gregor <dgregor@apple.com> When an import statement fails to find a module in the module cache,
but there is a corresponding umbrella header in a framework, build the
module on-the-fly so it can be immediately loaded at the import
statement. This is very much proof-of-concept code, with details to be
fleshed out over time.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139558 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
9a6da6930644b4f2dbe4885b0eb4fc1274ff56a4 12-Sep-2011 Douglas Gregor <dgregor@apple.com> Introduce a cc1-level option to provide the path to the module cache,
where the compiler will look for module files. Eliminates the
egregious hack where we looked into the header search paths for
modules.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139538 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f8a1e51c48761ee1d7803c3fa35ac94f42ebb55e 02-Sep-2011 Douglas Gregor <dgregor@apple.com> Always construct an ASTReader with a non-NULL ASTContext and
Preprocessor, eliminating the constructor that was used by ASTUnit
(which didn't provide an ASTContext or Prepreprocessor). Ensuring that
both objects are non-NULL will simplify module loading (but none of
that is done yet).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138986 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
bcfd1f55bfbb3e5944cd5e03d07b343e280838c4 02-Sep-2011 Douglas Gregor <dgregor@apple.com> Extend the ASTContext constructor to delay the initialization of
builtin types (When requested). This is another step toward making
ASTUnit build the ASTContext as needed when loading an AST file,
rather than doing so after the fact. No actual functionality change (yet).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138985 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
998b3d3e8528ebd9d2c5d78d3a82edd90a8953a4 02-Sep-2011 Douglas Gregor <dgregor@apple.com> Allow the preprocessor to be constructed without performing target-
and language-specific initialization. Use this to allow ASTUnit to
create a preprocessor object *before* loading the AST file. No actual
functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138983 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e082af17d4b425a49f7f8bccc2a99810f0072828 31-Aug-2011 Douglas Gregor <dgregor@apple.com> Switch the "no module found" default-fatal warning to a default-fatal error.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138909 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6aa52ec6b969faabf3764baf79d89810b8249a7e 27-Aug-2011 Douglas Gregor <dgregor@apple.com> Introduce support for a simple module import declaration, which
loads the named module. The syntax itself is intentionally hideous and
will be replaced at some later point with something more
palatable. For now, we're focusing on the semantics:
- Module imports are handled first by the preprocessor (to get macro
definitions) and then the same tokens are also handled by the parser
(to get declarations). If both happen (as in normal compilation),
the second one is redundant, because we currently have no way to
hide macros or declarations when loading a module. Chris gets credit
for this mad-but-workable scheme.
- The Preprocessor now holds on to a reference to a module loader,
which is responsible for loading named modules. CompilerInstance is
the only important module loader: it now knows how to create and
wire up an AST reader on demand to actually perform the module load.
- We search for modules in the include path, using the module name
with the suffix ".pcm" (precompiled module) for the file name. This
is a temporary hack; we hope to improve the situation in the
future.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138679 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
467dc88512b4ba4bb16e274ea3771dc1415d31da 26-Aug-2011 Douglas Gregor <dgregor@apple.com> Introduce a -cc1 option "-emit-module", that creates a binary module
from the given source. -emit-module behaves similarly to -emit-pch,
except that Sema is somewhat more strict about the contents of
-emit-module. In the future, there are likely to be more interesting
differences.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138595 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
7e90985df09855dc309ed888a5b16a0ae684f8e3 28-Jul-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> Cut down the number of open/close system calls for output files.

For PCH files, have only one open/close for temporary + rename to be safe from race conditions.
For all other output files open/close the output file directly.

Depends on llvm r136310. rdar://9082880 & http://llvm.org/PR9374.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136315 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
5f9e272e632e951b1efe824cd16acb4d96077930 23-Jul-2011 Chris Lattner <sabre@nondot.org> remove unneeded llvm:: namespace qualifiers on some core types now that LLVM.h imports
them into the clang namespace.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135852 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
832d620b4ae0fc5fe28561b885b4cfc65cf5c9ab 22-Jul-2011 Douglas Gregor <dgregor@apple.com> Switch all of the "isysroot" const char*'s throughout the AST reader
and writer to StringRef or std::string, as appropriate.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135769 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
72a9ae18553bf8b6bdad84d2c54f73741a47e275 22-Jul-2011 Douglas Gregor <dgregor@apple.com> Rename ASTReader::PerFileData to serialization::Module, pulling it out
of ASTReader so it can become its own full-fledged class
(eventually). No functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135767 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
bc9d5a3ace7cb75e4bff3dd4a3999a3fc04f4d45 21-Jul-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> Cut down one open/close pair of system calls by using Path's makeUnique instead of createTemporaryFileOnDisk.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135690 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f62d43d2afe1960755a1b5813cae1e5983bcac1b 19-Jul-2011 Douglas Gregor <dgregor@apple.com> Revamp the SourceManager to separate the representation of parsed
source locations from source locations loaded from an AST/PCH file.

Previously, loading an AST/PCH file involved carefully pre-allocating
space at the beginning of the source manager for the source locations
and FileIDs that correspond to the prefix, and then appending the
source locations/FileIDs used for parsing the remaining translation
unit. This design forced us into loading PCH files early, as a prefix,
whic has become a rather significant limitation.

This patch splits the SourceManager space into two parts: for source
location "addresses", the lower values (growing upward) are used to
describe parsed code, while upper values (growing downward) are used
for source locations loaded from AST/PCH files. Similarly, positive
FileIDs are used to describe parsed code while negative FileIDs are
used to file/macro locations loaded from AST/PCH files. As a result,
we can load PCH/AST files even during parsing, making various
improvemnts in the future possible, e.g., teaching #include <foo.h> to
look for and load <foo.h.gch> if it happens to be already available.

This patch was originally written by Sebastian Redl, then brought
forward to the modern age by Jonathan Turner, and finally
polished/finished by me to be committed.




git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135484 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
ba7537febdf1bc1cc617e1f1746f2644feba6274 14-Jul-2011 Chandler Carruth <chandlerc@gmail.com> NestedMacroInstantiations -> NestedMacroExpansions

This is switches all the interfaces points (and most of the commenst
/ local variables I saw on my way through) regarding the
NestedMacroInstantiations bit.

The libclang enums corresponding to this state were renamed, but
a legacy enum was added with the old name, and the same value to keep
existing clients working. I've added a documentation blurb for it, but
let me know if there is a canonical way to document legacy elemenst of
the libclang interface.

No functionality changed here, even in tests.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135141 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1626601b00a1feccd6b7a3f54e2991f56b659192 23-Jun-2011 Dylan Noblesmith <nobled@dreamwidth.org> avoid using config.h in public headers

This is the only usage in clang's headers, and it's for a define
that only exists on CMake builds for the sake of the MSVC compiler,
so just use an ifdef instead.

Also add an include for config.h in a file that actually needs it,
and was picking it up by accident indirectly.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133710 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f7f8188fac71e34e09ee457ff6f039f5d14ad117 16-Jun-2011 Chandler Carruth <chandlerc@gmail.com> Raise the ARCMT functionality in Clang into proper FrontendActions.
These are somewhat special in that they wrap any other FrontendAction,
running various ARC transformations or checks prior to the standard
action's run. To implement them easily, this extends FrontendAction to
have a WrapperFrontendAction utility class which forwards all calls by
default to an inner action setup at construction time. This is then
subclassed to override the specific behavior needed by the different
ARCMT tools.

Finally, FrontendTool is taught how to create these wrapper actions from
the existing flags and options structures.

The result is that clangFrontend no longer depends on clangARCMigrate.
This is very important, as clangARCMigrate *heavily* depends on
clangFrontend. Fundamentally ARCMigrate is at the same layer as
a library like Rewrite, sitting firmly on top of the Frontend, but tied
together with the FrontendTool when building the clang binary itself.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133161 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
8f0e8d22960d56f8390f4971e2c0f2f0a0884602 16-Jun-2011 John McCall <rjmccall@apple.com> The ARC Migration Tool. All the credit goes to Argyrios and Fariborz
for this.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133104 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
dca8ee8b7bc86076916a3a80f553f7a4e98c14af 06-May-2011 Douglas Gregor <dgregor@apple.com> Introduce a new libclang parsing flag,
CXTranslationUnit_NestedMacroInstantiations, which indicates whether
we want to see "nested" macro instantiations (e.g., those that occur
inside other macro instantiations) within the detailed preprocessing
record. Many clients (e.g., those that only care about visible tokens)
don't care about this information, and in code that uses preprocessor
metaprogramming, this information can have a very high cost.

Addresses <rdar://problem/9389320>.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130990 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e01eceb54c9235a41675bfd9f32c50bd005fb8d0 07-Apr-2011 Daniel Dunbar <daniel@zuster.org> Frontend/CC_LOG_DIAGNOSTICS: Fix thinko and open diag log in append mode.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129103 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b6534bbee90bf73f364072051d10b60352d43c3e 07-Apr-2011 Daniel Dunbar <daniel@zuster.org> Fronted/CC_LOG_DIAGNOSTICS: Wire up dwarf-debug-flags support.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129095 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
9df23493f5b8a223dfbc491e4b7de3850797c2e7 07-Apr-2011 Daniel Dunbar <daniel@zuster.org> Frontend: Sketch a LogDiagnosticPrinter object, and wire CC_LOG_DIAGNOSTICS to
it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129089 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
da60885cb4ee85d167cf704061f10b758067cf5a 21-Mar-2011 Daniel Dunbar <daniel@zuster.org> Frontend: Change CC_PRINT_HEADERS to not print header depth markers, these don't
really make any sense in this environment.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128014 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
4f32786ac45210143654390177105eb749b614e9 21-Mar-2011 Ted Kremenek <kremenek@apple.com> Improve crash recovery cleanup to recovery CompilerInstances during crash 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.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128011 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2e2468e2d2ccbb9a38fe3b6b754009af7e5d39a9 14-Mar-2011 Anders Carlsson <andersca@mac.com> Get rid of the static FileManager::FixupRelativePath.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127573 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
af036a6c25f540a9daf51e721485ae6d0e645bd8 06-Mar-2011 Anders Carlsson <andersca@mac.com> Convert FileManager::FixupRelativePath over to using PathV2.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127133 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
4b93d660c6326ec79b5e369317d1051cf826c2f3 20-Feb-2011 Peter Collingbourne <peter@pcc.me.uk> Re-instate r125819 and r125820 with no functionality change

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126060 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
96b1d4b4eb6b18dd6df7a2c0833332b45840580f 19-Feb-2011 Rafael Espindola <rafael.espindola@gmail.com> Revert 125820 and 125819 to fix PR9266.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126050 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
906c73ffbc78542ad333becb6e013dd9efc299b6 18-Feb-2011 Peter Collingbourne <peter@pcc.me.uk> Move CompilerInstance::LLVMContext and LLVMContext ownership to CodeGenAction

This removes the final dependency edge from any lib outside of CodeGen
to core. As a result we can, and do, trim the dependency on core
from libclang, PrintFunctionNames, the unit tests and c-index-test.
While at it, review and trim other unneeded dependencies.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125820 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
8ef6c8cb6c5627240e2339fd7062c9873f821d7e 05-Feb-2011 Douglas Gregor <dgregor@apple.com> Improve our uniquing of file entries when files are re-saved or are
overridden via remapping. Thus, when we create a "virtual" file in the
file manager, we still stat() the real file that lives behind it so
that we can provide proper uniquing based on inodes. This helps keep
the file manager much more consistent.

To take advantage of this when reparsing files in libclang, we disable
the use of the stat() cache when reparsing or performing code
completion, since the stat() cache is very likely to be out of date in
this use case.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124971 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
b34d69b9292534c1c574f168f0ac10aea652adca 02-Feb-2011 Daniel Dunbar <daniel@zuster.org> Frontend: Add -header-include-file option, for allowing saving header include
information to a file.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124750 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
eef63e0997e0f6d6436736ea919b851cfe34955a 02-Feb-2011 Daniel Dunbar <daniel@zuster.org> Frontend: Factor out header include dumping (-H) into its own preprocessor
callbacks class.
- Aside from being generally cleaner, this also allows -H to work correctly in
modes other than standard preprocessing (e.g., -c, -MM, etc.)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124723 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
ff9cd968cd5b623e3ec7e5f862b598cd22f7ec79 31-Jan-2011 Daniel Dunbar <daniel@zuster.org> Frontend: Add an explicit RemoveFileOnSignal flag argument, to control the
automatic behavior (which is undesirable in a multithreaded context).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124612 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
32bef4edba854303800b3b01cb49a282e5da4f69 10-Jan-2011 Michael J. Spencer <bigcheesegs@gmail.com> Replace all uses of PathV1::exists with PathV2::fs::exists.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123150 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
4eeebc464e1f968d9968a4786c82558f18ac2ed8 16-Dec-2010 Michael J. Spencer <bigcheesegs@gmail.com> MemoryBuffer API update.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@121956 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
3a321e23f66128dbb986343927456ff6702af617 09-Dec-2010 Michael J. Spencer <bigcheesegs@gmail.com> Use error_code instead of std::string* for MemoryBuffer.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@121378 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
414cb64f09ce48a36377458ce5e5a90c3ad41d00 30-Nov-2010 Douglas Gregor <dgregor@apple.com> When loading a precompiled preamble, use the file ID of the
precompiled preamble as the "main" source file's file ID within the
source manager. This makes compiling with a precompiled preamble
produce the same source locations as when compiling without the
precompiled preamble; prior to this change, we ended up with different
file IDs for source locations within the precompiled preamble
vs. those after the precompiled preamble, even for entities (e.g.,
preprocessing entities) in the same file.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120390 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
03013fa9a0bf1ef4b907f5fec006c8f4000fdd21 29-Nov-2010 Michael J. Spencer <bigcheesegs@gmail.com> Merge System into Support.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120297 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
681c74afe6a81161aa13291c6c114e5240b23865 23-Nov-2010 Chris Lattner <sabre@nondot.org> don't allow remapping PTH file paths with -fworking-directory, the
client should just pass in absolute paths.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120012 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
39b49bcaaddb1049234fca9500c0ac02c088e23d 23-Nov-2010 Chris Lattner <sabre@nondot.org> now the FileManager has a FileSystemOpts ivar, stop threading
FileSystemOpts through a ton of apis, simplifying a lot of code.
This also fixes a latent bug in ASTUnit where it would invoke
methods on FileManager without creating one in some code paths
in cindextext.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120010 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
7ad97ffa631af6ad678c79b38341ac995f347ce9 23-Nov-2010 Chris Lattner <sabre@nondot.org> give FileManager a 'FileSystemOptions' ivar, which will be used
to simplify a bunch of code in it. It should ultimately get inlined
into FileManager.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120007 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
ab41b97c3cddf1bcdd8bf82ab09ed3ceafcd05b1 18-Nov-2010 Argyrios Kyrtzidis <akyrtzi@gmail.com> Remove the hack where, to get the return status, we had special case for VerifyDiagnosticsClient
and just check the number of errors from the DiagnosticClient.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@119736 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f2224d89a6ae65a3839529e26d0f6d025d83d6bb 18-Nov-2010 Argyrios Kyrtzidis <akyrtzi@gmail.com> Since multiple diagnostics can share one diagnostic client, have the client keeping track
of the total number of warnings/errors reported.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@119731 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
33e4e70c8c0a17e0ccb7465d96556b077a68ecb1 18-Nov-2010 Argyrios Kyrtzidis <akyrtzi@gmail.com> Refactoring of Diagnostic class.

-Move the stuff of Diagnostic related to creating/querying diagnostic IDs into a new DiagnosticIDs class.
-DiagnosticIDs can be shared among multiple Diagnostics for multiple translation units.
-The rest of the state in Diagnostic object is considered related and tied to one translation unit.
-Have Diagnostic point to the SourceManager that is related with. Diagnostic can now accept just a
SourceLocation instead of a FullSourceLoc.
-Reflect the changes to various interfaces.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@119730 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e47be3e9682e82da15059006f43c7f3c021e4fff 11-Nov-2010 Douglas Gregor <dgregor@apple.com> Improve ASTUnit's capture of diagnostics so that the
diagnostic-capturing client lives as long as the ASTUnit itself
does. Otherwise, we can end up with crashes when we get a diagnostic
outside of parsing/code completion. The circumstances under which this
happen are really hard to reproduce, because a file needs to change
from under us.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118751 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
389db16c63eec6ecfa9b235155252d8da766e94e 03-Nov-2010 Argyrios Kyrtzidis <akyrtzi@gmail.com> Implement -working-directory.

When -working-directory is passed in command line, file paths are resolved relative to the specified directory.
This helps both when using libclang (where we can't require the user to actually change the working directory)
and to help reproduce test cases when the reproduction work comes along.

--FileSystemOptions is introduced which controls how file system operations are performed (currently it just contains
the working directory value if set).
--FileSystemOptions are passed around to various interfaces that perform file operations.
--Opening & reading the content of files should be done only through FileManager. This is useful in general since
file operations will be abstracted in the future for the reproduction mechanism.

FileSystemOptions is independent of FileManager so that we can have multiple translation units sharing the same
FileManager but with different FileSystemOptions.

Addresses rdar://8583824.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118203 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
90d9081cacb4b0163f2c7527f666d6515257067c 27-Oct-2010 Dan Gohman <gohman@apple.com> Add support for code completion on stdin.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117414 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
694137c54c79a33c9ac6c07e68327750dcd5adf7 26-Oct-2010 Dan Gohman <gohman@apple.com> Simplify this code: don't check for the same error two
different ways. Check once, and use an assert to handle
consistency checking.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117397 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a9f4f620daf073805b89e893afcdc5eb7a9bdc50 12-Oct-2010 Douglas Gregor <dgregor@apple.com> Eliminate the (de-)serialization of code completion results, now that
libclang does not support out-of-process code completion.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116253 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d3ab63e0f66429abf2a3e4cde889e420e41e8790 12-Oct-2010 Douglas Gregor <dgregor@apple.com> Eliminate -fdiagnostics-binary and all of the infrastructure for
emitting diagnostics in a binary form to be consumed by libclang,
since libclang no longer does any of its work out-of-process, making
this code dead. Besides, this stuff never worked at 100% anyway.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116250 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
7d0c4ccd65b4549283c55e4923602e234f3811c5 11-Oct-2010 Axel Naumann <Axel.Naumann@cern.ch> Tighten up constness of argv parameters to allow for string literals as argumants and to reflect actual (non-modifying) use.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116199 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1d9f1fe7173e3084325f43c78af812a36d8a2a7c 05-Oct-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Give every file that ASTReader loads a type: module, PCH, precompiled preamble or main file. Base Decls' PCHLevel on this to make it more sane.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@115626 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
dc24572a44575e07a5d8bb6de52641a69f1bab27 17-Sep-2010 Argyrios Kyrtzidis <akyrtzi@gmail.com> Use a temporary file for output which gets renamed after all the writing is finished.

This mainly prevents failures and/or crashes when multiple processes try to read/write the same PCH file. (rdar://8392711&8294781); suggestion & review by Daniel!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@114187 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f155dfa4e284be7dca8f1abf002476b2aaee8546 27-Aug-2010 Dan Gohman <gohman@apple.com> createMainFileID doesn't need its IncludePos argument, since
the main file isn't an included file, and the IncludePos is
always SourceLocation().


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112269 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6ab7cd853e9c15cf986a8a7c3db1f8d20e275409 19-Aug-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Rename the ASTReader header files.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111474 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
571db7f0cb31789737be92fce1c1b738e6dbe795 19-Aug-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Rename various classes from PCH to AST.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111471 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c43b54cbc10654ed59de797898042e1a05265246 19-Aug-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Rename PCHReader to ASTReader.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111467 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
bdbb004f38978da0c4a75af3294d1c7b5ff84af1 19-Aug-2010 Douglas Gregor <dgregor@apple.com> Simplify the ownership model for DiagnosticClients, which was really
convoluted and a bit leaky. Now, the Diagnostic object owns its
DiagnosticClient.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111437 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
857281328fa824782bdd979c3bfdd97ecdbc1609 17-Aug-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Reintroduce the serialization library, with fixed dependencies.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111279 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
4557e473c9e673e7e6f7063478f63a5b3c6c10b2 17-Aug-2010 Douglas Gregor <dgregor@apple.com> Revert Sebastian's build-breaking patch.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111265 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
93c972945bccd1a966b0445f9ed45db433b77bc1 17-Aug-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Create a new Serialization module that contains all the PCH code, and will contain all the module code in the future. Update the Makefiles, CMake projects and the Xcode project. I hope I did everything right for Xcode. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111258 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
8071e4212ae08f8014e0c3ae6d18b7388003a5cc 15-Aug-2010 Douglas Gregor <dgregor@apple.com> Extend the code-completion caching infrastructure to include global
declarations (in addition to macros). Each kind of declaration maps to
a certain set of completion contexts, and the ASTUnit completion logic
introduces the completion strings for those declarations if the actual
code-completion occurs in one of the contexts where it matters.

There are a few new code-completion-context kinds. Without these,
certain completions (e.g., after "using namespace") would need to
suppress all global completions, which would be unfortunate.

Note that we don't get the priorities right for global completions,
because we don't have enough type information. We'll need a way to
compare types in an ASTContext-agnostic way before this can be
implemented.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111093 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1e3a97c98a9ad099410fa5172ce8783baf0da0fd 13-Aug-2010 Douglas Gregor <dgregor@apple.com> The Sema object will get destroyed before all of the others anyway. We don't need to force it

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110993 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f18d0d8b39e891460d50f8a8b85029885b264986 13-Aug-2010 Douglas Gregor <dgregor@apple.com> Teach CompilerInstance to create and hold on to the Sema object used
for parsing, so that it can persist beyond the lifetime of the parsing
call.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110978 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1abc6bca3d7fb0e7b1e40fbcad6cfb5e10594548 04-Aug-2010 Douglas Gregor <dgregor@apple.com> Add code-completion support directly to ASTUnit, which performs code
completion within the translation unit using the same command-line
arguments for parsing the translation unit. Eventually, we'll reuse
the precompiled preamble to improve code-completion performance, and
this also gives us a place to cache results.

Expose this function via the new libclang function
clang_codeCompleteAt(), which performs the code completion within a
CXTranslationUnit. The completion occurs in-process
(clang_codeCompletion() runs code completion out-of-process).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110210 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
ffaab3e2bb13991bb3357e80f14bcae3745b2347 30-Jul-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Make macro weirdness in chained PCH work. This required changing the way PCHReader and PCHWriter are initialized to correctly pick up all initializer. On the upside, this means that there is far less repetition in the dependent PCH now.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109823 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
fae3b2f4743dad616623c4df2fdb0f5128bd36d9 27-Jul-2010 Douglas Gregor <dgregor@apple.com> Implement -fno-validate-pch at the -cc1 level, which suppresses most
of the usual consistency checks used to determine when a precompiled
header is incompatible with the translation unit it's being loaded
into.

Enable this option when loading a precompiled preamble, because the
preamble loader will be performing all of this checking itself. Enable
the preamble-based test now that it's working.

This option is also useful for debugging Clang's PCH
(<rdar://problem/7532213>).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109475 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
63fe86bee66fc145942c56b2cc564ea0b9b9ea12 25-Jul-2010 Douglas Gregor <dgregor@apple.com> Make ASTContext always use the BumpPtrAllocator.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109375 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
fae4f1546ab0fa645aeebb8da069a41538a53779 09-Jul-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Correctly initialize Reader to null.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107994 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a93e3b5bde9f0a7b59215f19f176f7d69881b81c 09-Jul-2010 Sebastian Redl <sebastian.redl@getdesigned.at> Some preparatory work for chained PCH. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107915 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2056048f0f619adadc9a5416a2c4cdf95c58eef7 08-Jun-2010 Daniel Dunbar <daniel@zuster.org> Frontend: Move some initialization from CompilerInstance to FrontendAction, to parallel what is done for AST inputs.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105579 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d3598a65716e120aef45aa2841d730e03f7101fe 08-Jun-2010 Daniel Dunbar <daniel@zuster.org> Frontend: Change FrontendAction::BeginSourceFile to take the input kind instead of an IsAST bool.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105578 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c34ce3fa613d5e4a283e53615fceafd17390445b 08-Jun-2010 Daniel Dunbar <daniel@zuster.org> Frontend: Lift InputKind enumeration to top level.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105577 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6f118975f9ca6318a933ee4bfad19fae628c9a8d 27-May-2010 Dan Gohman <gohman@apple.com> MemoryBuffer::getSTDIN may return a null pointer if an error occurs.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104856 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d8e8a58ee35ab334ab9d0c2154dca029c1822e8a 25-May-2010 Douglas Gregor <dgregor@apple.com> Only enable code patterns (e.g., try { statements } catch (...) {
statements }) in the code-completion results if explicitly requested.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104637 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
1864f2eb59471d07db51adfc3e5b1a229eed631a 15-Apr-2010 Douglas Gregor <dgregor@apple.com> Once we've emitted a fatal diagnostic, keep counting errors but with a
separate count of "suppressed" errors. This way, semantic analysis
bits that depend on the error count to determine whether problems
occured (e.g., some template argument deduction failures, jump-scope
checking) will not get confused.

The actual problem here is that a missing #include (which is a fatal
error) could cause the jump-scope checker to run on invalid code,
which it is not prepared to do. Trivial fix for both
<rdar://problem/7775941> and <rdar://problem/7775709>.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101297 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
53eee7ba970d21ff15bbd4334164037a3b4cc4b8 07-Apr-2010 Chris Lattner <sabre@nondot.org> Instead of counting totally diagnostics, split the count into a count
of errors and warnings. This allows us to emit something like this:

2 warnings and 1 error generated.

instead of:

3 diagnostics generated.

This also stops counting 'notes' because they are just follow-on information
about the previous diag, not a diagnostic in themselves.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100675 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
28019772db70d4547be05a042eb950bc910f134f 06-Apr-2010 Douglas Gregor <dgregor@apple.com> Make Diagnostic reference-counted, which is simpler than juggling
maybe-ownership vs. ownership.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100498 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
95dd5583e3900443a1d7970d557d8c54aa320601 30-Mar-2010 Douglas Gregor <dgregor@apple.com> Teach Clang's -cc1 option -print-stats to print LLVM statistics.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99894 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2758595023c5c7c0495f19260089f975022c50dc 19-Mar-2010 Daniel Dunbar <daniel@zuster.org> clang -cc1: Kill off -empty-input only, and replace with -init-only which is an
actual action.
- This is easier to use, and more reliable for timing the thing this was
actually meant to be useful for.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98978 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
94dc8f640ebea52241412512ed48601626edbc58 19-Mar-2010 Douglas Gregor <dgregor@apple.com> Optionally store a PreprocessingRecord in the preprocessor itself, and
tie its creation to a CC1 flag -detailed-preprocessing-record.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98963 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
69247139f5ce3edf46c48344129792b3a05d090a 17-Mar-2010 Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> Simplify error path using OwningPtr

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98722 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
5bf932bd0d5db98273938675dbf81cbb2f5ffff7 17-Mar-2010 Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> Simplify ProcessWarningOptions since it can't fail

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98721 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
3d67b1e25847319a5a271f9d5a8d607ef18d804a 17-Mar-2010 Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> Issue a proper diagnostic if we couldn't open dump file

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98719 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c3d43b783dfb1a1502aa8b31ab1985cf237b1f77 16-Mar-2010 Douglas Gregor <dgregor@apple.com> Don't consume tokens past the end-of-file in an @interface. Fixes
<rdar://problem/7735566>.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98613 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f715ca12bfc9fddfde75f98a197424434428b821 16-Mar-2010 Douglas Gregor <dgregor@apple.com> Give SourceManager a Diagnostic object with which to report errors,
and start simplifying the interfaces in SourceManager that can fail.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98594 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
e51dd7be67808d52c80c09b832d875e9655ce6e0 06-Mar-2010 Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> Lowercase for consistency

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97878 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a88084b78fd4ca5d3d858c14b02414f8cc399f02 18-Feb-2010 Douglas Gregor <dgregor@apple.com> Rework how CIndex handles diagnostics. Rather than using a callback,
we attach diagnostics to translation units and code-completion
results, so they can be queried at any time.

To facilitate this, the new StoredDiagnostic class stores a diagnostic
in a serializable/deserializable form, and ASTUnit knows how to
capture diagnostics in this stored form. CIndex's CXDiagnostic is a
thin wrapper around StoredDiagnostic, providing a C interface to
stored or de-serialized diagnostics.

I've XFAIL'd one test case temporarily, because currently we end up
storing diagnostics in an ASTUnit that's never returned to the user
(because it contains errors). I'll introduce a temporary fix for this
soon; the real fix will be to allow us to return and query invalid ASTs.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96592 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
42e9f8e4983d50f896ec716207817b9d96e7e79c 16-Feb-2010 Daniel Dunbar <daniel@zuster.org> CompilerInstance: Move LLVMContext member out of constructor.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96314 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
6228ca00121669ec06a19df4fad87d5049c097cf 30-Jan-2010 Daniel Dunbar <daniel@zuster.org> CompilerInstance: Change to not contain the CompilerInvocation object.

This allows clients to install their own CompilerInvocation object, which is
important for clients that may wish to create references to things like
LangOptions whose lifetime will extend past that of the CompilerInstance.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@94923 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
d93256e55673a17d18543397ec462416acb13792 28-Jan-2010 Douglas Gregor <dgregor@apple.com> Introduce serialization and deserialization of diagnostic information
so that CIndex can report diagnostics through the normal mechanisms
even when executing Clang in a separate process. This applies both
when performing code completion and when using ASTs as an intermediary
for clang_createTranslationUnitFromSourceFile().

The serialized format is not perfect at the moment, because it does
not encapsulate macro-instantiation information. Instead, it maps all
source locations back to the instantiation location. However, it does
maintain source-range and fix-it information. To get perfect fidelity
from the serialized format would require serializing a large chunk of
the source manager; at present, it isn't clear if this code will live
long enough for that to matter.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@94740 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
7d957472ef9a09048c03d8a11028536f908c18b9 13-Jan-2010 Fariborz Jahanian <fjahanian@apple.com> Predefine __weak attribute when doing objective-c
rewriting for any target. (refixes radar 7530235).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93331 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
0397af277e3bba16da1fd125ddba07415686b429 13-Jan-2010 Daniel Dunbar <daniel@zuster.org> cc1: Factor out CompilerInstance::ExecuteAction which has the majority of the
clang -cc1 logic for running an action against a set of options.
- This should make it easier to build tools that have a clang -cc1 like
interface, but aren't actually part of clang -cc1.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93282 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
dd63b28107f21692b5065588f0e90b4534946f93 12-Dec-2009 Daniel Dunbar <daniel@zuster.org> Update docs/comments/utils/examples to refer to clang -cc1 instead of clang-cc.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91176 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
360435908c9b90429cfe192fab22854af1d4497c 03-Dec-2009 Daniel Dunbar <daniel@zuster.org> Fix CompilerInstance::createOutputFile to use proper diagnostics, and (try to) update all clients to be able to handle failure.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90437 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
43adb7e9e9bc906210e265c637738b9a962fb6b6 03-Dec-2009 Daniel Dunbar <daniel@zuster.org> Remove an unnecessary (I believe) exit() on error.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90436 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2973c0eff437e57541735c9bb9561358715440e6 02-Dec-2009 Douglas Gregor <dgregor@apple.com> Move file-remapping logic into InitPreprocesor. No functionality change

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90322 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
716f0b3e2e36f362b64a2ce0a40a9ad915103255 02-Dec-2009 Douglas Gregor <dgregor@apple.com> Introduce a new clang-cc option

-remap-file=from;to

which takes the file "from" and transparently replaces its contents
with the contents of the file "to" from the source manager's
perspective. This is the moral equivalent of

cp from saved
cp to from
<call clang>
cp saved from
rm saved

without all of the pesky file copying.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90307 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2968442603b029949246467253eeac8139a5b6d8 02-Dec-2009 Douglas Gregor <dgregor@apple.com> Extend the source manager with the ability to override the contents of
files with the contents of an arbitrary memory buffer. Use this new
functionality to drastically clean up the way in which we handle file
truncation for code-completion: all of the truncation/completion logic
is now encapsulated in the preprocessor where it belongs
(<rdar://problem/7434737>).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90300 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2b4074f1d3919e77cb33ca49c960521dea27afab 01-Dec-2009 Douglas Gregor <dgregor@apple.com> Switch the clang-to-CIndex interface for code-completion to a binary format, for a massive speedup

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90209 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f79bafa608a5d7c49ec40ad199af5e32f3038b47 29-Nov-2009 Kovarththanan Rajaratnam <kovarththanan.rajaratnam@gmail.com> This patch moves the frontend timer from clang-cc into CompilerInstance.
CompilerInstance already contains various objects that are used
throughout the entire run.

Also addresses Daniels review comments in:

http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20091123/024508.html



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90073 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
fc97102a80bfe0afaa25883a2aa6b5e1d7307d0a 20-Nov-2009 Daniel Dunbar <daniel@zuster.org> Fix refactoro, clang-cc wasn't properly reporting errors when opening an output file failed.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89502 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
049d3a06ea9f8fc03582488a2b7f24512565a335 17-Nov-2009 Daniel Dunbar <daniel@zuster.org> Simplify PreprocessorOptions, it doesn't need abstracted field access.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89047 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
221c7211c507482a91e97ede1bf6cf65a456ff67 14-Nov-2009 Daniel Dunbar <daniel@zuster.org> Shuffle VerifyDiagnosticsClient API to be less fragile.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88765 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
ccb6cb6fd9e48697564d536b07397b95dfc28d5b 14-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add CompilerInstance::InitializeSourceManager.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88764 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f79dced038c63572965c016b969cfa870670d16e 14-Nov-2009 Daniel Dunbar <daniel@zuster.org> Switch -verify implementation to use VerifyDiagnosticClient.
- Not tested, but -verify with multiple inputs should work now.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88750 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
12ce6943aae499225708ecf364c5a8b0a3269c87 14-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add ASTConsumer to CompilerInstance.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88743 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
8a9f569262860b8d03203327afd6047be2a9b5a6 14-Nov-2009 Daniel Dunbar <daniel@zuster.org> Move CompilerInstance::set* methods out-of-line.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88731 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
f482d59386dbc70716f7a5f65adb37ff86b501e6 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add CompilerInstance utility functions for creating output files.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88667 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
a9204831639e31474b927681b97c46781b758a1a 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add output file list to CompilerInstance, so that it can track them instead of
forcing all clients to do it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87103 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
c2f484f1f05216a9a427ac84b5773789a4661111 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add CodeCompletion consumer to CompilerInvocation.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87100 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
0f800391ffbfe3820e1c60246a09a97e5f065179 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add CompilerInstance::createPCHExternalASTSource.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87097 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
5eb810024dc8a1d12d5f066c02c978f07c4fcb00 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add ASTContext to CompilerInstance.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87095 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
0fbb3d9a9cdd2201848be9eb017c54cd78538122 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add CompilerInstance::createDiagnostics, and move clang-cc to it.

clang-cc.cpp is now under 1k lines, if anyone is counting.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87090 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
22dacfacacf5559028550ba6ddfbaa4ea6cb3944 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add Preprocessor to CompilerInstance, and move clang-cc CreatePreprocessor to
CompilerInstance::createPreprocessor.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87088 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
16b7449d86b843d0926b04f87104cf3fff7149fe 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add {File,Source}Manager to CompilerInstance.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87079 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp
2a79e162a3fde25c1941151a67966830d873f2db 13-Nov-2009 Daniel Dunbar <daniel@zuster.org> Add CompilerInstance, and starting moving clang-cc to it.
- The design philosophy is in the CompilerInstance doxyment, if you don't agree
with it now would be a good time to speak up.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87078 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Frontend/CompilerInstance.cpp