qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] Tracing HMP commands
@ 2014-08-18 15:10 Lluís Vilanova
  2014-08-18 15:17 ` Eric Blake
  2014-08-18 15:17 ` Luiz Capitulino
  0 siblings, 2 replies; 4+ messages in thread
From: Lluís Vilanova @ 2014-08-18 15:10 UTC (permalink / raw)
  To: qemu-devel; +Cc: Stefan Hajnoczi, Luiz Capitulino

Hi! I've been writing some QAPI/QMP commands to control tracing state, and I was
wondering if the HMP commands (trace-event, trace-file and trace-events) can be
dropped, or whether I should adapt them to the new ones.


Thanks,
  Lluis

-- 
 "And it's much the same thing with knowledge, for whenever you learn
 something new, the whole world becomes that much richer."
 -- The Princess of Pure Reason, as told by Norton Juster in The Phantom
 Tollbooth

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] Tracing HMP commands
  2014-08-18 15:10 [Qemu-devel] Tracing HMP commands Lluís Vilanova
@ 2014-08-18 15:17 ` Eric Blake
  2014-08-18 16:02   ` Lluís Vilanova
  2014-08-18 15:17 ` Luiz Capitulino
  1 sibling, 1 reply; 4+ messages in thread
From: Eric Blake @ 2014-08-18 15:17 UTC (permalink / raw)
  To: qemu-devel, Stefan Hajnoczi, Luiz Capitulino

[-- Attachment #1: Type: text/plain, Size: 725 bytes --]

On 08/18/2014 09:10 AM, Lluís Vilanova wrote:
> Hi! I've been writing some QAPI/QMP commands to control tracing state, and I was
> wondering if the HMP commands (trace-event, trace-file and trace-events) can be
> dropped, or whether I should adapt them to the new ones.

We've already documented that HMP is an unstable interface; if it is
easier for you to drop commands than to retrofit them to cover new QMP,
it won't hurt my feelings (libvirt only uses QMP).  It boils down to a
judgment call of whether the ease of convenience for a developer's human
interface outweighs the burden of maintenance.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 539 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] Tracing HMP commands
  2014-08-18 15:10 [Qemu-devel] Tracing HMP commands Lluís Vilanova
  2014-08-18 15:17 ` Eric Blake
@ 2014-08-18 15:17 ` Luiz Capitulino
  1 sibling, 0 replies; 4+ messages in thread
From: Luiz Capitulino @ 2014-08-18 15:17 UTC (permalink / raw)
  To: Lluís Vilanova; +Cc: qemu-devel, Stefan Hajnoczi

On Mon, 18 Aug 2014 17:10:36 +0200
Lluís Vilanova <vilanova@ac.upc.edu> wrote:

> Hi! I've been writing some QAPI/QMP commands to control tracing state, and I was
> wondering if the HMP commands (trace-event, trace-file and trace-events) can be
> dropped, or whether I should adapt them to the new ones.

As far as compatibility is concerned, there's no problem dropping them as
they don't exist in QMP. So, this is more a question of deciding what's
the best API for tracing.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] Tracing HMP commands
  2014-08-18 15:17 ` Eric Blake
@ 2014-08-18 16:02   ` Lluís Vilanova
  0 siblings, 0 replies; 4+ messages in thread
From: Lluís Vilanova @ 2014-08-18 16:02 UTC (permalink / raw)
  To: Eric Blake; +Cc: qemu-devel, Stefan Hajnoczi, Luiz Capitulino

Eric Blake writes:

> On 08/18/2014 09:10 AM, Lluís Vilanova wrote:
>> Hi! I've been writing some QAPI/QMP commands to control tracing state, and I was
>> wondering if the HMP commands (trace-event, trace-file and trace-events) can be
>> dropped, or whether I should adapt them to the new ones.

> We've already documented that HMP is an unstable interface; if it is
> easier for you to drop commands than to retrofit them to cover new QMP,
> it won't hurt my feelings (libvirt only uses QMP).  It boils down to a
> judgment call of whether the ease of convenience for a developer's human
> interface outweighs the burden of maintenance.

So far I've added the QAPI commands:

  trace-event-get-state <pattern> # returns a list of event state descriptors
  trace-event-set-state <pattern> <state> # has no return value

They are used in the corresponding HMP commands "info trace-events" and
"trace-event", respectively. Still, I have not figured out how to propagate QMP
errors to HMP, and I was wondering if I can just drop them even if they are
simple to port (qmp-shell is quite convenient).

What I have not ported is "trace-file", which only works for the simple backend,
and would probably require multiple QAPI commands. I'm in favour of just
dropping this one, together with the backend code that exists only to handle
this command (the st_* functions in "trace/simple.h" can then be static or
dropped).


Thanks,
  Lluis

-- 
 "And it's much the same thing with knowledge, for whenever you learn
 something new, the whole world becomes that much richer."
 -- The Princess of Pure Reason, as told by Norton Juster in The Phantom
 Tollbooth

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-08-18 16:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-18 15:10 [Qemu-devel] Tracing HMP commands Lluís Vilanova
2014-08-18 15:17 ` Eric Blake
2014-08-18 16:02   ` Lluís Vilanova
2014-08-18 15:17 ` Luiz Capitulino

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).