| LLDB mainline
    | 
#include <EmulateInstructionRISCV.h>
| Public Member Functions | |
| EmulateInstructionRISCV (const ArchSpec &arch) | |
| llvm::StringRef | GetPluginName () override | 
| bool | SupportsEmulatingInstructionsOfType (InstructionType inst_type) override | 
| bool | CreateFunctionEntryUnwind (UnwindPlan &unwind_plan) override | 
| bool | SetTargetTriple (const ArchSpec &arch) override | 
| bool | ReadInstruction () override | 
| std::optional< uint32_t > | GetLastInstrSize () override | 
| bool | EvaluateInstruction (uint32_t options) override | 
| bool | TestEmulation (Stream &out_stream, ArchSpec &arch, OptionValueDictionary *test_data) override | 
| std::optional< RegisterInfo > | GetRegisterInfo (lldb::RegisterKind reg_kind, uint32_t reg_num) override | 
| bool | SetInstruction (const Opcode &opcode, const Address &inst_addr, Target *target) override | 
| std::optional< DecodeResult > | ReadInstructionAt (lldb::addr_t addr) | 
| std::optional< DecodeResult > | Decode (uint32_t inst) | 
| bool | Execute (DecodeResult inst, bool ignore_cond) | 
| template<typename T> | |
| std::enable_if_t< std::is_integral_v< T >, std::optional< T > > | ReadMem (uint64_t addr) | 
| template<typename T> | |
| bool | WriteMem (uint64_t addr, uint64_t value) | 
| llvm::RoundingMode | GetRoundingMode () | 
| bool | SetAccruedExceptions (llvm::APFloatBase::opStatus) | 
| Public Member Functions inherited from lldb_private::EmulateInstruction | |
| EmulateInstruction (const ArchSpec &arch) | |
| ~EmulateInstruction () override=default | |
| virtual InstructionCondition | GetInstructionCondition () | 
| std::optional< RegisterValue > | ReadRegister (const RegisterInfo ®_info) | 
| uint64_t | ReadRegisterUnsigned (const RegisterInfo ®_info, uint64_t fail_value, bool *success_ptr) | 
| bool | WriteRegister (const Context &context, const RegisterInfo &ref_info, const RegisterValue ®_value) | 
| bool | WriteRegisterUnsigned (const Context &context, const RegisterInfo ®_info, uint64_t reg_value) | 
| bool | ReadRegister (lldb::RegisterKind reg_kind, uint32_t reg_num, RegisterValue ®_value) | 
| bool | WriteRegister (const Context &context, lldb::RegisterKind reg_kind, uint32_t reg_num, const RegisterValue ®_value) | 
| uint64_t | ReadRegisterUnsigned (lldb::RegisterKind reg_kind, uint32_t reg_num, uint64_t fail_value, bool *success_ptr) | 
| bool | WriteRegisterUnsigned (const Context &context, lldb::RegisterKind reg_kind, uint32_t reg_num, uint64_t reg_value) | 
| size_t | ReadMemory (const Context &context, lldb::addr_t addr, void *dst, size_t dst_len) | 
| uint64_t | ReadMemoryUnsigned (const Context &context, lldb::addr_t addr, size_t byte_size, uint64_t fail_value, bool *success_ptr) | 
| bool | WriteMemory (const Context &context, lldb::addr_t addr, const void *src, size_t src_len) | 
| bool | WriteMemoryUnsigned (const Context &context, lldb::addr_t addr, uint64_t uval, size_t uval_byte_size) | 
| uint32_t | GetAddressByteSize () const | 
| lldb::ByteOrder | GetByteOrder () const | 
| const Opcode & | GetOpcode () const | 
| lldb::addr_t | GetAddress () const | 
| const ArchSpec & | GetArchitecture () const | 
| void | SetBaton (void *baton) | 
| void | SetCallbacks (ReadMemoryCallback read_mem_callback, WriteMemoryCallback write_mem_callback, ReadRegisterCallback read_reg_callback, WriteRegisterCallback write_reg_callback) | 
| void | SetReadMemCallback (ReadMemoryCallback read_mem_callback) | 
| void | SetWriteMemCallback (WriteMemoryCallback write_mem_callback) | 
| void | SetReadRegCallback (ReadRegisterCallback read_reg_callback) | 
| void | SetWriteRegCallback (WriteRegisterCallback write_reg_callback) | 
| std::optional< lldb::addr_t > | ReadPC () | 
| bool | WritePC (lldb::addr_t addr) | 
| Public Member Functions inherited from lldb_private::PluginInterface | |
| PluginInterface ()=default | |
| virtual | ~PluginInterface ()=default | 
| PluginInterface (const PluginInterface &)=delete | |
| PluginInterface & | operator= (const PluginInterface &)=delete | 
| Static Public Member Functions | |
| static llvm::StringRef | GetPluginNameStatic () | 
| static llvm::StringRef | GetPluginDescriptionStatic () | 
| static bool | SupportsThisInstructionType (InstructionType inst_type) | 
| static bool | SupportsThisArch (const ArchSpec &arch) | 
| static lldb_private::EmulateInstruction * | CreateInstance (const lldb_private::ArchSpec &arch, InstructionType inst_type) | 
| static void | Initialize () | 
| static void | Terminate () | 
| Static Public Member Functions inherited from lldb_private::EmulateInstruction | |
| static EmulateInstruction * | FindPlugin (const ArchSpec &arch, InstructionType supported_inst_type, const char *plugin_name) | 
| static const char * | TranslateRegister (lldb::RegisterKind reg_kind, uint32_t reg_num, std::string ®_name) | 
| static size_t | ReadMemoryFrame (EmulateInstruction *instruction, void *baton, const Context &context, lldb::addr_t addr, void *dst, size_t length) | 
| static size_t | WriteMemoryFrame (EmulateInstruction *instruction, void *baton, const Context &context, lldb::addr_t addr, const void *dst, size_t length) | 
| static bool | ReadRegisterFrame (EmulateInstruction *instruction, void *baton, const RegisterInfo *reg_info, RegisterValue ®_value) | 
| static bool | WriteRegisterFrame (EmulateInstruction *instruction, void *baton, const Context &context, const RegisterInfo *reg_info, const RegisterValue ®_value) | 
| static size_t | ReadMemoryDefault (EmulateInstruction *instruction, void *baton, const Context &context, lldb::addr_t addr, void *dst, size_t length) | 
| static size_t | WriteMemoryDefault (EmulateInstruction *instruction, void *baton, const Context &context, lldb::addr_t addr, const void *dst, size_t length) | 
| static bool | ReadRegisterDefault (EmulateInstruction *instruction, void *baton, const RegisterInfo *reg_info, RegisterValue ®_value) | 
| static bool | WriteRegisterDefault (EmulateInstruction *instruction, void *baton, const Context &context, const RegisterInfo *reg_info, const RegisterValue ®_value) | 
| static bool | GetBestRegisterKindAndNumber (const RegisterInfo *reg_info, lldb::RegisterKind ®_kind, uint32_t ®_num) | 
| static uint32_t | GetInternalRegisterNumber (RegisterContext *reg_ctx, const RegisterInfo ®_info) | 
| static std::unique_ptr< SingleStepBreakpointLocationsPredictor > | CreateBreakpointLocationPredictor (std::unique_ptr< EmulateInstruction > emulator_up) | 
| Private Member Functions | |
| BreakpointLocationsPredictorCreator | GetSingleStepBreakpointLocationsPredictorCreator () override | 
| Private Attributes | |
| DecodeResult | m_decoded | 
| Last decoded instruction from m_opcode. | |
| std::optional< uint32_t > | m_last_size | 
| Last decoded instruction size estimate. | |
Definition at line 50 of file EmulateInstructionRISCV.h.
| 
 | inline | 
