[PATCH v9 8/8] lib/pmu: fix out-of-bound access

2025-07-22 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v9 7/8] trace: add PMU

2025-07-22 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v9 6/8] test/pmu: enable test

2025-07-22 Thread Tomasz Duszynski
Enable test to allow users to verify basic functionality. Due to varying configuration options across distributions and kernels user should ensure that all requirements are satisfied before starting test. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 60

[PATCH v9 5/8] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-07-22 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v9 3/8] lib/pmu: reimplement per-arch ops as callbacks

2025-07-22 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v9 4/8] lib/pmu: do not try enabling perf counter access on arm64

2025-07-22 Thread Tomasz Duszynski
about that. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 4 lib/pmu/pmu_arm64.c | 39 +++ lib/pmu/pmu_private.h | 8 3 files changed, 15 insertions(+), 36 deletions(-) diff --git a/lib/pmu/pmu.c b/lib/pmu/pmu.c index d8212

[PATCH v9 1/8] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-07-22 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v9 2/8] lib/pmu: export only necessary arch headers

2025-07-22 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v9 0/8] lib/pmu: cleanups and trace integration

2025-07-22 Thread Tomasz Duszynski
ional compilation - skip testing if paranoia is at wrong level v2: - explicitly check against NULL - make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (8): lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs lib/pmu: export only necessary arch headers li

[PATCH v8 8/8] lib/pmu: fix out-of-bound access

2025-07-22 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v8 7/8] trace: add PMU

2025-07-22 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v8 6/8] test/pmu: enable test

2025-07-22 Thread Tomasz Duszynski
Enable test to allow users to verify basic functionality. Due to varying configuration options across distributions and kernels user should ensure that all requirements are satisfied before starting test. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 60

[PATCH v8 4/8] lib/pmu: do not try enabling perf counter access on arm64

2025-07-22 Thread Tomasz Duszynski
about that. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 4 lib/pmu/pmu_arm64.c | 39 +++ lib/pmu/pmu_private.h | 8 3 files changed, 15 insertions(+), 36 deletions(-) diff --git a/lib/pmu/pmu.c b/lib/pmu/pmu.c index 0709f

[PATCH v8 5/8] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-07-22 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v8 3/8] lib/pmu: reimplement per-arch ops as callbacks

2025-07-22 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v8 2/8] lib/pmu: export only necessary arch headers

2025-07-22 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v8 1/8] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-07-22 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v8 0/8] lib/pmu: cleanups and trace integration

2025-07-22 Thread Tomasz Duszynski
el v2: - explicitly check against NULL - make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (8): lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs lib/pmu: export only necessary arch headers lib/pmu: reimplement per-arch ops as callbacks lib/pmu: do no

Re: [PATCH v7 7/8] trace: add PMU

2025-07-22 Thread Tomasz Duszynski
> > From: Thomas Monjalon [mailto:tho...@monjalon.net] > > Sent: Monday, 21 July 2025 12.46 > > > > 21/07/2025 12:24, Tomasz Duszynski: > > > > On Fri, Jun 27, 2025 at 5:41 PM Tomasz Duszynski > > wrote: > > > > > > > > >

Re: [PATCH v7 7/8] trace: add PMU

2025-07-21 Thread Tomasz Duszynski
> On Fri, Jun 27, 2025 at 5:41 PM Tomasz Duszynski > wrote: > > > > In order to profile app, one needs to store significant amount of samples > > somewhere for an analysis later on. > > Since trace library supports storing data in a CTF format, > > lets take a

[PATCH v7 8/8] lib/pmu: fix out-of-bound access

2025-06-27 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v7 6/8] test/pmu: enable test

2025-06-27 Thread Tomasz Duszynski
Enable test to allow users to verify basic functionality. Due to varying configuration options across distributions and kernels user should ensure that all requirements are satisfied before starting test. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 60

[PATCH v7 7/8] trace: add PMU

