This is the mail archive of the gdb@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: The 'x' command: size problem


On Tue, Sep 06, 2005 at 07:35:12PM +0400, Vladimir Prus wrote:
> No, it's not very hard. But given anynchronious nature of communication with 
> gdb I'm trying to limit the number of queries to minimum, to minimize the 
> amount of data I have to keep.

The MI data stream is basically synchronous.  Sure, there are
asynchronous notifications in it.  But a synchronous reply always
corresponds to the previously implemented synchronous command, doesn't
it?  It's serialized, so if you have a lot of different threads wanting
to bang away at GDB, sure you're going to need some bookkeeping.

> <aside>
> I might be wrong, but I feel it would be much better if gdb were a library 
> that I could link to. That would eliminate most anynchonious communication 
> and won't require to keep track which gdb reply corresponds to which 
> previously issued command and where the result of the command must be sent 
> inside the frontend.
> </aside>

And it'll give you a whole new host of issues keeping up with the
changing interface.  And GDB does some fairly complicated things using
signals and wait, which can yield very surprising behavior if you're
running it in the same context as your GUI.

I don't see how it would eliminate the need for asynchronous
interfaces, either.

I still think the MI communication model we've evolved is the best
choice.

-- 
Daniel Jacobowitz
CodeSourcery, LLC


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