20 uint8_t AddressSize)
const {
36 "invalid range list offset 0x%" PRIx64, *offset_ptr);
41 "range list at offset 0x%" PRIx64, *offset_ptr))
46 Entry.SectionIndex = -1ULL;
54 if (*offset_ptr != prev_offset + 2 * AddressSize) {
57 "invalid range list entry at offset 0x%" PRIx64,
60 if (Entry.isEndOfListEntry())
62 Entries.push_back(Entry);
69 switch (AddressSize) {
71 AddrFmt =
"%08" PRIx64
" %04" PRIx64
" %04" PRIx64
"\n";
74 AddrFmt =
"%08" PRIx64
" %08" PRIx64
" %08" PRIx64
"\n";
77 AddrFmt =
"%08" PRIx64
" %016" PRIx64
" %016" PRIx64
"\n";
83 OS <<
format(AddrFmt, Offset, RLE.StartAddress, RLE.EndAddress);
84 OS <<
format(
"%08" PRIx64
" <End of list>\n", Offset);
88 std::optional<object::SectionedAddress> BaseAddr)
const {
94 if (RLE.isBaseAddressSelectionEntry(AddressSize)) {
95 BaseAddr = {RLE.EndAddress, RLE.SectionIndex};
100 E.
LowPC = RLE.StartAddress;
101 if (E.
LowPC == Tombstone)
103 E.
HighPC = RLE.EndAddress;
109 if (BaseAddr->Address == Tombstone)
111 E.
LowPC += BaseAddr->Address;
112 E.
HighPC += BaseAddr->Address;
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
static Error checkAddressSizeSupported(unsigned AddressSize, std::error_code EC, char const *Fmt, const Ts &...Vals)
static bool isAddressSizeSupported(unsigned AddressSize)
Error extract(const DWARFDataExtractor &data, uint64_t *offset_ptr)
DWARFAddressRangesVector getAbsoluteRanges(std::optional< object::SectionedAddress > BaseAddr) const
getAbsoluteRanges - Returns absolute address ranges defined by this range list.
void dump(raw_ostream &OS) const
Lightweight error class with error context and mandatory checking.
static ErrorSuccess success()
Create a success value.
This class implements an extremely fast bulk output stream that can only output to a stream.
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
uint64_t computeTombstoneAddress(uint8_t AddressByteSize)
This is an optimization pass for GlobalISel generic memory operations.
std::vector< DWARFAddressRange > DWARFAddressRangesVector
DWARFAddressRangesVector - represents a set of absolute address ranges.
Error createStringError(std::error_code EC, char const *Fmt, const Ts &... Vals)
Create formatted StringError object.
format_object< Ts... > format(const char *Fmt, const Ts &... Vals)
These are helper functions used to produce formatted output.
bool isBaseAddressSelectionEntry(uint8_t AddressSize) const
A base address selection entry consists of:
uint64_t StartAddress
A beginning address offset.