Skip to content

[lldb][debugserver] Fix an off-by-one error in watchpoint identification (#134314) #10450

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

jasonmolenda
Copy link

debugserver takes the address of a watchpoint exception and calculates which watchpoint was responsible for it. There was an off-by-one error in the range calculation which causes two watchpoints on consecutive ranges to not correctly identify hits to the second watchpoint. The result is that lldb wouldn't show the second watchpoint as ever being hit.

Re-landing this test with a modification to only require two watchpoints in the test, instead of four. If four watchpoints can be set, it will test them.

rdar://145107575
(cherry picked from commit df28c81) (cherry picked from commit 4cf806a)

…ion (llvm#134314)

debugserver takes the address of a watchpoint exception and calculates
which watchpoint was responsible for it. There was an off-by-one error
in the range calculation which causes two watchpoints on consecutive
ranges to not correctly identify hits to the second watchpoint. The
result is that lldb wouldn't show the second watchpoint as ever being
hit.

Re-landing this test with a modification to only require two
watchpoints in the test, instead of four.  If four watchpoints can
be set, it will test them.

rdar://145107575
(cherry picked from commit df28c81)
(cherry picked from commit 4cf806a)
@jasonmolenda jasonmolenda requested a review from a team as a code owner April 8, 2025 00:42
@jasonmolenda
Copy link
Author

@swift-ci test

@jasonmolenda
Copy link
Author

@swift-ci test windows

@jasonmolenda jasonmolenda merged commit e606ddd into swiftlang:stable/20240723 Apr 14, 2025
3 checks passed
@jasonmolenda jasonmolenda deleted the cp/r145107575-handle-adjacent-watchpoints-correctly2 branch April 14, 2025 23:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant