#include #include #include #include #include #include #include #include #include #include #include #include #include "clang/Serialization/TypeBitCodes.def" #include "clang/AST/TypeLocNodes.def" #include "clang/Basic/DiagnosticOptions.def" #include "clang/Basic/LangOptions.def" #include "clang/Basic/Sanitizers.def" #include "clang/Serialization/AttrPCHWrite.inc" #include "clang/AST/CXXRecordDeclDefinitionBits.def" #include "llvm/Frontend/OpenMP/OMP.inc"">

clang: lib/Serialization/ASTWriter.cpp File Reference (original) (raw)

#include "[ASTCommon.h](ASTCommon%5F8h%5Fsource.html)"
#include "[ASTReaderInternals.h](ASTReaderInternals%5F8h%5Fsource.html)"
#include "[MultiOnDiskHashTable.h](MultiOnDiskHashTable%5F8h%5Fsource.html)"
#include "[TemplateArgumentHasher.h](TemplateArgumentHasher%5F8h%5Fsource.html)"
#include "[clang/AST/ASTContext.h](ASTContext%5F8h%5Fsource.html)"
#include "[clang/AST/ASTUnresolvedSet.h](ASTUnresolvedSet%5F8h%5Fsource.html)"
#include "[clang/AST/AbstractTypeWriter.h](AbstractTypeWriter%5F8h%5Fsource.html)"
#include "[clang/AST/Attr.h](AST%5F2Attr%5F8h%5Fsource.html)"
#include "[clang/AST/Decl.h](Decl%5F8h%5Fsource.html)"
#include "[clang/AST/DeclBase.h](DeclBase%5F8h%5Fsource.html)"
#include "[clang/AST/DeclCXX.h](DeclCXX%5F8h%5Fsource.html)"
#include "[clang/AST/DeclContextInternals.h](DeclContextInternals%5F8h%5Fsource.html)"
#include "[clang/AST/DeclFriend.h](DeclFriend%5F8h%5Fsource.html)"
#include "[clang/AST/DeclObjC.h](DeclObjC%5F8h%5Fsource.html)"
#include "[clang/AST/DeclTemplate.h](DeclTemplate%5F8h%5Fsource.html)"
#include "[clang/AST/DeclarationName.h](DeclarationName%5F8h%5Fsource.html)"
#include "[clang/AST/Expr.h](Expr%5F8h%5Fsource.html)"
#include "[clang/AST/ExprCXX.h](ExprCXX%5F8h%5Fsource.html)"
#include "[clang/AST/LambdaCapture.h](LambdaCapture%5F8h%5Fsource.html)"
#include "[clang/AST/NestedNameSpecifier.h](NestedNameSpecifier%5F8h%5Fsource.html)"
#include "[clang/AST/OpenACCClause.h](OpenACCClause%5F8h%5Fsource.html)"
#include "[clang/AST/OpenMPClause.h](OpenMPClause%5F8h%5Fsource.html)"
#include "[clang/AST/RawCommentList.h](RawCommentList%5F8h%5Fsource.html)"
#include "[clang/AST/TemplateName.h](TemplateName%5F8h%5Fsource.html)"
#include "[clang/AST/Type.h](Type%5F8h%5Fsource.html)"
#include "[clang/AST/TypeLoc.h](TypeLoc%5F8h%5Fsource.html)"
#include "[clang/AST/TypeLocVisitor.h](TypeLocVisitor%5F8h%5Fsource.html)"
#include "[clang/Basic/Diagnostic.h](Basic%5F2Diagnostic%5F8h%5Fsource.html)"
#include "[clang/Basic/DiagnosticOptions.h](DiagnosticOptions%5F8h%5Fsource.html)"
#include "[clang/Basic/FileEntry.h](FileEntry%5F8h%5Fsource.html)"
#include "[clang/Basic/FileManager.h](FileManager%5F8h%5Fsource.html)"
#include "[clang/Basic/FileSystemOptions.h](FileSystemOptions%5F8h%5Fsource.html)"
#include "[clang/Basic/IdentifierTable.h](IdentifierTable%5F8h%5Fsource.html)"
#include "[clang/Basic/LLVM.h](LLVM%5F8h%5Fsource.html)"
#include "[clang/Basic/Lambda.h](Lambda%5F8h%5Fsource.html)"
#include "[clang/Basic/LangOptions.h](LangOptions%5F8h%5Fsource.html)"
#include "[clang/Basic/Module.h](Module%5F8h%5Fsource.html)"
#include "[clang/Basic/ObjCRuntime.h](ObjCRuntime%5F8h%5Fsource.html)"
#include "[clang/Basic/OpenACCKinds.h](OpenACCKinds%5F8h%5Fsource.html)"
#include "[clang/Basic/OpenCLOptions.h](OpenCLOptions%5F8h%5Fsource.html)"
#include "[clang/Basic/SourceLocation.h](SourceLocation%5F8h%5Fsource.html)"
#include "[clang/Basic/SourceManager.h](SourceManager%5F8h%5Fsource.html)"
#include "[clang/Basic/SourceManagerInternals.h](SourceManagerInternals%5F8h%5Fsource.html)"
#include "[clang/Basic/Specifiers.h](Specifiers%5F8h%5Fsource.html)"
#include "[clang/Basic/TargetInfo.h](include%5F2clang%5F2Basic%5F2TargetInfo%5F8h%5Fsource.html)"
#include "[clang/Basic/TargetOptions.h](TargetOptions%5F8h%5Fsource.html)"
#include "[clang/Basic/Version.h](Version%5F8h%5Fsource.html)"
#include "[clang/Lex/HeaderSearch.h](HeaderSearch%5F8h%5Fsource.html)"
#include "[clang/Lex/HeaderSearchOptions.h](HeaderSearchOptions%5F8h%5Fsource.html)"
#include "[clang/Lex/MacroInfo.h](MacroInfo%5F8h%5Fsource.html)"
#include "[clang/Lex/ModuleMap.h](ModuleMap%5F8h%5Fsource.html)"
#include "[clang/Lex/PreprocessingRecord.h](PreprocessingRecord%5F8h%5Fsource.html)"
#include "[clang/Lex/Preprocessor.h](Preprocessor%5F8h%5Fsource.html)"
#include "[clang/Lex/PreprocessorOptions.h](PreprocessorOptions%5F8h%5Fsource.html)"
#include "[clang/Lex/Token.h](Token%5F8h%5Fsource.html)"
#include "[clang/Sema/IdentifierResolver.h](IdentifierResolver%5F8h%5Fsource.html)"
#include "[clang/Sema/ObjCMethodList.h](ObjCMethodList%5F8h%5Fsource.html)"
#include "[clang/Sema/Sema.h](Sema%5F8h%5Fsource.html)"
#include "[clang/Sema/SemaCUDA.h](SemaCUDA%5F8h%5Fsource.html)"
#include "[clang/Sema/SemaObjC.h](SemaObjC%5F8h%5Fsource.html)"
#include "[clang/Sema/Weak.h](Weak%5F8h%5Fsource.html)"
#include "[clang/Serialization/ASTBitCodes.h](ASTBitCodes%5F8h%5Fsource.html)"
#include "[clang/Serialization/ASTReader.h](ASTReader%5F8h%5Fsource.html)"
#include "[clang/Serialization/ASTRecordWriter.h](ASTRecordWriter%5F8h%5Fsource.html)"
#include "[clang/Serialization/InMemoryModuleCache.h](InMemoryModuleCache%5F8h%5Fsource.html)"
#include "[clang/Serialization/ModuleFile.h](ModuleFile%5F8h%5Fsource.html)"
#include "[clang/Serialization/ModuleFileExtension.h](ModuleFileExtension%5F8h%5Fsource.html)"
#include "[clang/Serialization/SerializationDiagnostic.h](SerializationDiagnostic%5F8h%5Fsource.html)"
#include "llvm/ADT/APFloat.h"
#include "llvm/ADT/APInt.h"
#include "llvm/ADT/APSInt.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/Hashing.h"
#include "llvm/ADT/PointerIntPair.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/ScopeExit.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Bitstream/BitCodes.h"
#include "llvm/Bitstream/BitstreamWriter.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/Compression.h"
#include "llvm/Support/DJB.h"
#include "llvm/Support/Endian.h"
#include "llvm/Support/EndianStream.h"
#include "llvm/Support/Error.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/LEB128.h"
#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/OnDiskHashTable.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/SHA1.h"
#include "llvm/Support/TimeProfiler.h"
#include "llvm/Support/VersionTuple.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
#include <cassert>
#include <cstdint>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <limits>
#include <memory>
#include <optional>
#include <queue>
#include <tuple>
#include <utility>
#include <vector>
#include "clang/Serialization/TypeBitCodes.def"
#include "clang/AST/TypeLocNodes.def"
#include "clang/Basic/DiagnosticOptions.def"
#include "clang/Basic/LangOptions.def"
#include "clang/Basic/Sanitizers.def"
#include "clang/Serialization/AttrPCHWrite.inc"
#include "clang/AST/CXXRecordDeclDefinitionBits.def"
#include "llvm/Frontend/OpenMP/OMP.inc"

