#include "bolt/Core/DebugNames.h"
#include "bolt/Core/BinaryContext.h"
#include "llvm/DebugInfo/DWARF/DWARFExpression.h"
#include "llvm/DebugInfo/DWARF/DWARFTypeUnit.h"
#include "llvm/Support/EndianStream.h"
#include "llvm/Support/LEB128.h"
#include <cstdint>
#include <optional>
namespace llvm {
namespace bolt {
DWARF5AcceleratorTable::DWARF5AcceleratorTable(
const bool CreateDebugNames, BinaryContext &BC,
DebugStrWriter &MainBinaryStrWriter)
: … { … }
void DWARF5AcceleratorTable::setCurrentUnit(DWARFUnit &Unit,
const uint64_t UnitStartOffset) { … }
void DWARF5AcceleratorTable::addUnit(DWARFUnit &Unit,
const std::optional<uint64_t> &DWOID) { … }
static bool shouldIncludeVariable(const DWARFUnit &Unit, const DIE &Die) { … }
bool static canProcess(const DWARFUnit &Unit, const DIE &Die,
std::string &NameToUse, const bool TagsOnly) { … }
bool DWARF5AcceleratorTable::canGenerateEntryWithCrossCUReference(
const DWARFUnit &Unit, const DIE &Die,
const DWARFAbbreviationDeclaration::AttributeSpec &AttrSpec) { … }
static uint64_t getNameOffset(BinaryContext &BC, DWARFUnit &Unit,
const uint64_t Index) { … }
static uint64_t getEntryID(const BOLTDWARF5AccelTableData &Entry) { … }
std::optional<BOLTDWARF5AccelTableData *>
DWARF5AcceleratorTable::addAccelTableEntry(
DWARFUnit &Unit, const DIE &Die, const std::optional<uint64_t> &DWOID,
const uint32_t NumberParentsInChain,
std::optional<BOLTDWARF5AccelTableData *> &Parent) { … }
void DWARF5AcceleratorTable::computeBucketCount() { … }
void DWARF5AcceleratorTable::finalize() { … }
std::optional<DWARF5AccelTable::UnitIndexAndEncoding>
DWARF5AcceleratorTable::getIndexForEntry(
const BOLTDWARF5AccelTableData &Value) const { … }
std::optional<DWARF5AccelTable::UnitIndexAndEncoding>
DWARF5AcceleratorTable::getSecondIndexForEntry(
const BOLTDWARF5AccelTableData &Value) const { … }
void DWARF5AcceleratorTable::populateAbbrevsMap() { … }
void DWARF5AcceleratorTable::writeEntry(BOLTDWARF5AccelTableData &Entry) { … }
void DWARF5AcceleratorTable::writeEntries() { … }
void DWARF5AcceleratorTable::writeAugmentationString() { … }
static constexpr uint32_t getDebugNamesHeaderSize() { … }
void DWARF5AcceleratorTable::emitHeader() const { … }
void DWARF5AcceleratorTable::emitCUList() const { … }
void DWARF5AcceleratorTable::emitTUList() const { … }
void DWARF5AcceleratorTable::emitBuckets() const { … }
void DWARF5AcceleratorTable::emitHashes() const { … }
void DWARF5AcceleratorTable::emitStringOffsets() const { … }
void DWARF5AcceleratorTable::emitOffsets() const { … }
void DWARF5AcceleratorTable::emitAbbrevs() { … }
void DWARF5AcceleratorTable::emitData() { … }
void DWARF5AcceleratorTable::emitAugmentationString() const { … }
void DWARF5AcceleratorTable::emitAccelTable() { … }
}
}