LLDB  mainline
Public Member Functions | Static Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
UnwindAssemblyInstEmulation Class Reference

#include <UnwindAssemblyInstEmulation.h>

Inheritance diagram for UnwindAssemblyInstEmulation:
Inheritance graph
[legend]
Collaboration diagram for UnwindAssemblyInstEmulation:
Collaboration graph
[legend]

Public Member Functions

 ~UnwindAssemblyInstEmulation () override=default
 
bool GetNonCallSiteUnwindPlanFromAssembly (lldb_private::AddressRange &func, lldb_private::Thread &thread, lldb_private::UnwindPlan &unwind_plan) override
 
bool GetNonCallSiteUnwindPlanFromAssembly (lldb_private::AddressRange &func, uint8_t *opcode_data, size_t opcode_size, lldb_private::UnwindPlan &unwind_plan)
 
bool AugmentUnwindPlanFromCallSite (lldb_private::AddressRange &func, lldb_private::Thread &thread, lldb_private::UnwindPlan &unwind_plan) override
 
bool GetFastUnwindPlan (lldb_private::AddressRange &func, lldb_private::Thread &thread, lldb_private::UnwindPlan &unwind_plan) override
 
bool FirstNonPrologueInsn (lldb_private::AddressRange &func, const lldb_private::ExecutionContext &exe_ctx, lldb_private::Address &first_non_prologue_insn) override
 
lldb_private::ConstString GetPluginName () override
 
- Public Member Functions inherited from lldb_private::PluginInterface
 PluginInterface ()=default
 
virtual ~PluginInterface ()=default
 
 PluginInterface (const PluginInterface &)=delete
 
PluginInterfaceoperator= (const PluginInterface &)=delete
 

Static Public Member Functions

static lldb_private::UnwindAssemblyCreateInstance (const lldb_private::ArchSpec &arch)
 
static void Initialize ()
 
static void Terminate ()
 
static lldb_private::ConstString GetPluginNameStatic ()
 
static const char * GetPluginDescriptionStatic ()
 
- Static Public Member Functions inherited from lldb_private::UnwindAssembly
static lldb::UnwindAssemblySP FindPlugin (const ArchSpec &arch)
 

Private Types

typedef std::map< uint64_t, uint64_t > PushedRegisterToAddrMap
 
typedef std::map< uint64_t, lldb_private::RegisterValueRegisterValueMap
 

Private Member Functions

 UnwindAssemblyInstEmulation (const lldb_private::ArchSpec &arch, lldb_private::EmulateInstruction *inst_emulator)
 
size_t WriteMemory (lldb_private::EmulateInstruction *instruction, const lldb_private::EmulateInstruction::Context &context, lldb::addr_t addr, const void *dst, size_t length)
 
bool ReadRegister (lldb_private::EmulateInstruction *instruction, const lldb_private::RegisterInfo *reg_info, lldb_private::RegisterValue &reg_value)
 
bool WriteRegister (lldb_private::EmulateInstruction *instruction, const lldb_private::EmulateInstruction::Context &context, const lldb_private::RegisterInfo *reg_info, const lldb_private::RegisterValue &reg_value)
 
void SetRegisterValue (const lldb_private::RegisterInfo &reg_info, const lldb_private::RegisterValue &reg_value)
 
bool GetRegisterValue (const lldb_private::RegisterInfo &reg_info, lldb_private::RegisterValue &reg_value)
 

Static Private Member Functions

static size_t ReadMemory (lldb_private::EmulateInstruction *instruction, void *baton, const lldb_private::EmulateInstruction::Context &context, lldb::addr_t addr, void *dst, size_t length)
 
static size_t WriteMemory (lldb_private::EmulateInstruction *instruction, void *baton, const lldb_private::EmulateInstruction::Context &context, lldb::addr_t addr, const void *dst, size_t length)
 
static bool ReadRegister (lldb_private::EmulateInstruction *instruction, void *baton, const lldb_private::RegisterInfo *reg_info, lldb_private::RegisterValue &reg_value)
 
static bool WriteRegister (lldb_private::EmulateInstruction *instruction, void *baton, const lldb_private::EmulateInstruction::Context &context, const lldb_private::RegisterInfo *reg_info, const lldb_private::RegisterValue &reg_value)
 
static uint64_t MakeRegisterKindValuePair (const lldb_private::RegisterInfo &reg_info)
 

Private Attributes

std::unique_ptr< lldb_private::EmulateInstructionm_inst_emulator_up
 
lldb_private::AddressRangem_range_ptr
 
lldb_private::UnwindPlanm_unwind_plan_ptr
 
lldb_private::UnwindPlan::RowSP m_curr_row
 
uint64_t m_initial_sp
 
lldb_private::RegisterInfo m_cfa_reg_info
 
bool m_fp_is_cfa
 
RegisterValueMap m_register_values
 
PushedRegisterToAddrMap m_pushed_regs
 
