/* This file is autogenerated by tracetool, do not edit. */
/* SPDX-License-Identifier: GPL-2.0-or-later */

#ifndef TRACE_ROOT_GENERATED_TRACERS_H
#define TRACE_ROOT_GENERATED_TRACERS_H

#include "trace/control.h"

extern TraceEvent _TRACE_BREAKPOINT_INSERT_EVENT;
extern TraceEvent _TRACE_BREAKPOINT_REMOVE_EVENT;
extern TraceEvent _TRACE_BREAKPOINT_SINGLESTEP_EVENT;
extern TraceEvent _TRACE_CPU_EXEC_START_EVENT;
extern TraceEvent _TRACE_CPU_EXEC_END_EVENT;
extern TraceEvent _TRACE_JOB_STATE_TRANSITION_EVENT;
extern TraceEvent _TRACE_JOB_APPLY_VERB_EVENT;
extern TraceEvent _TRACE_JOB_COMPLETED_EVENT;
extern TraceEvent _TRACE_QMP_JOB_CANCEL_EVENT;
extern TraceEvent _TRACE_QMP_JOB_PAUSE_EVENT;
extern TraceEvent _TRACE_QMP_JOB_RESUME_EVENT;
extern TraceEvent _TRACE_QMP_JOB_COMPLETE_EVENT;
extern TraceEvent _TRACE_QMP_JOB_FINALIZE_EVENT;
extern TraceEvent _TRACE_QMP_JOB_DISMISS_EVENT;
extern uint16_t _TRACE_BREAKPOINT_INSERT_DSTATE;
extern uint16_t _TRACE_BREAKPOINT_REMOVE_DSTATE;
extern uint16_t _TRACE_BREAKPOINT_SINGLESTEP_DSTATE;
extern uint16_t _TRACE_CPU_EXEC_START_DSTATE;
extern uint16_t _TRACE_CPU_EXEC_END_DSTATE;
extern uint16_t _TRACE_JOB_STATE_TRANSITION_DSTATE;
extern uint16_t _TRACE_JOB_APPLY_VERB_DSTATE;
extern uint16_t _TRACE_JOB_COMPLETED_DSTATE;
extern uint16_t _TRACE_QMP_JOB_CANCEL_DSTATE;
extern uint16_t _TRACE_QMP_JOB_PAUSE_DSTATE;
extern uint16_t _TRACE_QMP_JOB_RESUME_DSTATE;
extern uint16_t _TRACE_QMP_JOB_COMPLETE_DSTATE;
extern uint16_t _TRACE_QMP_JOB_FINALIZE_DSTATE;
extern uint16_t _TRACE_QMP_JOB_DISMISS_DSTATE;
#define TRACE_BREAKPOINT_INSERT_ENABLED 1
#define TRACE_BREAKPOINT_REMOVE_ENABLED 1
#define TRACE_BREAKPOINT_SINGLESTEP_ENABLED 1
#define TRACE_CPU_EXEC_START_ENABLED 1
#define TRACE_CPU_EXEC_END_ENABLED 1
#define TRACE_JOB_STATE_TRANSITION_ENABLED 1
#define TRACE_JOB_APPLY_VERB_ENABLED 1
#define TRACE_JOB_COMPLETED_ENABLED 1
#define TRACE_QMP_JOB_CANCEL_ENABLED 1
#define TRACE_QMP_JOB_PAUSE_ENABLED 1
#define TRACE_QMP_JOB_RESUME_ENABLED 1
#define TRACE_QMP_JOB_COMPLETE_ENABLED 1
#define TRACE_QMP_JOB_FINALIZE_ENABLED 1
#define TRACE_QMP_JOB_DISMISS_ENABLED 1
#include "qemu/log-for-trace.h"


#define TRACE_BREAKPOINT_INSERT_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_BREAKPOINT_INSERT) || \
    false)

static inline void trace_breakpoint_insert(int cpu_index, uint64_t pc, int flags)
{
    if (trace_event_get_state(TRACE_BREAKPOINT_INSERT)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 29 "../xemu/trace-events"
            qemu_log("breakpoint_insert " "cpu=%d pc=0x%" PRIx64 " flags=0x%x" "\n", cpu_index, pc, flags);
#line 65 "trace/trace-root.h"
        }
    }
}

#define TRACE_BREAKPOINT_REMOVE_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_BREAKPOINT_REMOVE) || \
    false)

static inline void trace_breakpoint_remove(int cpu_index, uint64_t pc, int flags)
{
    if (trace_event_get_state(TRACE_BREAKPOINT_REMOVE)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 30 "../xemu/trace-events"
            qemu_log("breakpoint_remove " "cpu=%d pc=0x%" PRIx64 " flags=0x%x" "\n", cpu_index, pc, flags);
#line 80 "trace/trace-root.h"
        }
    }
}

#define TRACE_BREAKPOINT_SINGLESTEP_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_BREAKPOINT_SINGLESTEP) || \
    false)

static inline void trace_breakpoint_singlestep(int cpu_index, int enabled)
{
    if (trace_event_get_state(TRACE_BREAKPOINT_SINGLESTEP)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 31 "../xemu/trace-events"
            qemu_log("breakpoint_singlestep " "cpu=%d enable=%d" "\n", cpu_index, enabled);
#line 95 "trace/trace-root.h"
        }
    }
}

