From nobody Sat May 06 17:49:43 2023 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4QDFS8095Pz49skf; Sat, 6 May 2023 17:49:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4QDFS74YfCz3FsT; Sat, 6 May 2023 17:49:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1683395383; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DrBiTKUoDcAjmJFRtKUYyT0sY4v3O1SMgxA2uocYbWc=; b=GrgqU1Y9IFgQgp3w1pwt2Dinp+17HSztB9dojO73qK/MY7mpwB5rCqO4B+sGlWElP008CW DXWJxlRKglOsJ2FEyRm+J+37ygcBP4ifQmsFMWHN/V0tCRqtesggTImY03Vin0rc4Mu14l C7zwtiDWo1OzXcs+dw8ozQ39rvF73b1XmQXETO+uOih+BcwdMEVDAWNdMBOA8gbNU/nOUR qXS2Su5YPZ9iGnOcVJRLmWHk/LphLZQta3dBnwA7dtg3d6F9y8SAJ3ohayp4zb7fvJA49D jU9k+M3PmtIH9SZIDTUKodMKiVUmQwVirbNeMIB8miMf66k3ndvdA5Lc7VRHXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1683395383; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DrBiTKUoDcAjmJFRtKUYyT0sY4v3O1SMgxA2uocYbWc=; b=CbVUCcbuXzPErTY74EsQji717p+FyQ2Nlonlw76WyZdBcqbWaMjrOZJ/H7mae64LMi4CSg p6Fzg0u4Qvht9DH+KhCXeJxSk4NpeDSjD8fsE1c68KAH7dtetM3aYs8yAkCP3ylRuDMQ5r tKka2lbXAwbIm2TaOf13nOwv9kV1coEMndrRUgofku475JjSu7CvBJN3e1R/xG27P/qakq uuMU/Yl8z6BlrCqnmeoiOu/8aDfW7gz/WyzlVGsx6hx7FTxUZ5Ok9N5qblqMRDaIEfKmzo eLufXs0oI6AuHFmtsusjO/dBkUYAXWfLjqysNb+4qNKBoNlMS8Egq2cA4mFV5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1683395383; a=rsa-sha256; cv=none; b=EPSnq2CR5HM5ohbDcKR6OoVAUNPOUSb3U8JNN+BJVUvsq5A5K03hRDNF53CXS9+mBp8QWc EKyRRhA8jw/XHi8GGbqeOQvBOc2zZ1brk8riCJwmKpse9+K9hHuwieiY2RdOMIZL/tpts+ o0eKX+qkfqv/d0+uW94gRiigndhpzdMdz5KJCJAeTCRX3bQMeFut2poMXgm7TNj5fHjkA8 f933uIcRodLe+Lgel/PlJoj3zFRMKVMn0wUIwCPtb6LQQqmN6bvQrvFT+iL6krcMLI30g0 DagN1AGuxzIeFThTL8xqO9TH5/W1cgmr35AqWirjHeb0wNy7c08fC5Yp4ovF1Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4QDFS73SBszlFc; Sat, 6 May 2023 17:49:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 346Hnh22017910; Sat, 6 May 2023 17:49:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 346HnhDd017909; Sat, 6 May 2023 17:49:43 GMT (envelope-from git) Date: Sat, 6 May 2023 17:49:43 GMT Message-Id: <202305061749.346HnhDd017909@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: 7253dc57a0b4 - main - hwpmc: formatting of CPU and class lists List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7253dc57a0b400ff745a43017928304ff8dcf33f Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=7253dc57a0b400ff745a43017928304ff8dcf33f commit 7253dc57a0b400ff745a43017928304ff8dcf33f Author: Mitchell Horne AuthorDate: 2023-05-05 21:58:13 +0000 Commit: Mitchell Horne CommitDate: 2023-05-06 17:49:19 +0000 hwpmc: formatting of CPU and class lists The end result is much more legible in both cases. Reviewed by: jkoshy MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D39906 --- sys/sys/pmc.h | 126 +++++++++++++++++++++++++++++----------------------------- 1 file changed, 62 insertions(+), 64 deletions(-) diff --git a/sys/sys/pmc.h b/sys/sys/pmc.h index 6a9f614bcbc8..558fe4b20d39 100644 --- a/sys/sys/pmc.h +++ b/sys/sys/pmc.h @@ -82,50 +82,49 @@ extern char pmc_cpuid[PMC_CPUID_LEN]; * * Please keep the pmc(3) manual page in sync with this list. */ - -#define __PMC_CPUS() \ - __PMC_CPU(AMD_K7, 0x00, "AMD K7") \ - __PMC_CPU(AMD_K8, 0x01, "AMD K8") \ - __PMC_CPU(INTEL_CORE, 0x87, "Intel Core Solo/Duo") \ - __PMC_CPU(INTEL_CORE2, 0x88, "Intel Core2") \ - __PMC_CPU(INTEL_CORE2EXTREME, 0x89, "Intel Core2 Extreme") \ - __PMC_CPU(INTEL_ATOM, 0x8A, "Intel Atom") \ - __PMC_CPU(INTEL_COREI7, 0x8B, "Intel Core i7") \ - __PMC_CPU(INTEL_WESTMERE, 0x8C, "Intel Westmere") \ - __PMC_CPU(INTEL_SANDYBRIDGE, 0x8D, "Intel Sandy Bridge") \ - __PMC_CPU(INTEL_IVYBRIDGE, 0x8E, "Intel Ivy Bridge") \ - __PMC_CPU(INTEL_SANDYBRIDGE_XEON, 0x8F, "Intel Sandy Bridge Xeon") \ - __PMC_CPU(INTEL_IVYBRIDGE_XEON, 0x90, "Intel Ivy Bridge Xeon") \ - __PMC_CPU(INTEL_HASWELL, 0x91, "Intel Haswell") \ - __PMC_CPU(INTEL_ATOM_SILVERMONT, 0x92, "Intel Atom Silvermont") \ - __PMC_CPU(INTEL_NEHALEM_EX, 0x93, "Intel Nehalem Xeon 7500") \ - __PMC_CPU(INTEL_WESTMERE_EX, 0x94, "Intel Westmere Xeon E7") \ - __PMC_CPU(INTEL_HASWELL_XEON, 0x95, "Intel Haswell Xeon E5 v3") \ - __PMC_CPU(INTEL_BROADWELL, 0x96, "Intel Broadwell") \ - __PMC_CPU(INTEL_BROADWELL_XEON, 0x97, "Intel Broadwell Xeon") \ - __PMC_CPU(INTEL_SKYLAKE, 0x98, "Intel Skylake") \ - __PMC_CPU(INTEL_SKYLAKE_XEON, 0x99, "Intel Skylake Xeon") \ - __PMC_CPU(INTEL_ATOM_GOLDMONT, 0x9A, "Intel Atom Goldmont") \ - __PMC_CPU(INTEL_ICELAKE, 0x9B, "Intel Icelake") \ - __PMC_CPU(INTEL_ICELAKE_XEON, 0x9C, "Intel Icelake Xeon") \ - __PMC_CPU(INTEL_ALDERLAKE, 0x9D, "Intel Alderlake") \ - __PMC_CPU(INTEL_ATOM_GOLDMONT_P, 0x9E, "Intel Atom Goldmont Plus") \ - __PMC_CPU(INTEL_ATOM_TREMONT, 0x9F, "Intel Atom Tremont") \ - __PMC_CPU(INTEL_XSCALE, 0x100, "Intel XScale") \ - __PMC_CPU(PPC_7450, 0x300, "PowerPC MPC7450") \ - __PMC_CPU(PPC_E500, 0x340, "PowerPC e500 Core") \ - __PMC_CPU(PPC_970, 0x380, "IBM PowerPC 970") \ - __PMC_CPU(PPC_POWER8, 0x390, "IBM POWER8") \ - __PMC_CPU(GENERIC, 0x400, "Generic") \ - __PMC_CPU(ARMV7_CORTEX_A5, 0x500, "ARMv7 Cortex A5") \ - __PMC_CPU(ARMV7_CORTEX_A7, 0x501, "ARMv7 Cortex A7") \ - __PMC_CPU(ARMV7_CORTEX_A8, 0x502, "ARMv7 Cortex A8") \ - __PMC_CPU(ARMV7_CORTEX_A9, 0x503, "ARMv7 Cortex A9") \ - __PMC_CPU(ARMV7_CORTEX_A15, 0x504, "ARMv7 Cortex A15") \ - __PMC_CPU(ARMV7_CORTEX_A17, 0x505, "ARMv7 Cortex A17") \ - __PMC_CPU(ARMV8_CORTEX_A53, 0x600, "ARMv8 Cortex A53") \ - __PMC_CPU(ARMV8_CORTEX_A57, 0x601, "ARMv8 Cortex A57") \ - __PMC_CPU(ARMV8_CORTEX_A76, 0x602, "ARMv8 Cortex A76") +#define __PMC_CPUS() \ + __PMC_CPU(AMD_K7, 0x00, "AMD K7") \ + __PMC_CPU(AMD_K8, 0x01, "AMD K8") \ + __PMC_CPU(INTEL_CORE, 0x87, "Intel Core Solo/Duo") \ + __PMC_CPU(INTEL_CORE2, 0x88, "Intel Core2") \ + __PMC_CPU(INTEL_CORE2EXTREME, 0x89, "Intel Core2 Extreme") \ + __PMC_CPU(INTEL_ATOM, 0x8A, "Intel Atom") \ + __PMC_CPU(INTEL_COREI7, 0x8B, "Intel Core i7") \ + __PMC_CPU(INTEL_WESTMERE, 0x8C, "Intel Westmere") \ + __PMC_CPU(INTEL_SANDYBRIDGE, 0x8D, "Intel Sandy Bridge") \ + __PMC_CPU(INTEL_IVYBRIDGE, 0x8E, "Intel Ivy Bridge") \ + __PMC_CPU(INTEL_SANDYBRIDGE_XEON, 0x8F, "Intel Sandy Bridge Xeon") \ + __PMC_CPU(INTEL_IVYBRIDGE_XEON, 0x90, "Intel Ivy Bridge Xeon") \ + __PMC_CPU(INTEL_HASWELL, 0x91, "Intel Haswell") \ + __PMC_CPU(INTEL_ATOM_SILVERMONT, 0x92, "Intel Atom Silvermont") \ + __PMC_CPU(INTEL_NEHALEM_EX, 0x93, "Intel Nehalem Xeon 7500") \ + __PMC_CPU(INTEL_WESTMERE_EX, 0x94, "Intel Westmere Xeon E7") \ + __PMC_CPU(INTEL_HASWELL_XEON, 0x95, "Intel Haswell Xeon E5 v3") \ + __PMC_CPU(INTEL_BROADWELL, 0x96, "Intel Broadwell") \ + __PMC_CPU(INTEL_BROADWELL_XEON, 0x97, "Intel Broadwell Xeon") \ + __PMC_CPU(INTEL_SKYLAKE, 0x98, "Intel Skylake") \ + __PMC_CPU(INTEL_SKYLAKE_XEON, 0x99, "Intel Skylake Xeon") \ + __PMC_CPU(INTEL_ATOM_GOLDMONT, 0x9A, "Intel Atom Goldmont") \ + __PMC_CPU(INTEL_ICELAKE, 0x9B, "Intel Icelake") \ + __PMC_CPU(INTEL_ICELAKE_XEON, 0x9C, "Intel Icelake Xeon") \ + __PMC_CPU(INTEL_ALDERLAKE, 0x9D, "Intel Alderlake") \ + __PMC_CPU(INTEL_ATOM_GOLDMONT_P, 0x9E, "Intel Atom Goldmont Plus") \ + __PMC_CPU(INTEL_ATOM_TREMONT, 0x9F, "Intel Atom Tremont") \ + __PMC_CPU(INTEL_XSCALE, 0x100, "Intel XScale") \ + __PMC_CPU(PPC_7450, 0x300, "PowerPC MPC7450") \ + __PMC_CPU(PPC_E500, 0x340, "PowerPC e500 Core") \ + __PMC_CPU(PPC_970, 0x380, "IBM PowerPC 970") \ + __PMC_CPU(PPC_POWER8, 0x390, "IBM POWER8") \ + __PMC_CPU(GENERIC, 0x400, "Generic") \ + __PMC_CPU(ARMV7_CORTEX_A5, 0x500, "ARMv7 Cortex A5") \ + __PMC_CPU(ARMV7_CORTEX_A7, 0x501, "ARMv7 Cortex A7") \ + __PMC_CPU(ARMV7_CORTEX_A8, 0x502, "ARMv7 Cortex A8") \ + __PMC_CPU(ARMV7_CORTEX_A9, 0x503, "ARMv7 Cortex A9") \ + __PMC_CPU(ARMV7_CORTEX_A15, 0x504, "ARMv7 Cortex A15") \ + __PMC_CPU(ARMV7_CORTEX_A17, 0x505, "ARMv7 Cortex A17") \ + __PMC_CPU(ARMV8_CORTEX_A53, 0x600, "ARMv8 Cortex A53") \ + __PMC_CPU(ARMV8_CORTEX_A57, 0x601, "ARMv8 Cortex A57") \ + __PMC_CPU(ARMV8_CORTEX_A76, 0x602, "ARMv8 Cortex A76") enum pmc_cputype { #undef __PMC_CPU @@ -139,26 +138,25 @@ enum pmc_cputype { /* * Classes of PMCs */ - -#define __PMC_CLASSES() \ - __PMC_CLASS(TSC, 0x00, "CPU Timestamp counter") \ - __PMC_CLASS(K7, 0x01, "AMD K7 performance counters") \ - __PMC_CLASS(K8, 0x02, "AMD K8 performance counters") \ - __PMC_CLASS(IAF, 0x06, "Intel Core2/Atom, fixed function") \ - __PMC_CLASS(IAP, 0x07, "Intel Core...Atom, programmable") \ - __PMC_CLASS(UCF, 0x08, "Intel Uncore fixed function") \ - __PMC_CLASS(UCP, 0x09, "Intel Uncore programmable") \ - __PMC_CLASS(XSCALE, 0x0A, "Intel XScale counters") \ - __PMC_CLASS(PPC7450, 0x0D, "Motorola MPC7450 class") \ - __PMC_CLASS(PPC970, 0x0E, "IBM PowerPC 970 class") \ - __PMC_CLASS(SOFT, 0x0F, "Software events") \ - __PMC_CLASS(ARMV7, 0x10, "ARMv7") \ - __PMC_CLASS(ARMV8, 0x11, "ARMv8") \ - __PMC_CLASS(E500, 0x13, "Freescale e500 class") \ - __PMC_CLASS(POWER8, 0x15, "IBM POWER8 class") \ - __PMC_CLASS(DMC620_PMU_CD2, 0x16, "ARM DMC620 Memory Controller PMU CLKDIV2") \ - __PMC_CLASS(DMC620_PMU_C, 0x17, "ARM DMC620 Memory Controller PMU CLK") \ - __PMC_CLASS(CMN600_PMU, 0x18, "Arm CoreLink CMN600 Coherent Mesh Network PMU") +#define __PMC_CLASSES() \ + __PMC_CLASS(TSC, 0x00, "CPU Timestamp counter") \ + __PMC_CLASS(K7, 0x01, "AMD K7 performance counters") \ + __PMC_CLASS(K8, 0x02, "AMD K8 performance counters") \ + __PMC_CLASS(IAF, 0x06, "Intel Core2/Atom, fixed function") \ + __PMC_CLASS(IAP, 0x07, "Intel Core...Atom, programmable") \ + __PMC_CLASS(UCF, 0x08, "Intel Uncore fixed function") \ + __PMC_CLASS(UCP, 0x09, "Intel Uncore programmable") \ + __PMC_CLASS(XSCALE, 0x0A, "Intel XScale counters") \ + __PMC_CLASS(PPC7450, 0x0D, "Motorola MPC7450 class") \ + __PMC_CLASS(PPC970, 0x0E, "IBM PowerPC 970 class") \ + __PMC_CLASS(SOFT, 0x0F, "Software events") \ + __PMC_CLASS(ARMV7, 0x10, "ARMv7") \ + __PMC_CLASS(ARMV8, 0x11, "ARMv8") \ + __PMC_CLASS(E500, 0x13, "Freescale e500 class") \ + __PMC_CLASS(POWER8, 0x15, "IBM POWER8 class") \ + __PMC_CLASS(DMC620_PMU_CD2, 0x16, "ARM DMC620 Memory Controller PMU CLKDIV2") \ + __PMC_CLASS(DMC620_PMU_C, 0x17, "ARM DMC620 Memory Controller PMU CLK") \ + __PMC_CLASS(CMN600_PMU, 0x18, "Arm CoreLink CMN600 Coherent Mesh Network PMU") enum pmc_class { #undef __PMC_CLASS