[SDK][rocprofv3] MI300 Stochastic PC sampling (#92)

* MI300 Stochastic PC sampling SDK API implementation

* ROCProfV3: Stochastic PC sampling Support (#94)

* ROCProfV3: MI300 Stochastic PC sampling initial draft

* ROCProfV3: Initial Stochastic PC sampling Tests (#95)

ROCProfV3: Initial Stochastic PC sampling tests

* Update rocprofiler_pc_sampling_record_stochastic_v0_t

- update doxygen docs for members
- replace rocprofiler_correlation_id_t with rocprofiler_async_correlation_id_t

* Relax the check in JSON tests

* drain PC sampling buffer during finalize_rocprofv3

* Increase timeout for "Test Install Build" step

- 10 minutes -> 20 minutes
- "Test Installed Packages" has 20 minutes so "Test Install Build" should also

---------

Co-authored-by: Jonathan R. Madsen <jonathanrmadsen@gmail.com>
This commit is contained in:
Indic, Vladimir
2025-03-21 20:40:45 +01:00
committed by GitHub
parent c06feccf2a
commit 49ce79a5b5
98 changed files with 5266 additions and 1031 deletions
+20 -2
View File
@@ -285,10 +285,28 @@ config::config()
{"stochastic", ROCPROFILER_PC_SAMPLING_METHOD_STOCHASTIC},
{"host_trap", ROCPROFILER_PC_SAMPLING_METHOD_HOST_TRAP}};
pc_sampling_method_value = pc_sampling_method_map.at(pc_sampling_method);
try
{
pc_sampling_method_value = pc_sampling_method_map.at(pc_sampling_method);
} catch(...)
{
ROCP_FATAL << "Invalid value for ROCPROF_PC_SAMPLING_METHOD: " << pc_sampling_method << "."
<< "Valid choices are stochastic and host_trap\n";
}
if(pc_sampling_method_value == ROCPROFILER_PC_SAMPLING_METHOD_HOST_TRAP)
pc_sampling_host_trap = true;
pc_sampling_unit_value = pc_sampling_unit_map.at(pc_sampling_unit);
else if(pc_sampling_method_value == ROCPROFILER_PC_SAMPLING_METHOD_STOCHASTIC)
pc_sampling_stochastic = true;
try
{
pc_sampling_unit_value = pc_sampling_unit_map.at(pc_sampling_unit);
} catch(...)
{
ROCP_FATAL << "Invalid value for ROCPROF_PC_SAMPLING_UNIT: " << pc_sampling_unit << "."
<< "Valid choices are instructions, cycles and time\n";
}
if(auto _collection_period = get_env("ROCPROF_COLLECTION_PERIOD", "");
!_collection_period.empty())