mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-19 06:24:51 +08:00
refactor: add BlitSyncPropertiesExt to BlitSyncProperties
Added BlitSyncPropertiesExt to provide additional information for different platform and/or blitter commands. Signed-off-by: Aravind Gopalakrishnan <aravind.gopalakrishnan@intel.com> Signed-off-by: Young Jin Yoon <young.jin.yoon@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
3438a14fc4
commit
b5a259aded
@@ -17,3 +17,4 @@ list(APPEND DG2_AND_LATER_CORE_TYPES ${PVC_AND_LATER_CORE_TYPES} "XE_HPG_CORE")
|
||||
list(APPEND MTL_AND_LATER_CORE_TYPES ${DG2_AND_LATER_CORE_TYPES})
|
||||
list(APPEND XEHP_AND_LATER_CORE_TYPES ${MTL_AND_LATER_CORE_TYPES})
|
||||
list(APPEND XE_HPC_AND_BEFORE_CORE_TYPES "GEN12LP" "XE_HPG_CORE" "XE_HPC_CORE")
|
||||
list(APPEND XE3_AND_BEFORE_CORE_TYPES "GEN12LP" "XE_HPG_CORE" "XE_HPC_CORE" "XE2_HPG_CORE" "XE3_CORE")
|
||||
|
||||
@@ -31,6 +31,15 @@ foreach(CORE_TYPE ${XE_HPC_AND_BEFORE_CORE_TYPES})
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
foreach(CORE_TYPE ${XE3_AND_BEFORE_CORE_TYPES})
|
||||
if(TESTS_${CORE_TYPE})
|
||||
set(TESTS_XE3_AND_BEFORE 1)
|
||||
endif()
|
||||
if(SUPPORT_${CORE_TYPE})
|
||||
set(SUPPORT_XE3_AND_BEFORE 1)
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
foreach(CORE_TYPE ${XEHP_AND_LATER_CORE_TYPES})
|
||||
if(TESTS_${CORE_TYPE})
|
||||
set(TESTS_XEHP_AND_LATER 1)
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "shared/source/command_stream/transfer_direction.h"
|
||||
#include "shared/source/helpers/blit_properties.h"
|
||||
#include "shared/source/helpers/hw_mapper.h"
|
||||
#include "shared/source/helpers/pipe_control_args.h"
|
||||
#include "shared/source/helpers/vec.h"
|
||||
@@ -239,7 +240,8 @@ struct CommandListCoreFamily : public CommandListImp {
|
||||
uint64_t dstOffset, uintptr_t srcPtr,
|
||||
NEO::GraphicsAllocation *srcPtrAlloc,
|
||||
uint64_t srcOffset,
|
||||
uint64_t size);
|
||||
uint64_t size,
|
||||
Event *signalEvent);
|
||||
|
||||
MOCKABLE_VIRTUAL ze_result_t appendMemoryCopyBlitRegion(AlignedAllocationData *srcAllocationData,
|
||||
AlignedAllocationData *dstAllocationData,
|
||||
@@ -335,6 +337,8 @@ struct CommandListCoreFamily : public CommandListImp {
|
||||
void addFlushRequiredCommand(bool flushOperationRequired, Event *signalEvent, bool copyOperation, bool flushL3InPipeControl);
|
||||
void handlePostSubmissionState();
|
||||
|
||||
MOCKABLE_VIRTUAL void setAdditionalBlitProperties(NEO::BlitProperties &blitProperties, Event *signalEvent);
|
||||
|
||||
void setupFillKernelArguments(size_t baseOffset,
|
||||
size_t patternSize,
|
||||
size_t dstSize,
|
||||
@@ -367,6 +371,13 @@ struct CommandListCoreFamily : public CommandListImp {
|
||||
}
|
||||
return this->containsStatelessUncachedResource;
|
||||
}
|
||||
|
||||
bool isUsingSystemAllocation(const NEO::AllocationType &allocType) const {
|
||||
return ((allocType == NEO::AllocationType::bufferHostMemory) ||
|
||||
(allocType == NEO::AllocationType::svmCpu) ||
|
||||
(allocType == NEO::AllocationType::externalHostPtr));
|
||||
}
|
||||
|
||||
void postInitComputeSetup();
|
||||
NEO::PreemptionMode obtainKernelPreemptionMode(Kernel *kernel);
|
||||
virtual bool isRelaxedOrderingDispatchAllowed(uint32_t numWaitEvents, bool copyOffload) { return false; }
|
||||
@@ -407,6 +418,7 @@ struct CommandListCoreFamily : public CommandListImp {
|
||||
bool allowCbWaitEventsNoopDispatch = false;
|
||||
bool copyOperationFenceSupported = false;
|
||||
bool implicitSynchronizedDispatchForCooperativeKernelsAllowed = false;
|
||||
bool useAdditionalBlitProperties = false;
|
||||
};
|
||||
|
||||
template <PRODUCT_FAMILY gfxProductFamily>
|
||||
|
||||
@@ -264,6 +264,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::initialize(Device *device, NEO
|
||||
this->maxLocalSubRegionSize = productHelper.getMaxLocalSubRegionSize(hwInfo);
|
||||
this->l3FlushAfterPostSyncRequired = productHelper.isL3FlushAfterPostSyncRequired(heaplessModeEnabled);
|
||||
this->compactL3FlushEventPacket = L0GfxCoreHelper::useCompactL3FlushEventPacket(hwInfo, this->l3FlushAfterPostSyncRequired);
|
||||
this->useAdditionalBlitProperties = productHelper.useAdditionalBlitProperties();
|
||||
|
||||
if (NEO::debugManager.flags.OverrideThreadArbitrationPolicy.get() != -1) {
|
||||
this->defaultPipelinedThreadArbitrationPolicy = NEO::debugManager.flags.OverrideThreadArbitrationPolicy.get();
|
||||
@@ -1413,10 +1414,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendMemoryCopyKernelWithGA(v
|
||||
|
||||
auto dstAllocationType = dstPtrAlloc->getAllocationType();
|
||||
launchParams.isBuiltInKernel = true;
|
||||
launchParams.isDestinationAllocationInSystemMemory =
|
||||
(dstAllocationType == NEO::AllocationType::bufferHostMemory) ||
|
||||
(dstAllocationType == NEO::AllocationType::svmCpu) ||
|
||||
(dstAllocationType == NEO::AllocationType::externalHostPtr);
|
||||
launchParams.isDestinationAllocationInSystemMemory = this->isUsingSystemAllocation(dstAllocationType);
|
||||
|
||||
if constexpr (checkIfAllocationImportedRequired()) {
|
||||
launchParams.isDestinationAllocationImported = this->isAllocationImported(dstPtrAlloc, device->getDriverHandle()->getSvmAllocsManager());
|
||||
@@ -1430,17 +1428,21 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendMemoryCopyBlit(uintptr_t
|
||||
uint64_t dstOffset, uintptr_t srcPtr,
|
||||
NEO::GraphicsAllocation *srcPtrAlloc,
|
||||
uint64_t srcOffset,
|
||||
uint64_t size) {
|
||||
uint64_t size,
|
||||
Event *signalEvent) {
|
||||
dstOffset += ptrDiff<uintptr_t>(dstPtr, dstPtrAlloc->getGpuAddress());
|
||||
srcOffset += ptrDiff<uintptr_t>(srcPtr, srcPtrAlloc->getGpuAddress());
|
||||
|
||||
auto clearColorAllocation = device->getNEODevice()->getDefaultEngine().commandStreamReceiver->getClearColorAllocation();
|
||||
|
||||
auto blitProperties = NEO::BlitProperties::constructPropertiesForCopy(dstPtrAlloc, srcPtrAlloc, {dstOffset, 0, 0}, {srcOffset, 0, 0}, {size, 0, 0}, 0, 0, 0, 0, clearColorAllocation);
|
||||
commandContainer.addToResidencyContainer(dstPtrAlloc);
|
||||
commandContainer.addToResidencyContainer(srcPtrAlloc);
|
||||
commandContainer.addToResidencyContainer(clearColorAllocation);
|
||||
|
||||
if (useAdditionalBlitProperties) {
|
||||
setAdditionalBlitProperties(blitProperties, signalEvent);
|
||||
}
|
||||
|
||||
NEO::BlitPropertiesContainer blitPropertiesContainer{blitProperties};
|
||||
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitCommandsForBufferPerRow(blitProperties, *commandContainer.getCommandStream(), *this->dummyBlitWa.rootDeviceEnvironment);
|
||||
@@ -1559,7 +1561,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendPageFaultCopy(NEO::Graph
|
||||
if (isCopyOnly(false)) {
|
||||
return appendMemoryCopyBlit(dstAddress, dstAllocation, 0u,
|
||||
srcAddress, srcAllocation, 0u,
|
||||
size);
|
||||
size, nullptr);
|
||||
} else {
|
||||
CmdListKernelLaunchParams launchParams = {};
|
||||
launchParams.isKernelSplitOperation = rightSize > 0;
|
||||
@@ -1712,7 +1714,9 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendMemoryCopy(void *dstptr,
|
||||
|
||||
launchParams.pipeControlSignalling = (signalEvent && singlePipeControlPacket) || getDcFlushRequired(dstAllocationStruct.needsFlush);
|
||||
|
||||
appendEventForProfilingAllWalkers(signalEvent, nullptr, nullptr, true, singlePipeControlPacket, false, isCopyOnlyEnabled);
|
||||
if (!useAdditionalBlitProperties || !isCopyOnlyEnabled) {
|
||||
appendEventForProfilingAllWalkers(signalEvent, nullptr, nullptr, true, singlePipeControlPacket, false, isCopyOnlyEnabled);
|
||||
}
|
||||
|
||||
if (isCopyOnlyEnabled) {
|
||||
if (NEO::debugManager.flags.FlushTlbBeforeCopy.get() == 1) {
|
||||
@@ -1723,7 +1727,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendMemoryCopy(void *dstptr,
|
||||
ret = appendMemoryCopyBlit(dstAllocationStruct.alignedAllocationPtr,
|
||||
dstAllocationStruct.alloc, dstAllocationStruct.offset,
|
||||
srcAllocationStruct.alignedAllocationPtr,
|
||||
srcAllocationStruct.alloc, srcAllocationStruct.offset, size);
|
||||
srcAllocationStruct.alloc, srcAllocationStruct.offset, size, signalEvent);
|
||||
} else {
|
||||
if (NEO::debugManager.flags.FlushTlbBeforeCopy.get() == 1) {
|
||||
NEO::PipeControlArgs args;
|
||||
@@ -1784,7 +1788,9 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendMemoryCopy(void *dstptr,
|
||||
|
||||
appendCopyOperationFence(signalEvent, srcAllocationStruct.alloc, dstAllocationStruct.alloc, isCopyOnlyEnabled);
|
||||
|
||||
appendEventForProfilingAllWalkers(signalEvent, nullptr, nullptr, false, singlePipeControlPacket, false, isCopyOnlyEnabled);
|
||||
if (!useAdditionalBlitProperties || !isCopyOnlyEnabled) {
|
||||
appendEventForProfilingAllWalkers(signalEvent, nullptr, nullptr, false, singlePipeControlPacket, false, isCopyOnlyEnabled);
|
||||
}
|
||||
|
||||
bool l3flushInPipeControl = !l3FlushAfterPostSyncRequired || isSplitOperation;
|
||||
addFlushRequiredCommand(dstAllocationStruct.needsFlush, signalEvent, isCopyOnlyEnabled, l3flushInPipeControl);
|
||||
@@ -2475,7 +2481,6 @@ void CommandListCoreFamily<gfxCoreFamily>::appendEventForProfilingCopyCommand(Ev
|
||||
return;
|
||||
}
|
||||
commandContainer.addToResidencyContainer(event->getAllocation(this->device));
|
||||
|
||||
if (beforeWalker) {
|
||||
event->resetKernelCountAndPacketUsedCount();
|
||||
} else {
|
||||
|
||||
@@ -14,4 +14,8 @@ constexpr bool CommandListCoreFamily<gfxCoreFamily>::checkIfAllocationImportedRe
|
||||
return false;
|
||||
}
|
||||
|
||||
template <GFXCORE_FAMILY gfxCoreFamily>
|
||||
void CommandListCoreFamily<gfxCoreFamily>::setAdditionalBlitProperties(NEO::BlitProperties &blitProperties, Event *signalEvent) {
|
||||
}
|
||||
|
||||
} // namespace L0
|
||||
|
||||
@@ -812,7 +812,7 @@ ze_result_t CommandListCoreFamilyImmediate<gfxCoreFamily>::appendPageFaultCopy(N
|
||||
ret = static_cast<DeviceImp *>(this->device)->bcsSplit.appendSplitCall<gfxCoreFamily, uintptr_t, uintptr_t>(this, dstAddress, srcAddress, size, nullptr, 0u, nullptr, false, relaxedOrdering, direction, [&](uintptr_t dstAddressParam, uintptr_t srcAddressParam, size_t sizeParam, ze_event_handle_t hSignalEventParam) {
|
||||
this->appendMemoryCopyBlit(dstAddressParam, dstAllocation, 0u,
|
||||
srcAddressParam, srcAllocation, 0u,
|
||||
sizeParam);
|
||||
sizeParam, nullptr);
|
||||
return CommandListCoreFamily<gfxCoreFamily>::appendSignalEvent(hSignalEventParam, false);
|
||||
});
|
||||
} else {
|
||||
|
||||
@@ -207,9 +207,10 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendLaunchKernelWithParams(K
|
||||
.inOrderIncrementValue = 0,
|
||||
.device = neoDevice,
|
||||
.inOrderExecInfo = nullptr,
|
||||
.isCounterBasedEvent = false,
|
||||
.isTimestampEvent = false,
|
||||
.isHostScopeSignalEvent = false,
|
||||
.isKernelUsingSystemAllocation = false,
|
||||
.isUsingSystemAllocation = false,
|
||||
.dcFlushEnable = this->dcFlushSupport,
|
||||
.interruptEvent = false,
|
||||
.isFlushL3ForExternalAllocationRequired = false,
|
||||
|
||||
@@ -319,6 +319,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendLaunchKernelWithParams(K
|
||||
|
||||
bool inOrderExecSignalRequired = false;
|
||||
bool inOrderNonWalkerSignalling = false;
|
||||
bool isCounterBasedEvent = false;
|
||||
|
||||
uint64_t inOrderCounterValue = 0;
|
||||
uint64_t inOrderIncrementValue = 0;
|
||||
@@ -348,6 +349,7 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendLaunchKernelWithParams(K
|
||||
inOrderCounterValue = this->inOrderExecInfo->getCounterValue() + getInOrderIncrementValue();
|
||||
inOrderExecInfo = this->inOrderExecInfo.get();
|
||||
if (eventForInOrderExec && eventForInOrderExec->isCounterBased()) {
|
||||
isCounterBasedEvent = true;
|
||||
if (eventForInOrderExec->getInOrderIncrementValue() > 0) {
|
||||
inOrderIncrementGpuAddress = eventForInOrderExec->getInOrderExecInfo()->getBaseDeviceAddress();
|
||||
inOrderIncrementValue = eventForInOrderExec->getInOrderIncrementValue();
|
||||
@@ -382,9 +384,10 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendLaunchKernelWithParams(K
|
||||
.inOrderIncrementValue = inOrderIncrementValue,
|
||||
.device = neoDevice,
|
||||
.inOrderExecInfo = inOrderExecInfo,
|
||||
.isCounterBasedEvent = isCounterBasedEvent,
|
||||
.isTimestampEvent = isTimestampEvent,
|
||||
.isHostScopeSignalEvent = isHostSignalScopeEvent,
|
||||
.isKernelUsingSystemAllocation = isKernelUsingSystemAllocation,
|
||||
.isUsingSystemAllocation = isKernelUsingSystemAllocation,
|
||||
.dcFlushEnable = this->dcFlushSupport,
|
||||
.interruptEvent = interruptEvent,
|
||||
.isFlushL3ForExternalAllocationRequired = isFlushL3AfterPostSync && isKernelUsingExternalAllocation,
|
||||
|
||||
@@ -114,6 +114,7 @@ struct WhiteBox<::L0::CommandListCoreFamily<gfxCoreFamily>>
|
||||
using BaseClass::requiresDcFlushForDcMitigation;
|
||||
using BaseClass::requiresQueueUncachedMocs;
|
||||
using BaseClass::scratchAddressPatchingEnabled;
|
||||
using BaseClass::setAdditionalBlitProperties;
|
||||
using BaseClass::setupTimestampEventForMultiTile;
|
||||
using BaseClass::signalAllEventPackets;
|
||||
using BaseClass::stateBaseAddressTracking;
|
||||
@@ -628,6 +629,7 @@ class MockCommandListCoreFamily : public CommandListCoreFamily<gfxCoreFamily> {
|
||||
using BaseClass::encodeMiFlush;
|
||||
using BaseClass::getDeviceCounterAllocForResidency;
|
||||
using BaseClass::ownedPrivateAllocations;
|
||||
using BaseClass::setAdditionalBlitProperties;
|
||||
using BaseClass::taskCountUpdateFenceRequired;
|
||||
|
||||
ze_result_t executeMemAdvise(ze_device_handle_t hDevice,
|
||||
@@ -654,7 +656,7 @@ class MockCommandListCoreFamily : public CommandListCoreFamily<gfxCoreFamily> {
|
||||
uint64_t dstOffset, uintptr_t srcPtr,
|
||||
NEO::GraphicsAllocation *srcPtrAlloc,
|
||||
uint64_t srcOffset,
|
||||
uint64_t size));
|
||||
uint64_t size, Event *signalEvent));
|
||||
|
||||
ADDMETHOD_VOIDRETURN(allocateOrReuseKernelPrivateMemory,
|
||||
false,
|
||||
|
||||
@@ -82,7 +82,7 @@ class MockCommandListHw : public WhiteBox<::L0::CommandListCoreFamily<gfxCoreFam
|
||||
uint64_t dstOffset, uintptr_t srcPtr,
|
||||
NEO::GraphicsAllocation *srcPtrAlloc,
|
||||
uint64_t srcOffset,
|
||||
uint64_t size) override {
|
||||
uint64_t size, Event *signalEvent) override {
|
||||
appendMemoryCopyBlitCalledTimes++;
|
||||
if (failOnFirstCopy && appendMemoryCopyBlitCalledTimes == 1) {
|
||||
return ZE_RESULT_ERROR_UNKNOWN;
|
||||
@@ -108,6 +108,7 @@ class MockCommandListHw : public WhiteBox<::L0::CommandListCoreFamily<gfxCoreFam
|
||||
return ZE_RESULT_SUCCESS;
|
||||
}
|
||||
|
||||
void setAdditionalBlitProperties(NEO::BlitProperties &blitProperties, Event *signalEvent) override {}
|
||||
ze_result_t appendMemoryCopyKernel2d(AlignedAllocationData *dstAlignedAllocation, AlignedAllocationData *srcAlignedAllocation,
|
||||
Builtin builtin, const ze_copy_region_t *dstRegion,
|
||||
uint32_t dstPitch, size_t dstOffset,
|
||||
|
||||
@@ -683,6 +683,9 @@ HWTEST2_F(AppendMemoryCopyTests, givenCommandListAndHostPointersWhenMemoryCopyCa
|
||||
|
||||
HWTEST2_F(AppendMemoryCopyTests, givenCopyCommandListWhenTimestampPassedToMemoryCopyThenAppendProfilingCalledOnceBeforeAndAfterCommand, MatchAny) {
|
||||
|
||||
if (device->getProductHelper().useAdditionalBlitProperties()) {
|
||||
GTEST_SKIP();
|
||||
}
|
||||
using MI_STORE_REGISTER_MEM = typename FamilyType::MI_STORE_REGISTER_MEM;
|
||||
using MI_FLUSH_DW = typename FamilyType::MI_FLUSH_DW;
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ class MockCommandListForMemFill : public WhiteBox<::L0::CommandListCoreFamily<gf
|
||||
uint64_t dstOffset, uintptr_t srcPtr,
|
||||
NEO::GraphicsAllocation *srcPtrAlloc,
|
||||
uint64_t srcOffset,
|
||||
uint64_t size) override {
|
||||
uint64_t size, Event *signalEvent) override {
|
||||
appendMemoryCopyBlitCalledTimes++;
|
||||
return ZE_RESULT_SUCCESS;
|
||||
}
|
||||
@@ -213,7 +213,7 @@ HWTEST2_F(AppendMemoryCopyTests, givenCopyOnlyCommandListThenDcFlushIsNotAddedAf
|
||||
NEO::MockGraphicsAllocation mockAllocationDst(0, 1u /*num gmms*/, NEO::AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(dstPtr), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
commandList->appendMemoryCopyBlit(ptrOffset(dstPtr, dstOffset), &mockAllocationDst, 0, ptrOffset(srcPtr, srcOffset), &mockAllocationSrc, 0, copySize);
|
||||
commandList->appendMemoryCopyBlit(ptrOffset(dstPtr, dstOffset), &mockAllocationDst, 0, ptrOffset(srcPtr, srcOffset), &mockAllocationSrc, 0, copySize, nullptr);
|
||||
|
||||
auto &commandContainer = commandList->getCmdContainer();
|
||||
GenCmdList genCmdList;
|
||||
@@ -429,5 +429,72 @@ HWTEST2_F(AppendMemoryCopyTests, givenCopyCommandListWhenNotTiled1DArrayImagePas
|
||||
EXPECT_EQ(cmd->getSourceSurfaceHeight(), arrayLevels);
|
||||
}
|
||||
|
||||
template <GFXCORE_FAMILY gfxCoreFamily>
|
||||
class MockCommandListForAdditionalBlitProperties : public WhiteBox<::L0::CommandListCoreFamily<gfxCoreFamily>> {
|
||||
public:
|
||||
using BaseClass = WhiteBox<::L0::CommandListCoreFamily<gfxCoreFamily>>;
|
||||
using BaseClass::setAdditionalBlitProperties;
|
||||
using BaseClass::useAdditionalBlitProperties;
|
||||
};
|
||||
|
||||
HWTEST_F(AppendMemoryCopyTests, givenBlitPropertiesWhenCallingSetAdditionalBlitPropertiesThenSyncPropertiesExtRemainsUnchanged) {
|
||||
NEO::BlitProperties blitProperties{}, blitProperties2{}, blitPropertiesExpected{};
|
||||
EncodePostSyncArgs &postSyncArgs = blitProperties.blitSyncProperties.postSyncArgs;
|
||||
EncodePostSyncArgs &postSyncArgs2 = blitProperties2.blitSyncProperties.postSyncArgs;
|
||||
EncodePostSyncArgs &postSyncArgsExpected = blitPropertiesExpected.blitSyncProperties.postSyncArgs;
|
||||
|
||||
auto commandList = std::make_unique<MockCommandListForAdditionalBlitProperties<FamilyType::gfxCoreFamily>>();
|
||||
EXPECT_FALSE(commandList->useAdditionalBlitProperties);
|
||||
commandList->setAdditionalBlitProperties(blitProperties, nullptr);
|
||||
EXPECT_EQ(postSyncArgs.isTimestampEvent, postSyncArgsExpected.isTimestampEvent);
|
||||
EXPECT_EQ(postSyncArgs.postSyncImmValue, postSyncArgsExpected.postSyncImmValue);
|
||||
EXPECT_EQ(postSyncArgs.interruptEvent, postSyncArgsExpected.interruptEvent);
|
||||
EXPECT_EQ(postSyncArgs.eventAddress, postSyncArgsExpected.eventAddress);
|
||||
|
||||
commandList->useAdditionalBlitProperties = true;
|
||||
commandList->setAdditionalBlitProperties(blitProperties2, nullptr);
|
||||
EXPECT_EQ(postSyncArgs2.isTimestampEvent, postSyncArgsExpected.isTimestampEvent);
|
||||
EXPECT_EQ(postSyncArgs2.postSyncImmValue, postSyncArgsExpected.postSyncImmValue);
|
||||
EXPECT_EQ(postSyncArgs2.interruptEvent, postSyncArgsExpected.interruptEvent);
|
||||
EXPECT_EQ(postSyncArgs2.eventAddress, postSyncArgsExpected.eventAddress);
|
||||
EXPECT_EQ(nullptr, postSyncArgs2.inOrderExecInfo);
|
||||
}
|
||||
|
||||
template <GFXCORE_FAMILY gfxCoreFamily>
|
||||
class MockCommandListForAdditionalBlitProperties2 : public WhiteBox<::L0::CommandListCoreFamily<gfxCoreFamily>> {
|
||||
public:
|
||||
using BaseClass = WhiteBox<::L0::CommandListCoreFamily<gfxCoreFamily>>;
|
||||
using BaseClass::useAdditionalBlitProperties;
|
||||
void setAdditionalBlitProperties(NEO::BlitProperties &blitProperties, Event *signalEvent) override {
|
||||
additionalBlitPropertiesCalled++;
|
||||
BaseClass::setAdditionalBlitProperties(blitProperties, signalEvent);
|
||||
}
|
||||
uint32_t additionalBlitPropertiesCalled = 0;
|
||||
};
|
||||
|
||||
HWTEST_F(AppendMemoryCopyTests, givenCopyOnlyCommandListWithUseAdditionalBlitPropertiesWhenCallingAppendMemoryCopyBlitThenAdditionalBlitPropertiesCalled) {
|
||||
auto commandList = std::make_unique<MockCommandListForAdditionalBlitProperties2<FamilyType::gfxCoreFamily>>();
|
||||
commandList->initialize(device, NEO::EngineGroupType::copy, 0u);
|
||||
uintptr_t srcPtr = 0x5001;
|
||||
uintptr_t dstPtr = 0x7001;
|
||||
uint64_t srcOffset = 0x101;
|
||||
uint64_t dstOffset = 0x201;
|
||||
uint64_t copySize = 0x301;
|
||||
NEO::MockGraphicsAllocation mockAllocationSrc(0, 1u /*num gmms*/, NEO::AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(srcPtr), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
NEO::MockGraphicsAllocation mockAllocationDst(0, 1u /*num gmms*/, NEO::AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(dstPtr), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
commandList->useAdditionalBlitProperties = false;
|
||||
EXPECT_EQ(0u, commandList->additionalBlitPropertiesCalled);
|
||||
commandList->appendMemoryCopyBlit(ptrOffset(dstPtr, dstOffset), &mockAllocationDst, 0, ptrOffset(srcPtr, srcOffset), &mockAllocationSrc, 0, copySize, nullptr);
|
||||
EXPECT_EQ(0u, commandList->additionalBlitPropertiesCalled);
|
||||
|
||||
commandList->useAdditionalBlitProperties = true;
|
||||
commandList->appendMemoryCopyBlit(ptrOffset(dstPtr, dstOffset), &mockAllocationDst, 0, ptrOffset(srcPtr, srcOffset), &mockAllocationSrc, 0, copySize, nullptr);
|
||||
EXPECT_EQ(1u, commandList->additionalBlitPropertiesCalled);
|
||||
}
|
||||
|
||||
} // namespace ult
|
||||
} // namespace L0
|
||||
|
||||
@@ -120,7 +120,7 @@ class MockCommandListExtensionHw : public WhiteBox<::L0::CommandListCoreFamily<g
|
||||
uint64_t dstOffset, uintptr_t srcPtr,
|
||||
NEO::GraphicsAllocation *srcPtrAlloc,
|
||||
uint64_t srcOffset,
|
||||
uint64_t size) override {
|
||||
uint64_t size, Event *signalEvent) override {
|
||||
appendMemoryCopyBlitCalledTimes++;
|
||||
if (failOnFirstCopy && appendMemoryCopyBlitCalledTimes == 1) {
|
||||
return ZE_RESULT_ERROR_UNKNOWN;
|
||||
@@ -128,6 +128,8 @@ class MockCommandListExtensionHw : public WhiteBox<::L0::CommandListCoreFamily<g
|
||||
return ZE_RESULT_SUCCESS;
|
||||
}
|
||||
|
||||
void setAdditionalBlitProperties(NEO::BlitProperties &blitProperties, Event *signalEvent) override {}
|
||||
|
||||
ze_result_t appendMemoryCopyBlitRegion(AlignedAllocationData *srcAllocationData,
|
||||
AlignedAllocationData *dstAllocationData,
|
||||
ze_copy_region_t srcRegion,
|
||||
|
||||
@@ -3436,21 +3436,22 @@ void BcsSplitInOrderCmdListTests::verifySplitCmds(LinearStream &cmdStream, size_
|
||||
ASSERT_NE(cmdList.end(), itor);
|
||||
ASSERT_NE(nullptr, genCmdCast<XY_COPY_BLT *>(*itor));
|
||||
|
||||
auto flushDwItor = find<MI_FLUSH_DW *>(++itor, cmdList.end());
|
||||
ASSERT_NE(cmdList.end(), flushDwItor);
|
||||
|
||||
auto signalSubCopyEvent = genCmdCast<MI_FLUSH_DW *>(*flushDwItor);
|
||||
ASSERT_NE(nullptr, signalSubCopyEvent);
|
||||
|
||||
while (signalSubCopyEvent->getDestinationAddress() != signalSubCopyEventGpuVa) {
|
||||
flushDwItor = find<MI_FLUSH_DW *>(++flushDwItor, cmdList.end());
|
||||
if (!device->getProductHelper().useAdditionalBlitProperties()) {
|
||||
auto flushDwItor = find<MI_FLUSH_DW *>(++itor, cmdList.end());
|
||||
ASSERT_NE(cmdList.end(), flushDwItor);
|
||||
|
||||
signalSubCopyEvent = genCmdCast<MI_FLUSH_DW *>(*flushDwItor);
|
||||
auto signalSubCopyEvent = genCmdCast<MI_FLUSH_DW *>(*flushDwItor);
|
||||
ASSERT_NE(nullptr, signalSubCopyEvent);
|
||||
}
|
||||
|
||||
itor = ++flushDwItor;
|
||||
while (signalSubCopyEvent->getDestinationAddress() != signalSubCopyEventGpuVa) {
|
||||
flushDwItor = find<MI_FLUSH_DW *>(++flushDwItor, cmdList.end());
|
||||
ASSERT_NE(cmdList.end(), flushDwItor);
|
||||
|
||||
signalSubCopyEvent = genCmdCast<MI_FLUSH_DW *>(*flushDwItor);
|
||||
ASSERT_NE(nullptr, signalSubCopyEvent);
|
||||
}
|
||||
itor = ++flushDwItor;
|
||||
}
|
||||
|
||||
auto semaphoreCmds = findAll<MI_SEMAPHORE_WAIT *>(beginItor, itor);
|
||||
EXPECT_EQ(numExpectedSemaphores, semaphoreCmds.size());
|
||||
|
||||
@@ -2259,4 +2259,4 @@ HWTEST_F(BcsTests, given1DNotTiledArrayImageWhenConstructPropertiesThenImageNotT
|
||||
builtinOpParams);
|
||||
EXPECT_EQ(blitProperties.copySize.y, builtinOpParams.size.y);
|
||||
EXPECT_EQ(blitProperties.copySize.z, builtinOpParams.size.z);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -57,16 +57,20 @@ struct EncodePostSyncArgs {
|
||||
uint64_t inOrderIncrementValue = 0;
|
||||
Device *device = nullptr;
|
||||
NEO::InOrderExecInfo *inOrderExecInfo = nullptr;
|
||||
bool isCounterBasedEvent = false;
|
||||
bool isTimestampEvent = false;
|
||||
bool isHostScopeSignalEvent = false;
|
||||
bool isKernelUsingSystemAllocation = false;
|
||||
bool isUsingSystemAllocation = false;
|
||||
bool dcFlushEnable = false;
|
||||
bool interruptEvent = false;
|
||||
bool isFlushL3ForExternalAllocationRequired = false;
|
||||
bool isFlushL3ForHostUsmRequired = false;
|
||||
|
||||
bool requiresSystemMemoryFence() const {
|
||||
return (isHostScopeSignalEvent && isKernelUsingSystemAllocation && this->device->getProductHelper().isGlobalFenceInPostSyncRequired(this->device->getHardwareInfo()));
|
||||
return (isHostScopeSignalEvent && isUsingSystemAllocation && this->device->getProductHelper().isGlobalFenceInPostSyncRequired(this->device->getHardwareInfo()));
|
||||
}
|
||||
bool isValidEvent() const {
|
||||
return (eventAddress != 0) || (isCounterBasedEvent && !isTimestampEvent);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -42,12 +42,19 @@ bool EncodeDispatchKernel<Family>::singleTileExecImplicitScalingRequired(bool co
|
||||
return cooperativeKernel;
|
||||
}
|
||||
|
||||
template <typename Family>
|
||||
template <typename CommandType>
|
||||
inline auto &EncodePostSync<Family>::getPostSync(CommandType &cmd, size_t index) {
|
||||
UNRECOVERABLE_IF(index != 0);
|
||||
return cmd.getPostSync();
|
||||
}
|
||||
|
||||
template <typename Family>
|
||||
template <typename CommandType>
|
||||
void EncodePostSync<Family>::setupPostSyncForInOrderExec(CommandType &cmd, const EncodePostSyncArgs &args) {
|
||||
using POSTSYNC_DATA = decltype(Family::template getPostSyncType<CommandType>());
|
||||
|
||||
auto &postSync = cmd.getPostSync();
|
||||
auto &postSync = getPostSync(cmd, 0);
|
||||
|
||||
uint64_t gpuVa = args.inOrderExecInfo->getBaseDeviceAddress() + args.inOrderExecInfo->getAllocationOffset();
|
||||
UNRECOVERABLE_IF(!(isAligned<immWriteDestinationAddressAlignment>(gpuVa)));
|
||||
|
||||
@@ -372,7 +372,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
|
||||
if (args.postSyncArgs.inOrderExecInfo) {
|
||||
EncodePostSync<Family>::setupPostSyncForInOrderExec(walkerCmd, args.postSyncArgs);
|
||||
} else if (args.postSyncArgs.eventAddress) {
|
||||
} else if (args.postSyncArgs.isValidEvent()) {
|
||||
EncodePostSync<Family>::setupPostSyncForRegularEvent(walkerCmd, args.postSyncArgs);
|
||||
} else {
|
||||
EncodeDispatchKernel<Family>::forceComputeWalkerPostSyncFlushWithWrite(walkerCmd);
|
||||
@@ -487,7 +487,7 @@ template <typename CommandType>
|
||||
void EncodePostSync<Family>::setupPostSyncForRegularEvent(CommandType &cmd, const EncodePostSyncArgs &args) {
|
||||
using POSTSYNC_DATA = decltype(Family::template getPostSyncType<CommandType>());
|
||||
|
||||
auto &postSync = cmd.getPostSync();
|
||||
auto &postSync = getPostSync(cmd, 0);
|
||||
|
||||
auto operationType = POSTSYNC_DATA::OPERATION_WRITE_IMMEDIATE_DATA;
|
||||
uint64_t gpuVa = args.eventAddress;
|
||||
|
||||
@@ -16,6 +16,7 @@ using Family = NEO::Gen12LpFamily;
|
||||
#include "shared/source/gmm_helper/gmm.h"
|
||||
#include "shared/source/helpers/address_patch.h"
|
||||
#include "shared/source/helpers/blit_commands_helper_base.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_from_gen12lp_to_xe3.inl"
|
||||
#include "shared/source/helpers/populate_factory.h"
|
||||
#include "shared/source/helpers/state_base_address_tgllp_and_later.inl"
|
||||
|
||||
@@ -332,6 +333,8 @@ bool BlitCommandsHelper<Family>::preBlitCommandWARequired() {
|
||||
template class CommandStreamReceiverHw<Family>;
|
||||
template struct BlitCommandsHelper<Family>;
|
||||
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_BLOCK_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_BLOCK_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
|
||||
const Family::GPGPU_WALKER Family::cmdInitGpgpuWalker = Family::GPGPU_WALKER::sInit();
|
||||
const Family::INTERFACE_DESCRIPTOR_DATA Family::cmdInitInterfaceDescriptorData = Family::INTERFACE_DESCRIPTOR_DATA::sInit();
|
||||
const Family::MEDIA_INTERFACE_DESCRIPTOR_LOAD Family::cmdInitMediaInterfaceDescriptorLoad = Family::MEDIA_INTERFACE_DESCRIPTOR_LOAD::sInit();
|
||||
|
||||
@@ -234,6 +234,12 @@ if(SUPPORT_XE3_AND_LATER)
|
||||
)
|
||||
endif()
|
||||
|
||||
if(SUPPORT_XE3_AND_BEFORE)
|
||||
list(APPEND NEO_CORE_HELPERS
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/blit_commands_helper_from_gen12lp_to_xe3.inl
|
||||
)
|
||||
endif()
|
||||
|
||||
set(NEO_CORE_HELPERS_GMM_CALLBACKS_WINDOWS
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/windows/gmm_callbacks.cpp
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/windows/gmm_callbacks.h
|
||||
|
||||
@@ -96,5 +96,8 @@ struct BlitCommandsHelper {
|
||||
|
||||
static void encodeWa(LinearStream &cmdStream, const BlitProperties &blitProperties, uint32_t &latestSentBcsWaValue);
|
||||
static size_t getWaCmdsSize(const BlitPropertiesContainer &blitPropertiesContainer);
|
||||
|
||||
template <typename CommandType>
|
||||
static void applyAdditionalBlitProperties(const BlitProperties &blitProperties, CommandType &cmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
};
|
||||
} // namespace NEO
|
||||
|
||||
@@ -209,10 +209,13 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitCommandsForBufferPerRow(const Bl
|
||||
|
||||
appendColorDepth(blitProperties, bltCmd);
|
||||
|
||||
const bool useAdditionalBlitProperties = rootDeviceEnvironment.getHelper<ProductHelper>().useAdditionalBlitProperties();
|
||||
|
||||
for (uint64_t slice = 0; slice < blitProperties.copySize.z; slice++) {
|
||||
for (uint64_t row = 0; row < blitProperties.copySize.y; row++) {
|
||||
uint64_t offset = 0;
|
||||
uint64_t sizeToBlit = blitProperties.copySize.x;
|
||||
bool lastIteration = (slice == blitProperties.copySize.z - 1) && (row == blitProperties.copySize.y - 1);
|
||||
while (sizeToBlit != 0) {
|
||||
if (sizeToBlit > maxWidth) {
|
||||
// dispatch 2D blit: maxBlitWidth x (1 .. maxBlitHeight)
|
||||
@@ -223,6 +226,8 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitCommandsForBufferPerRow(const Bl
|
||||
width = sizeToBlit;
|
||||
height = 1;
|
||||
}
|
||||
auto blitSize = width * height;
|
||||
auto lastCommand = lastIteration && (sizeToBlit - blitSize == 0);
|
||||
|
||||
bltCmd.setDestinationX2CoordinateRight(static_cast<uint32_t>(width));
|
||||
bltCmd.setDestinationY2CoordinateBottom(static_cast<uint32_t>(height));
|
||||
@@ -237,6 +242,9 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitCommandsForBufferPerRow(const Bl
|
||||
|
||||
bltCmd.setDestinationBaseAddress(dstAddr);
|
||||
bltCmd.setSourceBaseAddress(srcAddr);
|
||||
if (useAdditionalBlitProperties && lastCommand) {
|
||||
applyAdditionalBlitProperties(blitProperties, bltCmd, rootDeviceEnvironment, lastCommand);
|
||||
}
|
||||
|
||||
appendBlitCommandsForBuffer(blitProperties, bltCmd, rootDeviceEnvironment);
|
||||
|
||||
@@ -245,7 +253,6 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitCommandsForBufferPerRow(const Bl
|
||||
|
||||
dispatchPostBlitCommand(linearStream, rootDeviceEnvironment);
|
||||
|
||||
auto blitSize = width * height;
|
||||
sizeToBlit -= blitSize;
|
||||
offset += blitSize;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
* Copyright (C) 2025 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/source/helpers/blit_properties.h"
|
||||
|
||||
namespace NEO {
|
||||
|
||||
template <typename GfxFamily>
|
||||
template <typename CommandType>
|
||||
void BlitCommandsHelper<GfxFamily>::applyAdditionalBlitProperties(const BlitProperties &blitProperties,
|
||||
CommandType &cmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last) {
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
@@ -220,4 +220,4 @@ void BlitProperties::transform1DArrayTo2DArrayIfNeeded() {
|
||||
this->copySize.y = 1;
|
||||
}
|
||||
}
|
||||
} // namespace NEO
|
||||
} // namespace NEO
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#include "shared/source/command_container/command_encoder.h"
|
||||
#include "shared/source/command_stream/csr_deps.h"
|
||||
#include "shared/source/gmm_helper/gmm_lib.h"
|
||||
#include "shared/source/helpers/aux_translation.h"
|
||||
@@ -17,6 +18,7 @@
|
||||
|
||||
namespace NEO {
|
||||
struct TimestampPacketDependencies;
|
||||
struct BlitSyncPropertiesExt;
|
||||
class TagNodeBase;
|
||||
class TimestampPacketContainer;
|
||||
class GraphicsAllocation;
|
||||
@@ -31,13 +33,13 @@ enum class BlitSyncMode {
|
||||
};
|
||||
|
||||
struct BlitSyncProperties {
|
||||
EncodePostSyncArgs postSyncArgs{};
|
||||
TagNodeBase *outputTimestampPacket = nullptr;
|
||||
BlitSyncMode syncMode = BlitSyncMode::none;
|
||||
uint64_t deviceGpuWriteAddress = 0;
|
||||
uint64_t hostGpuWriteAddress = 0;
|
||||
uint64_t timestampGpuWriteAddress = 0;
|
||||
uint64_t writeValue = 0;
|
||||
|
||||
bool isTimestampMode() const {
|
||||
return (syncMode == BlitSyncMode::timestamp) || (syncMode == BlitSyncMode::timestampAndImmediate);
|
||||
}
|
||||
@@ -104,4 +106,4 @@ struct BlitProperties {
|
||||
bool isSystemMemoryPoolUsed = false;
|
||||
};
|
||||
|
||||
} // namespace NEO
|
||||
} // namespace NEO
|
||||
|
||||
@@ -271,6 +271,7 @@ class ProductHelper {
|
||||
virtual void setRenderCompressedFlags(HardwareInfo &hwInfo) const = 0;
|
||||
virtual bool isCompressionForbidden(const HardwareInfo &hwInfo) const = 0;
|
||||
virtual bool isExposingSubdevicesAllowed() const = 0;
|
||||
virtual bool useAdditionalBlitProperties() const = 0;
|
||||
|
||||
virtual ~ProductHelper() = default;
|
||||
|
||||
|
||||
@@ -1121,4 +1121,9 @@ bool ProductHelperHw<gfxProduct>::isExposingSubdevicesAllowed() const {
|
||||
return true;
|
||||
}
|
||||
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
bool ProductHelperHw<gfxProduct>::useAdditionalBlitProperties() const {
|
||||
return false;
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
@@ -209,6 +209,7 @@ class ProductHelperHw : public ProductHelper {
|
||||
void setRenderCompressedFlags(HardwareInfo &hwInfo) const override;
|
||||
bool isCompressionForbidden(const HardwareInfo &hwInfo) const override;
|
||||
bool isExposingSubdevicesAllowed() const override;
|
||||
bool useAdditionalBlitProperties() const override;
|
||||
|
||||
~ProductHelperHw() override = default;
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@ using Family = NEO::Xe2HpgCoreFamily;
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_heap_addressing.inl"
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_xehp_and_later.inl"
|
||||
#include "shared/source/gmm_helper/gmm.h"
|
||||
#include "shared/source/helpers/blit_commands_helper_from_gen12lp_to_xe3.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_pvc_and_later.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_xe2_and_later.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_xehp_and_later.inl"
|
||||
@@ -271,6 +272,9 @@ template void BlitCommandsHelper<Family>::appendColorDepth<typename Family::XY_B
|
||||
template void BlitCommandsHelper<Family>::appendColorDepth<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd);
|
||||
template void BlitCommandsHelper<Family>::appendBlitCommandsForBuffer<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_BLOCK_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_BLOCK_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
|
||||
const Family::COMPUTE_WALKER Family::cmdInitGpgpuWalker = Family::COMPUTE_WALKER::sInit();
|
||||
const Family::CFE_STATE Family::cmdInitCfeState = Family::CFE_STATE::sInit();
|
||||
const Family::INTERFACE_DESCRIPTOR_DATA Family::cmdInitInterfaceDescriptorData = Family::INTERFACE_DESCRIPTOR_DATA::sInit();
|
||||
|
||||
@@ -14,6 +14,7 @@ using Family = NEO::Xe3CoreFamily;
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_heap_addressing.inl"
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_xehp_and_later.inl"
|
||||
#include "shared/source/gmm_helper/gmm.h"
|
||||
#include "shared/source/helpers/blit_commands_helper_from_gen12lp_to_xe3.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_pvc_and_later.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_xe2_and_later.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_xehp_and_later.inl"
|
||||
@@ -225,6 +226,9 @@ template void BlitCommandsHelper<Family>::appendColorDepth<typename Family::XY_B
|
||||
template void BlitCommandsHelper<Family>::appendColorDepth<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd);
|
||||
template void BlitCommandsHelper<Family>::appendBlitCommandsForBuffer<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_BLOCK_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_BLOCK_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
|
||||
const Family::COMPUTE_WALKER Family::cmdInitGpgpuWalker = Family::COMPUTE_WALKER::sInit();
|
||||
const Family::CFE_STATE Family::cmdInitCfeState = Family::CFE_STATE::sInit();
|
||||
const Family::INTERFACE_DESCRIPTOR_DATA Family::cmdInitInterfaceDescriptorData = Family::INTERFACE_DESCRIPTOR_DATA::sInit();
|
||||
|
||||
@@ -16,6 +16,7 @@ using Family = NEO::XeHpcCoreFamily;
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_heap_addressing.inl"
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_xehp_and_later.inl"
|
||||
#include "shared/source/gmm_helper/gmm.h"
|
||||
#include "shared/source/helpers/blit_commands_helper_from_gen12lp_to_xe3.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_pvc_and_later.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_xehp_and_later.inl"
|
||||
#include "shared/source/helpers/blit_properties.h"
|
||||
@@ -273,6 +274,8 @@ template class CommandStreamReceiverHw<Family>;
|
||||
template struct BlitCommandsHelper<Family>;
|
||||
template void BlitCommandsHelper<Family>::appendBlitCommandsForBuffer<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
|
||||
const Family::COMPUTE_WALKER Family::cmdInitGpgpuWalker = Family::COMPUTE_WALKER::sInit();
|
||||
const Family::CFE_STATE Family::cmdInitCfeState = Family::CFE_STATE::sInit();
|
||||
const Family::INTERFACE_DESCRIPTOR_DATA Family::cmdInitInterfaceDescriptorData = Family::INTERFACE_DESCRIPTOR_DATA::sInit();
|
||||
|
||||
@@ -14,6 +14,7 @@ using Family = NEO::XeHpgCoreFamily;
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_dg2_and_later.inl"
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_heap_addressing.inl"
|
||||
#include "shared/source/command_stream/command_stream_receiver_hw_xehp_and_later.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_from_gen12lp_to_xe3.inl"
|
||||
#include "shared/source/helpers/blit_commands_helper_xehp_and_later.inl"
|
||||
#include "shared/source/helpers/populate_factory.h"
|
||||
#include "shared/source/helpers/state_base_address_xehp_and_later.inl"
|
||||
@@ -162,6 +163,8 @@ template struct BlitCommandsHelper<Family>;
|
||||
template void BlitCommandsHelper<Family>::appendColorDepth<typename Family::XY_BLOCK_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_BLOCK_COPY_BLT &blitCmd);
|
||||
template void BlitCommandsHelper<Family>::appendBlitCommandsForBuffer<typename Family::XY_BLOCK_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_BLOCK_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
|
||||
template void BlitCommandsHelper<Family>::applyAdditionalBlitProperties<typename Family::XY_BLOCK_COPY_BLT>(const BlitProperties &blitProperties, typename Family::XY_BLOCK_COPY_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment, bool last);
|
||||
|
||||
const Family::COMPUTE_WALKER Family::cmdInitGpgpuWalker = Family::COMPUTE_WALKER::sInit();
|
||||
const Family::CFE_STATE Family::cmdInitCfeState = Family::CFE_STATE::sInit();
|
||||
const Family::INTERFACE_DESCRIPTOR_DATA Family::cmdInitInterfaceDescriptorData = Family::INTERFACE_DESCRIPTOR_DATA::sInit();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2022-2024 Intel Corporation
|
||||
* Copyright (C) 2022-2025 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -27,6 +27,7 @@ struct MockProductHelperHw : NEO::ProductHelperHw<productFamily> {
|
||||
std::vector<uint32_t> getSupportedNumGrfs(const ReleaseHelper *releaseHelper) const override;
|
||||
aub_stream::EngineType getDefaultCopyEngine() const override;
|
||||
bool isBufferPoolAllocatorSupported() const override;
|
||||
bool useAdditionalBlitProperties() const override { return enableAdditionalBlitProperties; }
|
||||
|
||||
bool use128MbEdram = false;
|
||||
bool enableMidThreadPreemption = false;
|
||||
@@ -36,6 +37,7 @@ struct MockProductHelperHw : NEO::ProductHelperHw<productFamily> {
|
||||
bool isCooperativeEngineSupportedValue = true;
|
||||
bool returnedIsUnlockingLockedPtrNecessary = false;
|
||||
bool isBufferPoolAllocatorSupportedValue = true;
|
||||
bool enableAdditionalBlitProperties = false;
|
||||
uint32_t returnedStepping = 0;
|
||||
uint32_t returnedL1CachePolicy = 0;
|
||||
uint32_t returnedL1CachePolicyIfDebugger = 0;
|
||||
@@ -43,4 +45,4 @@ struct MockProductHelperHw : NEO::ProductHelperHw<productFamily> {
|
||||
std::vector<int32_t> threadArbPolicies = {};
|
||||
aub_stream::EngineType mockDefaultCopyEngine = aub_stream::EngineType::ENGINE_BCS;
|
||||
};
|
||||
} // namespace NEO
|
||||
} // namespace NEO
|
||||
|
||||
@@ -30,6 +30,7 @@ using IsBeforeXeHpgCore = IsBeforeGfxCore<IGFX_XE_HPG_CORE>;
|
||||
using IsAtLeastXeHpcCore = IsAtLeastGfxCore<IGFX_XE_HPC_CORE>;
|
||||
using IsAtMostXeHpcCore = IsAtMostGfxCore<IGFX_XE_HPC_CORE>;
|
||||
using IsBeforeXeHpcCore = IsBeforeGfxCore<IGFX_XE_HPC_CORE>;
|
||||
using IsWithinXeHpcCoreAndXe3Core = IsWithinGfxCore<IGFX_XE_HPC_CORE, IGFX_XE3_CORE>;
|
||||
|
||||
using IsAtLeastXe2HpgCore = IsAtLeastGfxCore<IGFX_XE2_HPG_CORE>;
|
||||
using IsAtMostXe2HpgCore = IsAtMostGfxCore<IGFX_XE2_HPG_CORE>;
|
||||
|
||||
@@ -8,10 +8,12 @@
|
||||
#include "shared/source/command_container/cmdcontainer.h"
|
||||
#include "shared/source/command_container/command_encoder.h"
|
||||
#include "shared/source/command_container/encode_surface_state.h"
|
||||
#include "shared/source/helpers/in_order_cmd_helpers.h"
|
||||
#include "shared/test/common/cmd_parse/gen_cmd_parse.h"
|
||||
#include "shared/test/common/fixtures/device_fixture.h"
|
||||
#include "shared/test/common/mocks/mock_device.h"
|
||||
#include "shared/test/common/mocks/mock_graphics_allocation.h"
|
||||
#include "shared/test/common/mocks/mock_timestamp_container.h"
|
||||
#include "shared/test/common/test_macros/hw_test.h"
|
||||
|
||||
using namespace NEO;
|
||||
@@ -220,7 +222,7 @@ HWTEST_F(CommandEncoderTest, givenEncodePostSyncArgsWhenCallingRequiresSystemMem
|
||||
for (bool kernelUsingSystemAllocation : {true, false}) {
|
||||
args.device = pDevice;
|
||||
args.isHostScopeSignalEvent = hostScopeSignalEvent;
|
||||
args.isKernelUsingSystemAllocation = kernelUsingSystemAllocation;
|
||||
args.isUsingSystemAllocation = kernelUsingSystemAllocation;
|
||||
|
||||
if (hostScopeSignalEvent && kernelUsingSystemAllocation && pDevice->getProductHelper().isGlobalFenceInPostSyncRequired(pDevice->getHardwareInfo())) {
|
||||
EXPECT_TRUE(args.requiresSystemMemoryFence());
|
||||
@@ -230,3 +232,21 @@ HWTEST_F(CommandEncoderTest, givenEncodePostSyncArgsWhenCallingRequiresSystemMem
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
HWTEST_F(CommandEncoderTest, givenEncodePostSyncArgsWhenCallingIsRegularEventThenCorrectValuesAreReturned) {
|
||||
EncodePostSyncArgs args{};
|
||||
MockTagAllocator<DeviceAllocNodeType<true>> deviceTagAllocator(0, pDevice->getMemoryManager());
|
||||
auto inOrderExecInfo = InOrderExecInfo::create(deviceTagAllocator.getTag(), deviceTagAllocator.getTag(), *pDevice, 1, false); // setting duplicateStorage = true;
|
||||
for (bool counterBasedEvent : {true, false}) {
|
||||
for (bool timestampEvent : {true, false}) {
|
||||
for (uint64_t eventAddress : {0, 0x1010}) {
|
||||
args.device = pDevice;
|
||||
args.isCounterBasedEvent = counterBasedEvent;
|
||||
args.isTimestampEvent = timestampEvent;
|
||||
args.eventAddress = eventAddress;
|
||||
bool expectedValidEvent = (eventAddress != 0) || (counterBasedEvent && !timestampEvent);
|
||||
EXPECT_EQ(expectedValidEvent, args.isValidEvent());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,9 +54,10 @@ class CommandEncodeStatesFixture : public DeviceFixture {
|
||||
.inOrderIncrementValue = 0,
|
||||
.device = device,
|
||||
.inOrderExecInfo = nullptr,
|
||||
.isCounterBasedEvent = false,
|
||||
.isTimestampEvent = false,
|
||||
.isHostScopeSignalEvent = false,
|
||||
.isKernelUsingSystemAllocation = false,
|
||||
.isUsingSystemAllocation = false,
|
||||
.dcFlushEnable = false,
|
||||
.interruptEvent = false,
|
||||
.isFlushL3ForExternalAllocationRequired = false,
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include "shared/test/common/fixtures/device_fixture.h"
|
||||
#include "shared/test/common/helpers/debug_manager_state_restore.h"
|
||||
#include "shared/test/common/helpers/default_hw_info.h"
|
||||
#include "shared/test/common/helpers/mock_product_helper_hw.h"
|
||||
#include "shared/test/common/mocks/mock_device.h"
|
||||
#include "shared/test/common/mocks/mock_graphics_allocation.h"
|
||||
#include "shared/test/common/mocks/mock_timestamp_container.h"
|
||||
@@ -710,3 +711,79 @@ HWTEST_F(BlitTests, givenPlatformWhenCallingDispatchPreBlitCommandThenNoneMiFlus
|
||||
blitPropertiesContainer2, false, true, false, false, pDevice->getRootDeviceEnvironment());
|
||||
EXPECT_NE(estimatedSizeWithoutNode, estimatedSizeWithNode);
|
||||
}
|
||||
|
||||
HWTEST2_F(BlitTests, givenPlatformWithBlitSyncPropertiesWithAndWithoutTimestampModeWhenCallingDispatchBlitCommandForBufferThenTheResultsAreTheSame, MatchAny) {
|
||||
uint32_t src[] = {1, 2, 3, 4};
|
||||
uint32_t dst[] = {4, 3, 2, 1};
|
||||
uint32_t clear[] = {5, 6, 7, 8};
|
||||
uint64_t srcGpuAddr = 0x12345;
|
||||
uint64_t dstGpuAddr = 0x54321;
|
||||
uint64_t clearGpuAddr = 0x5678;
|
||||
std::unique_ptr<MockGraphicsAllocation> srcAlloc(new MockGraphicsAllocation(src, srcGpuAddr, sizeof(src)));
|
||||
std::unique_ptr<MockGraphicsAllocation> dstAlloc(new MockGraphicsAllocation(dst, dstGpuAddr, sizeof(dst)));
|
||||
std::unique_ptr<GraphicsAllocation> clearColorAllocation(new MockGraphicsAllocation(clear, clearGpuAddr, sizeof(clear)));
|
||||
|
||||
Vec3<size_t> srcOffsets{1, 0, 0};
|
||||
Vec3<size_t> dstOffsets{1, 0, 0};
|
||||
Vec3<size_t> copySize{(BlitterConstants::maxBlitWidth * BlitterConstants::maxBlitHeight) + 1, 2, 2};
|
||||
|
||||
size_t srcRowPitch = 0;
|
||||
size_t srcSlicePitch = 0;
|
||||
|
||||
size_t dstRowPitch = 0;
|
||||
size_t dstSlicePitch = 0;
|
||||
|
||||
auto blitProperties = NEO::BlitProperties::constructPropertiesForCopy(dstAlloc.get(), srcAlloc.get(),
|
||||
dstOffsets, srcOffsets, copySize, srcRowPitch, srcSlicePitch,
|
||||
dstRowPitch, dstSlicePitch, clearColorAllocation.get());
|
||||
|
||||
uint32_t streamBuffer[400] = {};
|
||||
LinearStream stream(streamBuffer, sizeof(streamBuffer));
|
||||
NEO::BlitCommandsHelper<FamilyType>::dispatchBlitCommandsForBufferPerRow(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
|
||||
// change it into timestamp mode
|
||||
blitProperties.blitSyncProperties.syncMode = NEO::BlitSyncMode::timestamp;
|
||||
|
||||
uint32_t streamBuffer2[400] = {};
|
||||
LinearStream stream2(streamBuffer2, sizeof(streamBuffer2));
|
||||
NEO::BlitCommandsHelper<FamilyType>::dispatchBlitCommandsForBufferPerRow(blitProperties, stream2, pDevice->getRootDeviceEnvironmentRef());
|
||||
|
||||
EXPECT_EQ(stream.getUsed(), stream2.getUsed());
|
||||
EXPECT_EQ(0, memcmp(ptrOffset(stream.getCpuBase(), 0), ptrOffset(stream2.getCpuBase(), 0), std::min(stream.getUsed(), stream2.getUsed())));
|
||||
|
||||
// change productHelper to return true
|
||||
pDevice->getRootDeviceEnvironmentRef().productHelper.reset(new MockProductHelperHw<productFamily>);
|
||||
auto *mockProductHelper = static_cast<MockProductHelperHw<productFamily> *>(pDevice->getRootDeviceEnvironmentRef().productHelper.get());
|
||||
mockProductHelper->enableAdditionalBlitProperties = true;
|
||||
|
||||
uint32_t streamBuffer3[400] = {};
|
||||
LinearStream stream3(streamBuffer3, sizeof(streamBuffer2));
|
||||
NEO::BlitCommandsHelper<FamilyType>::dispatchBlitCommandsForBufferPerRow(blitProperties, stream3, pDevice->getRootDeviceEnvironmentRef());
|
||||
|
||||
EXPECT_EQ(stream.getUsed(), stream3.getUsed());
|
||||
EXPECT_EQ(0, memcmp(ptrOffset(stream.getCpuBase(), 0), ptrOffset(stream3.getCpuBase(), 0), std::min(stream.getUsed(), stream3.getUsed())));
|
||||
}
|
||||
|
||||
HWTEST_F(BlitTests, givenBlitPropertieswithImageOperationWhenCallingEstimateBlitCommandSizeThenBlockCopySizeIsReturned) {
|
||||
Vec3<size_t> copySize{BlitterConstants::maxBlitWidth - 1, 1, 1};
|
||||
NEO::CsrDependencies csrDependencies{};
|
||||
|
||||
size_t totalSize = NEO::BlitCommandsHelper<FamilyType>::estimateBlitCommandSize(copySize, csrDependencies, false, false, true, pDevice->getRootDeviceEnvironmentRef(), false, false);
|
||||
|
||||
size_t expectedSize = sizeof(typename FamilyType::XY_BLOCK_COPY_BLT);
|
||||
expectedSize += NEO::BlitCommandsHelper<FamilyType>::estimatePostBlitCommandSize();
|
||||
expectedSize += NEO::BlitCommandsHelper<FamilyType>::estimatePreBlitCommandSize();
|
||||
EXPECT_EQ(expectedSize, totalSize);
|
||||
}
|
||||
|
||||
using IsWithinGen12LPAndXe3Core = IsWithinGfxCore<IGFX_GEN12LP_CORE, IGFX_XE3_CORE>;
|
||||
HWTEST2_F(BlitTests, givenXyCopyBltCommandWhenApplyBlitPropertiesIsCalledThenNothingChanged, IsWithinGen12LPAndXe3Core) {
|
||||
using XY_COPY_BLT = typename FamilyType::XY_COPY_BLT;
|
||||
auto bltCmd = FamilyType::cmdInitXyCopyBlt;
|
||||
auto bltCmdBefore = bltCmd;
|
||||
BlitProperties properties = {};
|
||||
NEO::BlitCommandsHelper<FamilyType>::applyAdditionalBlitProperties(properties, bltCmd, pDevice->getRootDeviceEnvironment(), false);
|
||||
EXPECT_EQ(memcmp(&bltCmd, &bltCmdBefore, sizeof(XY_COPY_BLT)), 0);
|
||||
NEO::BlitCommandsHelper<FamilyType>::applyAdditionalBlitProperties(properties, bltCmd, pDevice->getRootDeviceEnvironment(), true);
|
||||
EXPECT_EQ(memcmp(&bltCmd, &bltCmdBefore, sizeof(XY_COPY_BLT)), 0);
|
||||
}
|
||||
|
||||
@@ -1176,3 +1176,7 @@ HWTEST_F(ProductHelperTest, givenProductHelperWhenIsExposingSubdevicesAllowedThe
|
||||
HWTEST_F(ProductHelperTest, givenProductHelperWhenGettingIsPrimaryContextsAggregationSupportedThenReturnCorrectValue) {
|
||||
EXPECT_FALSE(productHelper->isPrimaryContextsAggregationSupported());
|
||||
}
|
||||
|
||||
HWTEST_F(ProductHelperTest, givenProductHelperWhenCallingUseAdditionalBlitPropertiesThenFalseReturned) {
|
||||
EXPECT_FALSE(productHelper->useAdditionalBlitProperties());
|
||||
}
|
||||
|
||||
@@ -373,7 +373,7 @@ XE2_HPG_CORETEST_F(EncodeKernelXe2HpgCoreTest, givenDefaultSettingForFenceWhenKe
|
||||
dispatchInterface->getCrossThreadDataSizeResult = 0;
|
||||
|
||||
EncodeDispatchKernelArgs dispatchArgs = createDefaultDispatchKernelArgs(pDevice, dispatchInterface.get(), dims, false);
|
||||
dispatchArgs.postSyncArgs.isKernelUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isUsingSystemAllocation = true;
|
||||
|
||||
EncodeDispatchKernel<FamilyType>::template encode<DefaultWalkerType>(*cmdContainer.get(), dispatchArgs);
|
||||
|
||||
@@ -425,7 +425,7 @@ XE2_HPG_CORETEST_F(EncodeKernelXe2HpgCoreTest, givenDefaultSettingForFenceWhenKe
|
||||
dispatchInterface->getCrossThreadDataSizeResult = 0;
|
||||
|
||||
EncodeDispatchKernelArgs dispatchArgs = createDefaultDispatchKernelArgs(pDevice, dispatchInterface.get(), dims, false);
|
||||
dispatchArgs.postSyncArgs.isKernelUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isHostScopeSignalEvent = true;
|
||||
|
||||
EncodeDispatchKernel<FamilyType>::template encode<DefaultWalkerType>(*cmdContainer.get(), dispatchArgs);
|
||||
|
||||
@@ -314,7 +314,7 @@ XE3_CORETEST_F(EncodeKernelXe3CoreTest, givenDefaultSettingForFenceWhenKernelUse
|
||||
dispatchInterface->getCrossThreadDataSizeResult = 0;
|
||||
|
||||
EncodeDispatchKernelArgs dispatchArgs = createDefaultDispatchKernelArgs(pDevice, dispatchInterface.get(), dims, false);
|
||||
dispatchArgs.postSyncArgs.isKernelUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isUsingSystemAllocation = true;
|
||||
|
||||
EncodeDispatchKernel<FamilyType>::template encode<DefaultWalkerType>(*cmdContainer.get(), dispatchArgs);
|
||||
|
||||
@@ -366,7 +366,7 @@ XE3_CORETEST_F(EncodeKernelXe3CoreTest, givenDefaultSettingForFenceWhenKernelUse
|
||||
dispatchInterface->getCrossThreadDataSizeResult = 0;
|
||||
|
||||
EncodeDispatchKernelArgs dispatchArgs = createDefaultDispatchKernelArgs(pDevice, dispatchInterface.get(), dims, false);
|
||||
dispatchArgs.postSyncArgs.isKernelUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isHostScopeSignalEvent = true;
|
||||
|
||||
EncodeDispatchKernel<FamilyType>::template encode<DefaultWalkerType>(*cmdContainer.get(), dispatchArgs);
|
||||
|
||||
@@ -374,7 +374,7 @@ XE_HPC_CORETEST_F(EncodeKernelXeHpcCoreTest, givenDefaultSettingForFenceWhenKern
|
||||
|
||||
bool requiresUncachedMocs = false;
|
||||
EncodeDispatchKernelArgs dispatchArgs = createDefaultDispatchKernelArgs(pDevice, dispatchInterface.get(), dims, requiresUncachedMocs);
|
||||
dispatchArgs.postSyncArgs.isKernelUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isUsingSystemAllocation = true;
|
||||
|
||||
EncodeDispatchKernel<FamilyType>::template encode<DefaultWalkerType>(*cmdContainer.get(), dispatchArgs);
|
||||
|
||||
@@ -445,7 +445,7 @@ XE_HPC_CORETEST_F(EncodeKernelXeHpcCoreTest, givenDefaultSettingForFenceWhenKern
|
||||
dispatchInterface->getCrossThreadDataSizeResult = 0;
|
||||
|
||||
EncodeDispatchKernelArgs dispatchArgs = createDefaultDispatchKernelArgs(pDevice, dispatchInterface.get(), dims, false);
|
||||
dispatchArgs.postSyncArgs.isKernelUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isUsingSystemAllocation = true;
|
||||
dispatchArgs.postSyncArgs.isHostScopeSignalEvent = true;
|
||||
|
||||
EncodeDispatchKernel<FamilyType>::template encode<DefaultWalkerType>(*cmdContainer.get(), dispatchArgs);
|
||||
|
||||
Reference in New Issue
Block a user