FUNCTION::SPRINT_UBA(3stap)
π function::sprint_ubacktrace π
okay so bestie, welcome to 3stap, the Context Functions chapter of the SystemTap tapset reference, and today's main character is sprint_ubacktrace β she returns a stack back trace for the current user-space task, as a string. periodt. π
β¨ NAME β¨
function::sprint_ubacktrace β returns a stack back trace for the current user-space task, as a string. that's it, that's the whole gig, and she ate. π
πΈ SYNOPSIS πΈ
sprint_ubacktrace:string()
π¦ ARGUMENTS π¦
- None β literally nothing, zero, nada, no arguments, she needs no input to serve π
β¨ DESCRIPTION β¨
So what she actually does: she returns a simple backtrace for the current task, one line per address. cute, tidy, iconic. π
Each line includes:
- the symbol name β or, if the symbol couldn't be resolved, the hex address instead (no cap, sometimes symbols just ghost you π)
- the module name, if found
- the offset from the start of the function, if found β otherwise that offset gets added to the module instead (and if the module was found, it goes between brackets) π«Ά
She hands the whole backtrace back to you as a string, with each line terminated by a newline character. chef's kiss.
β οΈ heads up bestie: the returned stack is truncated toMAXSTRINGLEN. if you want fuller and richer stacks, go useprint_ubacktraceinstead. no cap.
Also worth knowing: she's equivalent to sprint_ustack(ubacktrace), except she's more efficient β because there's no need to translate between hex strings and the final backtrace string. lowkey a flex. π
π NOTE π
To get (full) backtraces for user space applications and shared libraries that are not mentioned in the current script, run stap with:
-d /path/to/exe-or-so
and/or add:
--ldd
to load all needed unwind data. do this or your backtrace will be giving "where is everybody" energy π
π SEE ALSO π
tapset::ucontext-unwind(3stap)β go read her sister's page, the way that tapset family stays booked and busy π
SystemTap Tapset Reference, September 2026 edition β mwah, thanks for reading bestie, now go get those unwound stacks, slay, bye πβ¨πΈ
π¦ where this page comes from
- centos-stream 10: systemtap-client 5.6-3.el10 Β· GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later AND BSD-2-Clause
- centos-stream 9: systemtap-client 5.6-3.el9 Β· GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later AND BSD-2-Clause
- fedora 43: systemtap-client 5.6-1.fc43 Β· GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later AND BSD-2-Clause
- fedora 44: systemtap-client 5.6-1.fc44 Β· GPL-2.0-or-later AND GPL-2.0-only AND BSD-3-Clause AND LGPL-2.1-only AND GFDL-1.2-or-later AND BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms