LLDB  mainline
Classes | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Friends | List of all members
lldb_private::AppleObjCRuntimeV2 Class Reference

#include <AppleObjCRuntimeV2.h>

Inheritance diagram for lldb_private::AppleObjCRuntimeV2:
Inheritance graph
[legend]
Collaboration diagram for lldb_private::AppleObjCRuntimeV2:
Collaboration graph
[legend]

Public Member Functions

 ~AppleObjCRuntimeV2 () override=default
 
bool GetDynamicTypeAndAddress (ValueObject &in_value, lldb::DynamicValueType use_dynamic, TypeAndOrName &class_type_or_name, Address &address, Value::ValueType &value_type) override
 
UtilityFunctionCreateObjectChecker (const char *) override
 
ConstString GetPluginName () override
 
uint32_t GetPluginVersion () override
 
ObjCRuntimeVersions GetRuntimeVersion () const override
 
size_t GetByteOffsetForIvar (CompilerType &parent_qual_type, const char *ivar_name) override
 
void UpdateISAToDescriptorMapIfNeeded () override
 
ConstString GetActualTypeName (ObjCLanguageRuntime::ObjCISA isa) override
 
ClassDescriptorSP GetClassDescriptor (ValueObject &in_value) override
 
ClassDescriptorSP GetClassDescriptorFromISA (ObjCISA isa) override
 
DeclVendorGetDeclVendor () override
 
lldb::addr_t LookupRuntimeSymbol (ConstString name) override
 
EncodingToTypeSP GetEncodingToType () override
 
bool IsTaggedPointer (lldb::addr_t ptr) override
 
TaggedPointerVendorGetTaggedPointerVendor () override
 
lldb::addr_t GetTaggedPointerObfuscator ()
 
void GetValuesForGlobalCFBooleans (lldb::addr_t &cf_true, lldb::addr_t &cf_false) override
 
- Public Member Functions inherited from lldb_private::AppleObjCRuntime
 ~AppleObjCRuntime () override
 
bool GetObjectDescription (Stream &str, Value &value, ExecutionContextScope *exe_scope) override
 
bool GetObjectDescription (Stream &str, ValueObject &object) override
 
bool CouldHaveDynamicValue (ValueObject &in_value) override
 
TypeAndOrName FixUpDynamicType (const TypeAndOrName &type_and_or_name, ValueObject &static_value) override
 
bool IsModuleObjCLibrary (const lldb::ModuleSP &module_sp) override
 
bool ReadObjCLibrary (const lldb::ModuleSP &module_sp) override
 
bool HasReadObjCLibrary () override
 
lldb::ThreadPlanSP GetStepThroughTrampolinePlan (Thread &thread, bool stop_others) override
 
lldb::ModuleSP GetObjCModule ()
 
void ModulesDidLoad (const ModuleList &module_list) override
 
void SetExceptionBreakpoints () override
 
void ClearExceptionBreakpoints () override
 
bool ExceptionBreakpointsAreSet () override
 
bool ExceptionBreakpointsExplainStop (lldb::StopInfoSP stop_reason) override
 
lldb::SearchFilterSP CreateExceptionSearchFilter () override
 
lldb::ValueObjectSP GetExceptionObjectForThread (lldb::ThreadSP thread_sp) override
 
lldb::ThreadSP GetBacktraceThreadFromException (lldb::ValueObjectSP thread_sp) override
 
uint32_t GetFoundationVersion ()
 
- Public Member Functions inherited from lldb_private::ObjCLanguageRuntime
 ~ObjCLanguageRuntime () override
 
ClassDescriptorSP GetNonKVOClassDescriptor (ValueObject &in_value)
 
virtual ClassDescriptorSP GetClassDescriptorFromClassName (ConstString class_name)
 
ClassDescriptorSP GetNonKVOClassDescriptor (ObjCISA isa)
 
lldb::LanguageType GetLanguageType () const override
 
lldb::addr_t LookupInMethodCache (lldb::addr_t class_addr, lldb::addr_t sel)
 
