From: Pedro Alves <palves@redhat.com>
To: Yao Qi <yao@codesourcery.com>
Cc: Hui Zhu <hui_zhu@mentor.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] Fix error when gdb connect to a stub that tracepoint is running[1/2] reset current_trace_status in the begin of remote_start_remote
Date: Wed, 08 Feb 2012 18:31:00 -0000 [thread overview]
Message-ID: <4F32BF7A.4000900@redhat.com> (raw)
In-Reply-To: <4F27A4AD.9020608@codesourcery.com>
On 01/31/2012 08:22 AM, Yao Qi wrote:
> Patch attached is used to illustrate my thought to fix this problem. I
> am not confident on it because I don't know it is correct to change the
> order of function calls in remote_start_remote. The "non stop" path in
> remote_start_remote is not affected by this patch. In the "stop" path,
> the order of some functions call is changed, but don't know they are
> equivalent.
>
> Original Patched
>
> start_remote merge_uploaded_tracepoints
> remote_check_symbols start_remote
> merge_uploaded_tracepoints remote_check_symbols
The tracepoints module depends on remote_check_symbols (qSymbols), in
order to detect the IPA is loaded, and so that anything related
to fast tracepoints works. On the other hand, if there are already
fast tracepoints on the target, then the qSymbols business must have
already have been done in the previous time gdb was connected.
I don't think we're okay with this in non-stop mode though. We should
relocate our symbols before we try to merge tracepoints. Yet, we need to
merge tracepoints before any breakpoint re-set. Thing is in non-stop mode,
you find new inferiors and possibly do re-sets early in remote_start_remote
(find threads -> remote_notice_new_inferior -> notice_new_inferior can do a lot
behind the scenes).
It may be simpler and safer to just have a way for update_global_location_list
to know that it shouldn't try to install tracepoints yet (cause we're still going
through startup)?
--
Pedro Alves
next prev parent reply other threads:[~2012-02-08 18:31 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-31 2:05 Hui Zhu
2012-01-31 11:26 ` Yao Qi
2012-01-31 13:06 ` Hui Zhu
2012-01-31 16:49 ` Yao Qi
2012-02-08 18:31 ` Pedro Alves [this message]
2012-02-10 7:50 ` Hui Zhu
2012-02-10 7:54 ` Hui Zhu
2012-02-17 1:26 ` Hui Zhu
2012-02-17 1:21 ` Hui Zhu
2012-02-08 8:39 ` Hui Zhu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F32BF7A.4000900@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=hui_zhu@mentor.com \
--cc=yao@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox