llvm/llvm/lib/DebugInfo/DWARF/DWARFDebugFrame.cpp

//===- DWARFDebugFrame.h - Parsing of .debug_frame ------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//

#include "llvm/DebugInfo/DWARF/DWARFDebugFrame.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/BinaryFormat/Dwarf.h"
#include "llvm/DebugInfo/DIContext.h"
#include "llvm/DebugInfo/DWARF/DWARFDataExtractor.h"
#include "llvm/Support/Compiler.h"
#include "llvm/Support/DataExtractor.h"
#include "llvm/Support/Errc.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/Format.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
#include <cassert>
#include <cinttypes>
#include <cstdint>
#include <optional>

usingnamespacellvm;
usingnamespacedwarf;

static void printRegister(raw_ostream &OS, DIDumpOptions DumpOpts,
                          unsigned RegNum) {}

UnwindLocation UnwindLocation::createUnspecified() {}

UnwindLocation UnwindLocation::createUndefined() {}

UnwindLocation UnwindLocation::createSame() {}

UnwindLocation UnwindLocation::createIsConstant(int32_t Value) {}

UnwindLocation UnwindLocation::createIsCFAPlusOffset(int32_t Offset) {}

UnwindLocation UnwindLocation::createAtCFAPlusOffset(int32_t Offset) {}

UnwindLocation
UnwindLocation::createIsRegisterPlusOffset(uint32_t RegNum, int32_t Offset,
                                           std::optional<uint32_t> AddrSpace) {}

UnwindLocation
UnwindLocation::createAtRegisterPlusOffset(uint32_t RegNum, int32_t Offset,
                                           std::optional<uint32_t> AddrSpace) {}

UnwindLocation UnwindLocation::createIsDWARFExpression(DWARFExpression Expr) {}

UnwindLocation UnwindLocation::createAtDWARFExpression(DWARFExpression Expr) {}

void UnwindLocation::dump(raw_ostream &OS, DIDumpOptions DumpOpts) const {}

raw_ostream &llvm::dwarf::operator<<(raw_ostream &OS,
                                     const UnwindLocation &UL) {}

bool UnwindLocation::operator==(const UnwindLocation &RHS) const {}

void RegisterLocations::dump(raw_ostream &OS, DIDumpOptions DumpOpts) const {}

raw_ostream &llvm::dwarf::operator<<(raw_ostream &OS,
                                     const RegisterLocations &RL) {}

void UnwindRow::dump(raw_ostream &OS, DIDumpOptions DumpOpts,
                     unsigned IndentLevel) const {}

raw_ostream &llvm::dwarf::operator<<(raw_ostream &OS, const UnwindRow &Row) {}

void UnwindTable::dump(raw_ostream &OS, DIDumpOptions DumpOpts,
                       unsigned IndentLevel) const {}

raw_ostream &llvm::dwarf::operator<<(raw_ostream &OS, const UnwindTable &Rows) {}

Expected<UnwindTable> UnwindTable::create(const FDE *Fde) {}

Expected<UnwindTable> UnwindTable::create(const CIE *Cie) {}

// See DWARF standard v3, section 7.23
const uint8_t DWARF_CFI_PRIMARY_OPCODE_MASK =;
const uint8_t DWARF_CFI_PRIMARY_OPERAND_MASK =;

Error CFIProgram::parse(DWARFDataExtractor Data, uint64_t *Offset,
                        uint64_t EndOffset) {}

StringRef CFIProgram::callFrameString(unsigned Opcode) const {}

const char *CFIProgram::operandTypeString(CFIProgram::OperandType OT) {}

llvm::Expected<uint64_t>
CFIProgram::Instruction::getOperandAsUnsigned(const CFIProgram &CFIP,
                                              uint32_t OperandIdx) const {}

llvm::Expected<int64_t>
CFIProgram::Instruction::getOperandAsSigned(const CFIProgram &CFIP,
                                            uint32_t OperandIdx) const {}

Error UnwindTable::parseRows(const CFIProgram &CFIP, UnwindRow &Row,
                             const RegisterLocations *InitialLocs) {}

ArrayRef<CFIProgram::OperandType[CFIProgram::MaxOperands]>
CFIProgram::getOperandTypes() {}

/// Print \p Opcode's operand number \p OperandIdx which has value \p Operand.
void CFIProgram::printOperand(raw_ostream &OS, DIDumpOptions DumpOpts,
                              const Instruction &Instr, unsigned OperandIdx,
                              uint64_t Operand,
                              std::optional<uint64_t> &Address) const {}

void CFIProgram::dump(raw_ostream &OS, DIDumpOptions DumpOpts,
                      unsigned IndentLevel,
                      std::optional<uint64_t> Address) const {}

// Returns the CIE identifier to be used by the requested format.
// CIE ids for .debug_frame sections are defined in Section 7.24 of DWARFv5.
// For CIE ID in .eh_frame sections see
// https://refspecs.linuxfoundation.org/LSB_5.0.0/LSB-Core-generic/LSB-Core-generic/ehframechpt.html
constexpr uint64_t getCIEId(bool IsDWARF64, bool IsEH) {}

void CIE::dump(raw_ostream &OS, DIDumpOptions DumpOpts) const {}

void FDE::dump(raw_ostream &OS, DIDumpOptions DumpOpts) const {}

DWARFDebugFrame::DWARFDebugFrame(Triple::ArchType Arch,
    bool IsEH, uint64_t EHFrameAddress)
    :{}

DWARFDebugFrame::~DWARFDebugFrame() = default;

static void LLVM_ATTRIBUTE_UNUSED dumpDataAux(DataExtractor Data,
                                              uint64_t Offset, int Length) {}

Error DWARFDebugFrame::parse(DWARFDataExtractor Data) {}

FrameEntry *DWARFDebugFrame::getEntryAtOffset(uint64_t Offset) const {}

void DWARFDebugFrame::dump(raw_ostream &OS, DIDumpOptions DumpOpts,
                           std::optional<uint64_t> Offset) const {}