Go to the source code of this file.

Macros
#define TYPE_BIT_CODE(CLASS_ID, CODE_ID, CODE_VALUE) case Type::CLASS_ID: return TYPE_##CODE_ID;
#define ABSTRACT_TYPELOC(CLASS, PARENT)
#define TYPELOC(CLASS, PARENT) void Visit##CLASS##TypeLoc(CLASS##TypeLoc TyLoc);
#define RECORD(X) EmitRecordID(X, #X, Stream, Record)
#define BLOCK(X) EmitBlockID(X ## _ID, #X, Stream, Record)
#define RECORD(X) EmitRecordID(X, #X, Stream, Record)
#define DIAGOPT(Name, Bits, Default) Record.push_back(DiagOpts.Name);
#define ENUM_DIAGOPT(Name, Type, Bits, Default) Record.push_back(static_cast<unsigned>(DiagOpts.get##Name()));
#define LANGOPT(Name, Bits, Default, Description) Record.push_back(LangOpts.Name);
#define ENUM_LANGOPT(Name, Type, Bits, Default, Description) Record.push_back(static_cast<unsigned>(LangOpts.get##Name()));
#define SANITIZER(NAME, ID) Record.push_back(LangOpts.Sanitize.has(SanitizerKind::ID));
#define FIELD(Name, Width, Merge)
#define GEN_CLANG_CLAUSE_CLASS
#define CLAUSE_CLASS(Enum, Str, Class) void Visit##Class(Class *S);
Functions
template<typename T , typename Allocator >
static StringRef bytes (const std::vector< T, Allocator > &v)
template
static StringRef bytes (const SmallVectorImpl< T > &v)
static std::string bytes (const std::vector< bool > &V)
static TypeCode getTypeCodeForTypeClass (Type::TypeClass id)
static void EmitBlockID (unsigned ID, const char *Name, llvm::BitstreamWriter &Stream, ASTWriter::RecordDataImpl &Record)
static void EmitRecordID (unsigned ID, const char *Name, llvm::BitstreamWriter &Stream, ASTWriter::RecordDataImpl &Record)
static void AddStmtsExprs (llvm::BitstreamWriter &Stream, ASTWriter::RecordDataImpl &Record)
static bool cleanPathForOutput (FileManager &FileMgr, SmallVectorImpl< char > &Path)
Prepares a path for being written to an AST file by converting it to an absolute path and removing nested '.
static const char * adjustFilenameForRelocatableAST (const char *Filename, StringRef BaseDir)
Adjusts the given filename to only write out the portion of the filename that is not part of the system root directory.
static void BackpatchSignatureAt (llvm::BitstreamWriter &Stream, const ASTFileSignature &S, uint64_t BitNo)
static unsigned CreateSLocFileAbbrev (llvm::BitstreamWriter &Stream)
Create an abbreviation for the SLocEntry that refers to a file.
static unsigned CreateSLocBufferAbbrev (llvm::BitstreamWriter &Stream)
Create an abbreviation for the SLocEntry that refers to a buffer.
static unsigned CreateSLocBufferBlobAbbrev (llvm::BitstreamWriter &Stream, bool Compressed)
Create an abbreviation for the SLocEntry that refers to a buffer's blob.
static unsigned CreateSLocExpansionAbbrev (llvm::BitstreamWriter &Stream)
Create an abbreviation for the SLocEntry that refers to a macro expansion.
static std::pair< unsigned, unsigned > emitULEBKeyDataLength (unsigned KeyLen, unsigned DataLen, raw_ostream &Out)
Emit key length and data length as ULEB-encoded data, and return them as a pair.
static void emitBlob (llvm::BitstreamWriter &Stream, StringRef Blob, unsigned SLocBufferBlobCompressedAbbrv, unsigned SLocBufferBlobAbbrv)
static bool shouldIgnoreMacro (MacroDirective *MD, bool IsModule, const Preprocessor &PP)
static unsigned getNumberOfModules (Module *Mod)
Compute the number of modules within the given tree (including the given module).
static bool IsInternalDeclFromFileContext (const Decl *D)
static NamedDecl * getDeclForLocalLookup (const LangOptions &LangOpts, NamedDecl *D)
Determine the declaration that should be put into the name lookup table to represent the given declaration in this module.
static bool isLocalIdentifierID (IdentifierID ID)
If the.
static bool isLookupResultNotInteresting (ASTWriter &Writer, StoredDeclsList &Result)
Returns ture if all of the lookup result are either external, not emitted or predefined.
template<typename Vector >
static void AddLazyVectorDecls (ASTWriter &Writer, Vector &Vec)
template<typename Vector >
static void AddLazyVectorEmiitedDecls (ASTWriter &Writer, Vector &Vec, ASTWriter::RecordData &Record)
template
static TypeID MakeTypeID (ASTContext &Context, QualType T, IdxForTypeTy IdxForType)
static uint64_t EmitCXXBaseSpecifiers (ASTContext &Context, ASTWriter &W, ArrayRef< CXXBaseSpecifier > Bases)
static uint64_t EmitCXXCtorInitializers (ASTContext &Context, ASTWriter &W, ArrayRef< CXXCtorInitializer * > CtorInits)
static bool isImportedDeclContext (ASTReader *Chain, const Decl *D)

