qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 1/1] monitor: improve tracing in handle_qmp_c


From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v2 1/1] monitor: improve tracing in handle_qmp_command
Date: Mon, 31 Jul 2017 09:25:41 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Eric Blake <address@hidden> writes:

> On 07/28/2017 12:01 PM, Markus Armbruster wrote:
>> "Denis V. Lunev" <address@hidden> writes:
>> 
>>> Calculate req_json only if trace_handle_qmp_command enabled.
>>>
>>> Signed-off-by: Denis V. Lunev <address@hidden>
>>> CC: Stefan Hajnoczi <address@hidden>
>>> CC: LluĂ­s Vilanova <address@hidden>
>>> CC: Dr. David Alan Gilbert <address@hidden>
>>> CC: Markus Armbruster <address@hidden>
>>> ---
>
>> Conflicts with Eric's commit 8a4613a, but I can resolve that in my tree.
>> 
>> The commit message is too terse.  "Improve tracing" makes me think of
>> more informative traces, but that's not the case.  What exactly is
>> improved here?
>
> Reduce overhead when not tracing.  Without the patch, we are malloc'ing
> a QString and spending CPU cycles on converting a QObject to string,
> just for the sake of sticking the string in the trace message - if we
> aren't tracing, it's wasted effort.

What about:

    monitor: Reduce handle_qmp_command() tracing overhead

    We are malloc'ing a QString and spending CPU cycles on converting a
    QObject to string, just for the sake of sticking the string in the
    trace message.  Wasted when we aren't tracing.  Avoid that.

Denis?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]