Thread (161 messages) 161 messages, 8 authors, 2025-04-24

Re: [PATCH v4 28/39] unwind_user/deferred: Add deferred unwinding interface

From: Peter Zijlstra <peterz@infradead.org>
Date: 2025-01-22 13:37:47
Also in: linux-perf-users, linux-toolchains, lkml

On Tue, Jan 21, 2025 at 06:31:20PM -0800, Josh Poimboeuf wrote:
+/*
+ * The context cookie is a unique identifier which allows post-processing to
+ * correlate kernel trace(s) with user unwinds.  The high 12 bits are the CPU
s/12/16/ ?
+ * id; the lower 48 bits are a per-CPU entry counter.
+ */
+static u64 ctx_to_cookie(u64 cpu, u64 ctx)
+{
+	BUILD_BUG_ON(NR_CPUS > 65535);
+	return (ctx & ((1UL << 48) - 1)) | (cpu << 48);
+}
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help