|
LLVM
10.0.0
|
A class that represents an address range. More...
#include "llvm/DebugInfo/GSYM/Range.h"
Public Member Functions | |
| AddressRange () | |
| AddressRange (uint64_t S, uint64_t E) | |
| uint64_t | size () const |
| bool | contains (uint64_t Addr) const |
| bool | intersects (const AddressRange &R) const |
| bool | operator== (const AddressRange &R) const |
| bool | operator!= (const AddressRange &R) const |
| bool | operator< (const AddressRange &R) const |
| void | decode (DataExtractor &Data, uint64_t BaseAddr, uint64_t &Offset) |
| AddressRange objects are encoded and decoded to be relative to a base address. More... | |
| void | encode (FileWriter &O, uint64_t BaseAddr) const |
Static Public Member Functions | |
| static void | skip (DataExtractor &Data, uint64_t &Offset) |
| Skip an address range object in the specified data a the specified offset. More... | |
Public Attributes | |
| uint64_t | Start |
| uint64_t | End |
A class that represents an address range.
The range is specified using a start and an end address.
|
inline |
|
inline |
Definition at line 38 of file Range.h.
References End.
Referenced by llvm::gsym::AddressRanges::empty().
| void AddressRange::decode | ( | DataExtractor & | Data, |
| uint64_t | BaseAddr, | ||
| uint64_t & | Offset | ||
| ) |
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.
Definition at line 76 of file Range.cpp.
References llvm::DataExtractor::getULEB128(), and Size.
Referenced by llvm::gsym::AddressRanges::end(), and operator<().
| void AddressRange::encode | ( | FileWriter & | O, |
| uint64_t | BaseAddr | ||
| ) | const |
Definition at line 70 of file Range.cpp.
References assert().
Referenced by llvm::gsym::AddressRanges::end(), and operator<().
|
inline |
|
inline |
|
inline |
Definition at line 49 of file Range.h.
References llvm::Data, decode(), encode(), End, llvm::RISCVFenceField::O, llvm::gsym::operator<<(), skip(), and Start.
|
inline |
|
inline |
Definition at line 37 of file Range.h.
References Start.
Referenced by llvm::gsym::AddressRanges::contains(), llvm::gsym::AddressRanges::insert(), and llvm::gsym::FunctionInfo::size().
|
static |
Skip an address range object in the specified data a the specified offset.
| Data | The binary stream to read the data from. |
| Offset | The byte offset within Data. |
Definition at line 104 of file Range.cpp.
References llvm::DataExtractor::getULEB128().
Referenced by llvm::gsym::AddressRanges::end(), operator<(), and llvm::gsym::AddressRanges::skip().
| uint64_t llvm::gsym::AddressRange::End |
Definition at line 34 of file Range.h.
Referenced by contains(), llvm::gsym::AddressRanges::contains(), llvm::gsym::FunctionInfo::decode(), llvm::gsym::FunctionInfo::endAddress(), llvm::gsym::AddressRanges::insert(), intersects(), llvm::gsym::FunctionInfo::lookup(), operator<(), llvm::gsym::operator<<(), operator==(), llvm::gsym::FunctionInfo::setEndAddress(), and llvm::gsym::FunctionInfo::setSize().
| uint64_t llvm::gsym::AddressRange::Start |
Definition at line 33 of file Range.h.
Referenced by llvm::gsym::AddressRanges::contains(), llvm::gsym::FunctionInfo::decode(), llvm::gsym::FunctionInfo::encode(), llvm::gsym::AddressRanges::insert(), intersects(), llvm::gsym::FunctionInfo::lookup(), operator<(), llvm::gsym::operator<<(), operator==(), llvm::gsym::FunctionInfo::setSize(), llvm::gsym::FunctionInfo::setStartAddress(), size(), and llvm::gsym::FunctionInfo::startAddress().
1.8.13