void AddToMethodCache (lldb::addr_t class_addr, lldb::addr_t sel, 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)
 
bool IsValidISA (ObjCISA isa)
 
void UpdateISAToDescriptorMap ()
 
virtual ObjCISA GetISA (ConstString name)
 
virtual ObjCISA GetParentClass (ObjCISA isa)
 
bool HasNewLiteralsAndIndexing ()
 
virtual void SymbolsDidLoad (const ModuleList &module_list)
 
bool GetTypeBitSize (const CompilerType &compiler_type, uint64_t &size) override
 
bool IsRuntimeSupportValue (ValueObject &valobj) override
 Identify whether a value is a language implementation detaul that should be hidden from the user interface by default. More...
 
- Public Member Functions inherited from lldb_private::LanguageRuntime
 ~LanguageRuntime () override
 
virtual CompilerType GetConcreteType (ExecutionContextScope *exe_scope, ConstString abstract_type_name)
 
ProcessGetProcess ()
 
TargetGetTargetRef ()
 
virtual bool GetOverrideExprOptions (clang::TargetOptions &prototype)
 
virtual bool GetIRPasses (LLVMUserExpression::IRPasses &custom_passes)
 
- Public Member Functions inherited from lldb_private::PluginInterface
virtual ~PluginInterface ()
 

Static Public Member Functions

static void Initialize ()
 
static void Terminate ()
 
static lldb_private::LanguageRuntimeCreateInstance (Process *process, lldb::LanguageType language)
 
static lldb_private::ConstString GetPluginNameStatic ()
 
static bool classof (const ObjCLanguageRuntime *runtime)
 
- Static Public Member Functions inherited from lldb_private::AppleObjCRuntime
static bool classof (const ObjCLanguageRuntime *runtime)
 
static std::tuple< FileSpec, ConstStringGetExceptionThrowLocation ()
 
- Static Public Member Functions inherited from lldb_private::ObjCLanguageRuntime
static bool IsWhitelistedRuntimeValue (ConstString name)
 Check whether the name is "self" or "_cmd" and should show up in "frame variable". More...
 
- 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 Breakpoint::BreakpointPreconditionSP CreateExceptionPrecondition (lldb::LanguageType language, bool catch_bp, bool throw_bp)
 

Static Public Attributes

static const ObjCLanguageRuntime::ObjCISA g_objc_Tagged_ISA = 1
 
static const ObjCLanguageRuntime::ObjCISA g_objc_Tagged_ISA_NSAtom = 2
 
static const ObjCLanguageRuntime::ObjCISA g_objc_Tagged_ISA_NSNumber = 3
 
static const ObjCLanguageRuntime::ObjCISA g_objc_Tagged_ISA_NSDateTS = 4
 
static const ObjCLanguageRuntime::ObjCISA g_objc_Tagged_ISA_NSManagedObject
 
static const ObjCLanguageRuntime::ObjCISA g_objc_Tagged_ISA_NSDate = 6
 

Protected Member Functions

lldb::BreakpointResolverSP CreateExceptionResolver (Breakpoint *bkpt, bool catch_bp, bool throw_bp) override
 
- Protected Member Functions inherited from lldb_private::AppleObjCRuntime
 AppleObjCRuntime (Process *process)
 
bool CalculateHasNewLiteralsAndIndexing () override
 
void ReadObjCLibraryIfNeeded (const ModuleList &module_list)
 
AddressGetPrintForDebuggerAddr ()
 
- Protected Member Functions inherited from lldb_private::ObjCLanguageRuntime
 ObjCLanguageRuntime (Process *process)
 
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, ISAToDescriptorIterator > GetDescriptorIteratorPair (bool update_if_needed=true)
 
void ReadObjCLibraryIfNeeded (const ModuleList &module_list)
 
 DISALLOW_COPY_AND_ASSIGN (ObjCLanguageRuntime)
 
- Protected Member Functions inherited from lldb_private::LanguageRuntime
 LanguageRuntime (Process *process)
 

Friends

class ClassDescriptorV2
 

Additional Inherited Members

- Public Types inherited from lldb_private::ObjCLanguageRuntime
enum  ObjCRuntimeVersions { ObjCRuntimeVersions::eObjC_VersionUnknown = 0, ObjCRuntimeVersions::eAppleObjC_V1 = 1, ObjCRuntimeVersions::eAppleObjC_V2 = 2 }
 
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::TypeWP > CompleteClassMap
 
typedef std::unordered_set< ConstString, ConstStringSetHelpers, ConstStringSetHelpersCompleteClassSet
 
- Static Protected Member Functions inherited from lldb_private::AppleObjCRuntime
static bool AppleIsModuleObjCLibrary (const lldb::ModuleSP &module_sp)
 
static ObjCRuntimeVersions GetObjCVersion (Process *process, lldb::ModuleSP &objc_module_sp)
 
- Protected Attributes inherited from lldb_private::AppleObjCRuntime
std::unique_ptr< Addressm_PrintForDebugger_addr
 
bool m_read_objc_library
 
std::unique_ptr< lldb_private::AppleObjCTrampolineHandlerm_objc_trampoline_handler_up
 
lldb::BreakpointSP m_objc_exception_bp_sp
 
lldb::ModuleWP m_objc_module_wp
 
std::unique_ptr< FunctionCallerm_print_object_caller_up
 
llvm::Optional< uint32_tm_Foundation_major
 
- 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::LanguageRuntime
Processm_process
 

Detailed Description

Definition at line 24 of file AppleObjCRuntimeV2.h.

Constructor & Destructor Documentation

◆ ~AppleObjCRuntimeV2()

lldb_private::AppleObjCRuntimeV2::~AppleObjCRuntimeV2 ( )
overridedefault

Member Function Documentation

◆ classof()

static bool lldb_private::AppleObjCRuntimeV2::classof ( const ObjCLanguageRuntime runtime)
inlinestatic

◆ CreateExceptionResolver()

BreakpointResolverSP AppleObjCRuntimeV2::CreateExceptionResolver ( Breakpoint bkpt,
bool  catch_bp,
bool  throw_bp 
)
overrideprotectedvirtual

◆ CreateInstance()

LanguageRuntime * AppleObjCRuntimeV2::CreateInstance ( Process process,
lldb::LanguageType  language 
)
static

Definition at line 479 of file AppleObjCRuntimeV2.cpp.

References lldb::eLanguageTypeObjC.

◆ CreateObjectChecker()

UtilityFunction * AppleObjCRuntimeV2::CreateObjectChecker ( const char *  name)
overridevirtual

Implements lldb_private::ObjCLanguageRuntime.

Definition at line 831 of file AppleObjCRuntimeV2.cpp.

References lldb::eLanguageTypeObjC, and UNUSED_IF_ASSERT_DISABLED.

Referenced by classof().

◆ GetActualTypeName()

ConstString AppleObjCRuntimeV2::GetActualTypeName ( ObjCLanguageRuntime::ObjCISA  isa)
overridevirtual

Reimplemented from lldb_private::ObjCLanguageRuntime.

Definition at line 1934 of file AppleObjCRuntimeV2.cpp.

Referenced by GetRuntimeVersion().

◆ GetByteOffsetForIvar()

size_t AppleObjCRuntimeV2::GetByteOffsetForIvar ( CompilerType parent_qual_type,
const char *  ivar_name 
)
overridevirtual

◆ GetClassDescriptor()

ObjCLanguageRuntime::ClassDescriptorSP AppleObjCRuntimeV2::GetClassDescriptor ( ValueObject in_value)
overridevirtual

◆ GetClassDescriptorFromISA()

ObjCLanguageRuntime::ClassDescriptorSP AppleObjCRuntimeV2::GetClassDescriptorFromISA ( ObjCISA  isa)
overridevirtual

Reimplemented from lldb_private::ObjCLanguageRuntime.

Definition at line 1157 of file AppleObjCRuntimeV2.cpp.

Referenced by GetRuntimeVersion().

◆ GetDeclVendor()

DeclVendor * AppleObjCRuntimeV2::GetDeclVendor ( )
overridevirtual

