summaryrefslogtreecommitdiffstats
path: root/llvm/lib/XRay/InstrumentationMap.cpp
diff options
context:
space:
mode:
authorIgor Kudrin <ikudrin@accesssoftek.com>2019-08-06 10:49:40 +0000
committerIgor Kudrin <ikudrin@accesssoftek.com>2019-08-06 10:49:40 +0000
commitf26a70a5e7b7b8715eadcb6dec3ff39a267fc666 (patch)
treed178246aab19aded049ff79111d90654bdbfe497 /llvm/lib/XRay/InstrumentationMap.cpp
parentf5f35c5cd110e22c4b216ec1dc53255e32adc011 (diff)
downloadbcm5719-llvm-f26a70a5e7b7b8715eadcb6dec3ff39a267fc666.tar.gz
bcm5719-llvm-f26a70a5e7b7b8715eadcb6dec3ff39a267fc666.zip
Switch LLVM to use 64-bit offsets (2/5)
This updates all libraries and tools in LLVM Core to use 64-bit offsets which directly or indirectly come to DataExtractor. Differential Revision: https://reviews.llvm.org/D65638 llvm-svn: 368014
Diffstat (limited to 'llvm/lib/XRay/InstrumentationMap.cpp')
-rw-r--r--llvm/lib/XRay/InstrumentationMap.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/XRay/InstrumentationMap.cpp b/llvm/lib/XRay/InstrumentationMap.cpp
index fe5e941f7ea..7de953d46b7 100644
--- a/llvm/lib/XRay/InstrumentationMap.cpp
+++ b/llvm/lib/XRay/InstrumentationMap.cpp
@@ -118,7 +118,7 @@ loadObj(StringRef Filename, object::OwningBinary<object::ObjectFile> &ObjFile,
"an XRay sled entry in ELF64."),
std::make_error_code(std::errc::executable_format_error));
- auto RelocateOrElse = [&](uint32_t Offset, uint64_t Address) {
+ auto RelocateOrElse = [&](uint64_t Offset, uint64_t Address) {
if (!Address) {
uint64_t A = I->getAddress() + C - Contents.bytes_begin() + Offset;
RelocMap::const_iterator R = Relocs.find(A);
@@ -136,10 +136,10 @@ loadObj(StringRef Filename, object::OwningBinary<object::ObjectFile> &ObjFile,
8);
Sleds.push_back({});
auto &Entry = Sleds.back();
- uint32_t OffsetPtr = 0;
- uint32_t AddrOff = OffsetPtr;
+ uint64_t OffsetPtr = 0;
+ uint64_t AddrOff = OffsetPtr;
Entry.Address = RelocateOrElse(AddrOff, Extractor.getU64(&OffsetPtr));
- uint32_t FuncOff = OffsetPtr;
+ uint64_t FuncOff = OffsetPtr;
Entry.Function = RelocateOrElse(FuncOff, Extractor.getU64(&OffsetPtr));
auto Kind = Extractor.getU8(&OffsetPtr);
static constexpr SledEntry::FunctionKinds Kinds[] = {
OpenPOWER on IntegriCloud