2 *------------------------------------------------------------------
3 * Copyright (c) 2019 Cisco and/or its affiliates.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at:
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *------------------------------------------------------------------
18 #ifndef _PERFMON_INTEL_H_
19 #define _PERFMON_INTEL_H_
21 #include <vppinfra/clib.h>
22 #include <vppinfra/format.h>
29 } perfmon_intel_pmc_event_t;
36 } perfmon_intel_pmc_cpu_model_t;
40 perfmon_intel_pmc_event_t *events;
41 perfmon_intel_pmc_cpu_model_t *models;
44 } perfmon_intel_pmc_registration_t;
48 perfmon_register_intel_pmc (perfmon_intel_pmc_cpu_model_t * m, int n_models,
49 perfmon_intel_pmc_event_t * e, int n_events);
51 #define PERFMON_REGISTER_INTEL_PMC(m, e) \
52 static void __clib_constructor \
53 perfmon_register_intel_pmc_constructor() \
55 perfmon_register_intel_pmc (m, ARRAY_LEN(m), e, ARRAY_LEN (e)); \
58 #endif /* _PERFMON_INTEL_H_ */
61 * fd.io coding-style-patch-verification: ON
64 * eval: (c-set-style "gnu")