diff --git a/opencl/source/gen12lp/hardware_commands_helper_gen12lp.cpp b/opencl/source/gen12lp/hardware_commands_helper_gen12lp.cpp index c36aceecbf..b5892f6b54 100644 --- a/opencl/source/gen12lp/hardware_commands_helper_gen12lp.cpp +++ b/opencl/source/gen12lp/hardware_commands_helper_gen12lp.cpp @@ -1,20 +1,126 @@ /* - * Copyright (C) 2019-2024 Intel Corporation + * Copyright (C) 2019-2025 Intel Corporation * * SPDX-License-Identifier: MIT * */ #include "shared/source/gen12lp/hw_cmds.h" +#include "shared/source/helpers/flat_batch_buffer_helper.h" +#include "shared/source/helpers/gfx_core_helper.h" +#include "shared/source/helpers/pipe_control_args.h" #include "opencl/source/command_queue/command_queue.h" #include "opencl/source/helpers/hardware_commands_helper.h" #include "opencl/source/helpers/hardware_commands_helper_base.inl" -#include "opencl/source/helpers/hardware_commands_helper_bdw_and_later.inl" +#include "opencl/source/kernel/kernel.h" namespace NEO { using FamilyType = Gen12LpFamily; +template +typename HardwareCommandsHelper::INTERFACE_DESCRIPTOR_DATA *HardwareCommandsHelper::getInterfaceDescriptor( + const IndirectHeap &indirectHeap, + uint64_t offsetInterfaceDescriptor, + HardwareCommandsHelper::INTERFACE_DESCRIPTOR_DATA *inlineInterfaceDescriptor) { + return static_cast(ptrOffset(indirectHeap.getCpuBase(), (size_t)offsetInterfaceDescriptor)); +} + +template +uint32_t HardwareCommandsHelper::additionalSizeRequiredDsh() { + return sizeof(INTERFACE_DESCRIPTOR_DATA); +} + +template +size_t HardwareCommandsHelper::getSizeRequiredCS() { + size_t size = 2 * sizeof(typename GfxFamily::MEDIA_STATE_FLUSH) + + sizeof(typename GfxFamily::MEDIA_INTERFACE_DESCRIPTOR_LOAD); + return size; +} + +template +void HardwareCommandsHelper::sendMediaStateFlush( + LinearStream &commandStream, + size_t offsetInterfaceDescriptorData) { + + using MEDIA_STATE_FLUSH = typename GfxFamily::MEDIA_STATE_FLUSH; + auto pCmd = commandStream.getSpaceForCmd(); + MEDIA_STATE_FLUSH cmd = GfxFamily::cmdInitMediaStateFlush; + + cmd.setInterfaceDescriptorOffset(static_cast(offsetInterfaceDescriptorData)); + *pCmd = cmd; +} + +template +void HardwareCommandsHelper::sendMediaInterfaceDescriptorLoad( + LinearStream &commandStream, + size_t offsetInterfaceDescriptorData, + size_t sizeInterfaceDescriptorData) { + { + using MEDIA_STATE_FLUSH = typename GfxFamily::MEDIA_STATE_FLUSH; + auto pCmd = commandStream.getSpaceForCmd(); + *pCmd = GfxFamily::cmdInitMediaStateFlush; + } + + { + using MEDIA_INTERFACE_DESCRIPTOR_LOAD = typename GfxFamily::MEDIA_INTERFACE_DESCRIPTOR_LOAD; + auto pCmd = commandStream.getSpaceForCmd(); + MEDIA_INTERFACE_DESCRIPTOR_LOAD cmd = GfxFamily::cmdInitMediaInterfaceDescriptorLoad; + cmd.setInterfaceDescriptorDataStartAddress(static_cast(offsetInterfaceDescriptorData)); + cmd.setInterfaceDescriptorTotalLength(static_cast(sizeInterfaceDescriptorData)); + *pCmd = cmd; + } +} + +template +template +size_t HardwareCommandsHelper::sendCrossThreadData( + IndirectHeap &indirectHeap, + Kernel &kernel, + bool inlineDataProgrammingRequired, + WalkerType *walkerCmd, + uint32_t &sizeCrossThreadData, + uint64_t scratchAddress, + const RootDeviceEnvironment &rootDeviceEnvironment) { + indirectHeap.align(GfxFamily::cacheLineSize); + + auto pImplicitArgs = kernel.getImplicitArgs(); + if (pImplicitArgs) { + const auto &kernelDescriptor = kernel.getDescriptor(); + + auto isHwLocalIdGeneration = false; + auto sizeForImplicitArgsProgramming = ImplicitArgsHelper::getSizeForImplicitArgsPatching(pImplicitArgs, kernelDescriptor, isHwLocalIdGeneration, rootDeviceEnvironment); + + auto implicitArgsGpuVA = indirectHeap.getGraphicsAllocation()->getGpuAddress() + indirectHeap.getUsed(); + auto ptrToPatchImplicitArgs = indirectHeap.getSpace(sizeForImplicitArgsProgramming); + + ImplicitArgsHelper::patchImplicitArgs(ptrToPatchImplicitArgs, *pImplicitArgs, kernelDescriptor, {}, rootDeviceEnvironment, nullptr); + + auto implicitArgsCrossThreadPtr = ptrOffset(reinterpret_cast(kernel.getCrossThreadData()), kernelDescriptor.payloadMappings.implicitArgs.implicitArgsBuffer); + *implicitArgsCrossThreadPtr = implicitArgsGpuVA; + } + auto offsetCrossThreadData = indirectHeap.getUsed(); + char *pDest = nullptr; + + pDest = static_cast(indirectHeap.getSpace(sizeCrossThreadData)); + memcpy_s(pDest, sizeCrossThreadData, kernel.getCrossThreadData(), sizeCrossThreadData); + + if (debugManager.flags.AddPatchInfoCommentsForAUBDump.get()) { + FlatBatchBufferHelper::fixCrossThreadDataInfo(kernel.getPatchInfoDataList(), offsetCrossThreadData, indirectHeap.getGraphicsAllocation()->getGpuAddress()); + } + + return offsetCrossThreadData + static_cast(indirectHeap.getHeapGpuStartOffset()); +} + +template +template +void HardwareCommandsHelper::setInterfaceDescriptorOffset( + WalkerType *walkerCmd, + uint32_t &interfaceDescriptorIndex) { + + walkerCmd->setInterfaceDescriptorOffset(interfaceDescriptorIndex++); +} + template <> size_t HardwareCommandsHelper::getSizeRequiredCS() { size_t size = 2 * sizeof(typename FamilyType::MEDIA_STATE_FLUSH) + diff --git a/opencl/source/helpers/CMakeLists.txt b/opencl/source/helpers/CMakeLists.txt index 26d7dac652..7e819e44ea 100644 --- a/opencl/source/helpers/CMakeLists.txt +++ b/opencl/source/helpers/CMakeLists.txt @@ -34,7 +34,6 @@ set(RUNTIME_SRCS_HELPERS_BASE ${CMAKE_CURRENT_SOURCE_DIR}/gmm_types_converter.h ${CMAKE_CURRENT_SOURCE_DIR}/hardware_commands_helper.h ${CMAKE_CURRENT_SOURCE_DIR}/hardware_commands_helper_base.inl - ${CMAKE_CURRENT_SOURCE_DIR}/hardware_commands_helper_bdw_and_later.inl ${CMAKE_CURRENT_SOURCE_DIR}/helper_options.cpp ${CMAKE_CURRENT_SOURCE_DIR}/implicit_scaling_ocl.cpp ${CMAKE_CURRENT_SOURCE_DIR}/mipmap.cpp diff --git a/opencl/source/helpers/hardware_commands_helper_bdw_and_later.inl b/opencl/source/helpers/hardware_commands_helper_bdw_and_later.inl deleted file mode 100644 index 06aec3aaee..0000000000 --- a/opencl/source/helpers/hardware_commands_helper_bdw_and_later.inl +++ /dev/null @@ -1,122 +0,0 @@ -/* - * Copyright (C) 2020-2024 Intel Corporation - * - * SPDX-License-Identifier: MIT - * - */ - -#pragma once -#include "shared/source/helpers/flat_batch_buffer_helper.h" -#include "shared/source/helpers/gfx_core_helper.h" -#include "shared/source/helpers/pipe_control_args.h" - -#include "opencl/source/command_queue/command_queue.h" -#include "opencl/source/helpers/hardware_commands_helper.h" -#include "opencl/source/kernel/kernel.h" - -namespace NEO { - -template -typename HardwareCommandsHelper::INTERFACE_DESCRIPTOR_DATA *HardwareCommandsHelper::getInterfaceDescriptor( - const IndirectHeap &indirectHeap, - uint64_t offsetInterfaceDescriptor, - HardwareCommandsHelper::INTERFACE_DESCRIPTOR_DATA *inlineInterfaceDescriptor) { - return static_cast(ptrOffset(indirectHeap.getCpuBase(), (size_t)offsetInterfaceDescriptor)); -} - -template -uint32_t HardwareCommandsHelper::additionalSizeRequiredDsh() { - return sizeof(INTERFACE_DESCRIPTOR_DATA); -} - -template -size_t HardwareCommandsHelper::getSizeRequiredCS() { - size_t size = 2 * sizeof(typename GfxFamily::MEDIA_STATE_FLUSH) + - sizeof(typename GfxFamily::MEDIA_INTERFACE_DESCRIPTOR_LOAD); - return size; -} - -template -void HardwareCommandsHelper::sendMediaStateFlush( - LinearStream &commandStream, - size_t offsetInterfaceDescriptorData) { - - using MEDIA_STATE_FLUSH = typename GfxFamily::MEDIA_STATE_FLUSH; - auto pCmd = commandStream.getSpaceForCmd(); - MEDIA_STATE_FLUSH cmd = GfxFamily::cmdInitMediaStateFlush; - - cmd.setInterfaceDescriptorOffset(static_cast(offsetInterfaceDescriptorData)); - *pCmd = cmd; -} - -template -void HardwareCommandsHelper::sendMediaInterfaceDescriptorLoad( - LinearStream &commandStream, - size_t offsetInterfaceDescriptorData, - size_t sizeInterfaceDescriptorData) { - { - using MEDIA_STATE_FLUSH = typename GfxFamily::MEDIA_STATE_FLUSH; - auto pCmd = commandStream.getSpaceForCmd(); - *pCmd = GfxFamily::cmdInitMediaStateFlush; - } - - { - using MEDIA_INTERFACE_DESCRIPTOR_LOAD = typename GfxFamily::MEDIA_INTERFACE_DESCRIPTOR_LOAD; - auto pCmd = commandStream.getSpaceForCmd(); - MEDIA_INTERFACE_DESCRIPTOR_LOAD cmd = GfxFamily::cmdInitMediaInterfaceDescriptorLoad; - cmd.setInterfaceDescriptorDataStartAddress(static_cast(offsetInterfaceDescriptorData)); - cmd.setInterfaceDescriptorTotalLength(static_cast(sizeInterfaceDescriptorData)); - *pCmd = cmd; - } -} - -template -template -size_t HardwareCommandsHelper::sendCrossThreadData( - IndirectHeap &indirectHeap, - Kernel &kernel, - bool inlineDataProgrammingRequired, - WalkerType *walkerCmd, - uint32_t &sizeCrossThreadData, - uint64_t scratchAddress, - const RootDeviceEnvironment &rootDeviceEnvironment) { - indirectHeap.align(GfxFamily::cacheLineSize); - - auto pImplicitArgs = kernel.getImplicitArgs(); - if (pImplicitArgs) { - const auto &kernelDescriptor = kernel.getDescriptor(); - - auto isHwLocalIdGeneration = false; - auto sizeForImplicitArgsProgramming = ImplicitArgsHelper::getSizeForImplicitArgsPatching(pImplicitArgs, kernelDescriptor, isHwLocalIdGeneration, rootDeviceEnvironment); - - auto implicitArgsGpuVA = indirectHeap.getGraphicsAllocation()->getGpuAddress() + indirectHeap.getUsed(); - auto ptrToPatchImplicitArgs = indirectHeap.getSpace(sizeForImplicitArgsProgramming); - - ImplicitArgsHelper::patchImplicitArgs(ptrToPatchImplicitArgs, *pImplicitArgs, kernelDescriptor, {}, rootDeviceEnvironment, nullptr); - - auto implicitArgsCrossThreadPtr = ptrOffset(reinterpret_cast(kernel.getCrossThreadData()), kernelDescriptor.payloadMappings.implicitArgs.implicitArgsBuffer); - *implicitArgsCrossThreadPtr = implicitArgsGpuVA; - } - auto offsetCrossThreadData = indirectHeap.getUsed(); - char *pDest = nullptr; - - pDest = static_cast(indirectHeap.getSpace(sizeCrossThreadData)); - memcpy_s(pDest, sizeCrossThreadData, kernel.getCrossThreadData(), sizeCrossThreadData); - - if (debugManager.flags.AddPatchInfoCommentsForAUBDump.get()) { - FlatBatchBufferHelper::fixCrossThreadDataInfo(kernel.getPatchInfoDataList(), offsetCrossThreadData, indirectHeap.getGraphicsAllocation()->getGpuAddress()); - } - - return offsetCrossThreadData + static_cast(indirectHeap.getHeapGpuStartOffset()); -} - -template -template -void HardwareCommandsHelper::setInterfaceDescriptorOffset( - WalkerType *walkerCmd, - uint32_t &interfaceDescriptorIndex) { - - walkerCmd->setInterfaceDescriptorOffset(interfaceDescriptorIndex++); -} - -} // namespace NEO diff --git a/shared/source/command_stream/CMakeLists.txt b/shared/source/command_stream/CMakeLists.txt index 2b19a6dee7..e381850a0c 100644 --- a/shared/source/command_stream/CMakeLists.txt +++ b/shared/source/command_stream/CMakeLists.txt @@ -18,7 +18,6 @@ set(NEO_CORE_COMMAND_STREAM ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_hw_base.inl ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_simulated_common_hw.h ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_simulated_common_hw_base.inl - ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_simulated_common_hw_bdw_and_later.inl ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_simulated_hw.h ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_with_aub_dump.h ${CMAKE_CURRENT_SOURCE_DIR}/command_stream_receiver_with_aub_dump.inl diff --git a/shared/source/command_stream/command_stream_receiver_simulated_common_hw_bdw_and_later.inl b/shared/source/command_stream/command_stream_receiver_simulated_common_hw_bdw_and_later.inl deleted file mode 100644 index 8f438e4c7c..0000000000 --- a/shared/source/command_stream/command_stream_receiver_simulated_common_hw_bdw_and_later.inl +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (C) 2019-2024 Intel Corporation - * - * SPDX-License-Identifier: MIT - * - */ - -#include "shared/source/command_stream/command_stream_receiver_simulated_common_hw_base.inl" - -namespace NEO { - -template -void CommandStreamReceiverSimulatedCommonHw::initGlobalMMIO() { - for (auto &mmioPair : AUBFamilyMapper::globalMMIO) { - stream->writeMMIO(mmioPair.first, mmioPair.second); - } -} - -template -uint32_t CommandStreamReceiverSimulatedCommonHw::getMemoryBankForGtt() const { - return MemoryBanks::getBank(getDeviceIndex()); -} - -template -const AubMemDump::LrcaHelper &CommandStreamReceiverSimulatedCommonHw::getCsTraits(aub_stream::EngineType engineType) { - return *AUBFamilyMapper::csTraits[engineType]; -} - -template -void CommandStreamReceiverSimulatedCommonHw::initEngineMMIO() { - auto mmioList = AUBFamilyMapper::perEngineMMIO[osContext->getEngineType()]; - - DEBUG_BREAK_IF(!mmioList); - for (auto &mmioPair : *mmioList) { - stream->writeMMIO(mmioPair.first, mmioPair.second); - } -} -} // namespace NEO diff --git a/shared/source/gen12lp/command_stream_receiver_simulated_common_hw_gen12lp.cpp b/shared/source/gen12lp/command_stream_receiver_simulated_common_hw_gen12lp.cpp index f7005c70d4..b32971eb8d 100644 --- a/shared/source/gen12lp/command_stream_receiver_simulated_common_hw_gen12lp.cpp +++ b/shared/source/gen12lp/command_stream_receiver_simulated_common_hw_gen12lp.cpp @@ -1,15 +1,42 @@ /* - * Copyright (C) 2019-2023 Intel Corporation + * Copyright (C) 2019-2025 Intel Corporation * * SPDX-License-Identifier: MIT * */ -#include "shared/source/command_stream/command_stream_receiver_simulated_common_hw_bdw_and_later.inl" +#include "shared/source/command_stream/command_stream_receiver_simulated_common_hw_base.inl" namespace NEO { typedef Gen12LpFamily Family; +template +void CommandStreamReceiverSimulatedCommonHw::initGlobalMMIO() { + for (auto &mmioPair : AUBFamilyMapper::globalMMIO) { + stream->writeMMIO(mmioPair.first, mmioPair.second); + } +} + +template +uint32_t CommandStreamReceiverSimulatedCommonHw::getMemoryBankForGtt() const { + return MemoryBanks::getBank(getDeviceIndex()); +} + +template +const AubMemDump::LrcaHelper &CommandStreamReceiverSimulatedCommonHw::getCsTraits(aub_stream::EngineType engineType) { + return *AUBFamilyMapper::csTraits[engineType]; +} + +template +void CommandStreamReceiverSimulatedCommonHw::initEngineMMIO() { + auto mmioList = AUBFamilyMapper::perEngineMMIO[osContext->getEngineType()]; + + DEBUG_BREAK_IF(!mmioList); + for (auto &mmioPair : *mmioList) { + stream->writeMMIO(mmioPair.first, mmioPair.second); + } +} + template <> void CommandStreamReceiverSimulatedCommonHw::initGlobalMMIO() { for (auto &mmioPair : AUBFamilyMapper::globalMMIO) { diff --git a/shared/source/gen12lp/gfx_core_helper_gen12lp.cpp b/shared/source/gen12lp/gfx_core_helper_gen12lp.cpp index aa32e404d7..d0481ba01e 100644 --- a/shared/source/gen12lp/gfx_core_helper_gen12lp.cpp +++ b/shared/source/gen12lp/gfx_core_helper_gen12lp.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2019-2024 Intel Corporation + * Copyright (C) 2019-2025 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -10,15 +10,121 @@ using Family = NEO::Gen12LpFamily; +#include "shared/source/helpers/engine_node_helper.h" #include "shared/source/helpers/flat_batch_buffer_helper_hw.inl" +#include "shared/source/helpers/gfx_core_helper.h" #include "shared/source/helpers/gfx_core_helper_base.inl" -#include "shared/source/helpers/gfx_core_helper_bdw_and_later.inl" #include "shared/source/helpers/gfx_core_helper_bdw_to_dg2.inl" #include "shared/source/helpers/gfx_core_helper_tgllp_and_later.inl" +#include "shared/source/helpers/hw_info.h" #include "shared/source/helpers/local_memory_access_modes.h" +#include "shared/source/kernel/kernel_descriptor.h" namespace NEO { +template +void GfxCoreHelperHw::adjustDefaultEngineType(HardwareInfo *pHwInfo, const ProductHelper &productHelper, AILConfiguration *ailConfiguration) { +} + +template +inline uint32_t GfxCoreHelperHw::getGlobalTimeStampBits() const { + return 36; +} + +template +bool GfxCoreHelperHw::hvAlign4Required() const { + return true; +} + +template +bool GfxCoreHelperHw::timestampPacketWriteSupported() const { + return false; +} + +template +bool GfxCoreHelperHw::isTimestampWaitSupportedForQueues() const { + return false; +} + +template +bool GfxCoreHelperHw::isUpdateTaskCountFromWaitSupported() const { + return false; +} + +template +uint32_t GfxCoreHelperHw::getAmountOfAllocationsToFill() const { + if (debugManager.flags.SetAmountOfReusableAllocations.get() != -1) { + return debugManager.flags.SetAmountOfReusableAllocations.get(); + } + return 0u; +} + +template +bool GfxCoreHelperHw::makeResidentBeforeLockNeeded(bool precondition) const { + return precondition; +} + +template +inline uint32_t GfxCoreHelperHw::calculateMaxWorkGroupSize(const KernelDescriptor &kernelDescriptor, uint32_t defaultMaxGroupSize) const { + return std::min(defaultMaxGroupSize, CommonConstants::maxWorkgroupSize); +} + +constexpr uint32_t planarYuvMaxHeight = 16352; + +template +uint32_t GfxCoreHelperHw::getPlanarYuvMaxHeight() const { + return planarYuvMaxHeight; +} + +template +aub_stream::MMIOList GfxCoreHelperHw::getExtraMmioList(const HardwareInfo &hwInfo, const GmmHelper &gmmHelper) const { + return {}; +} + +template +inline void MemorySynchronizationCommands::setPostSyncExtraProperties(PipeControlArgs &args) { +} + +template +inline void MemorySynchronizationCommands::setBarrierWaFlags(void *barrierCmd) { + reinterpret_cast(barrierCmd)->setCommandStreamerStallEnable(true); +} + +template +bool GfxCoreHelperHw::unTypedDataPortCacheFlushRequired() const { + return false; +} + +template +bool GfxCoreHelperHw::isScratchSpaceSurfaceStateAccessible() const { + return false; +} + +template +uint32_t GfxCoreHelperHw::getMaxScratchSize(const NEO::ProductHelper &productHelper) const { + return 2 * MemoryConstants::megaByte; +} + +template +inline bool GfxCoreHelperHw::platformSupportsImplicitScaling(const NEO::RootDeviceEnvironment &rootDeviceEnvironment) const { + return false; +} + +template +inline bool GfxCoreHelperHw::preferInternalBcsEngine() const { + return false; +} + +template +uint32_t GfxCoreHelperHw::getMinimalScratchSpaceSize() const { + return 1024U; +} + +template +uint32_t GfxCoreHelperHw::getKernelPrivateMemSize(const KernelDescriptor &kernelDescriptor) const { + return kernelDescriptor.kernelAttributes.perHwThreadPrivateMemorySize; +} + template <> inline bool GfxCoreHelperHw::isFusedEuDispatchEnabled(const HardwareInfo &hwInfo, bool disableEUFusionForKernel) const { auto fusedEuDispatchEnabled = !hwInfo.workaroundTable.flags.waDisableFusedThreadScheduling; diff --git a/shared/source/helpers/CMakeLists.txt b/shared/source/helpers/CMakeLists.txt index 9ddd3a16c4..892affcd93 100644 --- a/shared/source/helpers/CMakeLists.txt +++ b/shared/source/helpers/CMakeLists.txt @@ -87,7 +87,6 @@ set(NEO_CORE_HELPERS ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper.cpp ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper.h ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper_base.inl - ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper_bdw_and_later.inl ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper_bdw_to_dg2.inl ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper_bdw_to_icllp.inl ${CMAKE_CURRENT_SOURCE_DIR}/gfx_core_helper_pvc_and_later.inl diff --git a/shared/source/helpers/gfx_core_helper_bdw_and_later.inl b/shared/source/helpers/gfx_core_helper_bdw_and_later.inl deleted file mode 100644 index a42543a5b7..0000000000 --- a/shared/source/helpers/gfx_core_helper_bdw_and_later.inl +++ /dev/null @@ -1,117 +0,0 @@ -/* - * Copyright (C) 2019-2024 Intel Corporation - * - * SPDX-License-Identifier: MIT - * - */ - -#include "shared/source/helpers/engine_node_helper.h" -#include "shared/source/helpers/gfx_core_helper.h" -#include "shared/source/helpers/hw_info.h" -#include "shared/source/kernel/kernel_descriptor.h" - -namespace NEO { - -template -void GfxCoreHelperHw::adjustDefaultEngineType(HardwareInfo *pHwInfo, const ProductHelper &productHelper, AILConfiguration *ailConfiguration) { -} - -template -inline uint32_t GfxCoreHelperHw::getGlobalTimeStampBits() const { - return 36; -} - -template -bool GfxCoreHelperHw::hvAlign4Required() const { - return true; -} - -template -bool GfxCoreHelperHw::timestampPacketWriteSupported() const { - return false; -} - -template -bool GfxCoreHelperHw::isTimestampWaitSupportedForQueues() const { - return false; -} - -template -bool GfxCoreHelperHw::isUpdateTaskCountFromWaitSupported() const { - return false; -} - -template -uint32_t GfxCoreHelperHw::getAmountOfAllocationsToFill() const { - if (debugManager.flags.SetAmountOfReusableAllocations.get() != -1) { - return debugManager.flags.SetAmountOfReusableAllocations.get(); - } - return 0u; -} - -template -bool GfxCoreHelperHw::makeResidentBeforeLockNeeded(bool precondition) const { - return precondition; -} - -template -inline uint32_t GfxCoreHelperHw::calculateMaxWorkGroupSize(const KernelDescriptor &kernelDescriptor, uint32_t defaultMaxGroupSize) const { - return std::min(defaultMaxGroupSize, CommonConstants::maxWorkgroupSize); -} - -constexpr uint32_t planarYuvMaxHeight = 16352; - -template -uint32_t GfxCoreHelperHw::getPlanarYuvMaxHeight() const { - return planarYuvMaxHeight; -} - -template -aub_stream::MMIOList GfxCoreHelperHw::getExtraMmioList(const HardwareInfo &hwInfo, const GmmHelper &gmmHelper) const { - return {}; -} - -template -inline void MemorySynchronizationCommands::setPostSyncExtraProperties(PipeControlArgs &args) { -} - -template -inline void MemorySynchronizationCommands::setBarrierWaFlags(void *barrierCmd) { - reinterpret_cast(barrierCmd)->setCommandStreamerStallEnable(true); -} - -template -bool GfxCoreHelperHw::unTypedDataPortCacheFlushRequired() const { - return false; -} - -template -bool GfxCoreHelperHw::isScratchSpaceSurfaceStateAccessible() const { - return false; -} - -template -uint32_t GfxCoreHelperHw::getMaxScratchSize(const NEO::ProductHelper &productHelper) const { - return 2 * MemoryConstants::megaByte; -} - -template -inline bool GfxCoreHelperHw::platformSupportsImplicitScaling(const NEO::RootDeviceEnvironment &rootDeviceEnvironment) const { - return false; -} - -template -inline bool GfxCoreHelperHw::preferInternalBcsEngine() const { - return false; -} - -template -uint32_t GfxCoreHelperHw::getMinimalScratchSpaceSize() const { - return 1024U; -} - -template -uint32_t GfxCoreHelperHw::getKernelPrivateMemSize(const KernelDescriptor &kernelDescriptor) const { - return kernelDescriptor.kernelAttributes.perHwThreadPrivateMemorySize; -} -} // namespace NEO