44 uint32_t objfile_lc_thread_idx)
66 const bool force =
false;
80 uint32_t concrete_frame_idx = 0;
84 if (concrete_frame_idx > 0)
101 if (!core_thread_regctx_sp)
108 if (process_md_sp && process_md_sp->GetAsDictionary() &&
109 process_md_sp->GetAsDictionary()->HasKey(
"threads")) {
116 if (thread_sp && thread_sp->GetAsDictionary())
117 thread_md_sp = thread_sp;
121 *
this, concrete_frame_idx, core_thread_regctx_sp, thread_md_sp);
128 case AppleArm64ExceptionClass::ESR_EC_UNCATEGORIZED:
129 case AppleArm64ExceptionClass::ESR_EC_SVC_32:
130 case AppleArm64ExceptionClass::ESR_EC_SVC_64:
146 Target &target = process_sp->GetTarget();
150 if (cputype == llvm::MachO::CPU_TYPE_ARM64 ||
151 cputype == llvm::MachO::CPU_TYPE_ARM64_32) {
152 const RegisterInfo *esr_info = reg_ctx_sp->GetRegisterInfoByName(
"esr");
153 const RegisterInfo *far_info = reg_ctx_sp->GetRegisterInfoByName(
"far");
155 if (reg_ctx_sp->ReadRegister(esr_info, esr) &&
156 reg_ctx_sp->ReadRegister(far_info, far)) {
162 S.
Printf(
"%s (fault address: 0x%" PRIx64
")",
static bool IsCrashExceptionClass(AppleArm64ExceptionClass EC)
std::string m_thread_name
friend class ProcessMachCore
lldb::addr_t m_thread_dispatch_qaddr
void RefreshStateAfterStop() override
std::string m_dispatch_queue_name
ThreadMachCore(lldb_private::Process &process, lldb::tid_t tid, uint32_t objfile_lc_thread_idx)
uint32_t m_objfile_lc_thread_idx
static bool ThreadIDIsValid(lldb::tid_t thread)
~ThreadMachCore() override
lldb::RegisterContextSP CreateRegisterContextForFrame(lldb_private::StackFrame *frame) override
const char * GetName() override
bool CalculateStopInfo() override
Ask the thread subclass to set its stop info.
lldb::RegisterContextSP GetRegisterContext() override
lldb::RegisterContextSP m_thread_reg_ctx_sp
An architecture specification class.
uint32_t GetMachOCPUType() const
A plug-in interface definition class for object file parsers.
virtual lldb::RegisterContextSP GetThreadContextAtIndex(uint32_t idx, lldb_private::Thread &thread)
virtual uint32_t GetNumThreadContexts()
virtual StructuredData::ObjectSP GetCorefileProcessMetadata()
Get process metadata from the corefile in a StructuredData dictionary.
A plug-in interface definition class for debugging a process.
uint64_t GetAsUInt64(uint64_t fail_value=UINT64_MAX, bool *success_ptr=nullptr) const
uint32_t GetAsUInt32(uint32_t fail_value=UINT32_MAX, bool *success_ptr=nullptr) const
uint32_t GetConcreteFrameIndex() const
Query this frame to find what frame it is in this Thread's StackFrameList, not counting inlined frame...
static lldb::StopInfoSP CreateStopReasonWithException(Thread &thread, const char *description)
size_t Printf(const char *format,...) __attribute__((format(printf
Output printf formatted output to the stream.
ObjectSP GetItemAtIndex(size_t idx) const
ObjectSP GetValueForKey(llvm::StringRef key) const
Dictionary * GetAsDictionary()
std::shared_ptr< Object > ObjectSP
const ArchSpec & GetArchitecture() const
void SetStopInfo(const lldb::StopInfoSP &stop_info_sp)
virtual void DestroyThread()
virtual Unwind & GetUnwinder()
Thread(Process &process, lldb::tid_t tid, bool use_invalid_index_id=false)
Constructor.
lldb::ProcessSP GetProcess() const
lldb::RegisterContextSP m_reg_context_sp
The register context for this thread's current register state.
lldb::RegisterContextSP CreateRegisterContextForFrame(StackFrame *frame)
#define LLDB_INVALID_ADDRESS
A class that represents a running process on the host machine.
AppleArm64ExceptionClass getAppleArm64ExceptionClass(uint32_t esr)
Get the Apple ARM64 exception class encoded within esr.
const char * toString(AppleArm64ExceptionClass EC)
std::shared_ptr< lldb_private::Process > ProcessSP
std::shared_ptr< lldb_private::StopInfo > StopInfoSP
std::shared_ptr< lldb_private::RegisterContext > RegisterContextSP
Every register is described in detail including its name, alternate name (optional),...