From 4ff170540e20aac1d8b5809d119b6d71e9d69a0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Gr=C3=A9goire?= Date: Thu, 29 Oct 2026 13:15:46 +0100 Subject: [PATCH] Address review comments on the shared sampling rings Move the shared ring comment onto `OpenSampleEvent`, where the sharing happens. Name the number of sampling event kinds with `NumSampleEventKinds` instead of using `EventVsync` directly, and assert in `OpenSampleEvent` that the event id is below it. --- public/client/TracySysTrace.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/public/client/TracySysTrace.cpp b/public/client/TracySysTrace.cpp index 4672c485..1407a3df 100644 --- a/public/client/TracySysTrace.cpp +++ b/public/client/TracySysTrace.cpp @@ -426,9 +426,6 @@ struct SysTraceState static SysTraceState s_state; -// Sampling events of one kind on one CPU share a ring: the first thread's event owns it -// (the sharedRingFd array, per event kind and CPU), the others are redirected into it with -// PERF_EVENT_IOC_SET_OUTPUT. Redirected fds are kept open, and enabled by the worker. static void CloseRedirectFds() { for( int i=0; i