LLDB mainline
lldb_private::GNUstepObjCRuntime Class Reference

#include <GNUstepObjCRuntime.h>

Inheritance diagram for lldb_private::GNUstepObjCRuntime:
[legend]

Public Member Functions

 ~GNUstepObjCRuntime () override
llvm::StringRef GetPluginName () override
void ModulesDidLoad (const ModuleList &module_list) override
 Called when modules have been loaded in the process.
bool isA (const void *ClassID) const override
llvm::Error GetObjectDescription (Stream &str, Value &value, ExecutionContextScope *exe_scope) override
llvm::Error GetObjectDescription (Stream &str, ValueObject &object) override
bool CouldHaveDynamicValue (ValueObject &in_value) override
bool GetDynamicTypeAndAddress (ValueObject &in_value, lldb::DynamicValueType use_dynamic, TypeAndOrName &class_type_or_name, Address &address, Value::ValueType &value_type, llvm::ArrayRef< uint8_t > &local_buffer) override
 This call should return true if it could set the name and/or the type Sets address to the address of the dynamic type if value_type is set to a file or load address.
TypeAndOrName FixUpDynamicType (const TypeAndOrName &type_and_or_name, ValueObject &static_value) override
lldb::BreakpointResolverSP CreateExceptionResolver (const lldb::BreakpointSP &bkpt, bool catch_bp, bool throw_bp) override
lldb::ThreadPlanSP GetStepThroughTrampolinePlan (Thread &thread, bool stop_others) override
bool IsModuleObjCLibrary (const lldb::ModuleSP &module_sp) override
bool ReadObjCLibrary (const lldb::ModuleSP &module_sp) override
bool HasReadObjCLibrary () override
llvm::Expected< std::unique_ptr< UtilityFunction > > CreateObjectChecker (std::string name, ExecutionContext &exe_ctx) override
ObjCRuntimeVersions GetRuntimeVersion () const override
void UpdateISAToDescriptorMapIfNeeded () override
Public Member Functions inherited from lldb_private::ObjCLanguageRuntime
 ~ObjCLanguageRuntime () override
bool isA (const void *ClassID) const override
virtual TaggedPointerVendorGetTaggedPointerVendor ()
virtual EncodingToTypeSP GetEncodingToType ()
virtual ClassDescriptorSP GetClassDescriptor (ValueObject &in_value)
ClassDescriptorSP GetNonKVOClassDescriptor (ValueObject &in_value)
virtual ClassDescriptorSP GetClassDescriptorFromClassName (ConstString class_name)
virtual ClassDescriptorSP GetClassDescriptorFromISA (ObjCISA isa)
ClassDescriptorSP GetNonKVOClassDescriptor (ObjCISA isa)
lldb::LanguageType GetLanguageType () const override
lldb::addr_t LookupInMethodCache (lldb::addr_t class_addr, lldb::addr_t sel)
lldb::addr_t LookupInMethodCache (lldb::addr_t class_addr, llvm::StringRef sel_str)
void AddToMethodCache (lldb::addr_t class_addr, lldb::addr_t sel, lldb::addr_t impl_addr)
void AddToMethodCache (lldb::addr_t class_addr, llvm::StringRef sel_str, lldb::addr_t impl_addr)
TypeAndOrName LookupInClassNameCache (lldb::addr_t class_addr)
void AddToClassNameCache (lldb::addr_t class_addr, const char *name, lldb::TypeSP type_sp)
void AddToClassNameCache (lldb::addr_t class_addr, const TypeAndOrName &class_or_type_name)
lldb::TypeSP LookupInCompleteClassCache (ConstString &name)
std::optional< CompilerTypeGetRuntimeType (CompilerType base_type) override
bool IsValidISA (ObjCISA isa)
void UpdateISAToDescriptorMap ()
virtual ObjCISA GetISA (ConstString name)
virtual ObjCISA GetParentClass (ObjCISA isa)
virtual size_t GetByteOffsetForIvar (CompilerType &parent_qual_type, const char *ivar_name)
bool HasNewLiteralsAndIndexing ()
void SymbolsDidLoad (const ModuleList &module_list) override
std::optional< uint64_t > GetTypeBitSize (const CompilerType &compiler_type) override
bool IsAllowedRuntimeValue (ConstString name) override
 Check whether the name is "self" or "_cmd" and should show up in "frame variable".
Public Member Functions inherited from lldb_private::LanguageRuntime
virtual LanguageRuntimeGetPreferredLanguageRuntime (ValueObject &in_value)
 Return the preferred language runtime instance, which in most cases will be the current instance.
virtual llvm::Expected< VTableInfoGetVTableInfo (ValueObject &in_value, bool check_type)
 Get the vtable information for a given value.
virtual CompilerType GetConcreteType (ExecutionContextScope *exe_scope, ConstString abstract_type_name)
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 DeclVendorGetDeclVendor ()
virtual lldb::SearchFilterSP CreateExceptionSearchFilter ()
void ModulesDidLoad (const ModuleList &module_list) override
 Called when modules have been loaded in the process.