2025-06-27 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v7 5/8] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-27 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v7 1/8] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-06-27 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v7 3/8] lib/pmu: reimplement per-arch ops as callbacks

2025-06-27 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v7 4/8] lib/pmu: do not try enabling perf counter access on arm64

2025-06-27 Thread Tomasz Duszynski
about that. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 4 lib/pmu/pmu_arm64.c | 39 +++ lib/pmu/pmu_private.h | 8 3 files changed, 15 insertions(+), 36 deletions(-) diff --git a/lib/pmu/pmu.c b/lib/pmu/pmu.c index 0709f

[PATCH v7 2/8] lib/pmu: export only necessary arch headers

2025-06-27 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v7 0/8] lib/pmu: cleanups and trace integration

2025-06-27 Thread Tomasz Duszynski
B_PMU Tomasz Duszynski (8): lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs lib/pmu: export only necessary arch headers lib/pmu: reimplement per-arch ops as callbacks lib/pmu: do not try enabling perf counter access on arm64 lib/pmu: use build system defined RTE_LIB_PMU

[PATCH v6 8/8] lib/pmu: fix out-of-bound access

2025-06-27 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v6 7/8] trace: add PMU

2025-06-27 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v6 6/8] test/pmu: enable test

2025-06-27 Thread Tomasz Duszynski
Enable test to allow users to verify basic functionality. Due to varying configuration options across distributions and kernels user should ensure that all requirements are satisfied before starting test. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 58

[PATCH v6 5/8] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-27 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v6 4/8] lib/pmu: do not try enabling perf counter access on arm64

2025-06-27 Thread Tomasz Duszynski
about that. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 4 lib/pmu/pmu_arm64.c | 39 +++ lib/pmu/pmu_private.h | 8 3 files changed, 15 insertions(+), 36 deletions(-) diff --git a/lib/pmu/pmu.c b/lib/pmu/pmu.c index 0709f

[PATCH v6 3/8] lib/pmu: reimplement per-arch ops as callbacks

2025-06-27 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v6 2/8] lib/pmu: export only necessary arch headers

2025-06-27 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v6 1/8] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-06-27 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v6 0/8] lib/pmu: cleanups and trace integration

2025-06-27 Thread Tomasz Duszynski
xport __rte_pmu_trace_read because that breaks compilation on windows - script generating map files does not handle conditional compilation - skip testing if paranoia is at wrong level v2: - explicitly check against NULL - make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (8):

[PATCH v4 1/7] lib/pmu: export only necessary arch headers

2025-06-25 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v4 7/7] lib/pmu: fix out-of-bound access

2025-06-25 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v4 2/7] lib/pmu: reimplement per-arch ops as callbacks

2025-06-25 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH] raw/cnxk_gpio: fix out of bound access

2025-06-25 Thread Tomasz Duszynski
ch to character-based GPIO interface") Signed-off-by: Tomasz Duszynski --- drivers/raw/cnxk_gpio/cnxk_gpio.c | 38 --- 1 file changed, 30 insertions(+), 8 deletions(-) diff --git a/drivers/raw/cnxk_gpio/cnxk_gpio.c b/drivers/raw/cnxk_gpio/cnxk_gpio.c index

[PATCH v4 3/7] lib/pmu: do not try enabling perf counter access on arm64

2025-06-25 Thread Tomasz Duszynski
about that. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 4 lib/pmu/pmu_arm64.c | 39 +++ lib/pmu/pmu_private.h | 8 3 files changed, 15 insertions(+), 36 deletions(-) diff --git a/lib/pmu/pmu.c b/lib/pmu/pmu.c index 0709f

[PATCH v5 5/8] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-24 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v5 1/8] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-06-24 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v5 2/8] lib/pmu: export only necessary arch headers

2025-06-24 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v5 8/8] lib/pmu: fix out-of-bound access

2025-06-24 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v5 7/8] trace: add PMU