ABSTRACT_TYPELOC

| #define ABSTRACT_TYPELOC | ( | | CLASS, | | ------------------------- | - | | ------ | | | PARENT | | | | | ) | | | |

BLOCK

CLAUSE_CLASS

| #define CLAUSE_CLASS | ( | | Enum, | | --------------------- | ----------------------------- | | ----------------------------------------------------------------------------------------------------- | | | Str, | | | | | | Class | | | | | ) | void Visit##Class(Class *S); | | |

DIAGOPT

| #define DIAGOPT | ( | | Name, | | --------------- | --------------------------------- | | ----- | | | Bits, | | | | | | Default | | | | | ) | Record.push_back(DiagOpts.Name); | | |

ENUM_DIAGOPT

| #define ENUM_DIAGOPT | ( | | Name, | | ------------------------------------------------------------------------ | --------------------------------------------------------------------------------------- | | ----- | | | Type, | | | | | | Bits, | | | | | | Default | | | | | ) | Record.push_back(static_cast<unsigned>(DiagOpts.get##Name())); | | |

ENUM_LANGOPT

| #define ENUM_LANGOPT | ( | | Name, | | ------------------------------------------------------------------------ | --------------------------------------------------------------------------------------- | | ----- | | | Type, | | | | | | Bits, | | | | | | Default, | | | | | | Description | | | | | ) | Record.push_back(static_cast<unsigned>(LangOpts.get##Name())); | | |