virtual bool GetIRPasses (LLVMUserExpression::IRPasses &custom_passes)
virtual bool IsSymbolARuntimeThunk (const Symbol &symbol)
virtual lldb::addr_t LookupRuntimeSymbol (ConstString name)
virtual StructuredData::ObjectSP GetLanguageSpecificData (SymbolContext sc)
 Language runtime plugins can use this API to report language-specific runtime information about this compile unit, such as additional language version details or feature flags.
Public Member Functions inherited from lldb_private::Runtime
 Runtime (Process *process)
virtual ~Runtime ()=default
 Runtime (const Runtime &)=delete
const Runtimeoperator= (const Runtime &)=delete
ProcessGetProcess ()
TargetGetTargetRef ()
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 void Initialize ()
static void Terminate ()
static lldb_private::LanguageRuntimeCreateInstance (Process *process, lldb::LanguageType language)
static llvm::StringRef GetPluginNameStatic ()
static bool classof (const LanguageRuntime *runtime)
Static Public Member Functions inherited from lldb_private::ObjCLanguageRuntime
static lldb::BreakpointPreconditionSP GetBreakpointExceptionPrecondition (lldb::LanguageType language, bool throw_bp)
static bool classof (const LanguageRuntime *runtime)
static ObjCLanguageRuntimeGet (Process &process)
Static Public Member Functions inherited from lldb_private::LanguageRuntime
static LanguageRuntimeFindPlugin (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::ObjCLanguageRuntime
static char ID = 0
Static Public Attributes inherited from lldb_private::LanguageRuntime
static char ID = 0

Protected Member Functions

 GNUstepObjCRuntime (Process *process)
Protected Member Functions inherited from lldb_private::ObjCLanguageRuntime
 ObjCLanguageRuntime (Process *process)
virtual bool CalculateHasNewLiteralsAndIndexing ()
bool ISAIsCached (ObjCISA isa) const
bool AddClass (ObjCISA isa, const ClassDescriptorSP &descriptor_sp)
bool AddClass (ObjCISA isa, const ClassDescriptorSP &descriptor_sp, const char *class_name)
bool AddClass (ObjCISA isa, const ClassDescriptorSP &descriptor_sp, uint32_t class_name_hash)
ISAToDescriptorIterator GetDescriptorIterator (ConstString name)
std::pair< ISAToDescriptorIterator, ISAToDescriptorIteratorGetDescriptorIteratorPair (bool update_if_needed=true)
void ReadObjCLibraryIfNeeded (const ModuleList &module_list)
 ObjCLanguageRuntime (const ObjCLanguageRuntime &)=delete
const ObjCLanguageRuntimeoperator= (const ObjCLanguageRuntime &)=delete
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)

Protected Attributes

lldb::ModuleSP m_objc_module_sp
Protected Attributes inherited from lldb_private::ObjCLanguageRuntime
uint32_t m_isa_to_descriptor_stop_id
CompleteClassMap m_complete_class_cache
CompleteClassSet m_negative_complete_class_cache
Protected Attributes inherited from lldb_private::Runtime
Processm_process

Additional Inherited Members

Public Types inherited from lldb_private::ObjCLanguageRuntime
enum class  ObjCRuntimeVersions { eObjC_VersionUnknown = 0 , eAppleObjC_V1 = 1 , eAppleObjC_V2 = 2 , eGNUstep_libobjc2 = 3 }
typedef lldb::addr_t ObjCISA
typedef std::shared_ptr< ClassDescriptorClassDescriptorSP
typedef std::shared_ptr< EncodingToTypeEncodingToTypeSP
Protected Types inherited from lldb_private::ObjCLanguageRuntime
typedef std::map< ConstString, lldb::TypeWPCompleteClassMap
typedef std::unordered_set< ConstString, ConstStringSetHelpers, ConstStringSetHelpersCompleteClassSet

Detailed Description

Definition at line 24 of file GNUstepObjCRuntime.h.

Constructor & Destructor Documentation

◆ ~GNUstepObjCRuntime()

GNUstepObjCRuntime::~GNUstepObjCRuntime ( )
overridedefault

◆ GNUstepObjCRuntime()

Member Function Documentation

◆ classof()

bool lldb_private::GNUstepObjCRuntime::classof ( const LanguageRuntime * runtime)
inlinestatic

Definition at line 53 of file GNUstepObjCRuntime.h.

References ID, and lldb_private::LanguageRuntime::isA().

◆ CouldHaveDynamicValue()

bool GNUstepObjCRuntime::CouldHaveDynamicValue ( ValueObject & in_value)
overridevirtual

◆ CreateExceptionResolver()

BreakpointResolverSP GNUstepObjCRuntime::CreateExceptionResolver ( const lldb::BreakpointSP & bkpt,
bool catch_bp,
bool throw_bp )
overridevirtual

◆ CreateInstance()

◆ CreateObjectChecker()

llvm::Expected< std::unique_ptr< UtilityFunction > > GNUstepObjCRuntime::CreateObjectChecker ( std::string name,
ExecutionContext & exe_ctx )
overridevirtual