Reimplemented from lldb_private::ObjCLanguageRuntime.

Definition at line 1963 of file AppleObjCRuntimeV2.cpp.

Referenced by GetRuntimeVersion().

◆ GetDynamicTypeAndAddress()

bool AppleObjCRuntimeV2::GetDynamicTypeAndAddress ( ValueObject in_value,
lldb::DynamicValueType  use_dynamic,
TypeAndOrName class_type_or_name,
Address address,
Value::ValueType value_type 
)
overridevirtual

◆ GetEncodingToType()

ObjCLanguageRuntime::EncodingToTypeSP AppleObjCRuntimeV2::GetEncodingToType ( )
overridevirtual

◆ GetPluginName()

lldb_private::ConstString AppleObjCRuntimeV2::GetPluginName ( )
overridevirtual

Implements lldb_private::PluginInterface.

Definition at line 809 of file AppleObjCRuntimeV2.cpp.

Referenced by classof().

◆ GetPluginNameStatic()

lldb_private::ConstString AppleObjCRuntimeV2::GetPluginNameStatic ( )
static

Definition at line 803 of file AppleObjCRuntimeV2.cpp.

◆ GetPluginVersion()

uint32_t AppleObjCRuntimeV2::GetPluginVersion ( )
overridevirtual

Implements lldb_private::PluginInterface.

Definition at line 813 of file AppleObjCRuntimeV2.cpp.

Referenced by classof().

◆ GetRuntimeVersion()

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

◆ GetTaggedPointerObfuscator()

lldb::addr_t AppleObjCRuntimeV2::GetTaggedPointerObfuscator ( )

Definition at line 1212 of file AppleObjCRuntimeV2.cpp.

References lldb_private::Process::AllocateMemory(), lldb_private::Status::AsCString(), lldb_private::DiagnosticManager::Clear(), lldb_private::Process::DeallocateMemory(), lldb_private::DiagnosticManager::Dump(), lldb::eBasicTypeVoid, lldb::eEncodingUint, lldb::eExpressionCompleted, lldb::eLanguageTypeObjC, lldb::eSymbolTypeAny, lldb_private::FunctionCaller::ExecuteFunction(), lldb_private::Status::Fail(), lldb_private::SectionList::FindSectionByName(), g_get_dynamic_class_info_body, g_get_dynamic_class_info_name, g_get_shared_cache_class_info_body, g_get_shared_cache_class_info_name, lldb_private::Process::GetAddressByteSize(), lldb_private::FunctionCaller::GetArgumentValues(), lldb_private::ClangASTContext::GetBasicType(), lldb_private::ClangASTContext::GetBuiltinTypeForEncodingAndBitSize(), lldb_private::Process::GetByteOrder(), lldb_private::DataBufferHeap::GetBytes(), lldb_private::DataBufferHeap::GetByteSize(), RemoteNXMapTable::GetCount(), lldb_private::ThreadList::GetExpressionExecutionThread(), lldb_private::Symbol::GetLoadAddress(), lldb_private::GetLogIfAllCategoriesSet(), lldb_private::GetLogIfAnyCategoriesSet(), lldb_private::DataExtractor::GetPointer(), lldb_private::CompilerType::GetPointerType(), lldb_private::Value::GetScalar(), lldb_private::Target::GetScratchClangASTContext(), RemoteNXMapTable::GetTableLoadAddress(), lldb_private::Process::GetTarget(), lldb_private::Process::GetThreadList(), lldb_private::DataExtractor::GetU32(), lldb_private::ProcessProperties::GetUtilityExpressionTimeout(), lldb_private::ValueList::GetValueAtIndex(), lldb_private::Log::GetVerbose(), LIBLLDB_LOG_PROCESS, LIBLLDB_LOG_TYPES, LLDB_INVALID_ADDRESS, lldb_private::Log::Printf(), lldb_private::ValueList::PushValue(), lldb_private::Process::ReadMemory(), lldb_private::Process::ReadPointerFromMemory(), lldb_private::Value::SetCompilerType(), lldb_private::EvaluateExpressionOptions::SetIgnoreBreakpoints(), lldb_private::EvaluateExpressionOptions::SetIsForUtilityExpr(), lldb_private::EvaluateExpressionOptions::SetStopOthers(), lldb_private::EvaluateExpressionOptions::SetTimeout(), lldb_private::EvaluateExpressionOptions::SetTryAllThreads(), lldb_private::EvaluateExpressionOptions::SetUnwindOnError(), lldb_private::Value::SetValueType(), lldb_private::Scalar::ULong(), and lldb_private::FunctionCaller::WriteFunctionArguments().