FIELD

| #define FIELD | ( | | Name, | | ------------- | - | | ----- | | | Width, | | | | | | Merge | | | | | ) | | | |

Value:

if (!DefinitionBits.canWriteNextNBits(Width)) { \

Record->push_back(DefinitionBits); \

DefinitionBits.reset(0); \

} \

DefinitionBits.addBits(Data.Name, Width);

llvm::MachO::Record Record

GEN_CLANG_CLAUSE_CLASS

#define GEN_CLANG_CLAUSE_CLASS

LANGOPT

| #define LANGOPT | ( | | Name, | | --------------- | --------------------------------- | | ----- | | | Bits, | | | | | | Default, | | | | | | Description | | | | | ) | Record.push_back(LangOpts.Name); | | |

RECORD [1/2]

RECORD [2/2]

SANITIZER

TYPE_BIT_CODE

| #define TYPE_BIT_CODE | ( | | CLASS_ID, | | ----------------------- | ----------------------------------------------------------------------------------------------------------- | | ---------- | | | CODE_ID, | | | | | | CODE_VALUE | | | | | ) | case Type::CLASS_ID: return TYPE_##CODE_ID; | | |

TYPELOC

| #define TYPELOC | ( | | CLASS, | | --------------- | --------------------------------------------------------------------------------------------------------------------- | | ------ | | | PARENT | | | | | ) | void Visit##CLASS##TypeLoc(CLASS##TypeLoc TyLoc); | | |

