Metrics Append Streamer Marker Multi-Device Support

Added multi-device support for zetCommandListAppendMetricStreamerMarker

Related-To: LOCI-2492

Signed-off-by: Joshua Santosh Ranjan <joshua.santosh.ranjan@intel.com>
This commit is contained in:
Joshua Santosh Ranjan
2021-09-07 17:13:53 +00:00
committed by Compute-Runtime-Automation
parent f0070df35a
commit a7f526c980
4 changed files with 132 additions and 5 deletions

View File

@@ -769,7 +769,13 @@ ze_result_t MetricQuery::appendStreamerMarker(CommandList &commandList,
zet_metric_streamer_handle_t hMetricStreamer,
uint32_t value) {
auto &metricContext = commandList.device->getMetricContext();
DeviceImp *pDeviceImp = static_cast<DeviceImp *>(commandList.device);
if (pDeviceImp->isMultiDeviceCapable()) {
// Use one of the sub-device contexts to append to command list.
pDeviceImp = static_cast<DeviceImp *>(pDeviceImp->subDevices[0]);
}
auto &metricContext = pDeviceImp->getMetricContext();
auto &metricsLibrary = metricContext.getMetricsLibrary();
const uint32_t streamerMarkerHighBitsShift = 25;