Referenced by GetTaggedPointerVendor().

◆ GetTaggedPointerVendor()

TaggedPointerVendor* lldb_private::AppleObjCRuntimeV2::GetTaggedPointerVendor ( )
inlineoverridevirtual

◆ GetValuesForGlobalCFBooleans()

void AppleObjCRuntimeV2::GetValuesForGlobalCFBooleans ( lldb::addr_t cf_true,
lldb::addr_t cf_false 
)
overridevirtual

Reimplemented from lldb_private::AppleObjCRuntime.

Definition at line 2610 of file AppleObjCRuntimeV2.cpp.

Referenced by GetTaggedPointerVendor().

◆ Initialize()

void AppleObjCRuntimeV2::Initialize ( )
static

◆ IsTaggedPointer()

bool AppleObjCRuntimeV2::IsTaggedPointer ( lldb::addr_t  ptr)
overridevirtual

Reimplemented from lldb_private::AppleObjCRuntime.

Definition at line 931 of file AppleObjCRuntimeV2.cpp.

Referenced by GetRuntimeVersion().

◆ LookupRuntimeSymbol()

lldb::addr_t AppleObjCRuntimeV2::LookupRuntimeSymbol ( ConstString  name)
overridevirtual

◆ Terminate()

void AppleObjCRuntimeV2::Terminate ( )
static

◆ UpdateISAToDescriptorMapIfNeeded()

void AppleObjCRuntimeV2::UpdateISAToDescriptorMapIfNeeded ( )
overridevirtual

Friends And Related Function Documentation

◆ ClassDescriptorV2

friend class ClassDescriptorV2
friend

Definition at line 315 of file AppleObjCRuntimeV2.h.

Member Data Documentation

◆ g_objc_Tagged_ISA

const ObjCLanguageRuntime::ObjCISA lldb_private::AppleObjCRuntimeV2::g_objc_Tagged_ISA = 1
static

Definition at line 97 of file AppleObjCRuntimeV2.h.

◆ g_objc_Tagged_ISA_NSAtom

const ObjCLanguageRuntime::ObjCISA lldb_private::AppleObjCRuntimeV2::g_objc_Tagged_ISA_NSAtom = 2
static

Definition at line 98 of file AppleObjCRuntimeV2.h.

◆ g_objc_Tagged_ISA_NSDate

const ObjCLanguageRuntime::ObjCISA lldb_private::AppleObjCRuntimeV2::g_objc_Tagged_ISA_NSDate = 6
static

Definition at line 103 of file AppleObjCRuntimeV2.h.

◆ g_objc_Tagged_ISA_NSDateTS

const ObjCLanguageRuntime::ObjCISA lldb_private::AppleObjCRuntimeV2::g_objc_Tagged_ISA_NSDateTS = 4
static

Definition at line 100 of file AppleObjCRuntimeV2.h.

◆ g_objc_Tagged_ISA_NSManagedObject

const ObjCLanguageRuntime::ObjCISA lldb_private::AppleObjCRuntimeV2::g_objc_Tagged_ISA_NSManagedObject
static
Initial value:
=
5

Definition at line 101 of file AppleObjCRuntimeV2.h.

◆ g_objc_Tagged_ISA_NSNumber

const ObjCLanguageRuntime::ObjCISA lldb_private::AppleObjCRuntimeV2::g_objc_Tagged_ISA_NSNumber = 3
static

Definition at line 99 of file AppleObjCRuntimeV2.h.


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