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] Delete struct inferior_suspend_state


On Thu, Jul 31, 2014 at 1:58 PM, Doug Evans <dje@google.com> wrote:
> [...]
> It would be interesting to do an audit and see how many outdated
> comments gdb has.
> [...]

I'm happy to go with whatever the community wants (I want to be clear
that I'm not trying to advance any particular position on this patch -
I do have opinions on how to handle the various choices, but I don't
favor any particular choice).

But as a data point to the above comment, because I think it's an
important issue,
this comment in inf-loop.c is odd.  I happened across it because I'm
trying to implement having the event loop handle waiting for all
threads to stop, instead of doing the waiting in a special loop apart
from the event loop.

inf-loop.c:

/* General function to handle events in the inferior.  So far it just
   takes care of detecting errors reported by select() or poll(),
   otherwise it assumes that all is OK, and goes on reading data from
   the fd.  This however may not always be what we want to do.  */
void
inferior_event_handler (enum inferior_event_type event_type,
                        gdb_client_data client_data)
{
  ...

AFAICT, it doesn't match what the function does at all.

inferior_event_handler + fetch_inferior_event is also a bit odd.
I see some cleanup potential here, more on that later (I hope, pending
finding the time :-)).


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