feat: add --tracemalloc flag for memory profiling

Uses Python's built-in tracemalloc module to show top N memory
allocators on exit. Orthogonal to --cprofile; both can run together.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
user
2026-02-17 10:43:47 +01:00
parent d2df32fdab
commit 6c84a144c0
4 changed files with 31 additions and 2 deletions

View File

@@ -110,6 +110,7 @@ Options:
-v, --verbose Debug logging
-q, --quiet Errors only
--cprofile [FILE] Enable cProfile, dump to FILE (default: s5p.prof)
--tracemalloc [N] Enable tracemalloc, show top N allocators on exit (default: 10)
-V, --version Show version
```