Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 28 Jul 2002 18:38:17 +1000
From:      Peter Grehan <peterg@ptree32.com.au>
To:        freebsd-ppc@freebsd.org
Subject:   Re: gdb
Message-ID:  <3D43AD79.8891C503@ptree32.com.au>
References:  <1027732166.3d41f2c662b9e@www.wantpackets.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi Andy,

>  Peter G, What is your take on the gdb "problem?"
> The simulator uses its own I/O scheme, but gdb uses readline for pretty-bloat.
> (Not to mention it actually is quite useful at times.)
> I want to know what you think (or anybody with helpful experiece) should be done,
> or rather, more precisely, how.

 When running in gdb, psim uses i/o calls from gdb/sim/common/callback.c,
which are all pretty simple, and blocking :-( There's at least a few solutions:

 - add a 'set nonblocking t/f' call to the callback vector in callback.c, so
   the sim_io_read_stdin code could call this before and after the read call.

 - in sim/ppc/sim_calls.c:sim_io_read_stdin(), if DONT_USE_STDIO is defined,
   copy the code from sim/ppc/main.c for that same block of code.

 - in sim/ppc/hw_pal.c, allow a filename to be specified for the tty
   read/write registers in the tree config file. This could default to be 
   the sim_io_{read/write} calls, but could allow some interesting uses, 
   such as a slave pty to allow sim i/o to occur in another terminal window.

later,

Peter.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ppc" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3D43AD79.8891C503>