summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/PCHReaderDecl.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Reintroduce the serialization library, with fixed dependencies.Sebastian Redl2010-08-171-1599/+0
| | | | llvm-svn: 111279
* Patch to add type parameter support for attribute iboutletcollection.Fariborz Jahanian2010-08-171-3/+2
| | | | | | Radar 8308053. llvm-svn: 111275
* Revert Sebastian's build-breaking patch.Douglas Gregor2010-08-171-0/+1600
| | | | llvm-svn: 111265
* Create a new Serialization module that contains all the PCH code, and will ↵Sebastian Redl2010-08-171-1600/+0
| | | | | | 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
* Instead of modifying the ObjC AST to not modify existing declarations, teach ↵Sebastian Redl2010-08-131-2/+8
| | | | | | chained PCH to overwrite declarations from earlier PCH files in dependent ones. Tell Sema to note when it changes AST nodes so that they have to be reserialized. Finally, the ObjCProtocolDecls created in forward decls, like the ObjCInterfaceDecls in @class forward decls, are not lexically part of the decl context; only the definition is. llvm-svn: 110989
* Added locations and type source info for DeclarationName inside UsingDecl.Abramo Bagnara2010-08-121-4/+6
| | | | llvm-svn: 110912
* Added locations and type source info for DeclarationName.Abramo Bagnara2010-08-111-1/+2
| | | | llvm-svn: 110860
* Speculatively revert r110610 " Make ObjCInterfaceDecl redeclarable,Douglas Gregor2010-08-111-13/+9
| | | | | | | | and create separate decl nodes for forward declarations and the definition," which appears to be causing significant Objective-C breakage. llvm-svn: 110803
* - Make ObjCInterfaceDecl redeclarable, and create separate decl nodes for ↵Sebastian Redl2010-08-091-9/+13
| | | | | | | | | | forward declarations and the definition. - Eagerly create ObjCInterfaceTypes for declarations. - The two above changes lead to a 0.5% increase in memory use and no speed regression when parsing Cocoa.h. On the other hand, now chained PCH works when there's a forward declaration in one PCH and the interface definition in another. - Add HandleInterestingDecl to ASTConsumer. PCHReader passes the "interesting" decls it finds to this function instead of HandleTopLevelDecl. The default implementation forwards to HandleTopLevelDecl, but ASTUnit's handler for example ignores them. This fixes a potential crash when lazy loading of PCH data would cause ASTUnit's "top level" declaration collection to change while being iterated. llvm-svn: 110610
* Complete PCH support for ObjCPropertyImplDecl.Argyrios Kyrtzidis2010-08-091-1/+2
| | | | llvm-svn: 110570
* Support ObjC implementation decls for PCH.Argyrios Kyrtzidis2010-08-091-2/+3
| | | | | | Strictly speaking, implementations don't go in headers but there's no law against it. llvm-svn: 110567
* Refactor into functions PCH reading/writing the CXXBaseOrMemberInitializers. ↵Argyrios Kyrtzidis2010-08-091-57/+2
| | | | | | No functionality change. llvm-svn: 110566
* Remove the DeclaredInCondition bit now that it's no longer used.Nick Lewycky2010-08-061-1/+0
| | | | llvm-svn: 110432
* Make sure C++ variable definitions are actually passed to the consumer when ↵Argyrios Kyrtzidis2010-08-051-1/+2
| | | | | | loaded from PCH. llvm-svn: 110322
* Implement #pragma GCC visibility.Eli Friedman2010-08-051-1/+2
| | | | llvm-svn: 110315
* Apart from storing/retrieving the previous redeclaration from PCH, also ↵Argyrios Kyrtzidis2010-08-031-13/+78
| | | | | | | | | | | | store/retrieve the most recent redeclaration. That way we are sure that the full redeclarations chain is loaded. When using chained PCHs, first declarations point to the most recent redeclarations in the same PCH. To address this use a REDECLS_UPDATE_LATEST record block to keep track of which first declarations need to point to a most recent redeclaration in another PCH. llvm-svn: 110125
* Refactor the way PCHReader tracks whether we are in recursive loading.Argyrios Kyrtzidis2010-07-301-1/+1
| | | | | | | | | | -Replace CurrentlyLoadingTypeOrDecl with a counting scheme (NumCurrentElementsDeserializing) -Provide outside access to the mechanism by adding methods StartedDeserializing/FinishedDeserializing to ExternalASTSource. These are preparation for the next commit. llvm-svn: 109856
* Store latest redeclaration for each redeclarable template declarationPeter Collingbourne2010-07-291-0/+5
| | | | | | | This patch adds a Latest field to RedeclarableTemplateDecl's CommonBase class which is used to store the latest redeclaration. llvm-svn: 109755
* Refactor redeclarable template declarationsPeter Collingbourne2010-07-291-24/+25
| | | | | | | | | | | This patch refactors much of the common code in ClassTemplateDecl and FunctionTemplateDecl into a common base class RedeclarableTemplateDecl together with support functions in a template class RedeclarableTemplate. The patch also includes similar refactoring for these classes' PCH reader and writer implementations. llvm-svn: 109754
* Update the list of lexical decls in the TU for chained PCHs. This makes ↵Sebastian Redl2010-07-271-1/+5
| | | | | | -ast-print show the decls from the dependent PCH. llvm-svn: 109524
* - Fix recording of offsets of types in dependent PCHs.Sebastian Redl2010-07-271-5/+35
| | | | | | | - Stop reading in (and thus deserializing) every declaration in the TU when creating a dependent PCH. - Switch the storage of a decl context's lexical declarations to a blob containing the IDs instead of a record. This is the only sane way of supporting update records later on. llvm-svn: 109474
* Add source location information to C++ base specifiers.Nick Lewycky2010-07-261-3/+3
| | | | llvm-svn: 109396
* Thread bitstream cursors all the way through the AST reading stuff. This ↵Sebastian Redl2010-07-221-36/+53
| | | | | | way, reading a trivial 2-element chained file actually works. llvm-svn: 109191
* atch for implementation of objective-c's -WselectorFariborz Jahanian2010-07-221-0/+1
| | | | | | | warning flag in clang. Little more to do for a PCH issue. Radar 6507158. llvm-svn: 109129
* Read/write C++0x static_assert for PCH.Argyrios Kyrtzidis2010-07-221-2/+4
| | | | llvm-svn: 109123
* Allow loading declcontext information from any file in the chain. Properly ↵Sebastian Redl2010-07-221-1/+6
| | | | | | write source locations to dependent files. WIP llvm-svn: 109119
* Read/write FriendTemplateDecl for PCH.Argyrios Kyrtzidis2010-07-221-2/+12
| | | | llvm-svn: 109113
* Apparently not every system thinks that references in pairs are as cool as I ↵Sebastian Redl2010-07-201-2/+2
| | | | | | think. llvm-svn: 108959
* Allow loading declarations from any file in the chain. WIPSebastian Redl2010-07-201-3/+17
| | | | llvm-svn: 108956
* Hide FunctionTemplateDecl's specializations folding set as implementation ↵Argyrios Kyrtzidis2010-07-201-5/+6
| | | | | | | | | | | detail and introduce FunctionTemplateDecl::findSpecialization. Redeclarations of specializations will not cause the previous decl to be removed from the set, the set will keep the canonical decl. findSpecialization will return the most recent redeclaration. llvm-svn: 108834
* Whether the specialization should be added to template's folding set when ↵Argyrios Kyrtzidis2010-07-201-1/+1
| | | | | | | | read from PCH, is determined by a isCanonicalDecl check. llvm-svn: 108833
* Remove PCHReader::getStream(), it was unused. Inline ↵Sebastian Redl2010-07-191-1/+1
| | | | | | PCHReader::getDelsCursor() into its sole caller and remove it. This reduces the attack surface of multiple PCH files towards code outside the PCH implementation. llvm-svn: 108763
* Added PCH/ASTImporter code for ObjCIvarDecl's field.Fariborz Jahanian2010-07-171-0/+2
| | | | llvm-svn: 108627
* First baby steps towards PCHReader being able to keep track of multiple PCH ↵Sebastian Redl2010-07-161-0/+2
| | | | | | files. WIP llvm-svn: 108537
* Simplify code using the new FoldingSetImpl::InsertNode() overload.Argyrios Kyrtzidis2010-07-121-8/+2
| | | | llvm-svn: 108198
* Switch to void-cast for this. Chris prefers that over the attribute, I'llChandler Carruth2010-07-111-3/+4
| | | | | | probably try and switch more of these if I can. llvm-svn: 108085
* Mark assert-only variables as unused.Chandler Carruth2010-07-111-2/+3
| | | | llvm-svn: 108068
* Reorganize how ClassTemplate[Partial]SpecializationDecls are read/written to ↵Argyrios Kyrtzidis2010-07-091-26/+20
| | | | | | | | avoid the possibility of adding an unitialized one into the folding set. llvm-svn: 108016
* isMemberSpecialization -> setMemberSpecialization.Argyrios Kyrtzidis2010-07-091-1/+1
| | | | llvm-svn: 108015
* Support TemplateTemplateParmDecl for PCH.Argyrios Kyrtzidis2010-07-081-3/+11
| | | | llvm-svn: 107884
* Fix reading of UsingDecl from PCH.Argyrios Kyrtzidis2010-07-081-1/+3
| | | | llvm-svn: 107871
* Delay passing InterestingDecls to the Consumer until when we know we are not ↵Argyrios Kyrtzidis2010-07-071-10/+5
| | | | | | | | in recursive loading and the declarations are fully initialized. llvm-svn: 107783
* Pacify versions of gcc that think these variables may be usedDuncan Sands2010-07-061-3/+3
| | | | | | | uninitialized (which doesn't seem to be the case), by giving them arbitrary initial values. llvm-svn: 107679
* Read/write function template specializations for PCH, properly this time.Argyrios Kyrtzidis2010-07-061-3/+6
| | | | llvm-svn: 107665
* Allow a CXXRecordDecl to get a DefinitionData pointer even when its owner is ↵Argyrios Kyrtzidis2010-07-061-47/+63
| | | | | | still initializing. llvm-svn: 107663
* Read/write instantiated-from-member of EnumDecl for PCH.Argyrios Kyrtzidis2010-07-061-1/+2
| | | | llvm-svn: 107662
* Read/write the identifier namespace in PCH for decls that may modify it.Argyrios Kyrtzidis2010-07-051-6/+8
| | | | | | We can now use a PCH'ed <map>. llvm-svn: 107617
* Read/write some source location for PCH.Argyrios Kyrtzidis2010-07-051-1/+5
| | | | llvm-svn: 107616
* Read/write more information of ASTContext for PCH. Overriden methods and ↵Argyrios Kyrtzidis2010-07-041-0/+19
| | | | | | instantiated-from information. llvm-svn: 107597
* Write/read ParmVarDecl's UninstantiatedDefaultArg for PCH.Argyrios Kyrtzidis2010-07-041-0/+2
| | | | llvm-svn: 107594
OpenPOWER on IntegriCloud