bool m_curr_row_modified
 
uint32_t m_forward_branch_offset
 

Additional Inherited Members

- Protected Member Functions inherited from lldb_private::UnwindAssembly
 UnwindAssembly (const ArchSpec &arch)
 
- Protected Attributes inherited from lldb_private::UnwindAssembly
ArchSpec m_arch
 

Detailed Description

Definition at line 18 of file UnwindAssemblyInstEmulation.h.

Member Typedef Documentation

◆ PushedRegisterToAddrMap

typedef std::map<uint64_t, uint64_t> UnwindAssemblyInstEmulation::PushedRegisterToAddrMap
private

Definition at line 131 of file UnwindAssemblyInstEmulation.h.

◆ RegisterValueMap

Definition at line 135 of file UnwindAssemblyInstEmulation.h.

Constructor & Destructor Documentation

◆ ~UnwindAssemblyInstEmulation()

UnwindAssemblyInstEmulation::~UnwindAssemblyInstEmulation ( )
overridedefault

◆ UnwindAssemblyInstEmulation()

UnwindAssemblyInstEmulation::UnwindAssemblyInstEmulation ( const lldb_private::ArchSpec arch,
lldb_private::EmulateInstruction inst_emulator 
)
inlineprivate

Member Function Documentation

◆ AugmentUnwindPlanFromCallSite()

bool UnwindAssemblyInstEmulation::AugmentUnwindPlanFromCallSite ( lldb_private::AddressRange func,
lldb_private::Thread thread,
lldb_private::UnwindPlan unwind_plan 
)
overridevirtual

Implements lldb_private::UnwindAssembly.

Definition at line 308 of file UnwindAssemblyInstEmulation.cpp.

◆ CreateInstance()

UnwindAssembly * UnwindAssemblyInstEmulation::CreateInstance ( const lldb_private::ArchSpec arch)
static

◆ FirstNonPrologueInsn()

bool UnwindAssemblyInstEmulation::FirstNonPrologueInsn ( lldb_private::AddressRange func,
const lldb_private::ExecutionContext exe_ctx,
lldb_private::Address first_non_prologue_insn 
)
overridevirtual

Implements lldb_private::UnwindAssembly.

Definition at line 319 of file UnwindAssemblyInstEmulation.cpp.

◆ GetFastUnwindPlan()

bool UnwindAssemblyInstEmulation::GetFastUnwindPlan ( lldb_private::AddressRange func,
lldb_private::Thread thread,
lldb_private::UnwindPlan unwind_plan 
)
overridevirtual

Implements lldb_private::UnwindAssembly.

Definition at line 313 of file UnwindAssemblyInstEmulation.cpp.

◆ GetNonCallSiteUnwindPlanFromAssembly() [1/2]

bool UnwindAssemblyInstEmulation::GetNonCallSiteUnwindPlanFromAssembly ( lldb_private::AddressRange func,
lldb_private::Thread thread,
lldb_private::UnwindPlan unwind_plan 
)
overridevirtual

Implements lldb_private::UnwindAssembly.

Definition at line 35 of file UnwindAssemblyInstEmulation.cpp.

References error().

◆ GetNonCallSiteUnwindPlanFromAssembly() [2/2]

bool UnwindAssemblyInstEmulation::GetNonCallSiteUnwindPlanFromAssembly ( lldb_private::AddressRange func,
uint8_t *  opcode_data,
size_t  opcode_size,
lldb_private::UnwindPlan unwind_plan 
)

◆ GetPluginDescriptionStatic()

const char * UnwindAssemblyInstEmulation::GetPluginDescriptionStatic ( )
static

Definition at line 355 of file UnwindAssemblyInstEmulation.cpp.

◆ GetPluginName()

ConstString UnwindAssemblyInstEmulation::GetPluginName ( )
overridevirtual

Implements lldb_private::PluginInterface.

Definition at line 337 of file UnwindAssemblyInstEmulation.cpp.

◆ GetPluginNameStatic()

ConstString UnwindAssemblyInstEmulation::GetPluginNameStatic ( )
static

Definition at line 350 of file UnwindAssemblyInstEmulation.cpp.

◆ GetRegisterValue()

bool UnwindAssemblyInstEmulation::GetRegisterValue ( const lldb_private::RegisterInfo &  reg_info,
lldb_private::RegisterValue reg_value 
)
private

◆ Initialize()

void UnwindAssemblyInstEmulation::Initialize ( )
static

Definition at line 341 of file UnwindAssemblyInstEmulation.cpp.

◆ MakeRegisterKindValuePair()

uint64_t UnwindAssemblyInstEmulation::MakeRegisterKindValuePair ( const lldb_private::RegisterInfo &  reg_info)
staticprivate

Definition at line 359 of file UnwindAssemblyInstEmulation.cpp.

◆ ReadMemory()

