[Lldb-commits] [lldb] [lldb][Windows] Append access-violation detail to lldb-server stop description (PR #203301)
Charles Zablit via lldb-commits
lldb-commits at lists.llvm.org
Thu Jun 11 08:58:44 PDT 2026
================
@@ -24,49 +28,31 @@ namespace lldb_private {
// notification of events that happen in a debugged process.
class ExceptionRecord {
public:
- ExceptionRecord(const EXCEPTION_RECORD &record, lldb::tid_t thread_id) {
- // Notes about the `record.ExceptionRecord` field:
- // In the past, some code tried to parse the nested exception with it, but
- // in practice, that code just causes Access Violation. I suspect
- // `ExceptionRecord` here actually points to the address space of the
- // debuggee process. However, I did not manage to find any official or
- // unofficial reference that clarifies this point. If anyone would like to
- // reimplement this, please also keep in mind to check how this behaves when
- // debugging a WOW64 process. I suspect you may have to use the explicit
- // `EXCEPTION_RECORD32` and `EXCEPTION_RECORD64` structs.
- m_code = record.ExceptionCode;
- m_continuable = (record.ExceptionFlags == 0);
- m_exception_addr = reinterpret_cast<lldb::addr_t>(record.ExceptionAddress);
- m_thread_id = thread_id;
- m_arguments.assign(record.ExceptionInformation,
- record.ExceptionInformation + record.NumberParameters);
- }
+ ExceptionRecord(const EXCEPTION_RECORD &record, lldb::tid_t thread_id);
// MINIDUMP_EXCEPTIONs are almost identical to EXCEPTION_RECORDs.
- ExceptionRecord(const MINIDUMP_EXCEPTION &record, lldb::tid_t thread_id)
- : m_code(record.ExceptionCode), m_continuable(record.ExceptionFlags == 0),
- m_exception_addr(static_cast<lldb::addr_t>(record.ExceptionAddress)),
- m_thread_id(thread_id),
- m_arguments(record.ExceptionInformation,
- record.ExceptionInformation + record.NumberParameters) {}
+ ExceptionRecord(const MINIDUMP_EXCEPTION &record, lldb::tid_t thread_id);
virtual ~ExceptionRecord() = default;
- DWORD
- GetExceptionCode() const { return m_code; }
+ unsigned long GetExceptionValue() const { return m_code; }
bool IsContinuable() const { return m_continuable; }
lldb::addr_t GetExceptionAddress() const { return m_exception_addr; }
lldb::tid_t GetThreadID() const { return m_thread_id; }
- const std::vector<ULONG_PTR>& GetExceptionArguments() const { return m_arguments; }
+ const std::vector<unsigned long long> &GetExceptionArguments() const {
----------------
charles-zablit wrote:
Fixed, thanks!
https://github.com/llvm/llvm-project/pull/203301
More information about the lldb-commits
mailing list