C++程序  |  112行  |  4.46 KB

/* Generated by ./xlat/gen.sh from ./xlat/perf_sw_ids.in; do not edit. */

#include "gcc_compat.h"
#include "static_assert.h"

#if defined(PERF_COUNT_SW_CPU_CLOCK) || (defined(HAVE_DECL_PERF_COUNT_SW_CPU_CLOCK) && HAVE_DECL_PERF_COUNT_SW_CPU_CLOCK)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_CPU_CLOCK) == (0), "PERF_COUNT_SW_CPU_CLOCK != 0");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_CPU_CLOCK 0
#endif
#if defined(PERF_COUNT_SW_TASK_CLOCK) || (defined(HAVE_DECL_PERF_COUNT_SW_TASK_CLOCK) && HAVE_DECL_PERF_COUNT_SW_TASK_CLOCK)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_TASK_CLOCK) == (1), "PERF_COUNT_SW_TASK_CLOCK != 1");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_TASK_CLOCK 1
#endif
#if defined(PERF_COUNT_SW_PAGE_FAULTS) || (defined(HAVE_DECL_PERF_COUNT_SW_PAGE_FAULTS) && HAVE_DECL_PERF_COUNT_SW_PAGE_FAULTS)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_PAGE_FAULTS) == (2), "PERF_COUNT_SW_PAGE_FAULTS != 2");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_PAGE_FAULTS 2
#endif
#if defined(PERF_COUNT_SW_CONTEXT_SWITCHES) || (defined(HAVE_DECL_PERF_COUNT_SW_CONTEXT_SWITCHES) && HAVE_DECL_PERF_COUNT_SW_CONTEXT_SWITCHES)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_CONTEXT_SWITCHES) == (3), "PERF_COUNT_SW_CONTEXT_SWITCHES != 3");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_CONTEXT_SWITCHES 3
#endif
#if defined(PERF_COUNT_SW_CPU_MIGRATIONS) || (defined(HAVE_DECL_PERF_COUNT_SW_CPU_MIGRATIONS) && HAVE_DECL_PERF_COUNT_SW_CPU_MIGRATIONS)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_CPU_MIGRATIONS) == (4), "PERF_COUNT_SW_CPU_MIGRATIONS != 4");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_CPU_MIGRATIONS 4
#endif
#if defined(PERF_COUNT_SW_PAGE_FAULTS_MIN) || (defined(HAVE_DECL_PERF_COUNT_SW_PAGE_FAULTS_MIN) && HAVE_DECL_PERF_COUNT_SW_PAGE_FAULTS_MIN)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_PAGE_FAULTS_MIN) == (5), "PERF_COUNT_SW_PAGE_FAULTS_MIN != 5");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_PAGE_FAULTS_MIN 5
#endif
#if defined(PERF_COUNT_SW_PAGE_FAULTS_MAJ) || (defined(HAVE_DECL_PERF_COUNT_SW_PAGE_FAULTS_MAJ) && HAVE_DECL_PERF_COUNT_SW_PAGE_FAULTS_MAJ)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_PAGE_FAULTS_MAJ) == (6), "PERF_COUNT_SW_PAGE_FAULTS_MAJ != 6");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_PAGE_FAULTS_MAJ 6
#endif
#if defined(PERF_COUNT_SW_ALIGNMENT_FAULTS) || (defined(HAVE_DECL_PERF_COUNT_SW_ALIGNMENT_FAULTS) && HAVE_DECL_PERF_COUNT_SW_ALIGNMENT_FAULTS)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_ALIGNMENT_FAULTS) == (7), "PERF_COUNT_SW_ALIGNMENT_FAULTS != 7");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_ALIGNMENT_FAULTS 7
#endif
#if defined(PERF_COUNT_SW_EMULATION_FAULTS) || (defined(HAVE_DECL_PERF_COUNT_SW_EMULATION_FAULTS) && HAVE_DECL_PERF_COUNT_SW_EMULATION_FAULTS)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_EMULATION_FAULTS) == (8), "PERF_COUNT_SW_EMULATION_FAULTS != 8");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_EMULATION_FAULTS 8
#endif
#if defined(PERF_COUNT_SW_DUMMY) || (defined(HAVE_DECL_PERF_COUNT_SW_DUMMY) && HAVE_DECL_PERF_COUNT_SW_DUMMY)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_DUMMY) == (9), "PERF_COUNT_SW_DUMMY != 9");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_DUMMY 9
#endif
#if defined(PERF_COUNT_SW_BPF_OUTPUT) || (defined(HAVE_DECL_PERF_COUNT_SW_BPF_OUTPUT) && HAVE_DECL_PERF_COUNT_SW_BPF_OUTPUT)
DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
static_assert((PERF_COUNT_SW_BPF_OUTPUT) == (10), "PERF_COUNT_SW_BPF_OUTPUT != 10");
DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
#else
# define PERF_COUNT_SW_BPF_OUTPUT 10
#endif

#ifndef XLAT_MACROS_ONLY

# ifdef IN_MPERS

#  error static const struct xlat perf_sw_ids in mpers mode

# else

static
const struct xlat perf_sw_ids[] = {

 XLAT(PERF_COUNT_SW_CPU_CLOCK),
 XLAT(PERF_COUNT_SW_TASK_CLOCK),
 XLAT(PERF_COUNT_SW_PAGE_FAULTS),
 XLAT(PERF_COUNT_SW_CONTEXT_SWITCHES),
 XLAT(PERF_COUNT_SW_CPU_MIGRATIONS),
 XLAT(PERF_COUNT_SW_PAGE_FAULTS_MIN),
 XLAT(PERF_COUNT_SW_PAGE_FAULTS_MAJ),
 XLAT(PERF_COUNT_SW_ALIGNMENT_FAULTS),
 XLAT(PERF_COUNT_SW_EMULATION_FAULTS),
 XLAT(PERF_COUNT_SW_DUMMY),
 XLAT(PERF_COUNT_SW_BPF_OUTPUT),
 XLAT_END
};

# endif /* !IN_MPERS */

#endif /* !XLAT_MACROS_ONLY */