msptiActivityApi

msptiActivityApi is the struct of the activity record type MSPTI_ACTIVITY_KIND_API. The definition is as follows:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
typedef struct PACKED_ALIGNMENT {
	msptiActivityKind kind;   // Activity record type MSPTI_ACTIVITY_KIND_API.
	uint64_t start;   // Start timestamp of API execution, in ns. If both the start and end timestamps are 0, the API timestamp information cannot be sampled.
	uint64_t end;   // End timestamp of API execution, in ns. If both the start and end timestamps are 0, the API timestamp information cannot be sampled.
	struct {
		uint32_t processId;   // Process ID of the API running device.
		uint32_t threadId;   // Thread ID of the API running stream.
	} pt;
	uint64_t correlationId;   // API association ID. Each API execution is assigned a unique association ID, which is the same as the association ID of the driver that starts the API or the API activity record during running.
	const char* name;   // API name. The name must be the same in the entire activity record. You are advised not to change the name.
} msptiActivityApi;