SWDEV-275232: Replaced the use of on_exit()

on_exit() registered exit_handler function, but in the case of OpenMP applications the registered exit func exit_handler was called after the dlclose of the library. So we removed exit_handler from roctracer as it is already handled in both rocprofiler and rocprof script.

Change-Id: I7c3d42e6ccc282e713b48b4a7faec4935e7a2600


[ROCm/roctracer commit: aa41554130]
This commit is contained in:
Ammar ELWazir
2021-10-08 20:25:12 -05:00
کامیت شده توسط Ammar Elwazir
والد 606d3dd8e8
کامیت 023cb806f9
@@ -960,15 +960,10 @@ void tool_load() {
ONLOAD_TRACE_END();
}
void exit_handler(int status, void* arg) {
ONLOAD_TRACE("status(" << status << ") arg(" << arg << ")");
}
// HSA-runtime tool on-load method
extern "C" PUBLIC_API bool OnLoad(HsaApiTable* table, uint64_t runtime_version, uint64_t failed_tool_count,
const char* const* failed_tool_names) {
ONLOAD_TRACE_BEG();
on_exit(exit_handler, NULL);
timer = new hsa_rt_utils::Timer(table->core_->hsa_system_get_info_fn);