AddLazyVectorDecls()

AddLazyVectorEmiitedDecls()

AddStmtsExprs()

Definition at line 754 of file ASTWriter.cpp.

References clang::serialization::EXPR_ADDR_LABEL, clang::serialization::EXPR_ARRAY_SUBSCRIPT, clang::serialization::EXPR_ARRAY_TYPE_TRAIT, clang::serialization::EXPR_BINARY_CONDITIONAL_OPERATOR, clang::serialization::EXPR_BINARY_OPERATOR, clang::serialization::EXPR_BLOCK, clang::serialization::EXPR_CALL, clang::serialization::EXPR_CHARACTER_LITERAL, clang::serialization::EXPR_CHOOSE, clang::serialization::EXPR_COMPOUND_ASSIGN_OPERATOR, clang::serialization::EXPR_COMPOUND_LITERAL, clang::serialization::EXPR_CONDITIONAL_OPERATOR, clang::serialization::EXPR_CSTYLE_CAST, clang::serialization::EXPR_CUDA_KERNEL_CALL, clang::serialization::EXPR_CXX_ADDRSPACE_CAST, clang::serialization::EXPR_CXX_BIND_TEMPORARY, clang::serialization::EXPR_CXX_BOOL_LITERAL, clang::serialization::EXPR_CXX_CONST_CAST, clang::serialization::EXPR_CXX_CONSTRUCT, clang::serialization::EXPR_CXX_DEFAULT_ARG, clang::serialization::EXPR_CXX_DEFAULT_INIT, clang::serialization::EXPR_CXX_DELETE, clang::serialization::EXPR_CXX_DEPENDENT_SCOPE_DECL_REF, clang::serialization::EXPR_CXX_DEPENDENT_SCOPE_MEMBER, clang::serialization::EXPR_CXX_DYNAMIC_CAST, clang::serialization::EXPR_CXX_EXPRESSION_TRAIT, clang::serialization::EXPR_CXX_FUNCTIONAL_CAST, clang::serialization::EXPR_CXX_MEMBER_CALL, clang::serialization::EXPR_CXX_NEW, clang::serialization::EXPR_CXX_NOEXCEPT, clang::serialization::EXPR_CXX_NULL_PTR_LITERAL, clang::serialization::EXPR_CXX_OPERATOR_CALL, clang::serialization::EXPR_CXX_PAREN_LIST_INIT, clang::serialization::EXPR_CXX_PSEUDO_DESTRUCTOR, clang::serialization::EXPR_CXX_REINTERPRET_CAST, clang::serialization::EXPR_CXX_REWRITTEN_BINARY_OPERATOR, clang::serialization::EXPR_CXX_SCALAR_VALUE_INIT, clang::serialization::EXPR_CXX_STATIC_CAST, clang::serialization::EXPR_CXX_STD_INITIALIZER_LIST, clang::serialization::EXPR_CXX_TEMPORARY_OBJECT, clang::serialization::EXPR_CXX_THIS, clang::serialization::EXPR_CXX_THROW, clang::serialization::EXPR_CXX_TYPEID_EXPR, clang::serialization::EXPR_CXX_TYPEID_TYPE, clang::serialization::EXPR_CXX_UNRESOLVED_CONSTRUCT, clang::serialization::EXPR_CXX_UNRESOLVED_LOOKUP, clang::serialization::EXPR_CXX_UNRESOLVED_MEMBER, clang::serialization::EXPR_CXX_UUIDOF_EXPR, clang::serialization::EXPR_CXX_UUIDOF_TYPE, clang::serialization::EXPR_DECL_REF, clang::serialization::EXPR_DESIGNATED_INIT, clang::serialization::EXPR_DESIGNATED_INIT_UPDATE, clang::serialization::EXPR_EXPR_WITH_CLEANUPS, clang::serialization::EXPR_EXT_VECTOR_ELEMENT, clang::serialization::EXPR_FIXEDPOINT_LITERAL, clang::serialization::EXPR_FLOATING_LITERAL, clang::serialization::EXPR_FUNCTION_PARM_PACK, clang::serialization::EXPR_GENERIC_SELECTION, clang::serialization::EXPR_GNU_NULL, clang::serialization::EXPR_IMAGINARY_LITERAL, clang::serialization::EXPR_IMPLICIT_CAST, clang::serialization::EXPR_IMPLICIT_VALUE_INIT, clang::serialization::EXPR_INIT_LIST, clang::serialization::EXPR_INTEGER_LITERAL, clang::serialization::EXPR_LAMBDA, clang::serialization::EXPR_MATERIALIZE_TEMPORARY, clang::serialization::EXPR_MEMBER, clang::serialization::EXPR_NO_INIT, clang::serialization::EXPR_OBJC_ARRAY_LITERAL, clang::serialization::EXPR_OBJC_BOOL_LITERAL, clang::serialization::EXPR_OBJC_BOXED_EXPRESSION, clang::serialization::EXPR_OBJC_DICTIONARY_LITERAL, clang::serialization::EXPR_OBJC_ENCODE, clang::serialization::EXPR_OBJC_IVAR_REF_EXPR, clang::serialization::EXPR_OBJC_KVC_REF_EXPR, clang::serialization::EXPR_OBJC_MESSAGE_EXPR, clang::serialization::EXPR_OBJC_PROPERTY_REF_EXPR, clang::serialization::EXPR_OBJC_PROTOCOL_EXPR, clang::serialization::EXPR_OBJC_SELECTOR_EXPR, clang::serialization::EXPR_OBJC_STRING_LITERAL, clang::serialization::EXPR_OPAQUE_VALUE, clang::serialization::EXPR_PACK_EXPANSION, clang::serialization::EXPR_PACK_INDEXING, clang::serialization::EXPR_PAREN, clang::serialization::EXPR_PAREN_LIST, clang::serialization::EXPR_PREDEFINED, clang::serialization::EXPR_SHUFFLE_VECTOR, clang::serialization::EXPR_SIZEOF_ALIGN_OF, clang::serialization::EXPR_SIZEOF_PACK, clang::serialization::EXPR_STMT, clang::serialization::EXPR_STRING_LITERAL, clang::serialization::EXPR_SUBST_NON_TYPE_TEMPLATE_PARM, clang::serialization::EXPR_SUBST_NON_TYPE_TEMPLATE_PARM_PACK, clang::serialization::EXPR_TYPE_TRAIT, clang::serialization::EXPR_UNARY_OPERATOR, clang::serialization::EXPR_USER_DEFINED_LITERAL, clang::serialization::EXPR_VA_ARG, RECORD, clang::serialization::STMT_ATTRIBUTED, clang::serialization::STMT_BREAK, clang::serialization::STMT_CASE, clang::serialization::STMT_COMPOUND, clang::serialization::STMT_CONTINUE, clang::serialization::STMT_CXX_CATCH, clang::serialization::STMT_CXX_FOR_RANGE, clang::serialization::STMT_CXX_TRY, clang::serialization::STMT_DECL, clang::serialization::STMT_DEFAULT, clang::serialization::STMT_DO, clang::serialization::STMT_FOR, clang::serialization::STMT_GCCASM, clang::serialization::STMT_GOTO, clang::serialization::STMT_IF, clang::serialization::STMT_INDIRECT_GOTO, clang::serialization::STMT_LABEL, clang::serialization::STMT_MSASM, clang::serialization::STMT_NULL, clang::serialization::STMT_NULL_PTR, clang::serialization::STMT_OBJC_AT_SYNCHRONIZED, clang::serialization::STMT_OBJC_AT_THROW, clang::serialization::STMT_OBJC_AT_TRY, clang::serialization::STMT_OBJC_CATCH, clang::serialization::STMT_OBJC_FINALLY, clang::serialization::STMT_OBJC_FOR_COLLECTION, clang::serialization::STMT_REF_PTR, clang::serialization::STMT_RETURN, clang::serialization::STMT_STOP, clang::serialization::STMT_SWITCH, and clang::serialization::STMT_WHILE.

