LLVM
5.0.0
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
lib
DebugInfo
DWARF
DWARFDataExtractor.cpp
Go to the documentation of this file.
1
//===- DWARFDataExtractor.cpp ---------------------------------------------===//
2
//
3
// The LLVM Compiler Infrastructure
4
//
5
// This file is distributed under the University of Illinois Open Source
6
// License. See LICENSE.TXT for details.
7
//
8
//===----------------------------------------------------------------------===//
9
10
#include "
llvm/DebugInfo/DWARF/DWARFDataExtractor.h
"
11
12
using namespace
llvm;
13
14
uint64_t
DWARFDataExtractor::getRelocatedValue
(
uint32_t
Size
,
uint32_t
*Off,
15
uint64_t *SecNdx)
const
{
16
if
(!RelocMap)
17
return
getUnsigned
(Off, Size);
18
RelocAddrMap::const_iterator
AI = RelocMap->
find
(*Off);
19
if
(AI == RelocMap->
end
())
20
return
getUnsigned
(Off, Size);
21
if
(SecNdx)
22
*SecNdx = AI->second.SectionIndex;
23
return
getUnsigned
(Off, Size) + AI->second.Value;
24
}
llvm::DWARFDataExtractor::getRelocatedValue
uint64_t getRelocatedValue(uint32_t Size, uint32_t *Off, uint64_t *SectionIndex=nullptr) const
Extracts a value and applies a relocation to the result if one exists for the given offset...
Definition:
DWARFDataExtractor.cpp:14
llvm::DenseMapBase::find
iterator find(const_arg_type_t< KeyT > Val)
Definition:
DenseMap.h:131
uint32_t
DWARFDataExtractor.h
llvm::AMDGPU::CodeObject::Kernel::Arg::Key::Size
constexpr char Size[]
Key for Kernel::Arg::Metadata::mSize.
Definition:
AMDGPUCodeObjectMetadata.h:154
llvm::DenseMapBase::end
iterator end()
Definition:
DenseMap.h:73
llvm::DenseMapIterator
Definition:
DenseMap.h:51
llvm::DataExtractor::getUnsigned
uint64_t getUnsigned(uint32_t *offset_ptr, uint32_t byte_size) const
Extract an unsigned integer of size byte_size from *offset_ptr.
Definition:
DataExtractor.cpp:99
Generated on Fri Sep 1 2017 14:13:34 for LLVM by
1.8.6