LLVM
8.0.1
|
Describe a collection of units. More...
#include "llvm/DebugInfo/DWARF/DWARFUnit.h"
Public Types | |
using | UnitVector = SmallVectorImpl< std::unique_ptr< DWARFUnit > > |
using | iterator = typename UnitVector::iterator |
using | iterator_range = llvm::iterator_range< typename UnitVector::iterator > |
Public Types inherited from llvm::SmallVectorImpl< std::unique_ptr< DWARFUnit > > | |
using | iterator = typename SuperClass::iterator |
using | const_iterator = typename SuperClass::const_iterator |
using | size_type = typename SuperClass::size_type |
Public Types inherited from llvm::SmallVectorTemplateCommon< T > | |
using | size_type = size_t |
using | difference_type = ptrdiff_t |
using | value_type = T |
using | iterator = T * |
using | const_iterator = const T * |
using | const_reverse_iterator = std::reverse_iterator< const_iterator > |
using | reverse_iterator = std::reverse_iterator< iterator > |
using | reference = T & |
using | const_reference = const T & |
using | pointer = T * |
using | const_pointer = const T * |
Additional Inherited Members | |
Protected Member Functions inherited from llvm::SmallVectorImpl< std::unique_ptr< DWARFUnit > > | |
SmallVectorImpl (unsigned N) | |
Protected Member Functions inherited from llvm::SmallVectorTemplateBase< T, bool > | |
SmallVectorTemplateBase (size_t Size) | |
void | grow (size_t MinSize=0) |
Grow the allocated memory (without initializing new elements), doubling the size of the allocated memory. More... | |
Protected Member Functions inherited from llvm::SmallVectorTemplateCommon< T > | |
SmallVectorTemplateCommon (size_t Size) | |
void | grow_pod (size_t MinCapacity, size_t TSize) |
bool | isSmall () const |
Return true if this is a smallvector which has not had dynamic memory allocated for it. More... | |
void | resetToSmall () |
Put this vector in a state of being small. More... | |
Protected Member Functions inherited from llvm::SmallVectorBase | |
SmallVectorBase ()=delete | |
SmallVectorBase (void *FirstEl, size_t Capacity) | |
void | grow_pod (void *FirstEl, size_t MinCapacity, size_t TSize) |
This is an implementation of the grow() method which only works on POD-like data types and is out of line to reduce code duplication. More... | |
Static Protected Member Functions inherited from llvm::SmallVectorTemplateBase< T, bool > | |
static void | destroy_range (T *S, T *E) |
template<typename It1 , typename It2 > | |
static void | uninitialized_move (It1 I, It1 E, It2 Dest) |
Move the range [I, E) into the uninitialized memory starting with "Dest", constructing elements as needed. More... | |
template<typename It1 , typename It2 > | |
static void | uninitialized_copy (It1 I, It1 E, It2 Dest) |
Copy the range [I, E) onto the uninitialized memory starting with "Dest", constructing elements as needed. More... | |
Protected Attributes inherited from llvm::SmallVectorBase | |
void * | BeginX |
unsigned | Size = 0 |
unsigned | Capacity |
Describe a collection of units.
Intended to hold all units either from .debug_info and .debug_types, or from .debug_info.dwo and .debug_types.dwo.
Definition at line 110 of file DWARFUnit.h.
using llvm::DWARFUnitVector::iterator = typename UnitVector::iterator |
Definition at line 119 of file DWARFUnit.h.
using llvm::DWARFUnitVector::iterator_range = llvm::iterator_range<typename UnitVector::iterator> |
Definition at line 120 of file DWARFUnit.h.
using llvm::DWARFUnitVector::UnitVector = SmallVectorImpl<std::unique_ptr<DWARFUnit> > |
Definition at line 118 of file DWARFUnit.h.
Add an existing DWARFUnit to this UnitVector.
This is used by the DWARF verifier to process unit separately.
Definition at line 121 of file DWARFUnit.cpp.
References llvm::sys::path::begin(), llvm::sys::path::end(), I, and llvm::upper_bound().
Referenced by llvm::DWARFVerifier::handleDebugAbbrev().
void DWARFUnitVector::addUnitsForDWOSection | ( | DWARFContext & | C, |
const DWARFSection & | DWOSection, | ||
DWARFSectionKind | SectionKind, | ||
bool | Lazy = false |
||
) |
Read units from a .debug_info.dwo or .debug_types.dwo section.
Calls made before finishedInfoUnits() are assumed to be for .debug_info.dwo sections, calls after finishedInfoUnits() are for .debug_types.dwo sections. Caller must not mix calls to addUnitsForSection and addUnitsForDWOSection.
Definition at line 48 of file DWARFUnit.cpp.
References llvm::sys::path::begin(), Context, D, llvm::Data, llvm::sys::path::end(), llvm::DWARFUnitHeader::extract(), llvm::DWARFObject::getAddrSection(), llvm::DWARFContext::getDebugAbbrevDWO(), llvm::DWARFContext::getDWARFObj(), llvm::getDWARFUnitIndex(), llvm::DWARFObject::getLineDWOSection(), llvm::DWARFObject::getLocDWOSection(), llvm::DWARFObject::getRangeDWOSection(), llvm::DWARFObject::getStringDWOSection(), llvm::DWARFObject::getStringOffsetDWOSection(), I, llvm::DWARFContext::isLittleEndian(), llvm::DWARFUnitHeader::isTypeUnit(), llvm::DataExtractor::isValidOffset(), llvm::AArch64CC::LE, llvm::AArch64CC::LS, and llvm::ARMBuildAttrs::Section.
Referenced by llvm::DWARFContext::getLineTableForUnit().
void DWARFUnitVector::addUnitsForSection | ( | DWARFContext & | C, |
const DWARFSection & | Section, | ||
DWARFSectionKind | SectionKind | ||
) |
Read units from a .debug_info or .debug_types section.
Calls made before finishedInfoUnits() are assumed to be for .debug_info sections, calls after finishedInfoUnits() are for .debug_types sections. Caller must not mix calls to addUnitsForSection and addUnitsForDWOSection.
Definition at line 37 of file DWARFUnit.cpp.
References D, llvm::DWARFObject::getAddrSection(), llvm::DWARFContext::getDebugAbbrev(), llvm::DWARFContext::getDWARFObj(), llvm::DWARFObject::getLineSection(), llvm::DWARFObject::getLocSection(), llvm::DWARFObject::getRangeSection(), llvm::DWARFObject::getStringOffsetSection(), llvm::DWARFObject::getStringSection(), and llvm::DWARFObject::isLittleEndian().
Referenced by llvm::DWARFContext::getLineTableForUnit().
|
inline |
Indicate that parsing .debug_info[.dwo] is done, and remaining units will be from .debug_types[.dwo].
Definition at line 153 of file DWARFUnit.h.
References llvm::AArch64CC::LE, llvm::AArch64CC::LS, llvm::ARMBuildAttrs::Section, and llvm::size().
Referenced by llvm::DWARFContext::getLineTableForUnit().
|
inline |
Returns number of units from all .debug_info[.dwo] sections.
Definition at line 146 of file DWARFUnit.h.
References llvm::size().
Referenced by llvm::DWARFContext::dwo_info_section_units(), llvm::DWARFContext::dwo_types_section_units(), llvm::DWARFContext::getNumCompileUnits(), llvm::DWARFContext::getNumDWOCompileUnits(), llvm::DWARFContext::info_section_units(), and llvm::DWARFContext::types_section_units().
|
inline |
Returns number of units from all .debug_types[.dwo] sections.
Definition at line 150 of file DWARFUnit.h.
References llvm::size().
Referenced by llvm::DWARFContext::getNumDWOTypeUnits(), and llvm::DWARFContext::getNumTypeUnits().
|
inline |
Returns number of all units held by this instance.
Definition at line 144 of file DWARFUnit.h.
References llvm::size().
DWARFUnit * DWARFUnitVector::getUnitForIndexEntry | ( | const DWARFUnitIndex::Entry & | E | ) |
Definition at line 143 of file DWARFUnit.cpp.
References llvm::sys::path::begin(), llvm::DW_SECT_INFO, llvm::sys::path::end(), llvm::DWARFUnitIndex::Entry::getOffset(), and llvm::upper_bound().
Referenced by llvm::DWARFContext::getDWOCompileUnitForHash().
Definition at line 130 of file DWARFUnit.cpp.
References llvm::sys::path::begin(), llvm::sys::path::end(), and llvm::upper_bound().
Referenced by llvm::DWARFContext::getCompileUnitForOffset(), and llvm::DWARFContext::getDIEForOffset().