qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCHv18/8] trace: [tcg] Add per-vCPU tracing states f


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] [PATCHv18/8] trace: [tcg] Add per-vCPU tracing states for events with the 'vcpu' property
Date: Fri, 16 Oct 2015 11:19:29 +0200
User-agent: Mutt/1.5.24 (2015-08-30)

On Tue, Oct 13, 2015 at 07:11:07PM +0200, Lluís Vilanova wrote:
> diff --git a/trace/control-internal.h b/trace/control-internal.h
> index 70e55df..b4069e3 100644
> --- a/trace/control-internal.h
> +++ b/trace/control-internal.h
> @@ -12,6 +12,12 @@
>  
>  #include <string.h>
>  
> +#include "qemu-common.h"
> +/* GTK headers conflict with QOM's '_' */
> +#if !defined(TRACE_CPU_INCLUDE_HACK)
> +#include "qom/cpu.h"
> +#endif
> +
>  
>  extern TraceEvent trace_events[];
>  
> @@ -63,11 +69,16 @@ static inline bool 
> trace_event_get_state_dynamic(TraceEvent *ev)
>      return ev->dstate;
>  }
>  
> -static inline void trace_event_set_state_dynamic(TraceEvent *ev, bool state)
> +static inline bool trace_event_get_cpu_state_dynamic(CPUState *cpu,
> +                                                     TraceEvent *ev)
>  {
> +#if !defined(TRACE_CPU_INCLUDE_HACK)
> +    assert(cpu != NULL);
>      assert(ev != NULL);
> -    assert(trace_event_get_state_static(ev));
> -    ev->dstate = state;
> +    return cpu->tb_phys_idx & (((unsigned long)1) << ev->cpu_id);
> +#else
> +    abort();
> +#endif
>  }

What exactly is the header conflict?



reply via email to

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