[PATCH,gdbserver] Put 'multiprocess+' in to qSupported reply if GDB supports multiprocess

Pedro Alves palves@redhat.com
Tue Jan 15 19:55:00 GMT 2013


On 01/15/2013 09:01 AM, Yao Qi wrote:
> GDBserver put 'multiprocess+' in to qSupported reply regardless of
> whether GDB supports multiprocess.  It doesn't cause any problems
> because if GDB doesn't support multiprocess, GDB doesn't understand
> 'multiprocess+'.  However, I feel it is better not to send
> 'multiprocess+' to GDB if GDB doesn't support multiprocess.

I disagree, and it's a dangerous path to follow.   It may prove useful
to know what exactly does a target support even if your gdb doesn't
support it for instance, as a debugging aid.  Or GDB itself may know
of a feature, but choose to not enable it (and therefore not broadcast
support in its qSupported), but still infer something about the
target from the target's reported features.  So it's more prudent to
make the qSupported reported features as stateless as possible.

-- 
Pedro Alves



More information about the Gdb-patches mailing list