#define TRACE_CPU_EXEC_START_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_CPU_EXEC_START) || \
    false)

static inline void trace_cpu_exec_start(int cpu_index)
{
    if (trace_event_get_state(TRACE_CPU_EXEC_START)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 32 "../xemu/trace-events"
            qemu_log("cpu_exec_start " "cpu=%d" "\n", cpu_index);
#line 110 "trace/trace-root.h"
        }
    }
}

#define TRACE_CPU_EXEC_END_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_CPU_EXEC_END) || \
    false)

static inline void trace_cpu_exec_end(int cpu_index)
{
    if (trace_event_get_state(TRACE_CPU_EXEC_END)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 33 "../xemu/trace-events"
            qemu_log("cpu_exec_end " "cpu=%d" "\n", cpu_index);
#line 125 "trace/trace-root.h"
        }
    }
}

#define TRACE_JOB_STATE_TRANSITION_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_JOB_STATE_TRANSITION) || \
    false)

static inline void trace_job_state_transition(void *job, int ret, const char *legal, const char *s0, const char *s1)
{
    if (trace_event_get_state(TRACE_JOB_STATE_TRANSITION)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 36 "../xemu/trace-events"
            qemu_log("job_state_transition " "job %p (ret: %d) attempting %s transition (%s-->%s)" "\n", job, ret, legal, s0, s1);
#line 140 "trace/trace-root.h"
        }
    }
}

#define TRACE_JOB_APPLY_VERB_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_JOB_APPLY_VERB) || \
    false)

static inline void trace_job_apply_verb(void *job, const char *state, const char *verb, const char *legal)
{
    if (trace_event_get_state(TRACE_JOB_APPLY_VERB)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 37 "../xemu/trace-events"
            qemu_log("job_apply_verb " "job %p in state %s; applying verb %s (%s)" "\n", job, state, verb, legal);
#line 155 "trace/trace-root.h"
        }
    }
}

#define TRACE_JOB_COMPLETED_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_JOB_COMPLETED) || \
    false)

static inline void trace_job_completed(void *job, int ret)
{
    if (trace_event_get_state(TRACE_JOB_COMPLETED)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 38 "../xemu/trace-events"
            qemu_log("job_completed " "job %p ret %d" "\n", job, ret);
#line 170 "trace/trace-root.h"
        }
    }
}

#define TRACE_QMP_JOB_CANCEL_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_QMP_JOB_CANCEL) || \
    false)

static inline void trace_qmp_job_cancel(void *job)
{
    if (trace_event_get_state(TRACE_QMP_JOB_CANCEL)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 41 "../xemu/trace-events"
            qemu_log("qmp_job_cancel " "job %p" "\n", job);
#line 185 "trace/trace-root.h"
        }
    }
}

#define TRACE_QMP_JOB_PAUSE_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_QMP_JOB_PAUSE) || \
    false)

static inline void trace_qmp_job_pause(void *job)
{
    if (trace_event_get_state(TRACE_QMP_JOB_PAUSE)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 42 "../xemu/trace-events"
            qemu_log("qmp_job_pause " "job %p" "\n", job);
#line 200 "trace/trace-root.h"
        }
    }
}

#define TRACE_QMP_JOB_RESUME_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_QMP_JOB_RESUME) || \
    false)

static inline void trace_qmp_job_resume(void *job)
{
    if (trace_event_get_state(TRACE_QMP_JOB_RESUME)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 43 "../xemu/trace-events"
            qemu_log("qmp_job_resume " "job %p" "\n", job);
#line 215 "trace/trace-root.h"
        }
    }
}

#define TRACE_QMP_JOB_COMPLETE_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_QMP_JOB_COMPLETE) || \
    false)

static inline void trace_qmp_job_complete(void *job)
{
    if (trace_event_get_state(TRACE_QMP_JOB_COMPLETE)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 44 "../xemu/trace-events"
            qemu_log("qmp_job_complete " "job %p" "\n", job);
#line 230 "trace/trace-root.h"
        }
    }
}

#define TRACE_QMP_JOB_FINALIZE_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_QMP_JOB_FINALIZE) || \
    false)

static inline void trace_qmp_job_finalize(void *job)
{
    if (trace_event_get_state(TRACE_QMP_JOB_FINALIZE)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 45 "../xemu/trace-events"
            qemu_log("qmp_job_finalize " "job %p" "\n", job);
#line 245 "trace/trace-root.h"
        }
    }
}

#define TRACE_QMP_JOB_DISMISS_BACKEND_DSTATE() ( \
    trace_event_get_state_dynamic_by_id(TRACE_QMP_JOB_DISMISS) || \
    false)

static inline void trace_qmp_job_dismiss(void *job)
{
    if (trace_event_get_state(TRACE_QMP_JOB_DISMISS)) {
        if (qemu_loglevel_mask(LOG_TRACE)) {
#line 46 "../xemu/trace-events"
            qemu_log("qmp_job_dismiss " "job %p" "\n", job);
#line 260 "trace/trace-root.h"
        }
    }
}
#endif /* TRACE_ROOT_GENERATED_TRACERS_H */
