scenario2: add perf

This commit is contained in:
illustris
2026-01-10 20:17:43 +05:30
parent 596ae02dd4
commit 658f4e98bc
3 changed files with 65 additions and 30 deletions

View File

@@ -38,6 +38,8 @@ py-spy record -o prime_slow.svg -- python3 prime_slow.py
Open `prime_slow.svg` in a browser. The widest bar at the top shows where time is spent.
**Note:** py-spy only traces Python functions. Time spent in native C code (like the C library calls in later steps) won't appear in py-spy flamegraphs.
### Step 4: Compile and run the partially optimized version
```bash
# Compile the C library