summaryrefslogtreecommitdiffstats
path: root/clang/lib/Serialization/ASTWriter.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Add testcase for C++ chained PCH and fix the bugs it uncovered in name lookup.Sebastian Redl2010-08-241-13/+3
| | | | llvm-svn: 111882
* Write visible update blocks. No regressions in normal PCH functionality, but ↵Sebastian Redl2010-08-241-1/+76
| | | | | | no tests for the chain yet. llvm-svn: 111881
* Fix an issue with writing to PCH another included PCH, introduced by the ↵Argyrios Kyrtzidis2010-08-201-1/+4
| | | | | | | | | | | "using an AST on-disk hash table for name lookup" commit. When including a PCH and later re-emitting to another PCH, the name lookup tables of DeclContexts may be incomplete, since we now lazily deserialize the visible decls of a particular name. Fix the issue by iterating over the un-deserialized visible decls and completing the lookup tables of DeclContexts before writing them out. llvm-svn: 111698
* Use the AST on-disk hash table for name lookup inside a DeclContext.Argyrios Kyrtzidis2010-08-201-53/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *Huge* improvement over the amount of deserializing that we do for C++ lookup. e.g, if he have the Carbon header precompiled and include it on a file containing this: int x; these are the before/after stats: BEFORE: *** AST File Statistics: 578 stat cache hits 4 stat cache misses 548/30654 source location entries read (1.787695%) 15907/16501 types read (96.400223%) 53525/59955 declarations read (89.275291%) 33993/43525 identifiers read (78.099945%) 41516/51891 statements read (80.006165%) 77/5317 macros read (1.448185%) 0/6335 lexical declcontexts read (0.000000%) 1/5424 visible declcontexts read (0.018437%) AFTER using the on-disk table: *** AST File Statistics: 578 stat cache hits 4 stat cache misses 548/30654 source location entries read (1.787695%) 10/16501 types read (0.060602%) 9/59955 declarations read (0.015011%) 161/43525 identifiers read (0.369902%) 20/51891 statements read (0.038542%) 6/5317 macros read (0.112846%) 0/6335 lexical declcontexts read (0.000000%) 2/5424 visible declcontexts read (0.036873%) There's only one issue affecting mostly the precompiled preambles which I will address soon. llvm-svn: 111636
* Introduce the mechanism for building an AST on-disk hash table for name ↵Argyrios Kyrtzidis2010-08-201-6/+130
| | | | | | lookup inside a DeclContext but don't use it yet. llvm-svn: 111635
* Refactoring; move the functionality of ASTWriter::GetOrCreateTypeID to the ↵Argyrios Kyrtzidis2010-08-201-50/+6
| | | | | | | | | | more generic MakeTypeID template function which accepts a type and a function object that returns a TypeIdx. MakeTypeID is in PCHCommon.h so that it can be used by ASTReader too. llvm-svn: 111634
* Introduce ASTWriter::GetOrCreateTypeID and move most of the functionality of ↵Argyrios Kyrtzidis2010-08-201-17/+10
| | | | | | | | AddTypeRef there. No functionality change. llvm-svn: 111633
* A bit of refactoring; Introduce ASTWriter::GetOrCreateTypeIdx and move the ↵Argyrios Kyrtzidis2010-08-201-10/+21
| | | | | | | | emission of types there. No functionality change. llvm-svn: 111632
* Rename TypeIDs -> TypeIdxs. No functionality change.Argyrios Kyrtzidis2010-08-201-4/+4
| | | | llvm-svn: 111631
* serialization::TypeID is used with or without qualifiers, both as index and ↵Argyrios Kyrtzidis2010-08-201-15/+15
| | | | | | | | as index + qualifiers. Disambiguate and provide some type safety by using a new class TypeIdx for the "TypeID as index" semantics. llvm-svn: 111630
* Share the common code of ComputeHash(Selector Sel) instead of keeping 2 ↵Argyrios Kyrtzidis2010-08-201-8/+2
| | | | | | | | copies in PCHReader and PCHWriter. No functionality change. llvm-svn: 111629
* Rename pch namespace to serialization.Sebastian Redl2010-08-181-178/+179
| | | | llvm-svn: 111478
* Rename stuff in PCHBitCodes.hSebastian Redl2010-08-181-3/+3
| | | | llvm-svn: 111475
* Rename the ASTReader header files.Sebastian Redl2010-08-181-1/+1
| | | | llvm-svn: 111474
* More PCH -> AST renaming.Sebastian Redl2010-08-181-3/+3
| | | | llvm-svn: 111472
* Rename PCHReader to ASTReader.Sebastian Redl2010-08-181-1/+1
| | | | llvm-svn: 111467
* Rename PCHWriter.h to ASTWriter.hSebastian Redl2010-08-181-1/+1
| | | | llvm-svn: 111466
* Rename the ASTWriter implementation filesSebastian Redl2010-08-181-0/+2938
llvm-svn: 111465
OpenPOWER on IntegriCloud