mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-29 09:03:14 +08:00
fix: add missing command buffer header translation for WSL in WDDM2.3 case
Related-To: NEO-12648 Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
c53393152a
commit
658a0667d4
@@ -156,8 +156,18 @@ bool WddmInterface23::submit(uint64_t commandBuffer, size_t size, void *commandH
|
||||
submitCommand.CommandBuffer = commandBuffer;
|
||||
submitCommand.CommandLength = static_cast<UINT>(size);
|
||||
|
||||
submitCommand.pPrivateDriverData = commandHeader;
|
||||
submitCommand.PrivateDriverDataSize = sizeof(COMMAND_BUFFER_HEADER);
|
||||
COMMAND_BUFFER_HEADER *pHeader = reinterpret_cast<COMMAND_BUFFER_HEADER *>(commandHeader);
|
||||
UmKmDataTempStorage<COMMAND_BUFFER_HEADER> internalRepresentation;
|
||||
if (wddm.getHwDeviceId()->getUmKmDataTranslator()->enabled()) {
|
||||
internalRepresentation.resize(wddm.getHwDeviceId()->getUmKmDataTranslator()->getSizeForCommandBufferHeaderDataInternalRepresentation());
|
||||
bool translated = wddm.getHwDeviceId()->getUmKmDataTranslator()->translateCommandBufferHeaderDataToInternalRepresentation(internalRepresentation.data(), internalRepresentation.size(), *pHeader);
|
||||
UNRECOVERABLE_IF(false == translated);
|
||||
submitCommand.pPrivateDriverData = internalRepresentation.data();
|
||||
submitCommand.PrivateDriverDataSize = static_cast<uint32_t>(internalRepresentation.size());
|
||||
} else {
|
||||
submitCommand.pPrivateDriverData = pHeader;
|
||||
submitCommand.PrivateDriverDataSize = sizeof(COMMAND_BUFFER_HEADER);
|
||||
}
|
||||
|
||||
if (!debugManager.flags.UseCommandBufferHeaderSizeForWddmQueueSubmission.get()) {
|
||||
submitCommand.PrivateDriverDataSize = MemoryConstants::pageSize;
|
||||
|
||||
Reference in New Issue
Block a user