adjustFilenameForRelocatableAST()

static const char * adjustFilenameForRelocatableAST ( const char * Filename, StringRef BaseDir ) static

Adjusts the given filename to only write out the portion of the filename that is not part of the system root directory.

Parameters

Filename the file name to adjust.
BaseDir When non-NULL, the PCH file is a relocatable AST file and the returned filename will be adjusted by this root directory.

Returns

either the original filename (if it needs no adjustment) or the adjusted filename (which points into the Filename parameter).

Definition at line 1186 of file ASTWriter.cpp.

References Filename.

Referenced by clang::ASTWriter::PreparePathForOutput().

BackpatchSignatureAt()

static void BackpatchSignatureAt ( llvm::BitstreamWriter & Stream, const ASTFileSignature & S, uint64_t BitNo ) static

bytes() [1/3]

bytes() [2/3]

static std::string bytes ( const std::vector< bool > & V) static

bytes() [3/3]

template<typename T , typename Allocator >

static StringRef bytes ( const std::vector< T, Allocator > & v) static

cleanPathForOutput()

CreateSLocBufferAbbrev()

static unsigned CreateSLocBufferAbbrev ( llvm::BitstreamWriter & Stream) static

CreateSLocBufferBlobAbbrev()

static unsigned CreateSLocBufferBlobAbbrev ( llvm::BitstreamWriter & Stream, bool Compressed ) static

CreateSLocExpansionAbbrev()

static unsigned CreateSLocExpansionAbbrev ( llvm::BitstreamWriter & Stream) static

CreateSLocFileAbbrev()

static unsigned CreateSLocFileAbbrev ( llvm::BitstreamWriter & Stream) static

emitBlob()

static void emitBlob ( llvm::BitstreamWriter & Stream, StringRef Blob, unsigned SLocBufferBlobCompressedAbbrv, unsigned SLocBufferBlobAbbrv ) static

EmitBlockID()

EmitCXXBaseSpecifiers()

EmitCXXCtorInitializers()

Definition at line 7130 of file ASTWriter.cpp.

References clang::ASTRecordWriter::AddDeclRef(), clang::ASTRecordWriter::AddSourceLocation(), clang::ASTRecordWriter::AddStmt(), clang::ASTRecordWriter::AddTypeSourceInfo(), clang::serialization::CTOR_INITIALIZER_BASE, clang::serialization::CTOR_INITIALIZER_DELEGATING, clang::serialization::CTOR_INITIALIZER_INDIRECT_MEMBER, clang::serialization::CTOR_INITIALIZER_MEMBER, clang::serialization::DECL_CXX_CTOR_INITIALIZERS, clang::ASTRecordWriter::Emit(), clang::Init, and clang::ASTRecordWriter::push_back().

Referenced by clang::ASTRecordWriter::AddCXXCtorInitializers().

EmitRecordID()

emitULEBKeyDataLength()

Emit key length and data length as ULEB-encoded data, and return them as a pair.

Definition at line 2009 of file ASTWriter.cpp.

getDeclForLocalLookup()

getNumberOfModules()

getTypeCodeForTypeClass()

isImportedDeclContext()

IsInternalDeclFromFileContext()

static bool IsInternalDeclFromFileContext ( const Decl * D) static

isLocalIdentifierID()

isLookupResultNotInteresting()

MakeTypeID()

template

shouldIgnoreMacro()