[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>
Cette révision appartient à :
@@ -44,14 +44,13 @@ namespace
|
||||
{
|
||||
struct FlatProfiler
|
||||
{
|
||||
public:
|
||||
FlatProfiler() = default;
|
||||
~FlatProfiler() = default;
|
||||
|
||||
CodeobjAddressTranslate translator;
|
||||
KernelObjectMap kernel_object_map;
|
||||
FlatProfile flat_profile;
|
||||
std::mutex global_mut;
|
||||
CodeobjAddressTranslate translator = {};
|
||||
KernelObjectMap kernel_object_map = {};
|
||||
FlatProfile flat_profile = {};
|
||||
std::mutex global_mut = {};
|
||||
};
|
||||
} // namespace
|
||||
|
||||
@@ -68,6 +67,7 @@ void
|
||||
fini()
|
||||
{
|
||||
delete flat_profiler;
|
||||
flat_profiler = nullptr;
|
||||
}
|
||||
|
||||
CodeobjAddressTranslate&
|
||||
@@ -186,15 +186,19 @@ dump_flat_profile()
|
||||
ss << "====================================\n" << std::endl;
|
||||
});
|
||||
|
||||
ss << "The total number of decoded samples: " << samples_num << std::endl;
|
||||
ss << "The total number of collected samples: " << client::pcs::total_samples_num()
|
||||
ss << "The total number of valid decoded samples: "
|
||||
<< flat_profile.get_valid_decoded_samples_num() << std::endl;
|
||||
ss << "The total number of invalid samples : " << flat_profile.get_invalid_samples_num()
|
||||
<< std::endl;
|
||||
|
||||
*utils::get_output_stream() << ss.str() << std::endl;
|
||||
|
||||
assert(samples_num == client::pcs::total_samples_num());
|
||||
// We expect at least one PC sample to be decoded/delivered;
|
||||
assert(samples_num > 0);
|
||||
utils::pcs_assert(
|
||||
samples_num == flat_profile.get_valid_decoded_samples_num(),
|
||||
"Number of collected valid samples different than the number of decoded samples.");
|
||||
utils::pcs_assert(samples_num > 0, "No valid samples collected/decoded.");
|
||||
utils::pcs_assert(flat_profile.more_valid_decoded_samples_expected(),
|
||||
"More invalid samples observed.");
|
||||
}
|
||||
|
||||
} // namespace address_translation
|
||||
|
||||
Référencer dans un nouveau ticket
Bloquer un utilisateur