Merge pull request #4490 from facebook/doc_profiling_vs

minor: add profiling notes for Visual Studio
This commit is contained in:
Yann Collet 2025-09-20 22:30:40 -08:00 committed by GitHub
commit ee9b5f4371
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -373,7 +373,12 @@ counter `L1-dcache-load-misses`
#### Visual Studio #### Visual Studio
TODO Build Zstd with symbols first (for example `cmake -B build -S build/cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo && ninja -C build zstd`) so the profiler resolves call stacks.
* Launch Visual Studios Performance Profiler (`Alt+F2`), enable CPU Usage (optionally Instrumentation), and point it at the `programs/zstd` benchmark you want to run.
* If you prefer to start the benchmark from a terminal, use “Attach to running process” to latch onto it mid-run; keep frame pointers (`-fno-omit-frame-pointer`) for clean stacks.
* When you stop the capture, review the call tree, hot path, and annotated source panes
* Microsofts [Performance Profiling docs](https://learn.microsoft.com/en-us/visualstudio/profiling/?view=vs-2022) cover deeper sampling, ETW, and collection options if required.
## Issues ## Issues
We use GitHub issues to track public bugs. Please ensure your description is We use GitHub issues to track public bugs. Please ensure your description is