LLVM 20.0.0git
|
#include "llvm/DebugInfo/PDB/Native/DbiModuleDescriptorBuilder.h"
Public Types | |
using | MergeSymbolsCallback = Error(*)(void *Ctx, void *Symbols, BinaryStreamWriter &Writer) |
Friends | |
class | DbiStreamBuilder |
Definition at line 63 of file DbiModuleDescriptorBuilder.h.
using llvm::pdb::DbiModuleDescriptorBuilder::MergeSymbolsCallback = Error (*)(void *Ctx, void *Symbols, BinaryStreamWriter &Writer) |
Definition at line 79 of file DbiModuleDescriptorBuilder.h.
DbiModuleDescriptorBuilder::DbiModuleDescriptorBuilder | ( | StringRef | ModuleName, |
uint32_t | ModIndex, | ||
msf::MSFBuilder & | Msf | ||
) |
Definition at line 43 of file DbiModuleDescriptorBuilder.cpp.
References llvm::pdb::ModuleInfoHeader::Mod, and string.
|
default |
|
delete |
void DbiModuleDescriptorBuilder::addDebugSubsection | ( | const codeview::DebugSubsectionRecord & | SubsectionContents | ) |
Definition at line 219 of file DbiModuleDescriptorBuilder.cpp.
void llvm::pdb::DbiModuleDescriptorBuilder::addDebugSubsection | ( | std::shared_ptr< codeview::DebugSubsection > | Subsection | ) |
void DbiModuleDescriptorBuilder::addSymbol | ( | codeview::CVSymbol | Symbol | ) |
Definition at line 70 of file DbiModuleDescriptorBuilder.cpp.
References addSymbolsInBulk().
void DbiModuleDescriptorBuilder::addSymbolsInBulk | ( | ArrayRef< uint8_t > | BulkSymbols | ) |
Definition at line 75 of file DbiModuleDescriptorBuilder.cpp.
References llvm::codeview::alignOf(), assert(), llvm::ArrayRef< T >::empty(), and llvm::ArrayRef< T >::size().
Referenced by addSymbol().
void DbiModuleDescriptorBuilder::addUnmergedSymbols | ( | void * | SymSrc, |
uint32_t | SymLength | ||
) |
Definition at line 89 of file DbiModuleDescriptorBuilder.cpp.
References llvm::codeview::alignOf(), and assert().
uint32_t DbiModuleDescriptorBuilder::calculateSerializedLength | ( | ) | const |
Definition at line 113 of file DbiModuleDescriptorBuilder.cpp.
References llvm::alignTo().
Error DbiModuleDescriptorBuilder::commit | ( | BinaryStreamWriter & | ModiWriter | ) |
Commit the DBI descriptor to the DBI stream.
Definition at line 150 of file DbiModuleDescriptorBuilder.cpp.
References llvm::codeview::EC, llvm::BinaryStreamWriter::padToAlignment(), llvm::Error::success(), llvm::BinaryStreamWriter::writeCString(), and llvm::BinaryStreamWriter::writeObject().
Error DbiModuleDescriptorBuilder::commitSymbolStream | ( | const msf::MSFLayout & | MsfLayout, |
WritableBinaryStreamRef | MsfBuffer | ||
) |
Commit the accumulated symbols to the module symbol stream.
Safe to call in parallel on different DbiModuleDescriptorBuilder objects. Only modifies the pre-allocated stream in question.
Definition at line 164 of file DbiModuleDescriptorBuilder.cpp.
References llvm::codeview::alignOf(), assert(), llvm::BinaryStreamWriter::bytesRemaining(), llvm::msf::WritableMappedBlockStream::createIndexedStream(), llvm::COFF::DEBUG_SECTION_MAGIC, E, llvm::codeview::EC, llvm::pdb::Fixup, llvm::msf::MSFBuilder::getAllocator(), llvm::BinaryStreamWriter::getOffset(), llvm::pdb::kInvalidStreamIndex, llvm::pdb::ModuleInfoHeader::ModDiStream, llvm::Ref, llvm::BinaryStreamWriter::setOffset(), llvm::pdb::stream_too_long, llvm::Error::success(), Sym, llvm::BinaryStreamWriter::writeBytes(), and llvm::BinaryStreamWriter::writeInteger().
void DbiModuleDescriptorBuilder::finalize | ( | ) |
Definition at line 120 of file DbiModuleDescriptorBuilder.cpp.
References llvm::pdb::ModuleInfoHeader::C11Bytes, llvm::pdb::ModuleInfoHeader::C13Bytes, llvm::pdb::ModuleInfoHeader::FileNameOffs, llvm::pdb::ModuleInfoHeader::Flags, getNextSymbolOffset(), llvm::pdb::kInvalidStreamIndex, llvm::pdb::ModuleInfoHeader::Mod, llvm::pdb::ModuleInfoHeader::ModDiStream, llvm::pdb::ModuleInfoHeader::NumFiles, llvm::pdb::ModuleInfoHeader::PdbFilePathNI, llvm::pdb::SourceFiles, llvm::pdb::ModuleInfoHeader::SrcFileNameNI, and llvm::pdb::ModuleInfoHeader::SymBytes.
Error DbiModuleDescriptorBuilder::finalizeMsfLayout | ( | ) |
Definition at line 137 of file DbiModuleDescriptorBuilder.cpp.
References llvm::msf::MSFBuilder::addStream(), calculateDiSymbolStreamSize(), llvm::pdb::kInvalidStreamIndex, llvm::pdb::ModuleInfoHeader::ModDiStream, and llvm::Error::success().
|
inline |
Definition at line 109 of file DbiModuleDescriptorBuilder.h.
References llvm::pdb::ModuleInfoHeader::Mod.
|
inline |
Definition at line 106 of file DbiModuleDescriptorBuilder.h.
|
inline |
Return the offset within the module symbol stream of the next symbol record passed to addSymbol.
Add four to account for the signature.
Definition at line 117 of file DbiModuleDescriptorBuilder.h.
Referenced by finalize().
|
inline |
Definition at line 107 of file DbiModuleDescriptorBuilder.h.
uint16_t DbiModuleDescriptorBuilder::getStreamIndex | ( | ) | const |
Definition at line 53 of file DbiModuleDescriptorBuilder.cpp.
References llvm::pdb::ModuleInfoHeader::ModDiStream.
|
delete |
void DbiModuleDescriptorBuilder::setFirstSectionContrib | ( | const SectionContrib & | SC | ) |
Definition at line 65 of file DbiModuleDescriptorBuilder.cpp.
References llvm::pdb::ModuleInfoHeader::SC.
|
inline |
Definition at line 82 of file DbiModuleDescriptorBuilder.h.
void DbiModuleDescriptorBuilder::setObjFileName | ( | StringRef | Name | ) |
Definition at line 57 of file DbiModuleDescriptorBuilder.cpp.
References Name.
void DbiModuleDescriptorBuilder::setPdbFilePathNI | ( | uint32_t | NI | ) |
Definition at line 61 of file DbiModuleDescriptorBuilder.cpp.
|
inline |
Definition at line 87 of file DbiModuleDescriptorBuilder.h.
|
inline |
Definition at line 111 of file DbiModuleDescriptorBuilder.h.
|
friend |
Definition at line 64 of file DbiModuleDescriptorBuilder.h.