size_t UnwindAssemblyInstEmulation::ReadMemory ( lldb_private::EmulateInstruction instruction,
void *  baton,
const lldb_private::EmulateInstruction::Context context,
lldb::addr_t  addr,
void *  dst,
size_t  length 
)
staticprivate

◆ ReadRegister() [1/2]

bool UnwindAssemblyInstEmulation::ReadRegister ( lldb_private::EmulateInstruction instruction,
const lldb_private::RegisterInfo *  reg_info,
lldb_private::RegisterValue reg_value 
)
private

◆ ReadRegister() [2/2]

static bool UnwindAssemblyInstEmulation::ReadRegister ( lldb_private::EmulateInstruction instruction,
void *  baton,
const lldb_private::RegisterInfo *  reg_info,
lldb_private::RegisterValue reg_value 
)
staticprivate

◆ SetRegisterValue()

void UnwindAssemblyInstEmulation::SetRegisterValue ( const lldb_private::RegisterInfo &  reg_info,
const lldb_private::RegisterValue reg_value 
)
private

Definition at line 369 of file UnwindAssemblyInstEmulation.cpp.

◆ Terminate()

void UnwindAssemblyInstEmulation::Terminate ( )
static

Definition at line 346 of file UnwindAssemblyInstEmulation.cpp.

◆ WriteMemory() [1/2]

size_t UnwindAssemblyInstEmulation::WriteMemory ( lldb_private::EmulateInstruction instruction,
const lldb_private::EmulateInstruction::Context context,
lldb::addr_t  addr,
const void *  dst,
size_t  length 
)
private

◆ WriteMemory() [2/2]

size_t UnwindAssemblyInstEmulation::WriteMemory ( lldb_private::EmulateInstruction instruction,
void *  baton,
const lldb_private::EmulateInstruction::Context context,
lldb::addr_t  addr,
const void *  dst,
size_t  length 
)
staticprivate

Definition at line 407 of file UnwindAssemblyInstEmulation.cpp.

Referenced by UnwindAssemblyInstEmulation().

◆ WriteRegister() [1/2]

bool UnwindAssemblyInstEmulation::WriteRegister ( lldb_private::EmulateInstruction instruction,
const lldb_private::EmulateInstruction::Context context,
const lldb_private::RegisterInfo *  reg_info,
const lldb_private::RegisterValue reg_value 
)
private

◆ WriteRegister() [2/2]

static bool UnwindAssemblyInstEmulation::WriteRegister ( lldb_private::EmulateInstruction instruction,
void *  baton,
const lldb_private::EmulateInstruction::Context context,
const lldb_private::RegisterInfo *  reg_info,
const lldb_private::RegisterValue reg_value 
)
staticprivate

Member Data Documentation

◆ m_cfa_reg_info

lldb_private::RegisterInfo UnwindAssemblyInstEmulation::m_cfa_reg_info
private

Definition at line 133 of file UnwindAssemblyInstEmulation.h.

◆ m_curr_row

lldb_private::UnwindPlan::RowSP UnwindAssemblyInstEmulation::m_curr_row
private

Definition at line 130 of file UnwindAssemblyInstEmulation.h.

◆ m_curr_row_modified

bool UnwindAssemblyInstEmulation::m_curr_row_modified
private

Definition at line 146 of file UnwindAssemblyInstEmulation.h.

◆ m_forward_branch_offset

uint32_t UnwindAssemblyInstEmulation::m_forward_branch_offset
private

Definition at line 149 of file UnwindAssemblyInstEmulation.h.

◆ m_fp_is_cfa

bool UnwindAssemblyInstEmulation::m_fp_is_cfa
private

Definition at line 134 of file UnwindAssemblyInstEmulation.h.

◆ m_initial_sp

uint64_t UnwindAssemblyInstEmulation::m_initial_sp
private

Definition at line 132 of file UnwindAssemblyInstEmulation.h.

◆ m_inst_emulator_up

std::unique_ptr<lldb_private::EmulateInstruction> UnwindAssemblyInstEmulation::m_inst_emulator_up
private

Definition at line 127 of file UnwindAssemblyInstEmulation.h.

Referenced by UnwindAssemblyInstEmulation().

◆ m_pushed_regs

PushedRegisterToAddrMap UnwindAssemblyInstEmulation::m_pushed_regs
private

Definition at line 137 of file UnwindAssemblyInstEmulation.h.

◆ m_range_ptr

lldb_private::AddressRange* UnwindAssemblyInstEmulation::m_range_ptr
private

Definition at line 128 of file UnwindAssemblyInstEmulation.h.

◆ m_register_values

RegisterValueMap UnwindAssemblyInstEmulation::m_register_values
private

Definition at line 136 of file UnwindAssemblyInstEmulation.h.

◆ m_unwind_plan_ptr

lldb_private::UnwindPlan* UnwindAssemblyInstEmulation::m_unwind_plan_ptr
private

Definition at line 129 of file UnwindAssemblyInstEmulation.h.


The documentation for this class was generated from the following files: