clang API Documentation
| typedef uint32_t clang::pch::DeclID |
An ID number that refers to a declaration in a PCH file.
The ID numbers of declarations are consecutive (in order of discovery) and start at 2. 0 is reserved for NULL, and 1 is reserved for the translation unit declaration.
Definition at line 53 of file PCHBitCodes.h.
| typedef uint32_t clang::pch::IdentID |
An ID number that refers to an identifier in a PCH file.
Definition at line 69 of file PCHBitCodes.h.
| typedef uint32_t clang::pch::SelectorID |
Definition at line 71 of file PCHBitCodes.h.
| typedef uint32_t clang::pch::TypeID |
An ID number that refers to a type in a PCH file.
The ID of a type is partitioned into two parts: the lower three bits are used to store the const/volatile/restrict qualifiers (as with QualType) and the upper bits provide a type index. The type index values are partitioned into two sets. The values below NUM_PREDEF_TYPE_IDs are predefined type IDs (based on the PREDEF_TYPE_*_ID constants), with 0 as a placeholder for "no type". Values from NUM_PREDEF_TYPE_IDs are other types that have serialized representations.
Definition at line 65 of file PCHBitCodes.h.
| enum clang::pch::BlockIDs |
Describes the various kinds of blocks that occur within a PCH file.
Definition at line 75 of file PCHBitCodes.h.
Record types that occur within the PCH block itself.
| TYPE_OFFSET |
Record code for the offsets of each type. The TYPE_OFFSET constant describes the record that occurs within the PCH block. The record itself is an array of offsets that point into the declarations and types block (identified by DECLTYPES_BLOCK_ID). The index into the array is based on the ID of a type. For a given type ID |
| DECL_OFFSET |
Record code for the offsets of each decl. The DECL_OFFSET constant describes the record that occurs within the block identified by DECL_OFFSETS_BLOCK_ID within the PCH block. The record itself is an array of offsets that point into the declarations and types block (identified by DECLTYPES_BLOCK_ID). The declaration ID is an index into this record, after subtracting one to account for the use of declaration ID 0 for a NULL declaration pointer. Index 0 is reserved for the translation unit declaration. |
| LANGUAGE_OPTIONS |
Record code for the language options table. The record with this code contains the contents of the LangOptions structure. We serialize the entire contents of the structure, and let the reader decide which options are actually important to check. |
| METADATA |
PCH metadata, including the PCH file version number and the target triple used to build the PCH file. |
| IDENTIFIER_OFFSET |
Record code for the table of offsets of each identifier ID. The offset table contains offsets into the blob stored in the IDENTIFIER_TABLE record. Each offset points to the NULL-terminated string that corresponds to that identifier. |
| IDENTIFIER_TABLE |
Record code for the identifier table. The identifier table is a simple blob that contains NULL-terminated strings for all of the identifiers referenced by the PCH file. The IDENTIFIER_OFFSET table contains the mapping from identifier IDs to the characters in this blob. Note that the starting offsets of all of the identifiers are odd, so that, when the identifier offset table is loaded in, we can use the low bit to distinguish between offsets (for unresolved identifier IDs) and IdentifierInfo pointers (for already-resolved identifier IDs). |
| EXTERNAL_DEFINITIONS |
Record code for the array of external definitions. The PCH file contains a list of all of the unnamed external definitions present within the parsed headers, stored as an array of declaration IDs. These external definitions will be reported to the AST consumer after the PCH file has been read, since their presence can affect the semantics of the program (e.g., for code generation). |
| SPECIAL_TYPES |
Record code for the set of non-builtin, special types. This record contains the type IDs for the various type nodes that are constructed during semantic analysis (e.g., __builtin_va_list). The SPECIAL_TYPE_* constants provide offsets into this record. |
| STATISTICS |
Record code for the extra statistics we gather while generating a PCH file. |
| TENTATIVE_DEFINITIONS |
Record code for the array of tentative definitions. |
| LOCALLY_SCOPED_EXTERNAL_DECLS |
Record code for the array of locally-scoped external declarations. |
| SELECTOR_OFFSETS |
Record code for the table of offsets into the Objective-C method pool. |
| METHOD_POOL |
Record code for the Objective-C method pool,. |
| PP_COUNTER_VALUE |
The value of the next __COUNTER__ to dispense. [PP_COUNTER_VALUE, Val]. |
| SOURCE_LOCATION_OFFSETS |
Record code for the table of offsets into the block of source-location information. |
| SOURCE_LOCATION_PRELOADS |
Record code for the set of source location entries that need to be preloaded by the PCH reader. This set contains the source location entry for the predefines buffer and for any file entries that need to be preloaded. |
| STAT_CACHE |
Record code for the stat() cache. |
| EXT_VECTOR_DECLS |
Record code for the set of ext_vector type names. |
| ORIGINAL_FILE_NAME |
Record code for the original file that was used to generate the precompiled header. |
| VERSION_CONTROL_BRANCH_REVISION |
Record #20 intentionally left blank. Record code for the version control branch and revision information of the compiler used to build this PCH file. |
| UNUSED_FILESCOPED_DECLS |
Record code for the array of unused file scoped decls. |
| MACRO_DEFINITION_OFFSETS |
Record code for the table of offsets to macro definition entries in the preprocessing record. |
| VTABLE_USES |
Record code for the array of VTable uses. |
| DYNAMIC_CLASSES |
Record code for the array of dynamic classes. |
| CHAINED_METADATA |
Record code for the chained PCH metadata, including the PCH version and the name of the PCH this is chained to. |
| REFERENCED_SELECTOR_POOL |
Record code for referenced selector pool. |
| TU_UPDATE_LEXICAL |
Record code for an update to the TU's lexically contained declarations. |
| REDECLS_UPDATE_LATEST |
Record code for an update to first decls pointing to the latest redeclarations. |
| SEMA_DECL_REFS |
Record code for declarations that Sema keeps references of. |
| WEAK_UNDECLARED_IDENTIFIERS |
Record code for weak undeclared identifiers. |
| PENDING_IMPLICIT_INSTANTIATIONS |
Record code for pending implicit instantiations. |
| DECL_REPLACEMENTS |
Record code for a decl replacement block. If a declaration is modified after having been deserialized, and then written to a dependent PCH file, its ID and offset must be added to the replacement block. |
Definition at line 94 of file PCHBitCodes.h.
Record types used within a preprocessor block.
| PP_MACRO_OBJECT_LIKE |
An object-like macro definition. [PP_MACRO_OBJECT_LIKE, IdentInfoID, SLoc, IsUsed]. |
| PP_MACRO_FUNCTION_LIKE |
A function-like macro definition. [PP_MACRO_FUNCTION_LIKE, <ObjectLikeStuff>, IsC99Varargs, IsGNUVarars, NumArgs, ArgIdentInfoID* ]. |
| PP_TOKEN |
Describes one token. [PP_TOKEN, SLoc, Length, IdentInfoID, Kind, Flags]. |
| PP_MACRO_INSTANTIATION |
Describes a macro instantiation within the preprocessing record. |
| PP_MACRO_DEFINITION |
Describes a macro definition within the preprocessing record. |
Definition at line 290 of file PCHBitCodes.h.
Record types used within a source manager block.
Definition at line 270 of file PCHBitCodes.h.
| const unsigned clang::pch::VERSION_MAJOR = 4 |
PCH major version number supported by this version of Clang.
Whenever the PCH format changes in a way that makes it incompatible with previous versions (such that a reader designed for the previous version could not support reading the new version), this number should be increased.
Version 4 of PCH files also requires that the version control branch and revision match exactly, since there is no backward compatibility of PCH files at this time.
Definition at line 36 of file PCHBitCodes.h.
| const unsigned clang::pch::VERSION_MINOR = 0 |
PCH minor version number supported by this version of Clang.
Whenever the PCH format changes in a way that is still compatible with previous versions (such that a reader designed for the previous version could still support reading the new version by ignoring new kinds of subblocks), this number should be increased.
Definition at line 46 of file PCHBitCodes.h.