2025-06-24 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v5 6/8] test/pmu: enable fast test

2025-06-24 Thread Tomasz Duszynski
DPDK test suite provides much broader architecture coverage than what can be tested locally so enable the test to help identify potential issues. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 51 + 1 file changed, 47 insertions(+), 4

[PATCH v5 3/8] lib/pmu: reimplement per-arch ops as callbacks

2025-06-24 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v5 4/8] lib/pmu: do not try enabling perf counter access on arm64

2025-06-24 Thread Tomasz Duszynski
about that. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 4 lib/pmu/pmu_arm64.c | 39 +++ lib/pmu/pmu_private.h | 8 3 files changed, 15 insertions(+), 36 deletions(-) diff --git a/lib/pmu/pmu.c b/lib/pmu/pmu.c index 0709f

[PATCH v5 0/8] lib/pmu: cleanups and trace integration

2025-06-24 Thread Tomasz Duszynski
anoia is at wrong level v2: - explicitly check against NULL - make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (8): lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs lib/pmu: export only necessary arch headers lib/pmu: reimplement per-arch ops as call

[PATCH v4 4/7] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-24 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v4 0/7] lib/pmu: cleanups and trace integration

2025-06-24 Thread Tomasz Duszynski
ainst NULL - make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (7): lib/pmu: export only necessary arch headers lib/pmu: reimplement per-arch ops as callbacks lib/pmu: do not try enabling perf counter access on arm64 lib/pmu: use build system defined RTE_LIB_PMU

[PATCH v4 6/7] trace: add PMU

2025-06-24 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v4 5/7] test/pmu: enable fast test

2025-06-24 Thread Tomasz Duszynski
DPDK test suite provides much broader architecture coverage than what can be tested locally so enable the test to help identify potential issues. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 51 + 1 file changed, 47 insertions(+), 4

[PATCH v3 0/7] lib/pmu: cleanups and trace integration

2025-06-20 Thread Tomasz Duszynski
__rte_pmu_trace_read because that breaks compilation on windows - script generating map files does not handle conditional compilation - skip testing if paranoia is at wrong level v2: - explicitly check against NULL - make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (7): lib

[PATCH v3 3/7] lib/pmu: reimplement per-arch ops as callbacks

2025-06-20 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v3 6/7] trace: add PMU

2025-06-20 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH v3 7/7] lib/pmu: fix out-of-bound access

2025-06-20 Thread Tomasz Duszynski
Make sure that out-of-bound access does not happen by saving one byte in buffer for NUL terminator. Fixes: a8926a65ad1d ("pmu: support Arm") Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Cc: tduszyn...@marvell.com Signed-off-by: Tomasz Duszynski

[PATCH v3 4/7] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-20 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v3 1/7] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-06-20 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v3 5/7] test/pmu: enable fast test

2025-06-20 Thread Tomasz Duszynski
DPDK test suite provides much broader architecture coverage than what can be tested locally so enable the test to help identify potential issues. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 44 +--- 1 file changed, 41 insertions(+), 3

[PATCH v3 2/7] lib/pmu: export only necessary arch headers

2025-06-20 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v2 6/6] trace: add PMU

2025-06-18 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

RE: [PATCH v2 6/6] trace: add PMU

2025-06-18 Thread Tomasz Duszynski
>> diff --git a/lib/meson.build b/lib/meson.build >> index 1934cb4a29..87b567f01b 100644 >> --- a/lib/meson.build >> +++ b/lib/meson.build >> @@ -13,7 +13,7 @@ libraries = [ >> 'kvargs', # eal depends on kvargs >> 'argparse', >> 'telemetry', # basic info querying >> -

[PATCH v2 5/6] test/pmu: enable fast test

2025-06-18 Thread Tomasz Duszynski
DPDK test suite provides much broader architecture coverage than what can be tested locally so enable the test to help identify potential issues. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/test/test_pmu.c b

[PATCH v2 4/6] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-18 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH v2 3/6] lib/pmu: reimplement per-arch ops as callbacks

