Skip to content

tp: introduce ForgedTracePacketWriter for writing TracePackets efficiently#4799

Merged
LalitMaganti merged 3 commits intomainfrom
dev/lalitm/forged-trace-packet
Feb 13, 2026
Merged

tp: introduce ForgedTracePacketWriter for writing TracePackets efficiently#4799
LalitMaganti merged 3 commits intomainfrom
dev/lalitm/forged-trace-packet

Conversation

@LalitMaganti
Copy link
Member

This CL introduces a new class to write TracePacket protos efficiently
and get out TraceBlobViews without creating tons of copies. There were
already N instances of this in the codebase and we're now introducing a
new one in #4768.

Instead now we have a single class which works with TraceBlob +
TraceBlobView and is stored in TraceProcessorContext so everyone can use
it. It works in 4MB chunks and reuses them across TracePacket calls
which makes it really efficient now to create these packets with 99% of
cases being totally zero-copy.

@LalitMaganti LalitMaganti requested a review from a team as a code owner February 13, 2026 17:55
@LalitMaganti LalitMaganti force-pushed the dev/lalitm/forged-trace-packet branch 2 times, most recently from 3ec9301 to e614b62 Compare February 13, 2026 19:17
…ently

This CL introduces a new class to write TracePacket protos efficiently
and get out TraceBlobViews without creating tons of copies. There were
already N instances of this in the codebase and we're now introducing a
new one in #4768.

Instead now we have a single class which works with TraceBlob +
TraceBlobView and is stored in TraceProcessorContext so everyone can use
it. It works in 4MB chunks and reuses them across TracePacket calls
which makes it really efficient now to create these packets with 99% of
cases being totally zero-copy.
@LalitMaganti LalitMaganti force-pushed the dev/lalitm/forged-trace-packet branch from e614b62 to c71656e Compare February 13, 2026 19:27
@LalitMaganti LalitMaganti enabled auto-merge (squash) February 13, 2026 23:32
@LalitMaganti LalitMaganti merged commit 799b6fe into main Feb 13, 2026
21 of 23 checks passed
@LalitMaganti LalitMaganti deleted the dev/lalitm/forged-trace-packet branch February 13, 2026 23:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants