Add kernel profiling time info to counter collection records (#1000)
* Add kernel profiling time info to counter collection records
- lib/rocprofiler-sdk/kernel_dispatch
- added profiling_time.{hpp,cpp}
- restructured tracing.cpp
- updated queue.cpp AsyncSignalHandler
- gets kernel dispatch profiling time and passes to dispatch_complete and signal callbacks
- structured some header includes to reduce cyclic include probability
- originally, including kernel_dispatch/tracing.hpp in hsa/queue.hpp created a lot of cyclic includes
* Fix kernel_dispatch.cpp includes
* Fix kernel_dispatch.cpp
- include <cstring>
- replace use of ROCPROFILER_HSA_AMD_EXT_API_ID_NONE with ROCPROFILER_KERNEL_DISPATCH_LAST
This commit is contained in:
zatwierdzone przez
GitHub
rodzic
fa1b9e67ab
commit
b15e498945
@@ -434,7 +434,8 @@ DispatchThreadTracer::start_context()
|
||||
[=](const hsa::Queue& /* q */,
|
||||
hsa::rocprofiler_packet /* kern_pkt */,
|
||||
const hsa::Queue::queue_info_session_t& session,
|
||||
inst_pkt_t& aql) { this->post_kernel_call(aql, session); });
|
||||
inst_pkt_t& aql,
|
||||
kernel_dispatch::profiling_time) { this->post_kernel_call(aql, session); });
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -22,16 +22,20 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "lib/rocprofiler-sdk/context/correlation_id.hpp"
|
||||
#include "lib/rocprofiler-sdk/hsa/agent_cache.hpp"
|
||||
#include "lib/rocprofiler-sdk/hsa/aql_packet.hpp"
|
||||
#include "lib/rocprofiler-sdk/hsa/queue_info_session.hpp"
|
||||
#include "lib/rocprofiler-sdk/thread_trace/code_object.hpp"
|
||||
|
||||
#include <rocprofiler-sdk/cxx/hash.hpp>
|
||||
#include <rocprofiler-sdk/cxx/operators.hpp>
|
||||
|
||||
#include <rocprofiler-sdk/amd_detail/thread_trace.h>
|
||||
#include <rocprofiler-sdk/intercept_table.h>
|
||||
#include <rocprofiler-sdk/cxx/hash.hpp>
|
||||
#include <rocprofiler-sdk/cxx/operators.hpp>
|
||||
|
||||
#include <atomic>
|
||||
#include <cstdint>
|
||||
#include <map>
|
||||
#include <memory>
|
||||
#include <mutex>
|
||||
#include <shared_mutex>
|
||||
@@ -149,7 +153,7 @@ public:
|
||||
rocprofiler_user_data_t* user_data,
|
||||
const context::correlation_id* corr_id);
|
||||
|
||||
void post_kernel_call(inst_pkt_t& aql, const hsa::Queue::queue_info_session_t& session);
|
||||
void post_kernel_call(inst_pkt_t& aql, const hsa::queue_info_session& session);
|
||||
|
||||
std::unordered_map<hsa_agent_t, std::unique_ptr<ThreadTracerQueue>> agents;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user