1
0
Fork 0
mirror of https://github.com/VSadov/Satori.git synced 2025-06-11 10:18:21 +09:00
* * Add license headers to autotrace.h|cpp
* use W() macro for getting correct string literal type
* formalize env vars to be COMPlus_* style
* add documentation
* modify cmake files to have the flag and set default value to 0

* Fix typo


Commit migrated from b3ff5135ec
This commit is contained in:
John Salem 2019-06-04 09:09:59 -07:00 committed by Andrew Au
parent 13bfbddf0f
commit 895e8b3e0a
5 changed files with 55 additions and 9 deletions

View file

@ -0,0 +1,23 @@
#AutoTrace:
> see: `src/vm/autotrace.h|cpp` for the code
AutoTrace is used to run automated testing of the Diagnostic Server based tracing and specifically
EventPipe. The feature itself is enabled via the feature flag `-DFEATURE_AUTO_TRACE`.
## Mechanism:
AutoTrace injects a waitable event into the startup path of the runtime and waits on that event until
some number of Diagnostics IPC (see: Diagnostics IPC in the dotnet/diagnostics repo) connections have occurred.
The runtime then creates some number of processes using a supplied path that typically are Diagnostics IPC based tracers.
Once all the tracers have connected to the server, the event will be signaled and execution will continue as normal.
## Use:
Two environment variables dictate behavior:
- `COMPlus_AutoTrace_N_Tracers`: The number of tracers to create. Should be a number in `[0,64]` where `0` will bypass the wait for attach.
- `COMPlus_AutoTrace_Command`: The path to the executable to be invoked. Typically this will be a `run.sh|cmd` script.
> (NB: you should `cd` into the directory you intend to execute `COMPlus_AutoTrace_Command` from as the first line of the script.)
Once turned on, AutoTrace will run the specified command `COMPlus_AutoTrace_N_Tracers` times.