Call stack context for user space trace points
Sunku, Sai
sunkusa at amazon.com
Sun Oct 5 22:50:20 EDT 2025
Hello,
I have a complex, multithreaded benchmark that emits LTTng trace points at various stages. I am trying to trace all malloc calls made by this benchmark. I'm specifically trying to get malloc trace points also through LTTng so that I can identify when the malloc call was made relative to other trace points from the benchmark. I also want to see the stack trace for each malloc call so that I can identify where in the benchmark the malloc call is coming from.
If I preload the lttng libc wrapper with `LD_PRELOAD=liblttng-ust-libc-wrapper.so`, I'm able to see the trace points from malloc calls.
But when I try to add the callstack-user context with this command `lttng add-context --userspace --channel 1 --type callstack-user`, I get an error saying "Error: callstack-user: UST invalid context"
I've successfully added user space stack traces for kernel trace points with a similar command `lttng add-context --kernel --type callstack-user`
Is the callstack-user context only available for kernel trace points? Is there another way to get the call stack for malloc calls?
Thank you,
Sai Sunku
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.lttng.org/pipermail/lttng-dev/attachments/20251006/200e0493/attachment.htm>
More information about the lttng-dev
mailing list