2025-06-17 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH v2 1/6] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-06-17 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH v2 2/6] lib/pmu: export only necessary arch headers

2025-06-17 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH v2 0/6] lib/pmu: cleanups and trace integration

2025-06-17 Thread Tomasz Duszynski
- make pmu lib optional by checking if dpdk config has RTE_LIB_PMU Tomasz Duszynski (6): lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs lib/pmu: export only necessary arch headers lib/pmu: reimplement per-arch ops as callbacks lib/pmu: use build system defined RTE_LIB_PMU

Re: [PATCH 4/6] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-16 Thread Tomasz Duszynski
>16/06/2025 08:53, Tomasz Duszynski: >> RTE_LIB_PMU is defined by build system automatically if DPDK is build >> for Linux. Otherwise it's missing. >> >> That said all cases where conditional compilation is required >> can be handled without introducing othe

Re: [PATCH 3/6] lib/pmu: reimplement per-arch ops as callbacks

2025-06-16 Thread Tomasz Duszynski
>16/06/2025 08:53, Tomasz Duszynski: >> +static inline int >> +pmu_arch_init(void) >> +{ >> + if (arch_ops && arch_ops->init) >> + return arch_ops->init(); > >These are not boolean values, please compare explicitly with NULL. Okay.

Re: [PATCH 6/6] trace: add PMU

2025-06-16 Thread Tomasz Duszynski
>16/06/2025 08:53, Tomasz Duszynski: >> @@ -86,6 +86,7 @@ always_enable = [ >> 'ring', >> 'stack', >> 'telemetry', >> +'pmu', >> ] > >This list is alphabetically sorted. Ri

[PATCH 4/6] lib/pmu: use build system defined RTE_LIB_PMU macro

2025-06-15 Thread Tomasz Duszynski
RTE_LIB_PMU is defined by build system automatically if DPDK is build for Linux. Otherwise it's missing. That said all cases where conditional compilation is required can be handled without introducing other macros. Signed-off-by: Tomasz Duszynski --- lib/pmu/rte_pmu.h | 3 --- 1 file ch

[PATCH 6/6] trace: add PMU

2025-06-15 Thread Tomasz Duszynski
In order to profile app, one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format, lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- MAINTAINERS

[PATCH 5/6] test/pmu: enable fast test

2025-06-15 Thread Tomasz Duszynski
DPDK test suite provides much broader architecture coverage than what can be tested locally so enable the test to help identify potential issues. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/test/test_pmu.c b

[PATCH 3/6] lib/pmu: reimplement per-arch ops as callbacks

2025-06-15 Thread Tomasz Duszynski
Replace static per-architecture ops with a callback-based ops structure. This makes architecture-specific PMU implementations more modular and easier to extend. Signed-off-by: Tomasz Duszynski --- lib/pmu/pmu.c | 17 + lib/pmu/pmu_arm64.c | 19 +-- lib

[PATCH 2/6] lib/pmu: export only necessary arch headers

2025-06-15 Thread Tomasz Duszynski
Install only architecture specific headers to avoid header pollution. Signed-off-by: Tomasz Duszynski --- lib/pmu/meson.build | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/pmu/meson.build b/lib/pmu/meson.build index bcb6d10f1a..53013d0ed6 100644 --- a/lib

[PATCH 1/6] lib/pmu: quiesce rte_pmu_read deprecation warning in chkincs

2025-06-15 Thread Tomasz Duszynski
Add a dummy rte_pmu_read() definition for chkincs when ALLOW_EXPERIMENTAL_API is not defined to suppress warnings from use of experimental APIs in tracepoints. Fixes: 960c43184c4d ("pmu: introduce library for reading PMU events") Signed-off-by: Tomasz Duszynski --- lib/pmu/rte

[PATCH 0/6] lib/pmu: cleanups and trace integration

2025-06-15 Thread Tomasz Duszynski
This series does some cleanup and refactoring around the rc1 code like: trimming unused headers, switching to callbacks for per-arch handling, and adding trace support. It also re-enables existing base test to help catch reported issues on some architectures. Tomasz Duszynski (6): lib/pmu

Re: [PATCH v17 0/4] add support for self monitoring

2025-06-10 Thread Tomasz Duszynski
Hi Thomas, Thanks for taking the time to merge the code and for the detailed update. Cleanup and fixes you've done - appreciated. I'm working on resolving remaining issues.

Re: [PATCH v17 0/4] add support for self monitoring

2025-06-06 Thread Tomasz Duszynski
Hi Thomas, >Hello, > >17/01/2025 10:00, Tomasz Duszynski: >> lib/pmu/meson.build | 22 + >> lib/pmu/pmu_arm64.c | 94 >> lib/pmu/pmu_private.h| 32 ++ >> lib/pmu/rte_p

[PATCH v4] raw/cnxk_gpio: switch to character based GPIO interface

2025-03-27 Thread Tomasz Duszynski
s the PMD to use the current GPIO interface ensuring compatibility with current kernel standards while improving maintainability and security. Signed-off-by: Tomasz Duszynski --- v2: - compile conditionally based on GPIO_V2_PRESENT v3: - fix compilation issues due to missing structure member - qu

[PATCH v3] raw/cnxk_gpio: switch to character based GPIO interface

2025-03-24 Thread Tomasz Duszynski
s the PMD to use the current GPIO interface ensuring compatibility with current kernel standards while improving maintainability and security. Signed-off-by: Tomasz Duszynski --- v2: - compile conditionally based on GPIO_V2_PRESENT v3: - fix compilation issues due to missing structure member - qu

[PATCH v2] raw/cnxk_gpio: switch to character based GPIO interface

2025-03-24 Thread Tomasz Duszynski
s the PMD to use the current GPIO interface ensuring compatibility with current kernel standards while improving maintainability and security. Signed-off-by: Tomasz Duszynski --- v2: - compile conditionally based on GPIO_V2_PRESENT doc/guides/rawdevs/cnxk_gpio.rst | 37 +- driver

[PATCH] raw/cnxk_gpio: switch to character based GPIO interface

2025-03-14 Thread Tomasz Duszynski
s the PMD to use the current GPIO interface ensuring compatibility with current kernel standards while improving maintainability and security. Signed-off-by: Tomasz Duszynski --- doc/guides/rawdevs/cnxk_gpio.rst | 37 +- drivers/raw/cnxk_gpio/cnxk_gpio.c

[PATCH v17 4/4] eal: add PMU support to tracing library

2025-01-17 Thread Tomasz Duszynski
In order to profile app one needs to store significant amount of samples somewhere for an analysis later on. Since trace library supports storing data in a CTF format lets take advantage of that and add a dedicated PMU tracepoint. Signed-off-by: Tomasz Duszynski --- app/test/test_trace_perf.c

[PATCH v17 3/4] pmu: support reading Intel x86_64 PMU events in runtime

2025-01-17 Thread Tomasz Duszynski
Add support for reading Intel x86_64 PMU events in runtime. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 2 ++ lib/pmu/meson.build | 1 + lib/pmu/rte_pmu.h| 2 ++ lib/pmu/rte_pmu_pmc_x86_64.h | 24 4 files changed, 29

[PATCH v17 2/4] pmu: support reading ARM PMU events in runtime

2025-01-17 Thread Tomasz Duszynski
Add support for reading ARM PMU events in runtime. Signed-off-by: Tomasz Duszynski --- app/test/test_pmu.c | 4 ++ lib/pmu/meson.build | 8 lib/pmu/pmu_arm64.c | 94 + lib/pmu/rte_pmu.h | 4 ++ lib/pmu

[PATCH v17 1/4] lib: add generic support for reading PMU events

2025-01-17 Thread Tomasz Duszynski
. Signed-off-by: Tomasz Duszynski --- MAINTAINERS| 5 + app/test/meson.build | 1 + app/test/test_pmu.c| 49 +++ doc/api/doxy-api-index.md | 3 +- doc/api/doxy-api.conf.in | 1 + doc/guides/prog_guide

[PATCH v17 0/4] add support for self monitoring

2025-01-17 Thread Tomasz Duszynski
rary - address review comments v5: - address review comments - fix sign extension while reading pmu on x86 - fix regex mentioned in doc - various minor changes/improvements here and there v4: - fix freeing mem detected by debug_autotest v3: - fix shared build v2: - fix problems reported by test bu

RE: [EXTERNAL] Re: [PATCH] net/tap: fix compilation issues if HAVE_TCA_FLOWER is missing

2025-01-08 Thread Tomasz Duszynski
>> From: Tomasz Duszynski >> To: , Stephen Hemminger , >"Pascal Mazon" >> CC: , Tomasz Duszynski >> Subject: [PATCH] net/tap: fix compilation issues if HAVE_TCA_FLOWER is >> missing >> Date: Wed, 8 Jan 2025 13:10:11 +0100 >> X-Mailer: git-

[PATCH] net/tap: fix compilation issues if HAVE_TCA_FLOWER is missing

2025-01-08 Thread Tomasz Duszynski
parameter ‘remote_iface’ [-Werror=unused-parameter] Fixes: bf7b7f437b49 ("net/tap: create netdevice during probing") Cc: pascal.ma...@6wind.com Signed-off-by: Tomasz Duszynski --- drivers/net/tap/rte_eth_tap.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drive

RE: [EXTERNAL] Re: [PATCH v16 4/4] eal: add PMU support to tracing library

2025-01-08 Thread Tomasz Duszynski
>> + >> +/* events are matched against occurrences of e=ev1[,ev2,..] pattern */ >> +ret = regcomp(®, "e=([_[:alnum:]-],?)+", REG_EXTENDED); >> +if (ret) { >> +PMU_LOG(ERR, "Failed to compile event matching regexp"); >> +return -EINVAL; >> +} >> + >> +for

RE: [EXTERNAL] Re: [PATCH v16 0/4] add support for self monitoring

2025-01-07 Thread Tomasz Duszynski
>> This series adds self monitoring support i.e allows to configure and >> read performance measurement unit (PMU) counters in runtime without >> using perf utility. This has certain advantages when application runs >> on isolated cores running dedicated tasks. >> >> Events can be read directly usi

RE: [EXTERNAL] Re: [PATCH v16 1/4] lib: add generic support for reading PMU events

2025-01-07 Thread Tomasz Duszynski
>> +Performance counter based profiling >> +--- >> + >> +Majority of architectures support some performance monitoring unit >(PMU). >> +Such unit provides programmable counters that monitor specific events. > >Sentence wording is awkward, maybe combine the two senten

RE: [PATCH v16 1/4] lib: add generic support for reading PMU events

2025-01-06 Thread Tomasz Duszynski
lity without sacrificing latency and performance. >> >> Signed-off-by: Tomasz Duszynski >> --- > >Acked-by: Konstantin Ananyev > >As future possible enhancements - I think it would be useful to make control- >path API MT safe, plus probably try to hide some of the e

RE: [PATCH v16 0/4] add support for self monitoring

2024-12-01 Thread Tomasz Duszynski
>-Original Message- >From: Tomasz Duszynski >Sent: Monday, November 18, 2024 8:37 AM >To: Tomasz Duszynski >Cc: ruifeng.w...@arm.com; bruce.richard...@intel.com; >david.march...@redhat.com; dev@dpdk.org; >Jerin Jacob ; konstantin.v.anan...@yandex.ru; >mattias.r

  1   2   3   4   5   6   7   8   9   >