Remove Critical Trace Support (#327)

* Delete core critical-trace files

* Update docs and README

* Update workflows

* Update testing

* Update cmake

* Remove critical trace usage in source code

* Update source/docs/critical_trace.md

- fix spelling

* Formatting

* Update bin/omnitrace-avail/avail.cpp

- statically allocate shared pointers for timemory manager and hash id/aliases to prevent use-after-free errors

[ROCm/rocprofiler-systems commit: 9499e2f521]
This commit is contained in:
Jonathan R. Madsen
2024-04-23 09:35:44 -05:00
کامیت شده توسط GitHub
والد 2a42e3abf0
کامیت ab551e7eb7
45فایلهای تغییر یافته به همراه55 افزوده شده و 2954 حذف شده
@@ -1,4 +1,4 @@
# Generating a Critical Trace
# Critical Trace Support
```eval_rst
.. toctree::
@@ -6,24 +6,5 @@
:maxdepth: 4
```
## Overview
A critical trace is defined in omnitrace as the most time-consuming path through a parallelized code.
The steps for generating a critical trace are:
1. Enable the `OMNITRACE_CRITICAL_TRACE` setting
2. Configure any other relevant critical-trace settings, as needed
- `omnitrace-avail --categories settings::critical_trace`
3. Execute application
4. Locate the JSON files with `call-chain` in their name
5. Provide these files to the `omnitrace-critical-trace` executable
6. Open generated perfetto file in [ui.perfetto.dev](https://ui.perfetto.dev/)
## omnitrace-critical-trace Executable
The `omnitrace-critical-trace` executable post-processes one or more `call-chain` JSON files and generates a perfetto output
for visualizing the critical trace.
**INCOMPLETE**
This executable is still under-development.
Critical trace support has been superseded by causal profiling support.
Critical trace support was removed in Omnitrace v1.11.0 due to incomplete implementation.
@@ -50,10 +50,6 @@ for each variant:
- For a binary rewrite: outputs new instrumented binary and exits
- For runtime instrumentation or attaching to a process: instructs the application to resume executing and then waits for the application to exit
### omnitrace-critical-trace: [source/bin/omnitrace-critical-trace](https://github.com/ROCm/omnitrace/tree/main/source/bin/omnitrace-critical-trace)
Post-processing tool for critical-trace data output by omnitrace.
## Libraries
### Common Library: [source/lib/common](https://github.com/ROCm/omnitrace/tree/main/source/lib/common)
@@ -25,7 +25,6 @@ manage extensions, resources, data, etc.
- Background thread records process-, system- and device-level metrics while the application executes
- Causal profiling
- Quantifies the potential impact of optimizations in parallel codes
- Critical trace generation
### Data Analysis
@@ -35,7 +34,6 @@ manage extensions, resources, data, etc.
- Comprehensive traces
- Every individual event/measurement
- Application speedup predictions resulting from potential optimizations in functions and lines of code (causal profiling)
- Critical trace analysis (alpha)
### Parallelism API Support
@@ -191,13 +191,7 @@ OMNITRACE_USE_PID = true
OMNITRACE_OUTPUT_PATH = omnitrace-%tag%-output
OMNITRACE_OUTPUT_PREFIX =
OMNITRACE_CI = false
OMNITRACE_CRITICAL_TRACE = false
OMNITRACE_CRITICAL_TRACE_BUFFER_COUNT = 2000
OMNITRACE_CRITICAL_TRACE_COUNT = 0
OMNITRACE_CRITICAL_TRACE_DEBUG = false
OMNITRACE_THREAD_POOL_SIZE = 8
OMNITRACE_CRITICAL_TRACE_PER_ROW = 0
OMNITRACE_CRITICAL_TRACE_SERIALIZE_NAMES = false
OMNITRACE_DEBUG = false
OMNITRACE_DL_VERBOSE = 0
OMNITRACE_INSTRUMENTATION_INTERVAL = 1
@@ -283,13 +277,7 @@ $ omnitrace-avail -S -bd
| OMNITRACE_CONFIG_FILE | Configuration file for omnitrace |
| OMNITRACE_COUT_OUTPUT | Write output to stdout |
| OMNITRACE_CPU_AFFINITY | Enable pinning threads to CPUs (Linu... |
| OMNITRACE_CRITICAL_TRACE | Enable generation of the critical trace |
| OMNITRACE_CRITICAL_TRACE_BUFFER_COUNT | Number of critical trace records to ... |
| OMNITRACE_CRITICAL_TRACE_COUNT | Number of critical trace to export (... |
| OMNITRACE_CRITICAL_TRACE_DEBUG | Enable debugging for critical trace |
| OMNITRACE_THREAD_POOL_SIZE | Number of threads to use when genera... |
| OMNITRACE_CRITICAL_TRACE_PER_ROW | How many critical traces per row in ... |
| OMNITRACE_CRITICAL_TRACE_SERIALIZE_N... | Include names in serialization of cr... |
| OMNITRACE_DEBUG | Enable debug output |
| OMNITRACE_DIFF_OUTPUT | Generate a difference output vs. a p... |
| OMNITRACE_DL_VERBOSE | Verbosity within the omnitrace-dl li... |
@@ -209,7 +209,6 @@ $ omnitrace-sample -- ./parallel-overhead-locks 30 4 100
HSA_TOOLS_LIB=/opt/omnitrace/lib/libomnitrace-dl.so.1.7.1
HSA_TOOLS_REPORT_LOAD_FAILURE=1
LD_PRELOAD=/opt/omnitrace/lib/libomnitrace-dl.so.1.7.1
OMNITRACE_CRITICAL_TRACE=false
OMNITRACE_USE_PROCESS_SAMPLING=false
OMNITRACE_USE_SAMPLING=true
OMP_TOOL_LIBRARIES=/opt/omnitrace/lib/libomnitrace-dl.so.1.7.1
@@ -228,7 +227,6 @@ HSA_TOOLS_REPORT_LOAD_FAILURE=1
KOKKOS_PROFILE_LIBRARY=/opt/omnitrace/lib/libomnitrace.so.1.7.1
LD_PRELOAD=/opt/omnitrace/lib/libomnitrace-dl.so.1.7.1
OMNITRACE_CPU_FREQ_ENABLED=true
OMNITRACE_CRITICAL_TRACE=false
OMNITRACE_TRACE_THREAD_LOCKS=true
OMNITRACE_TRACE_THREAD_RW_LOCKS=true
OMNITRACE_TRACE_THREAD_SPIN_LOCKS=true
@@ -258,7 +256,6 @@ $ omnitrace-sample -PTDH -E all -o omnitrace-output %tag% -- ./parallel-overhead
LD_PRELOAD=/opt/omnitrace/lib/libomnitrace-dl.so.1.7.1
OMNITRACE_CPU_FREQ_ENABLED=true
OMNITRACE_CRITICAL_TRACE=false
OMNITRACE_OUTPUT_PATH=omnitrace-output
OMNITRACE_OUTPUT_PREFIX=%tag%
OMNITRACE_TRACE_THREAD_LOCKS=false
@@ -288,7 +285,6 @@ $ omnitrace-sample -PTDH -E all -o omnitrace-output %tag% -c -- ./parallel-overh
LD_PRELOAD=/opt/omnitrace/lib/libomnitrace-dl.so.1.7.1
OMNITRACE_CONFIG_FILE=
OMNITRACE_CPU_FREQ_ENABLED=true
OMNITRACE_CRITICAL_TRACE=false
OMNITRACE_OUTPUT_PATH=omnitrace-output
OMNITRACE_OUTPUT_PREFIX=%tag%
OMNITRACE_TRACE_THREAD_LOCKS=false