Function Call Tracing
CommunityTrace C/C++ function calls with Perfetto.
Authorgadievron
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Trace all function calls in C/C++ programs to generate per-thread logs for Perfetto visualization.
Core Features & Use Cases
- Instrumentation Library (trace_instrument.c) captures function entry/exit, writes per-thread logs.
- Perfetto Converter (trace_to_perfetto.cpp) converts logs to Perfetto Chrome JSON format.
- Use Case: Profiling multi-threaded applications to visualize call graphs and performance hotspots in Perfetto.
Quick Start
- Copy trace_instrument.c and trace_to_perfetto.cpp to your project.
- Build the instrumentation library and your project.
- Enable -finstrument-functions in CFLAGS and link with -ltrace and -lpthread as needed.
- Run your program to generate trace_<tid>.log files.
- Convert logs to Perfetto: ./trace_to_perfetto trace_*.log -o trace.json and view it at ui.perfetto.dev.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: Function Call Tracing Download link: https://github.com/gadievron/raptor/archive/main.zip#function-call-tracing Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.