- Aug 17, 2010
-
-
Sebastian Redl authored
llvm-svn: 111279
-
Douglas Gregor authored
llvm-svn: 111267
-
Douglas Gregor authored
llvm-svn: 111265
-
Dan Gohman authored
llvm-svn: 111261
-
Sebastian Redl authored
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. llvm-svn: 111258
-
- Aug 15, 2010
-
-
Douglas Gregor authored
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. llvm-svn: 111093
-
- Aug 14, 2010
-
-
Ted Kremenek authored
Always recurse into sub-cursors when annotating tokens, as this information is used for annotating macro arguments. This finishes up <rdar://problem/8044584>. llvm-svn: 111066
-
Ted Kremenek authored
As a heuristic, annotate tokens (via clang_annotateTokens) that are the arguments of a macro instantiation using the closest cursor with the same spelling location. Because macro arguments can get token pasted in any arbitrary order, we use the annotation map to paper over the token -> cursor annotations during our post-processing stage. This fixes most of <rdar://problem/8044584>, but still doesn't work for assert(). llvm-svn: 111062
-
Douglas Gregor authored
when the CXTranslationUnit_CacheCompletionResults option is given to clang_parseTranslationUnit(). Essentially, we compute code-completion results for macro definitions after we have parsed the file, then store an ASTContext-agnostic version of those results (completion string, cursor kind, priority, and active contexts) in the ASTUnit. When performing code completion in that ASTUnit, we splice the macro definition results into the results provided by the actual code-completion (which has had macros turned off) before libclang gets those results. We use completion context information to only splice in those results that make sense for that context. With a completion involving all of the macros from Cocoa.h and a few other system libraries (totally ~8500 macro definitions) living in a precompiled header, we get about a 9% performance improvement from code completion, since we no longer have to deserialize all of the macro definitions from the precompiled header. Note that macro definitions are merely the canary; the cache is designed to also support other top-level declarations, which should be a bigger performance win. That optimization will be next. Note also that there is no mechanism for determining when to throw away the cache and recompute its contents. llvm-svn: 111051
-
- Aug 13, 2010
-
-
Douglas Gregor authored
llvm-svn: 111016
-
Douglas Gregor authored
into a PCH/AST file. llvm-svn: 111006
-
- Aug 12, 2010
-
-
Daniel Dunbar authored
ExecuteCompilerInvocation in libFrontend. llvm-svn: 110903
-
Daniel Dunbar authored
llvm-svn: 110902
-
- Aug 11, 2010
-
-
Douglas Gregor authored
the code-completion consumer. The consumer can use this information to augument, filter, or display the code-completion results. llvm-svn: 110858
-
Douglas Gregor authored
clang_reparseTranslationUnit(), along with a function to retrieve the default recommended reparsing options for a translation unit. Also, add the CXTranslationUnit_CacheCompletionResults flag, which is also currently unused. llvm-svn: 110811
-
- Aug 10, 2010
-
-
Douglas Gregor authored
provided by __builtin_types_compatible_p and __builtin_va_arg expressions, now that Abramo has added proper type-source information to those expressions. llvm-svn: 110681
-
Douglas Gregor authored
"editing" mode, introduce a separate function clang_defaultEditingTranslationUnitOptions() that retrieves the set of options. No functionality change. llvm-svn: 110613
-
- Aug 09, 2010
-
-
Daniel Dunbar authored
llvm-svn: 110602
-
Douglas Gregor authored
llvm-svn: 110599
-
Douglas Gregor authored
llvm-svn: 110596
-
- Aug 06, 2010
-
-
Douglas Gregor authored
llvm-svn: 110438
-
- Aug 05, 2010
-
-
Douglas Gregor authored
flags enumeration + default-generating function that allows code-completion to be customized via the libclang API. Plus, turn on spell-checking when performing code completion. llvm-svn: 110319
-
- Aug 04, 2010
-
-
Douglas Gregor authored
file buffers until the code completion results are destroyed; diagnostics may end up referring into the source. llvm-svn: 110216
-
Douglas Gregor authored
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). llvm-svn: 110210
-
- Aug 03, 2010
-
-
Douglas Gregor authored
declarations that we saw when creating the precompiled preamble, and provide those declarations in addition to the declarations parsed in the main source file when traversing top-level declarations. This makes the use of precompiled preambles a pure optimization, rather than changing the semantics of the parsed translation unit. llvm-svn: 110131
-
- Aug 02, 2010
-
-
Douglas Gregor authored
llvm-svn: 110062
-
Daniel Dunbar authored
for use in reporting diagnostics. - We don't want to use the Action's own CompilerInstance, because that is only initialized during file processing and I like that invariant. Also, if ParseArgs returns false then abandon execution. Also, remove unused PluginASTAction::PrintHelp virtual method. llvm-svn: 110039
-
Daniel Dunbar authored
was invoked from (which may not be where the executable itself is). - This allows having e.g., /Developer/usr/bin/clang be a symlink to some other location, while still making sure the Driver finds 'as', 'ld', etc. relative to itself. llvm-svn: 109989
-
Daniel Dunbar authored
llvm-svn: 109988
-
- Jul 31, 2010
-
-
Daniel Dunbar authored
anything. llvm-svn: 109958
-
- Jul 30, 2010
-
-
- Jul 29, 2010
-
-
Benjamin Kramer authored
llvm-svn: 109766
-
Ted Kremenek authored
Check for an invalid SourceLocation in clang_getCursor(). This avoids a possible assertion failure in SourceManager in the call to Lexer::GetBeginningOfToken(). Fixes <rdar://problem/8244873>. llvm-svn: 109713
-
Douglas Gregor authored
libclang, so that clang_annotateTokens() doesn't get confused and miss annotations. llvm-svn: 109706
-
- Jul 28, 2010
-
-
Argyrios Kyrtzidis authored
llvm-svn: 109550
-
Argyrios Kyrtzidis authored
DeclIsRequiredFunctionOrFileScopedVar. This function is part of the public CodeGen interface since it's essentially a CodeGen predicate that is also needed by the PCH mechanism to determine whether a decl needs to be deserialized during PCH loading for codegen purposes. This fixes current (and avoids future) codegen-from-PCH bugs. llvm-svn: 109546
-
- Jul 26, 2010
-
-
Dan Gohman authored
llvm-svn: 109447
-
Douglas Gregor authored
When LIBCLANG_CODE_COMPLETION_LOGGING is set in the environment, log code-completion command lines to stderr llvm-svn: 109395
-
Douglas Gregor authored
worked for C anyway. Also kills the -cc1 options -parse-noop and -parse-print-callbacks. llvm-svn: 109392
-
- Jul 25, 2010
-
-
Douglas Gregor authored
interaction, by effectively defaulting to DISABLE_SMART_POINTERS. We're embracing the model where all AST nodes are ASTContext-allocated and live as long as the ASTContext lives. llvm-svn: 109374
-