SWDEV-351980 - Move activity_ to the ProfilingInfo
The activity_ is only instantiated if profiling is enabled. Remove the HIP private global record ID. Instead, use the correlation ID stored in the hip_api_data_t by the profiler while the last HIP function is in scope. For NDRange and Copy commands, store the kernel name and byte size (respectively) in the record. General cleanups to improve the code's readability. Change-Id: I01907484b0d9611eb9440c3a7c4865479dc42289
This commit is contained in:
committed by
Maneesh Gupta
parent
5f77772e6e
commit
4fbae91468
@@ -42,7 +42,7 @@ typedef enum {
|
||||
ACTIVITY_EXT_OP_EXTERN_ID = 1
|
||||
} activity_ext_op_t;
|
||||
|
||||
// API calback type
|
||||
// API callback type
|
||||
typedef void (*activity_rtapi_callback_t)(uint32_t domain, uint32_t cid, const void* data, void* arg);
|
||||
typedef uint32_t activity_kind_t;
|
||||
typedef uint32_t activity_op_t;
|
||||
@@ -78,13 +78,15 @@ struct activity_record_t {
|
||||
activity_correlation_id_t external_id; // external correlatino id
|
||||
};
|
||||
};
|
||||
union {
|
||||
size_t bytes; // data size bytes
|
||||
const char* kernel_name;
|
||||
};
|
||||
};
|
||||
|
||||
// Activity sync calback type
|
||||
typedef void* (*activity_sync_callback_t)(uint32_t cid, activity_record_t* record, const void* data, void* arg);
|
||||
typedef void (*activity_sync_callback_t)(uint32_t cid, activity_record_t* record, const void* data, void* arg);
|
||||
// Activity async calback type
|
||||
typedef void (*activity_id_callback_t)(activity_correlation_id_t id);
|
||||
typedef void (*activity_async_callback_t)(uint32_t op, void* record, void* arg);
|
||||
typedef void (*activity_async_callback_t)(uint32_t op, activity_record_t* record, void* arg);
|
||||
|
||||
#endif // INC_EXT_PROF_PROTOCOL_H_
|
||||
|
||||
Reference in New Issue
Block a user