◆ FixUpDynamicType()

◆ GetDynamicTypeAndAddress()

bool GNUstepObjCRuntime::GetDynamicTypeAndAddress ( ValueObject & in_value,
lldb::DynamicValueType use_dynamic,
TypeAndOrName & class_type_or_name,
Address & address,
Value::ValueType & value_type,
llvm::ArrayRef< uint8_t > & local_buffer )
overridevirtual

This call should return true if it could set the name and/or the type Sets address to the address of the dynamic type if value_type is set to a file or load address.

Sets local_buffer to a buffer containing the data of the dynamic type if value_type is set to a host address. Callers should copy local_buffer over into their own buffer if they want to keep the data alive.

Implements lldb_private::LanguageRuntime.

Definition at line 127 of file GNUstepObjCRuntime.cpp.

◆ GetObjectDescription() [1/2]

llvm::Error GNUstepObjCRuntime::GetObjectDescription ( Stream & str,
Value & value,
ExecutionContextScope * exe_scope )
overridevirtual

Implements lldb_private::LanguageRuntime.

Definition at line 114 of file GNUstepObjCRuntime.cpp.

◆ GetObjectDescription() [2/2]

llvm::Error GNUstepObjCRuntime::GetObjectDescription ( Stream & str,
ValueObject & object )
overridevirtual

Implements lldb_private::LanguageRuntime.

Definition at line 107 of file GNUstepObjCRuntime.cpp.

◆ GetPluginName()

llvm::StringRef lldb_private::GNUstepObjCRuntime::GetPluginName ( )
inlineoverridevirtual

Implements lldb_private::PluginInterface.

Definition at line 45 of file GNUstepObjCRuntime.h.

References GetPluginNameStatic().

◆ GetPluginNameStatic()

llvm::StringRef lldb_private::GNUstepObjCRuntime::GetPluginNameStatic ( )
inlinestatic

Definition at line 41 of file GNUstepObjCRuntime.h.

Referenced by GetPluginName(), and Initialize().

◆ GetRuntimeVersion()

ObjCRuntimeVersions lldb_private::GNUstepObjCRuntime::GetRuntimeVersion ( ) const
inlineoverridevirtual

◆ GetStepThroughTrampolinePlan()

ThreadPlanSP GNUstepObjCRuntime::GetStepThroughTrampolinePlan ( Thread & thread,
bool stop_others )
overridevirtual

Implements lldb_private::LanguageRuntime.

Definition at line 198 of file GNUstepObjCRuntime.cpp.

◆ HasReadObjCLibrary()

bool lldb_private::GNUstepObjCRuntime::HasReadObjCLibrary ( )
inlineoverridevirtual

Implements lldb_private::ObjCLanguageRuntime.

Definition at line 91 of file GNUstepObjCRuntime.h.

References m_objc_module_sp.

◆ Initialize()

void GNUstepObjCRuntime::Initialize ( )
static

◆ isA()

bool lldb_private::GNUstepObjCRuntime::isA ( const void * ClassID) const
inlineoverridevirtual

Reimplemented from lldb_private::LanguageRuntime.

Definition at line 49 of file GNUstepObjCRuntime.h.

References ID, and lldb_private::ObjCLanguageRuntime::isA().

◆ IsModuleObjCLibrary()

bool GNUstepObjCRuntime::IsModuleObjCLibrary ( const lldb::ModuleSP & module_sp)
overridevirtual

Implements lldb_private::ObjCLanguageRuntime.

Definition at line 208 of file GNUstepObjCRuntime.cpp.

◆ ModulesDidLoad()

void GNUstepObjCRuntime::ModulesDidLoad ( const ModuleList & module_list)
overridevirtual

Called when modules have been loaded in the process.

Implements lldb_private::Runtime.

Definition at line 222 of file GNUstepObjCRuntime.cpp.

◆ ReadObjCLibrary()

bool GNUstepObjCRuntime::ReadObjCLibrary ( const lldb::ModuleSP & module_sp)
overridevirtual

Implements lldb_private::ObjCLanguageRuntime.

Definition at line 213 of file GNUstepObjCRuntime.cpp.

◆ Terminate()

void GNUstepObjCRuntime::Terminate ( )
static

◆ UpdateISAToDescriptorMapIfNeeded()

void GNUstepObjCRuntime::UpdateISAToDescriptorMapIfNeeded ( )
overridevirtual

Implements lldb_private::ObjCLanguageRuntime.

Definition at line 204 of file GNUstepObjCRuntime.cpp.

Member Data Documentation

◆ ID

char GNUstepObjCRuntime::ID = 0
static

Definition at line 32 of file GNUstepObjCRuntime.h.

Referenced by classof(), and isA().

◆ m_objc_module_sp

lldb::ModuleSP lldb_private::GNUstepObjCRuntime::m_objc_module_sp
protected

Definition at line 106 of file GNUstepObjCRuntime.h.

Referenced by GNUstepObjCRuntime(), and HasReadObjCLibrary().


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