Definition at line 81 of file EmulateInstructionRISCV.h.
References lldb_private::EmulateInstruction::EmulateInstruction().
Referenced by CreateInstance().
| 
 | overridevirtual | 
Reimplemented from lldb_private::EmulateInstruction.
Definition at line 1880 of file EmulateInstructionRISCV.cpp.
References lldb_private::UnwindPlan::AppendRow(), lldb_private::UnwindPlan::Clear(), lldb_private::eLazyBoolNo, lldb_private::eLazyBoolYes, lldb::eRegisterKindLLDB, lldb_private::UnwindPlan::Row::GetCFAValue(), gpr_fp_riscv, gpr_ra_riscv, gpr_sp_riscv, lldb_private::UnwindPlan::Row::FAValue::SetIsRegisterPlusOffset(), lldb_private::UnwindPlan::SetRegisterKind(), lldb_private::UnwindPlan::Row::SetRegisterLocationToSame(), lldb_private::UnwindPlan::SetReturnAddressRegister(), lldb_private::UnwindPlan::SetSourcedFromCompiler(), lldb_private::UnwindPlan::SetSourceName(), lldb_private::UnwindPlan::SetUnwindPlanForSignalTrap(), and lldb_private::UnwindPlan::SetUnwindPlanValidAtAllInstructions().
| 
 | static | 
