This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 2/3] skip_prolgoue (amd64)


On 12/04/2013 03:38 PM, Tom Tromey wrote:
>>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
> 
> Pedro> Actually "non-stop", vs "all-stop" here isn't the ideal
> Pedro> predicate.  The real predicate is "is any thread running".
> Pedro> "non-stop" is just being currently used in
> Pedro> prepare_execute_command as proxy for that, just because
> Pedro> that was the easiest.
> 
> It seemed to me that the predicate must be "is any thread associated
> with this particular address space running?" -- but I wanted to ask if
> that makes sense, or if that was what you meant.  This idea seems to
> open the door to finer-grained cache flushing.

Yes.  What I'm getting at is that checking whether in non-stop mode
doesn't even say whether anything is running or not, only that it
could, and that the real predicate revolves around "threads are
running" -- we can go finer-grained from that, though obviously at
the expense of predicate complexity.

Actually, even with target-async/all-stop, the target can also
be running when we get to prepare_execute_command, so the
check for non_stop isn't just being overzealous, it's
actually wrong.  We can't actually trigger badness currently,
I think, as with remote/async/all-stop, GDB can't issue RSP commands
to read memory off the target while the target is running, due to
RSP limitation.  And with Linux native/async, you can't read
memory off a running process, due to backend limination.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]