qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3 04/18] trace: remove global 'uint16 dstate[]'


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v3 04/18] trace: remove global 'uint16 dstate[]' array
Date: Mon, 19 Sep 2016 10:55:04 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0

On 09/19/2016 09:48 AM, Daniel P. Berrange wrote:
> Instead of having a global dstate array, declare a single
> 'uint16 TRACE_${EVENT_NAME}_DSTATE' variable for each
> trace event. Record a pointer to this variable in the
> TraceEvent struct too.
> 
> By turning trace_event_get_state_dynamic_by_id into a
> macro, this still hits the fast path, and cache affinity
> is ensured by declaring all the uint16 vars adjacent to
> each other.
> 
> Signed-off-by: Daniel P. Berrange <address@hidden>
> ---

> +++ b/scripts/tracetool/__init__.py
> @@ -265,11 +265,12 @@ class Event(object):
>  
>      QEMU_TRACE               = "trace_%(name)s"
>      QEMU_TRACE_TCG           = QEMU_TRACE + "_tcg"
> +    QEMU_DSTATE               = "___TRACE_%(NAME)s_DSTATE"

Inconsistent indentation.


> +++ b/trace/control.c
> @@ -28,12 +28,6 @@
>  #include "monitor/monitor.h"
>  
>  int trace_events_enabled_count;
> -/*
> - * Interpretation depends on wether the event has the 'vcpu' property:

Nice - we're nuking a typo while at it...

> +++ b/trace/event-internal.h
> @@ -19,6 +19,11 @@
>   * @vcpu_id: Unique per-vCPU event identifier.
>   * @name: Event name.
>   * @sstate: Static tracing state.
> + * @dstate: Dynamic tracing state
> + *
> + * Interpretation of @dstate depends on wether the event has the 'vcpu' 
> property:

...oh, we just moved it. s/wether/whether/ while touching this.

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

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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