LLDB mainline
|
#include <ItaniumABILanguageRuntime.h>
Public Member Functions | |
~ItaniumABILanguageRuntime () override=default | |
bool | isA (const void *ClassID) const override |
llvm::Expected< LanguageRuntime::VTableInfo > | GetVTableInfo (ValueObject &in_value, bool check_type) override |
Get the vtable information for a given value. | |
bool | GetDynamicTypeAndAddress (ValueObject &in_value, lldb::DynamicValueType use_dynamic, TypeAndOrName &class_type_or_name, Address &address, Value::ValueType &value_type) override |
TypeAndOrName | FixUpDynamicType (const TypeAndOrName &type_and_or_name, ValueObject &static_value) override |
bool | CouldHaveDynamicValue (ValueObject &in_value) override |
void | SetExceptionBreakpoints () override |
void | ClearExceptionBreakpoints () override |
bool | ExceptionBreakpointsAreSet () override |
bool | ExceptionBreakpointsExplainStop (lldb::StopInfoSP stop_reason) override |
lldb::BreakpointResolverSP | CreateExceptionResolver (const lldb::BreakpointSP &bkpt, bool catch_bp, bool throw_bp) override |
lldb::SearchFilterSP | CreateExceptionSearchFilter () override |
lldb::ValueObjectSP | GetExceptionObjectForThread (lldb::ThreadSP thread_sp) override |
llvm::StringRef | GetPluginName () override |
Public Member Functions inherited from lldb_private::CPPLanguageRuntime | |
LibCppStdFunctionCallableInfo | FindLibCppStdFunctionCallableInfo (lldb::ValueObjectSP &valobj_sp) |
bool | isA (const void *ClassID) const override |
lldb::LanguageType | GetLanguageType () const override |
llvm::Error | GetObjectDescription (Stream &str, ValueObject &object) override |
llvm::Error | GetObjectDescription (Stream &str, Value &value, ExecutionContextScope *exe_scope) override |
lldb::ThreadPlanSP | GetStepThroughTrampolinePlan (Thread &thread, bool stop_others) override |
Obtain a ThreadPlan to get us into C++ constructs such as std::function. | |
bool | IsAllowedRuntimeValue (ConstString name) override |
Identify whether a name is a runtime value that should not be hidden by from the user interface. | |
Public Member Functions inherited from lldb_private::LanguageRuntime | |
virtual lldb::LanguageType | GetLanguageType () const =0 |
virtual LanguageRuntime * | GetPreferredLanguageRuntime (ValueObject &in_value) |
Return the preferred language runtime instance, which in most cases will be the current instance. | |
virtual llvm::Error | GetObjectDescription (Stream &str, ValueObject &object)=0 |
virtual llvm::Error | GetObjectDescription (Stream &str, Value &value, ExecutionContextScope *exe_scope)=0 |
virtual llvm::Expected< VTableInfo > | GetVTableInfo (ValueObject &in_value, bool check_type) |
Get the vtable information for a given value. | |
virtual bool | GetDynamicTypeAndAddress (ValueObject &in_value, lldb::DynamicValueType use_dynamic, TypeAndOrName &class_type_or_name, Address &address, Value::ValueType &value_type)=0 |
virtual CompilerType | GetConcreteType (ExecutionContextScope *exe_scope, ConstString abstract_type_name) |
virtual bool | CouldHaveDynamicValue (ValueObject &in_value)=0 |
virtual TypeAndOrName | FixUpDynamicType (const TypeAndOrName &type_and_or_name, ValueObject &static_value)=0 |
virtual void | SetExceptionBreakpoints () |
virtual void | ClearExceptionBreakpoints () |
virtual bool | ExceptionBreakpointsAreSet () |
virtual bool | ExceptionBreakpointsExplainStop (lldb::StopInfoSP stop_reason) |
virtual lldb::ValueObjectSP | GetExceptionObjectForThread (lldb::ThreadSP thread_sp) |
virtual lldb::ThreadSP | GetBacktraceThreadFromException (lldb::ValueObjectSP thread_sp) |
virtual DeclVendor * | GetDeclVendor () |
virtual lldb::BreakpointResolverSP | CreateExceptionResolver (const lldb::BreakpointSP &bkpt, bool catch_bp, bool throw_bp)=0 |
virtual lldb::SearchFilterSP | CreateExceptionSearchFilter () |
virtual std::optional< uint64_t > | GetTypeBitSize (const CompilerType &compiler_type) |
virtual void | SymbolsDidLoad (const ModuleList &module_list) |
virtual lldb::ThreadPlanSP | GetStepThroughTrampolinePlan (Thread &thread, bool stop_others)=0 |
virtual bool | IsAllowedRuntimeValue (ConstString name) |
Identify whether a name is a runtime value that should not be hidden by from the user interface. | |
virtual std::optional< CompilerType > | GetRuntimeType (CompilerType base_type) |
void | ModulesDidLoad (const ModuleList &module_list) override |
Called when modules have been loaded in the process. | |
virtual bool | GetIRPasses (LLVMUserExpression::IRPasses &custom_passes) |
virtual lldb::addr_t | LookupRuntimeSymbol (ConstString name) |
virtual bool | isA (const void *ClassID) const |
Public Member Functions inherited from lldb_private::Runtime | |
Runtime (Process *process) | |
virtual | ~Runtime ()=default |
Runtime (const Runtime &)=delete | |
const Runtime & | operator= (const Runtime &)=delete |
Process * | GetProcess () |
Target & | GetTargetRef () |
virtual void | ModulesDidLoad (const ModuleList &module_list)=0 |
Called when modules have been loaded in the process. | |
Public Member Functions inherited from lldb_private::PluginInterface | |
PluginInterface ()=default | |
virtual | ~PluginInterface ()=default |
virtual llvm::StringRef | GetPluginName ()=0 |
PluginInterface (const PluginInterface &)=delete | |
PluginInterface & | operator= (const PluginInterface &)=delete |
Static Public Member Functions | |
static void | Initialize () |
static void | Terminate () |
static lldb_private::LanguageRuntime * | CreateInstance (Process *process, lldb::LanguageType language) |
static llvm::StringRef | GetPluginNameStatic () |
static bool | classof (const LanguageRuntime *runtime) |
Static Public Member Functions inherited from lldb_private::CPPLanguageRuntime | |
static bool | classof (const LanguageRuntime *runtime) |
static CPPLanguageRuntime * | Get (Process &process) |
Static Public Member Functions inherited from lldb_private::LanguageRuntime | |
static LanguageRuntime * | FindPlugin (Process *process, lldb::LanguageType language) |
static void | InitializeCommands (CommandObject *parent) |
static lldb::BreakpointSP | CreateExceptionBreakpoint (Target &target, lldb::LanguageType language, bool catch_bp, bool throw_bp, bool is_internal=false) |
static lldb::BreakpointPreconditionSP | GetExceptionPrecondition (lldb::LanguageType language, bool throw_bp) |
static lldb::UnwindPlanSP | GetRuntimeUnwindPlan (lldb_private::Thread &thread, lldb_private::RegisterContext *regctx, bool &behaves_like_zeroth_frame) |
A language runtime may be able to provide a special UnwindPlan for the frame represented by the register contents regctx when that frame is not following the normal ABI conventions. | |
Static Public Attributes | |
static char | ID = 0 |
Static Public Attributes inherited from lldb_private::CPPLanguageRuntime | |
static char | ID = 0 |
Static Public Attributes inherited from lldb_private::LanguageRuntime | |
static char | ID = 0 |
Protected Member Functions | |
lldb::BreakpointResolverSP | CreateExceptionResolver (const lldb::BreakpointSP &bkpt, bool catch_bp, bool throw_bp, bool for_expressions) |
lldb::BreakpointSP | CreateExceptionBreakpoint (bool catch_bp, bool throw_bp, bool for_expressions, bool is_internal) |
Protected Member Functions inherited from lldb_private::CPPLanguageRuntime | |
CPPLanguageRuntime (Process *process) | |
Protected Member Functions inherited from lldb_private::LanguageRuntime | |
virtual lldb::UnwindPlanSP | GetRuntimeUnwindPlan (lldb::ProcessSP process_sp, lldb_private::RegisterContext *regctx, bool &behaves_like_zeroth_frame) |
LanguageRuntime (Process *process) | |
Private Types | |
typedef std::map< lldb_private::Address, TypeAndOrName > | DynamicTypeCache |
typedef std::map< lldb_private::Address, VTableInfo > | VTableInfoCache |
Private Member Functions | |
ItaniumABILanguageRuntime (Process *process) | |
TypeAndOrName | GetTypeInfo (ValueObject &in_value, const VTableInfo &vtable_info) |
TypeAndOrName | GetDynamicTypeInfo (const lldb_private::Address &vtable_addr) |
void | SetDynamicTypeInfo (const lldb_private::Address &vtable_addr, const TypeAndOrName &type_info) |
llvm::Error | TypeHasVTable (CompilerType compiler_type) |
Private Attributes | |
lldb::BreakpointSP | m_cxx_exception_bp_sp |
DynamicTypeCache | m_dynamic_type_map |
VTableInfoCache | m_vtable_info_map |
std::mutex | m_mutex |
Additional Inherited Members | |
Public Types inherited from lldb_private::CPPLanguageRuntime | |
enum class | LibCppStdFunctionCallableCase { Lambda = 0 , CallableObject , FreeOrMemberFunction , Invalid } |
Protected Attributes inherited from lldb_private::Runtime | |
Process * | m_process |
Definition at line 26 of file ItaniumABILanguageRuntime.h.
|
private |
Definition at line 95 of file ItaniumABILanguageRuntime.h.
|
private |
Definition at line 96 of file ItaniumABILanguageRuntime.h.
|
overridedefault |
|
inlineprivate |
Definition at line 98 of file ItaniumABILanguageRuntime.h.
|
inlinestatic |
Definition at line 46 of file ItaniumABILanguageRuntime.h.
References ID, and lldb_private::LanguageRuntime::isA().
|
overridevirtual |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 582 of file ItaniumABILanguageRuntime.cpp.
References m_cxx_exception_bp_sp, and lldb_private::Runtime::m_process.
|
overridevirtual |
Implements lldb_private::LanguageRuntime.
Definition at line 50 of file ItaniumABILanguageRuntime.cpp.
Referenced by GetDynamicTypeAndAddress().
|
protected |
Definition at line 547 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::Target::CreateBreakpoint(), CreateExceptionResolver(), CreateExceptionSearchFilter(), lldb_private::Process::GetTarget(), and lldb_private::Runtime::m_process.
Referenced by SetExceptionBreakpoints().
|
overridevirtual |
Implements lldb_private::LanguageRuntime.
Definition at line 493 of file ItaniumABILanguageRuntime.cpp.
References CreateExceptionResolver().
Referenced by CreateExceptionBreakpoint(), and CreateExceptionResolver().
|
protected |
Definition at line 498 of file ItaniumABILanguageRuntime.cpp.
References lldb::eLanguageTypeUnknown, and lldb_private::eLazyBoolNo.
|
overridevirtual |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 532 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::FileSpecList::EmplaceBack(), lldb_private::Target::GetArchitecture(), lldb_private::Target::GetSearchFilterForModuleList(), lldb_private::Process::GetTarget(), lldb_private::ArchSpec::GetTriple(), and lldb_private::Runtime::m_process.
Referenced by CreateExceptionBreakpoint().
|
static |
Definition at line 402 of file ItaniumABILanguageRuntime.cpp.
References lldb::eLanguageTypeC_plus_plus, lldb::eLanguageTypeC_plus_plus_03, lldb::eLanguageTypeC_plus_plus_11, and lldb::eLanguageTypeC_plus_plus_14.
Referenced by Initialize(), and Terminate().
|
overridevirtual |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 591 of file ItaniumABILanguageRuntime.cpp.
References m_cxx_exception_bp_sp.
|
overridevirtual |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 595 of file ItaniumABILanguageRuntime.cpp.
References lldb::eStopReasonBreakpoint, lldb_private::Process::GetBreakpointSiteList(), m_cxx_exception_bp_sp, lldb_private::Runtime::m_process, and lldb_private::StopPointSiteList< StopPointSite >::StopPointSiteContainsBreakpoint().
|
overridevirtual |
Implements lldb_private::LanguageRuntime.
Definition at line 367 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::Flags::AllSet(), lldb_private::ValueObject::GetCompilerType(), lldb_private::TypeAndOrName::GetCompilerType(), lldb_private::ConstString::GetCString(), lldb_private::CompilerType::GetLValueReferenceType(), lldb_private::TypeAndOrName::GetName(), lldb_private::CompilerType::GetPointerType(), lldb_private::CompilerType::GetTypeInfo(), lldb_private::TypeAndOrName::HasType(), lldb_private::TypeAndOrName::SetCompilerType(), and lldb_private::TypeAndOrName::SetName().
|
overridevirtual |
Implements lldb_private::LanguageRuntime.
Definition at line 288 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::LanguageRuntime::VTableInfo::addr, lldb_private::TypeSystemClang::AreTypesSame(), lldb_private::TypeAndOrName::Clear(), CouldHaveDynamicValue(), error(), lldb_private::Process::GetAddressByteSize(), lldb_private::ValueObject::GetCompilerType(), lldb_private::TypeAndOrName::GetCompilerType(), lldb_private::Address::GetLoadAddress(), lldb_private::ValueObject::GetPointerValue(), lldb_private::Process::GetTarget(), GetTypeInfo(), GetVTableInfo(), LLDB_INVALID_ADDRESS, lldb_private::Runtime::m_process, lldb_private::Process::ReadSignedIntegerFromMemory(), lldb_private::Target::ResolveLoadAddress(), lldb_private::Value::Scalar, and lldb_private::Address::SetRawAddress().
|
private |
Definition at line 680 of file ItaniumABILanguageRuntime.cpp.
References m_dynamic_type_map, and m_mutex.
Referenced by GetTypeInfo().
|
overridevirtual |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 608 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::ValueObject::CreateValueObjectFromData(), lldb::eBasicTypeVoid, lldb::eDynamicDontRunTarget, lldb::eExpressionCompleted, lldb::eLanguageTypeC, error(), lldb::eSymbolTypeCode, lldb_private::FunctionCaller::ExecuteFunction(), lldb_private::ModuleList::FindSymbolsWithNameAndType(), lldb_private::Symbol::GetAddress(), lldb_private::Process::GetAddressByteSize(), lldb_private::formatters::InferiorSizedWord::GetAsData(), lldb_private::Process::GetByteOrder(), lldb_private::SymbolContextList::GetContextAtIndex(), lldb_private::ScratchTypeSystemClang::GetForTarget(), lldb_private::Target::GetFunctionCallerForLanguage(), lldb_private::Target::GetImages(), lldb_private::CompilerType::GetPointerType(), lldb_private::Value::GetScalar(), lldb_private::Process::GetTarget(), lldb_private::ProcessProperties::GetUtilityExpressionTimeout(), LLDB_INVALID_ADDRESS, lldb_private::Runtime::m_process, lldb_private::Process::ReadPointerFromMemory(), lldb_private::EvaluateExpressionOptions::SetIgnoreBreakpoints(), lldb_private::EvaluateExpressionOptions::SetStopOthers(), lldb_private::EvaluateExpressionOptions::SetTimeout(), lldb_private::EvaluateExpressionOptions::SetTryAllThreads(), lldb_private::EvaluateExpressionOptions::SetUnwindOnError(), lldb_private::SymbolContext::symbol, and lldb_private::Scalar::ULongLong().
|
inlineoverridevirtual |
Implements lldb_private::PluginInterface.
Definition at line 83 of file ItaniumABILanguageRuntime.h.
References GetPluginNameStatic().
|
inlinestatic |
Definition at line 38 of file ItaniumABILanguageRuntime.h.
Referenced by GetPluginName(), and Initialize().
|
private |
Definition at line 57 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::LanguageRuntime::VTableInfo::addr, lldb_private::ConstString::AsCString(), lldb_private::Symbol::CalculateSymbolContextModule(), lldb_private::TypeList::Empty(), lldb_private::ModuleList::FindTypes(), lldb_private::ConstString::GetCString(), lldb_private::Mangled::GetDemangledName(), GetDynamicTypeInfo(), lldb_private::TypeResults::GetFirstType(), lldb_private::Target::GetImages(), lldb_private::GetLog(), lldb_private::Symbol::GetMangled(), lldb_private::ValueObject::GetPointerValue(), lldb_private::TypeList::GetSize(), lldb_private::ConstString::GetStringRef(), lldb_private::Process::GetTarget(), lldb_private::TypeList::GetTypeAtIndex(), lldb_private::TypeResults::GetTypeMap(), lldb_private::ValueObject::GetTypeName(), lldb_private::TypeList::Insert(), lldb_private::TypeSystemClang::IsCXXClassType(), lldb_private::Address::IsSectionOffset(), LLDB_LOGF, lldb_private::Runtime::m_process, lldb_private::Object, SetDynamicTypeInfo(), lldb_private::TypeQuery::SetFindOne(), lldb_private::TypeAndOrName::SetName(), lldb_private::TypeAndOrName::SetTypeSP(), lldb_private::LanguageRuntime::VTableInfo::symbol, lldb_private::TypeMap::Types(), and vtable_demangled_prefix.
Referenced by GetDynamicTypeAndAddress().
|
overridevirtual |
Get the vtable information for a given value.
[in] | in_value | The value object to try and extract the VTableInfo from. |
[in] | check_type | If true, the compiler type of in_value will be checked to see if it is an instance to, or pointer or reference to a class or struct that has a vtable. If the type doesn't meet the requirements, an error will be returned explaining why the type isn't suitable. |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 218 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::Address::CalculateSymbolContextSymbol(), lldb_private::eAddressTypeLoad, error(), lldb_private::Process::FixDataAddress(), lldb_private::ValueObject::GetAddressOf(), lldb_private::ValueObject::GetCompilerType(), lldb_private::Mangled::GetDemangledName(), lldb_private::ValueObject::GetExecutionContextRef(), lldb_private::Symbol::GetMangled(), lldb_private::ValueObject::GetPointerValue(), lldb_private::ExecutionContext::GetProcessPtr(), lldb_private::ConstString::GetStringRef(), lldb_private::Process::GetTarget(), lldb_private::CompilerType::IsPointerOrReferenceType(), LLDB_INVALID_ADDRESS, m_mutex, m_vtable_info_map, lldb_private::Process::ReadPointerFromMemory(), lldb_private::Target::ResolveLoadAddress(), TypeHasVTable(), and vtable_demangled_prefix.
Referenced by GetDynamicTypeAndAddress().
|
static |
Definition at line 480 of file ItaniumABILanguageRuntime.cpp.
References CreateInstance(), GetPluginNameStatic(), and lldb_private::PluginManager::RegisterPlugin().
|
inlineoverridevirtual |
Reimplemented from lldb_private::CPPLanguageRuntime.
Definition at line 42 of file ItaniumABILanguageRuntime.h.
References ID, and lldb_private::CPPLanguageRuntime::isA().
|
private |
Definition at line 690 of file ItaniumABILanguageRuntime.cpp.
References m_dynamic_type_map, and m_mutex.
Referenced by GetTypeInfo().
|
overridevirtual |
Reimplemented from lldb_private::LanguageRuntime.
Definition at line 560 of file ItaniumABILanguageRuntime.cpp.
References CreateExceptionBreakpoint(), m_cxx_exception_bp_sp, and lldb_private::Runtime::m_process.
|
static |
Definition at line 489 of file ItaniumABILanguageRuntime.cpp.
References CreateInstance(), and lldb_private::PluginManager::UnregisterPlugin().
|
private |
Definition at line 184 of file ItaniumABILanguageRuntime.cpp.
References lldb_private::ConstString::AsCString(), lldb_private::CompilerType::GetPointeeType(), lldb_private::CompilerType::GetTypeClass(), lldb_private::CompilerType::GetTypeName(), lldb_private::CompilerType::IsPointerOrReferenceType(), and lldb_private::CompilerType::IsPolymorphicClass().
Referenced by GetVTableInfo().
|
static |
Definition at line 40 of file ItaniumABILanguageRuntime.h.
|
private |
Definition at line 102 of file ItaniumABILanguageRuntime.h.
Referenced by ClearExceptionBreakpoints(), ExceptionBreakpointsAreSet(), ExceptionBreakpointsExplainStop(), and SetExceptionBreakpoints().
|
private |
Definition at line 103 of file ItaniumABILanguageRuntime.h.
Referenced by GetDynamicTypeInfo(), and SetDynamicTypeInfo().
|
private |
Definition at line 105 of file ItaniumABILanguageRuntime.h.
Referenced by GetDynamicTypeInfo(), GetVTableInfo(), and SetDynamicTypeInfo().
|
private |
Definition at line 104 of file ItaniumABILanguageRuntime.h.
Referenced by GetVTableInfo().