From f5b27cbcc7cae5279aac512f805be73591f58eaa Mon Sep 17 00:00:00 2001 From: Damjan Marion Date: Fri, 11 Dec 2020 18:52:34 +0100 Subject: [PATCH] misc: deprecate old perfmon Type: refactor Change-Id: I1303219f9f2a25d821737665903b0264edd3de32 Signed-off-by: Damjan Marion --- MAINTAINERS | 5 -- .../deprecated}/perfmon/CMakeLists.txt | 0 .../deprecated}/perfmon/intel_json_to_c.py | 0 .../deprecated}/perfmon/mapfile_tool.c | 0 .../deprecated}/perfmon/perfmon.c | 0 .../deprecated}/perfmon/perfmon.h | 0 .../deprecated}/perfmon/perfmon_intel.h | 0 .../deprecated}/perfmon/perfmon_intel_bdw.c | 0 .../perfmon/perfmon_intel_bdw_de.c | 0 .../deprecated}/perfmon/perfmon_intel_bdx.c | 0 .../deprecated}/perfmon/perfmon_intel_bnl.c | 0 .../deprecated}/perfmon/perfmon_intel_clx.c | 0 .../deprecated}/perfmon/perfmon_intel_hsw.c | 0 .../deprecated}/perfmon/perfmon_intel_hsx.c | 0 .../deprecated}/perfmon/perfmon_intel_ivb.c | 0 .../perfmon/perfmon_intel_nhm_ep.c | 0 .../perfmon/perfmon_intel_nhm_ex.c | 0 .../deprecated}/perfmon/perfmon_intel_skl.c | 0 .../deprecated}/perfmon/perfmon_intel_skx.c | 0 .../deprecated}/perfmon/perfmon_intel_slm.c | 0 .../deprecated}/perfmon/perfmon_intel_snb.c | 0 .../perfmon/perfmon_intel_wsm_ep_dp.c | 0 .../perfmon/perfmon_intel_wsm_ep_sp.c | 0 .../perfmon/perfmon_intel_wsm_ex.c | 0 .../deprecated}/perfmon/perfmon_periodic.c | 0 .../deprecated}/perfmon/perfmon_plugin.c | 0 src/vlib/main.h | 1 - src/vppinfra/CMakeLists.txt | 1 - src/vppinfra/pmc.h | 46 ------------------- test/test_vlib.py | 1 - 30 files changed, 54 deletions(-) rename {src/plugins => extras/deprecated}/perfmon/CMakeLists.txt (100%) rename {src/plugins => extras/deprecated}/perfmon/intel_json_to_c.py (100%) rename {src/plugins => extras/deprecated}/perfmon/mapfile_tool.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon.h (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel.h (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_bdw.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_bdw_de.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_bdx.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_bnl.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_clx.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_hsw.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_hsx.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_ivb.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_nhm_ep.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_nhm_ex.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_skl.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_skx.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_slm.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_snb.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_wsm_ep_dp.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_wsm_ep_sp.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_intel_wsm_ex.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_periodic.c (100%) rename {src/plugins => extras/deprecated}/perfmon/perfmon_plugin.c (100%) delete mode 100644 src/vppinfra/pmc.h diff --git a/MAINTAINERS b/MAINTAINERS index f3cd8ab4d01..19a5763ad57 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -461,11 +461,6 @@ I: marvell M: Damjan Marion F: src/plugins/marvell/ -Plugin - performance counter -I: perfmon -M: Dave Barach -F: src/plugins/perfmon/ - Plugin - PPPoE I: pppoe M: Hongjun Ni diff --git a/src/plugins/perfmon/CMakeLists.txt b/extras/deprecated/perfmon/CMakeLists.txt similarity index 100% rename from src/plugins/perfmon/CMakeLists.txt rename to extras/deprecated/perfmon/CMakeLists.txt diff --git a/src/plugins/perfmon/intel_json_to_c.py b/extras/deprecated/perfmon/intel_json_to_c.py similarity index 100% rename from src/plugins/perfmon/intel_json_to_c.py rename to extras/deprecated/perfmon/intel_json_to_c.py diff --git a/src/plugins/perfmon/mapfile_tool.c b/extras/deprecated/perfmon/mapfile_tool.c similarity index 100% rename from src/plugins/perfmon/mapfile_tool.c rename to extras/deprecated/perfmon/mapfile_tool.c diff --git a/src/plugins/perfmon/perfmon.c b/extras/deprecated/perfmon/perfmon.c similarity index 100% rename from src/plugins/perfmon/perfmon.c rename to extras/deprecated/perfmon/perfmon.c diff --git a/src/plugins/perfmon/perfmon.h b/extras/deprecated/perfmon/perfmon.h similarity index 100% rename from src/plugins/perfmon/perfmon.h rename to extras/deprecated/perfmon/perfmon.h diff --git a/src/plugins/perfmon/perfmon_intel.h b/extras/deprecated/perfmon/perfmon_intel.h similarity index 100% rename from src/plugins/perfmon/perfmon_intel.h rename to extras/deprecated/perfmon/perfmon_intel.h diff --git a/src/plugins/perfmon/perfmon_intel_bdw.c b/extras/deprecated/perfmon/perfmon_intel_bdw.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_bdw.c rename to extras/deprecated/perfmon/perfmon_intel_bdw.c diff --git a/src/plugins/perfmon/perfmon_intel_bdw_de.c b/extras/deprecated/perfmon/perfmon_intel_bdw_de.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_bdw_de.c rename to extras/deprecated/perfmon/perfmon_intel_bdw_de.c diff --git a/src/plugins/perfmon/perfmon_intel_bdx.c b/extras/deprecated/perfmon/perfmon_intel_bdx.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_bdx.c rename to extras/deprecated/perfmon/perfmon_intel_bdx.c diff --git a/src/plugins/perfmon/perfmon_intel_bnl.c b/extras/deprecated/perfmon/perfmon_intel_bnl.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_bnl.c rename to extras/deprecated/perfmon/perfmon_intel_bnl.c diff --git a/src/plugins/perfmon/perfmon_intel_clx.c b/extras/deprecated/perfmon/perfmon_intel_clx.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_clx.c rename to extras/deprecated/perfmon/perfmon_intel_clx.c diff --git a/src/plugins/perfmon/perfmon_intel_hsw.c b/extras/deprecated/perfmon/perfmon_intel_hsw.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_hsw.c rename to extras/deprecated/perfmon/perfmon_intel_hsw.c diff --git a/src/plugins/perfmon/perfmon_intel_hsx.c b/extras/deprecated/perfmon/perfmon_intel_hsx.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_hsx.c rename to extras/deprecated/perfmon/perfmon_intel_hsx.c diff --git a/src/plugins/perfmon/perfmon_intel_ivb.c b/extras/deprecated/perfmon/perfmon_intel_ivb.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_ivb.c rename to extras/deprecated/perfmon/perfmon_intel_ivb.c diff --git a/src/plugins/perfmon/perfmon_intel_nhm_ep.c b/extras/deprecated/perfmon/perfmon_intel_nhm_ep.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_nhm_ep.c rename to extras/deprecated/perfmon/perfmon_intel_nhm_ep.c diff --git a/src/plugins/perfmon/perfmon_intel_nhm_ex.c b/extras/deprecated/perfmon/perfmon_intel_nhm_ex.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_nhm_ex.c rename to extras/deprecated/perfmon/perfmon_intel_nhm_ex.c diff --git a/src/plugins/perfmon/perfmon_intel_skl.c b/extras/deprecated/perfmon/perfmon_intel_skl.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_skl.c rename to extras/deprecated/perfmon/perfmon_intel_skl.c diff --git a/src/plugins/perfmon/perfmon_intel_skx.c b/extras/deprecated/perfmon/perfmon_intel_skx.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_skx.c rename to extras/deprecated/perfmon/perfmon_intel_skx.c diff --git a/src/plugins/perfmon/perfmon_intel_slm.c b/extras/deprecated/perfmon/perfmon_intel_slm.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_slm.c rename to extras/deprecated/perfmon/perfmon_intel_slm.c diff --git a/src/plugins/perfmon/perfmon_intel_snb.c b/extras/deprecated/perfmon/perfmon_intel_snb.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_snb.c rename to extras/deprecated/perfmon/perfmon_intel_snb.c diff --git a/src/plugins/perfmon/perfmon_intel_wsm_ep_dp.c b/extras/deprecated/perfmon/perfmon_intel_wsm_ep_dp.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_wsm_ep_dp.c rename to extras/deprecated/perfmon/perfmon_intel_wsm_ep_dp.c diff --git a/src/plugins/perfmon/perfmon_intel_wsm_ep_sp.c b/extras/deprecated/perfmon/perfmon_intel_wsm_ep_sp.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_wsm_ep_sp.c rename to extras/deprecated/perfmon/perfmon_intel_wsm_ep_sp.c diff --git a/src/plugins/perfmon/perfmon_intel_wsm_ex.c b/extras/deprecated/perfmon/perfmon_intel_wsm_ex.c similarity index 100% rename from src/plugins/perfmon/perfmon_intel_wsm_ex.c rename to extras/deprecated/perfmon/perfmon_intel_wsm_ex.c diff --git a/src/plugins/perfmon/perfmon_periodic.c b/extras/deprecated/perfmon/perfmon_periodic.c similarity index 100% rename from src/plugins/perfmon/perfmon_periodic.c rename to extras/deprecated/perfmon/perfmon_periodic.c diff --git a/src/plugins/perfmon/perfmon_plugin.c b/extras/deprecated/perfmon/perfmon_plugin.c similarity index 100% rename from src/plugins/perfmon/perfmon_plugin.c rename to extras/deprecated/perfmon/perfmon_plugin.c diff --git a/src/vlib/main.h b/src/vlib/main.h index adfdc87bf7c..477211d65ce 100644 --- a/src/vlib/main.h +++ b/src/vlib/main.h @@ -47,7 +47,6 @@ #include #include #include -#include #include #include diff --git a/src/vppinfra/CMakeLists.txt b/src/vppinfra/CMakeLists.txt index a972d906769..b83b57e8b89 100644 --- a/src/vppinfra/CMakeLists.txt +++ b/src/vppinfra/CMakeLists.txt @@ -150,7 +150,6 @@ set(VPPINFRA_HEADERS pcap_funcs.h pmalloc.h pool.h - pmc.h ptclosure.h random_buffer.h random.h diff --git a/src/vppinfra/pmc.h b/src/vppinfra/pmc.h deleted file mode 100644 index 258b925127d..00000000000 --- a/src/vppinfra/pmc.h +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) 2018 Cisco and/or its affiliates. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at: - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#ifndef included_clib_pmc_h -#define included_clib_pmc_h - -#if defined (__x86_64__) - -always_inline u64 -clib_rdpmc (int counter_id) -{ - u32 a, d; - - asm volatile ("rdpmc":"=a" (a), "=d" (d):"c" (counter_id)); - return (u64) a + ((u64) d << (u64) 32); -} - -#else -always_inline u64 -clib_rdpmc (int counter_id) -{ - return 0ULL; -} -#endif /* __aarch64__ */ - -#endif /* included_clib_pmc_h */ - -/* - * fd.io coding-style-patch-verification: ON - * - * Local Variables: - * eval: (c-set-style "gnu") - * End: - */ diff --git a/test/test_vlib.py b/test/test_vlib.py index 8a02639e76b..89ccb396ecd 100644 --- a/test/test_vlib.py +++ b/test/test_vlib.py @@ -50,7 +50,6 @@ class TestVlib(VppTestCase): "event-logger resize 102400", "event-logger restart", "pcap dispatch trace on max 100 buffer-trace pg-input 15", - "set pmc instructions-per-clock", "pa en", "show event-log 100 all", "event-log save",