uftrace is a function call graph tracer for C, C++, Rust, and Python programs.
The tool hooks into function entry and exit points to record timestamps, arguments, and return values, capturing both user-space and kernel-level execution in a unified timeline. It supports multiple tracing modes: compiler-assisted instrumentation using flags like -pg or -fpatchable-function-entry, dynamic patching without recompilation by analyzing function prologues, and library function tracing through PLT hooking. The tool can also capture kernel functions, trace events, task scheduling, and performance counter data. Beyond recording, uftrace provides filtering to reduce trace volume and visualization through Chrome trace viewer, flame graphs, and call-graph diagrams in graphviz or mermaid formats.
The tool suits developers debugging performance issues or understanding program execution flow in compiled languages and Python. It works best on unstripped binaries or those with available symbol information. The dynamic patching mode (-P.) removes the need for recompilation, making it accessible for analyzing existing binaries. Users can extend functionality by writing custom scripts in Python or Lua that run at function entry and exit points, enabling specialized analysis without modifying the traced program.
The project shows consistent maintenance with regular updates addressing bugs and adding features. Development includes active engagement with users through multiple communication channels and documentation resources. The codebase receives improvements to core tracing infrastructure and visualization capabilities. The project maintains broad platform support and continues expanding its instrumentation options.