-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[lldb] Override Should{Select,Show} in StopReasonBreakpoint #135637
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
[lldb] Override Should{Select,Show} in StopReasonBreakpoint #135637
Conversation
@llvm/pr-subscribers-lldb Author: Felipe de Azevedo Piovezan (felipepiovezan) ChangesThis is necessary so that LLDB does not select (or show the stop reason for) a thread which stopped at an internal breakpoint. Other than manual testing/inspection, which I've done, this does not seem to lend itself to API testing, as we cannot set internal breakpoints through the SBAPI. Full diff: https://github.com/llvm/llvm-project/pull/135637.diff 1 Files Affected:
diff --git a/lldb/source/Target/StopInfo.cpp b/lldb/source/Target/StopInfo.cpp
index f1272a723a8cb..6bdc467af6746 100644
--- a/lldb/source/Target/StopInfo.cpp
+++ b/lldb/source/Target/StopInfo.cpp
@@ -263,6 +263,14 @@ class StopInfoBreakpoint : public StopInfo {
return bp_site_sp->GetSuggestedStackFrameIndex();
}
+ bool ShouldShow() const override {
+ return !m_was_all_internal;
+ }
+
+ bool ShouldSelect() const override {
+ return !m_was_all_internal;
+ }
+
protected:
bool ShouldStop(Event *event_ptr) override {
// This just reports the work done by PerformAction or the synchronous
|
✅ With the latest revision this PR passed the C/C++ code formatter. |
This is necessary so that LLDB does not select (or show the stop reason for) a thread which stopped at an internal breakpoint. Other than manual testing/inspection, which I've done, this does not seem to lend itself to API testing, as we cannot set internal breakpoints through the SBAPI.
2252ae2
to
0383630
Compare
I'm also not sure how you would test this. Pretty much all the predictable internal breakpoints that we set get converted to different StopInfo's before the public stop. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
) This is necessary so that LLDB does not select (or show the stop reason for) a thread which stopped at an internal breakpoint. Other than manual testing/inspection, which I've done, this does not seem to lend itself to API testing, as we cannot set internal breakpoints through the SBAPI. (cherry picked from commit 7491ff7)
) This is necessary so that LLDB does not select (or show the stop reason for) a thread which stopped at an internal breakpoint. Other than manual testing/inspection, which I've done, this does not seem to lend itself to API testing, as we cannot set internal breakpoints through the SBAPI. (cherry picked from commit 7491ff7)
…show_should_select_62 [cherry-pick][lldb] Override Should{Select,Show} in StopReasonBreakpoint (llvm#135637)
This is necessary so that LLDB does not select (or show the stop reason for) a thread which stopped at an internal breakpoint.
Other than manual testing/inspection, which I've done, this does not seem to lend itself to API testing, as we cannot set internal breakpoints through the SBAPI.