summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp10
-rw-r--r--llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp37
-rw-r--r--llvm/lib/Support/DataExtractor.cpp85
3 files changed, 0 insertions, 132 deletions
diff --git a/llvm/lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp b/llvm/lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp
index b836c795187..875f5e9989a 100644
--- a/llvm/lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp
+++ b/llvm/lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp
@@ -622,16 +622,6 @@ DWARFDebugNames::NameIndex::getEntry(uint64_t *Offset) const {
return std::move(E);
}
-// A temporarily method to preserve compatibility with existing code.
-// Will be removed when the migration to 64-bit offsets is finished.
-Expected<DWARFDebugNames::Entry>
-DWARFDebugNames::NameIndex::getEntry(uint32_t *Offset) const {
- uint64_t Offset64 = *Offset;
- auto Result = getEntry(&Offset64);
- *Offset = Offset64;
- return Result;
-}
-
DWARFDebugNames::NameTableEntry
DWARFDebugNames::NameIndex::getNameTableEntry(uint32_t Index) const {
assert(0 < Index && Index <= Hdr.NameCount);
diff --git a/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp b/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
index 5abae7f3725..26090638b34 100644
--- a/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
+++ b/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
@@ -718,40 +718,3 @@ Optional<uint64_t> DWARFFormValue::getAsReferenceUVal() const {
return None;
return Value.uval;
}
-
-// The following is temporary code aimed to preserve compatibility with
-// existing code which uses 32-bit offsets.
-// It will be removed when migration to 64-bit offsets is finished.
-
-namespace {
-
-class WrapOffset {
- uint64_t Offset64;
- uint32_t *Offset32;
-
-public:
- WrapOffset(uint32_t *Offset)
- : Offset64(*Offset), Offset32(Offset) {}
- ~WrapOffset() { *Offset32 = Offset64; }
- operator uint64_t *() { return &Offset64; }
-};
-
-}
-
-DWARFFormValue DWARFFormValue::createFromUnit(dwarf::Form F, const DWARFUnit *U,
- uint32_t *OffsetPtr) {
- return createFromUnit(F, U, WrapOffset(OffsetPtr));
-}
-
-bool DWARFFormValue::skipValue(dwarf::Form Form, DataExtractor DebugInfoData,
- uint32_t *OffsetPtr,
- const dwarf::FormParams Params) {
- return skipValue(Form, DebugInfoData, WrapOffset(OffsetPtr), Params);
-}
-
-bool DWARFFormValue::extractValue(const DWARFDataExtractor &Data,
- uint32_t *OffsetPtr, dwarf::FormParams FP,
- const DWARFContext *Ctx,
- const DWARFUnit *CU) {
- return extractValue(Data, WrapOffset(OffsetPtr), FP, Ctx, CU);
-}
diff --git a/llvm/lib/Support/DataExtractor.cpp b/llvm/lib/Support/DataExtractor.cpp
index 73c215ea05a..1d88ec06151 100644
--- a/llvm/lib/Support/DataExtractor.cpp
+++ b/llvm/lib/Support/DataExtractor.cpp
@@ -171,88 +171,3 @@ int64_t DataExtractor::getSLEB128(uint64_t *offset_ptr) const {
*offset_ptr += bytes_read;
return result;
}
-
-// The following is temporary code aimed to preserve compatibility with
-// existing code which uses 32-bit offsets.
-// It will be removed when migration to 64-bit offsets is finished.
-
-namespace {
-
-class WrapOffset {
- uint64_t offset64;
- uint32_t *offset32_ptr;
-
-public:
- WrapOffset(uint32_t *offset_ptr)
- : offset64(*offset_ptr), offset32_ptr(offset_ptr) {}
- ~WrapOffset() { *offset32_ptr = offset64; }
- operator uint64_t *() { return &offset64; }
-};
-
-}
-
-uint8_t DataExtractor::getU8(uint32_t *offset_ptr) const {
- return getU8(WrapOffset(offset_ptr));
-}
-
-uint8_t *
-DataExtractor::getU8(uint32_t *offset_ptr, uint8_t *dst, uint32_t count) const {
- return getU8(WrapOffset(offset_ptr), dst, count);
-}
-
-uint16_t DataExtractor::getU16(uint32_t *offset_ptr) const {
- return getU16(WrapOffset(offset_ptr));
-}
-
-uint16_t *DataExtractor::getU16(uint32_t *offset_ptr, uint16_t *dst,
- uint32_t count) const {
- return getU16(WrapOffset(offset_ptr), dst, count);
-}
-
-uint32_t DataExtractor::getU24(uint32_t *offset_ptr) const {
- return getU24(WrapOffset(offset_ptr));
-}
-
-uint32_t DataExtractor::getU32(uint32_t *offset_ptr) const {
- return getU32(WrapOffset(offset_ptr));
-}
-
-uint32_t *DataExtractor::getU32(uint32_t *offset_ptr, uint32_t *dst,
- uint32_t count) const {
- return getU32(WrapOffset(offset_ptr), dst, count);
-}
-
-uint64_t DataExtractor::getU64(uint32_t *offset_ptr) const {
- return getU64(WrapOffset(offset_ptr));
-}
-
-uint64_t *DataExtractor::getU64(uint32_t *offset_ptr, uint64_t *dst,
- uint32_t count) const {
- return getU64(WrapOffset(offset_ptr), dst, count);
-}
-
-uint64_t
-DataExtractor::getUnsigned(uint32_t *offset_ptr, uint32_t byte_size) const {
- return getUnsigned(WrapOffset(offset_ptr), byte_size);
-}
-
-int64_t
-DataExtractor::getSigned(uint32_t *offset_ptr, uint32_t byte_size) const {
- return getSigned(WrapOffset(offset_ptr), byte_size);
-}
-
-const char *DataExtractor::getCStr(uint32_t *offset_ptr) const {
- return getCStr(WrapOffset(offset_ptr));
-}
-
-StringRef DataExtractor::getCStrRef(uint32_t *offset_ptr) const {
- return getCStrRef(WrapOffset(offset_ptr));
-}
-
-uint64_t DataExtractor::getULEB128(uint32_t *offset_ptr) const {
- return getULEB128(WrapOffset(offset_ptr));
-}
-
-int64_t DataExtractor::getSLEB128(uint32_t *offset_ptr) const {
- return getSLEB128(WrapOffset(offset_ptr));
-}
OpenPOWER on IntegriCloud