Definition at line 1919 of file EmulateInstructionRISCV.cpp.
References EmulateInstructionRISCV(), SupportsThisArch(), and SupportsThisInstructionType().
Referenced by Initialize(), and Terminate().
| std::optional< DecodeResult > lldb_private::EmulateInstructionRISCV::Decode | ( | uint32_t | inst | ) | 
Definition at line 685 of file EmulateInstructionRISCV.cpp.
References lldb_private::ArchSpec::eCore_riscv32, lldb_private::GetLog(), LLDB_LOGF, lldb_private::EmulateInstruction::m_addr, lldb_private::EmulateInstruction::m_arch, m_last_size, lldb_private::PATTERNS, lldb_private::RV32, lldb_private::RV64, and lldb_private::Unwind.
Referenced by ReadInstructionAt(), and SetInstruction().
| 
 | overridevirtual | 
Implements lldb_private::EmulateInstruction.
Definition at line 1703 of file EmulateInstructionRISCV.cpp.
References Execute(), m_decoded, lldb_private::EmulateInstruction::ReadPC(), lldb_private::Executor::size(), and lldb_private::EmulateInstruction::WritePC().
| bool lldb_private::EmulateInstructionRISCV::Execute | ( | DecodeResult | inst, | 
| bool | ignore_cond ) | 
Definition at line 1699 of file EmulateInstructionRISCV.cpp.
References lldb_private::DecodeResult::decoded, and lldb_private::DecodeResult::is_rvc.
Referenced by EvaluateInstruction().
| 
 | inlineoverridevirtual | 
Reimplemented from lldb_private::EmulateInstruction.
Definition at line 92 of file EmulateInstructionRISCV.h.
References m_last_size.
Referenced by lldb_private::RISCVSingleStepBreakpointLocationsPredictor::GetBreakpointSize().
| 
 | inlinestatic | 
Definition at line 54 of file EmulateInstructionRISCV.h.
Referenced by Initialize().
| 
 | inlineoverridevirtual | 
Implements lldb_private::PluginInterface.
Definition at line 83 of file EmulateInstructionRISCV.h.
References GetPluginNameStatic().
| 
 | inlinestatic | 
Definition at line 52 of file EmulateInstructionRISCV.h.
Referenced by GetPluginName(), and Initialize().
| 
 | overridevirtual | 
Implements lldb_private::EmulateInstruction.
Definition at line 1807 of file EmulateInstructionRISCV.cpp.
References lldb::eRegisterKindGeneric, lldb::eRegisterKindLLDB, RegisterInfoPOSIX_riscv64::eRegsetMaskAll, RegisterInfoPOSIX_riscv64::GetRegisterCount(), RegisterInfoPOSIX_riscv64::GetRegisterInfo(), gpr_fp_riscv, gpr_pc_riscv, gpr_ra_riscv, gpr_sp_riscv, LLDB_REGNUM_GENERIC_FP, LLDB_REGNUM_GENERIC_PC, LLDB_REGNUM_GENERIC_RA, LLDB_REGNUM_GENERIC_SP, and lldb_private::EmulateInstruction::m_arch.
Referenced by lldb_private::GPREncodingToRegisterInfo().
| RoundingMode lldb_private::EmulateInstructionRISCV::GetRoundingMode | ( | ) | 
Definition at line 1750 of file EmulateInstructionRISCV.cpp.
References lldb::eRegisterKindLLDB, fpr_fcsr_riscv, LLDB_INVALID_ADDRESS, and lldb_private::EmulateInstruction::ReadRegisterUnsigned().
| 
 | inlineoverrideprivatevirtual | 
Reimplemented from lldb_private::EmulateInstruction.
Definition at line 130 of file EmulateInstructionRISCV.h.
| 
 | static | 
Definition at line 1909 of file EmulateInstructionRISCV.cpp.
References CreateInstance(), GetPluginDescriptionStatic(), GetPluginNameStatic(), and lldb_private::PluginManager::RegisterPlugin().
| 
 | overridevirtual | 
