================
@@ -577,15 +577,18 @@ StopInfoSP
StopInfoMachException::CreateStopReasonWithMachException(
ProcessSP process_sp(thread.GetProcess());
RegisterContextSP reg_ctx_sp(thread.GetRegisterContext());
- BreakpointSiteSP bp_site_sp;
- addr_t pc = LLDB_INVALID_ADDRESS;
- if (reg_ctx_sp) {
- pc = reg_ctx_sp->GetPC();
- BreakpointSiteSP bp_site_sp =
- process_sp->GetBreakpointSiteList().FindByAddress(pc);
- if (bp_site_sp && bp_site_sp->IsEnabled())
- thread.SetThreadStoppedAtUnexecutedBP(pc);
- }
+ // Caveat: with x86 KDP if we've hit a breakpoint, the pc we
+ // receive is past the breakpoint instruction.
+ // If we have a breakpoint at 0x100 (on a 1-byte original instruction)
----------------
jimingham wrote:
This construction tripped me up, though the content is clear. I'd either say:
If we have breakpoints at ...
or
If we have a breakpoint at... and ONE at 0x101
(not capitalized, I just did that so you could see the change.
https://github.com/llvm/llvm-project/pull/96260
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits