This is the mail archive of the archer@sourceware.org mailing list for the Archer 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: froggy plans


On Wed, 25 Feb 2009 19:43:18 +0100, Chris Moller wrote:
> From comments during the mtg, I think what I need to do now is back off
> from wedging froggy into gdb for a while

add_file_handler() can be used with fd = froggy_fd (froggy),
proc = something-like-froggy.c:resp_listener.

You should remove at least `linux_nat_event_pipe' and `linux_nat_async' to get
errors on any of its use which should be now replaced by froggy and its
froggy_fd (froggy) handling.

my_waitpid() currently calls queued_waitpid() while
something-like-froggy.c:resp_listener should store the received events by
push_waitpid() to make them retrievable by my_waitpid().

If my_waitpid() finds `waitpid_queue' is empty and it would call waitpid(2)
the froggy port in such (only) case should do its blocking wait on a new event
to come from waitpid_queue.  (According to the 3rd paragraph of the
linux-nat.c doc part `Waiting for events in async mode'.)

You can fortunately get rid of `linux_nat_event_pipe' as poll() could not wait
on SIGCHLD.  IMO FSF GDB could use ppoll() directly catching both file events
and SIGCHLDs (leading to waitpid()).  Therefore to have only `waitpid_queue'
without the need of `linux_nat_event_pipe'.  But I may miss something.

Sure I miss a lot of stuff but IMO worth a try.


>     * detach with optional wait-until-detached (was already in plan, but
>       hadn't gotten around to coding it)
>     * kill with optional wait-until-dead-or-timeout

Any waiting/blocking call is not usable for the GDB non-stop/async mode (which
is the target for Eclipse/MI operation mode).  IMO the libfroggy functions
should be first more driven by the GDB port requirements, shouldn't they?


When using latest:
	cvs -d :ext:sources.redhat.com:/cvs/systemtap co froggy
	archer-moller-froggy-v2
	CFLAGS='-m32' ./configure --with-froggy=/home/jkratoch/redhat/froggy/froggy i386-unknown-linux-gnu
I still get (and cannot find froggy_singlestep_pid() anywhere):
	inf-ptrace-froggy.c:270: error: implicit declaration of function ‘froggy_singlestep_pid’

Also could you please provide a x86_64 port?  Without -m32 I get:
	froggy.c:424: error: invalid application of ‘sizeof’ to incomplete type ‘struct user_fpxregs_struct’ 
	


Regards,
Jan


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