37 uint32_t objfile_lc_thread_idx)
38 :
Thread(process, tid), m_thread_name(), m_dispatch_queue_name(),
40 m_objfile_lc_thread_idx(objfile_lc_thread_idx) {}
59 const bool force =
false;
74 uint32_t concrete_frame_idx = 0;
79 if (concrete_frame_idx == 0) {
98 case AppleArm64ExceptionClass::ESR_EC_UNCATEGORIZED:
99 case AppleArm64ExceptionClass::ESR_EC_SVC_32:
100 case AppleArm64ExceptionClass::ESR_EC_SVC_64:
116 Target &target = process_sp->GetTarget();
120 if (cputype == llvm::MachO::CPU_TYPE_ARM64 ||
121 cputype == llvm::MachO::CPU_TYPE_ARM64_32) {
122 const RegisterInfo *esr_info = reg_ctx_sp->GetRegisterInfoByName(
"esr");
123 const RegisterInfo *far_info = reg_ctx_sp->GetRegisterInfoByName(
"far");
125 if (reg_ctx_sp->ReadRegister(esr_info, esr) &&
126 reg_ctx_sp->ReadRegister(far_info, far)) {
132 S.
Printf(
"%s (fault address: 0x%" PRIx64
")",
static bool IsCrashExceptionClass(AppleArm64ExceptionClass EC)
std::string m_thread_name
void RefreshStateAfterStop() override
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)
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
This base class provides an interface to stack frames.
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)
const char * GetData() const
size_t Printf(const char *format,...) __attribute__((format(printf
Output printf formatted output to the stream.
const ArchSpec & GetArchitecture() const
void SetStopInfo(const lldb::StopInfoSP &stop_info_sp)
virtual void DestroyThread()
virtual Unwind & GetUnwinder()
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),...