tynd profile
tynd profile --memorytynd profile --memory -o profiles/startup.heapsnapshottynd profile --ipctynd profile --cpu -o host.svgPick exactly one mode.
| Mode | What it does | Output |
|---|---|---|
--cpu |
Runs cargo flamegraph on the native host |
flamegraph.svg |
--memory |
Runs tynd dev with BUN_OPTIONS=--heap-prof ... |
tynd-dev.heapsnapshot |
--ipc |
Runs tynd dev with RUST_LOG=tynd::ipc=trace,tynd::debug=debug |
Logs only |
Relative output paths are resolved against the project root. --memory and --ipc end when you close the app.
| Flag | Default | Effect |
|---|---|---|
--cwd <dir> |
. |
Start of the project-root search |
--cpu / --memory / --ipc |
one required | Profile mode |
-o, --out <path> |
see the table above | Output file for --cpu and --memory |
What can go wrong
Section titled “What can go wrong”--cpuneeds the generated host workspace (.tynd/build/Cargo.toml) or a Tynd source checkout. Before the firsttynd devortynd buildit fails; run one first, or use--memoryor--ipc. It also needscargo flamegraphinstalled.--out is only supported with --cpu or --memory.--memoryfails if Bun exits without writing the snapshot, and refuses an output path that contains".- The profiled session runs with a sanitized environment.