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:
@@ -419,6 +419,15 @@ s5p --cprofile output.prof -c config/s5p.yaml
|
||||
|
||||
# Analyze after stopping
|
||||
python -m pstats s5p.prof
|
||||
|
||||
# Memory profiling with tracemalloc (top 10 allocators on exit)
|
||||
s5p --tracemalloc -c config/s5p.yaml
|
||||
|
||||
# Show top 20 allocators
|
||||
s5p --tracemalloc 20 -c config/s5p.yaml
|
||||
|
||||
# Both profilers simultaneously
|
||||
s5p --cprofile --tracemalloc -c config/s5p.yaml
|
||||
```
|
||||
|
||||
## Testing the Proxy
|
||||
|
||||
Reference in New Issue
Block a user