Implements lldb_private::EmulateInstruction.
Definition at line 1734 of file EmulateInstructionRISCV.cpp.
References lldb_private::EmulateInstruction::GetByteOrder(), LLDB_INVALID_ADDRESS, lldb_private::EmulateInstruction::m_addr, m_decoded, lldb_private::EmulateInstruction::m_opcode, ReadInstructionAt(), and lldb_private::EmulateInstruction::ReadPC().
| std::optional< DecodeResult > lldb_private::EmulateInstructionRISCV::ReadInstructionAt | ( | lldb::addr_t | addr | ) | 
Definition at line 1728 of file EmulateInstructionRISCV.cpp.
References Decode(), and ReadMem().
Referenced by lldb_private::AtomicSequence(), lldb_private::RISCVSingleStepBreakpointLocationsPredictor::GetBreakpointLocations(), lldb_private::RISCVSingleStepBreakpointLocationsPredictor::GetBreakpointSize(), lldb_private::RISCVSingleStepBreakpointLocationsPredictor::HandleAtomicSequence(), and ReadInstruction().
| 
 | inline | 
Definition at line 107 of file EmulateInstructionRISCV.h.
References lldb_private::EmulateInstruction::eContextRegisterLoad, lldb_private::EmulateInstruction::ReadMemoryUnsigned(), lldb_private::EmulateInstruction::Context::SetNoArgs(), and lldb_private::EmulateInstruction::Context::type.
Referenced by lldb_private::AtomicADD(), lldb_private::AtomicBitOperate(), lldb_private::AtomicCmp(), lldb_private::AtomicSwap(), and ReadInstructionAt().
| bool lldb_private::EmulateInstructionRISCV::SetAccruedExceptions | ( | llvm::APFloatBase::opStatus | ) | 
Definition at line 1774 of file EmulateInstructionRISCV.cpp.
References lldb_private::EmulateInstruction::eContextRegisterStore, lldb::eRegisterKindLLDB, fpr_fcsr_riscv, LLDB_INVALID_ADDRESS, lldb_private::EmulateInstruction::ReadRegisterUnsigned(), lldb_private::EmulateInstruction::Context::SetNoArgs(), lldb_private::EmulateInstruction::Context::type, and lldb_private::EmulateInstruction::WriteRegisterUnsigned().
| 
 | overridevirtual | 
Reimplemented from lldb_private::EmulateInstruction.
Definition at line 1845 of file EmulateInstructionRISCV.cpp.
References Decode(), m_decoded, lldb_private::EmulateInstruction::m_opcode, and lldb_private::EmulateInstruction::SetInstruction().
| 
 | overridevirtual | 
Implements lldb_private::EmulateInstruction.
Definition at line 1900 of file EmulateInstructionRISCV.cpp.
References SupportsThisArch().
| 
 | inlineoverridevirtual | 
Implements lldb_private::EmulateInstruction.
Definition at line 85 of file EmulateInstructionRISCV.h.
References SupportsThisInstructionType().
Definition at line 1929 of file EmulateInstructionRISCV.cpp.
References lldb_private::ArchSpec::GetTriple().
Referenced by CreateInstance(), and SetTargetTriple().
| 
 | inlinestatic | 
Definition at line 58 of file EmulateInstructionRISCV.h.
References lldb_private::eInstructionTypeAll, lldb_private::eInstructionTypeAny, lldb_private::eInstructionTypePCModifying, and lldb_private::eInstructionTypePrologueEpilogue.
Referenced by CreateInstance(), and SupportsEmulatingInstructionsOfType().
| 
 | static | 
Definition at line 1914 of file EmulateInstructionRISCV.cpp.
References CreateInstance(), and lldb_private::PluginManager::UnregisterPlugin().
| 
 | overridevirtual | 
Implements lldb_private::EmulateInstruction.
Definition at line 1904 of file EmulateInstructionRISCV.cpp.
| 
 | inline | 
| 
 | private | 
Last decoded instruction from m_opcode.
Definition at line 137 of file EmulateInstructionRISCV.h.
Referenced by EvaluateInstruction(), ReadInstruction(), and SetInstruction().
| 
 | private | 
Last decoded instruction size estimate.
Definition at line 139 of file EmulateInstructionRISCV.h.
Referenced by Decode(), and GetLastInstrSize().