struct AddressRange

Declaration

struct AddressRange { /* full declaration omitted */ };

Description

A class that represents an address range. The range is specified using a start and an end address.

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:32

Member Variables

public uint64_t Start
public uint64_t End

Method Overview

  • public AddressRange()
  • public AddressRange(uint64_t S, uint64_t E)
  • public bool contains(uint64_t Addr) const
  • public void decode(llvm::DataExtractor & Data, uint64_t BaseAddr, uint64_t & Offset)
  • public void encode(llvm::gsym::FileWriter & O, uint64_t BaseAddr) const
  • public bool intersects(const llvm::gsym::AddressRange & R) const
  • public uint64_t size() const
  • public static void skip(llvm::DataExtractor & Data, uint64_t & Offset)

Methods

AddressRange()

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:35

AddressRange(uint64_t S, uint64_t E)

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:36

Parameters

uint64_t S
uint64_t E

bool contains(uint64_t Addr) const

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:38

Parameters

uint64_t Addr

void decode(llvm::DataExtractor& Data,
            uint64_t BaseAddr,
            uint64_t& Offset)

Description

AddressRange objects are encoded and decoded to be relative to a base address. This will be the FunctionInfo's start address if the AddressRange is directly contained in a FunctionInfo, or a base address of the containing parent AddressRange or AddressRanges. This allows address ranges to be efficiently encoded using ULEB128 encodings as we encode the offset and size of each range instead of full addresses. This also makes encoded addresses easy to relocate as we just need to relocate one base address. @ {

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:61

Parameters

llvm::DataExtractor& Data
uint64_t BaseAddr
uint64_t& Offset

void encode(llvm::gsym::FileWriter& O,
            uint64_t BaseAddr) const

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:62

Parameters

llvm::gsym::FileWriter& O
uint64_t BaseAddr

bool intersects(
    const llvm::gsym::AddressRange& R) const

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:39

Parameters

const llvm::gsym::AddressRange& R

uint64_t size() const

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:37

static void skip(llvm::DataExtractor& Data,
                 uint64_t& Offset)

Description

Skip an address range object in the specified data a the specified offset.

Declared at: llvm/include/llvm/DebugInfo/GSYM/Range.h:71

Parameters

llvm::DataExtractor& Data
The binary stream to read the data from.
uint64_t& Offset
The byte offset within \a Data.