Revert "refactor: unify blit memory fill methods and pass BlitProperties"
This reverts commit d7ca6568fc
.
Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
parent
7cbe19c5a9
commit
21021f0340
|
@ -2327,15 +2327,15 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendBlitFill(void *ptr,
|
|||
}
|
||||
}
|
||||
|
||||
auto offset = getAllocationOffsetForAppendBlitFill(ptr, *gpuAllocation);
|
||||
uint64_t offset = getAllocationOffsetForAppendBlitFill(ptr, *gpuAllocation);
|
||||
|
||||
commandContainer.addToResidencyContainer(gpuAllocation);
|
||||
uint32_t patternToCommand[4] = {};
|
||||
memcpy_s(&patternToCommand, sizeof(patternToCommand), pattern, patternSize);
|
||||
|
||||
auto blitProperties = NEO::BlitProperties::constructPropertiesForMemoryFill(gpuAllocation, size, patternToCommand, patternSize, offset);
|
||||
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryColorFill(blitProperties, *commandContainer.getCommandStream(), neoDevice->getRootDeviceEnvironmentRef());
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryColorFill(gpuAllocation, offset, patternToCommand, patternSize,
|
||||
*commandContainer.getCommandStream(),
|
||||
size,
|
||||
neoDevice->getRootDeviceEnvironmentRef());
|
||||
dummyBlitWa.isWaRequired = true;
|
||||
|
||||
appendSignalEventPostWalker(signalEvent, nullptr, nullptr, false, false, true);
|
||||
|
|
|
@ -108,8 +108,8 @@ void BlitCommandsHelper<Family>::appendBlitCommandsForImages(const BlitPropertie
|
|||
}
|
||||
|
||||
template <>
|
||||
void BlitCommandsHelper<Family>::dispatchBlitMemoryByteFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
NEO::BlitCommandsHelper<Family>::dispatchBlitMemoryFill(blitProperties, linearStream, rootDeviceEnvironment);
|
||||
void BlitCommandsHelper<Family>::dispatchBlitMemoryByteFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
NEO::BlitCommandsHelper<Family>::dispatchBlitMemoryFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment, COLOR_DEPTH::COLOR_DEPTH_8_BIT_COLOR, 1);
|
||||
}
|
||||
|
||||
template <>
|
||||
|
|
|
@ -49,9 +49,9 @@ struct BlitCommandsHelper {
|
|||
static void dispatchBlitCommandsForBufferRegion(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitCommandsForBufferPerRow(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitCommandsForImageRegion(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitMemoryColorFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitMemoryByteFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitMemoryFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitMemoryColorFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, size_t patternSize, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitMemoryByteFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void dispatchBlitMemoryFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment, COLOR_DEPTH depth, size_t patternSize);
|
||||
static void dispatchDummyBlit(LinearStream &linearStream, EncodeDummyBlitWaArgs &waArgs);
|
||||
static size_t getDummyBlitSize(const EncodeDummyBlitWaArgs &waArgs);
|
||||
static bool isDummyBlitWaNeeded(const EncodeDummyBlitWaArgs &waArgs);
|
||||
|
@ -67,9 +67,9 @@ struct BlitCommandsHelper {
|
|||
template <typename T = typename GfxFamily::XY_BLOCK_COPY_BLT>
|
||||
static void appendColorDepth(const BlitProperties &blitProperties, T &blitCmd);
|
||||
static void appendBlitMemoryOptionsForFillBuffer(NEO::GraphicsAllocation *dstAlloc, typename GfxFamily::XY_COLOR_BLT &blitCmd, const RootDeviceEnvironment &rootDeviceEnvironment);
|
||||
static void appendBlitFillCommand(const BlitProperties &blitProperties, typename GfxFamily::XY_COLOR_BLT &blitCmd);
|
||||
static void appendBlitFillCommand(typename GfxFamily::XY_COLOR_BLT &blitCmd);
|
||||
static void appendBlitMemSetCompressionFormat(void *blitCmd, NEO::GraphicsAllocation *dstAlloc, uint32_t compressionFormat);
|
||||
static void appendBlitMemSetCommand(const BlitProperties &blitProperties, void *blitCmd);
|
||||
static void appendBlitMemSetCommand(void *blitCmd);
|
||||
static void appendSurfaceType(const BlitProperties &blitProperties, typename GfxFamily::XY_BLOCK_COPY_BLT &blitCmd);
|
||||
static void appendTilingEnable(typename GfxFamily::XY_COLOR_BLT &blitCmd);
|
||||
static void appendTilingType(const GMM_TILE_TYPE srcTilingType, const GMM_TILE_TYPE dstTilingType, typename GfxFamily::XY_BLOCK_COPY_BLT &blitCmd);
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
#include "shared/source/helpers/gfx_core_helper.h"
|
||||
#include "shared/source/helpers/register_offsets.h"
|
||||
#include "shared/source/helpers/timestamp_packet.h"
|
||||
#include "shared/source/utilities/lookup_array.h"
|
||||
|
||||
#include <cmath>
|
||||
|
||||
|
@ -254,31 +253,22 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitCommandsForBufferPerRow(const Bl
|
|||
}
|
||||
|
||||
template <typename GfxFamily>
|
||||
void BlitCommandsHelper<GfxFamily>::appendBlitMemSetCommand(const BlitProperties &blitProperties, void *blitCmd) {}
|
||||
void BlitCommandsHelper<GfxFamily>::appendBlitMemSetCommand(void *blitCmd) {}
|
||||
|
||||
template <typename GfxFamily>
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment, COLOR_DEPTH depth, size_t patternSize) {
|
||||
using XY_COLOR_BLT = typename GfxFamily::XY_COLOR_BLT;
|
||||
auto blitCmd = GfxFamily::cmdInitXyColorBlt;
|
||||
const auto maxWidth = getMaxBlitWidth(rootDeviceEnvironment);
|
||||
const auto maxHeight = getMaxBlitHeight(rootDeviceEnvironment, true);
|
||||
|
||||
const LookupArray<size_t, COLOR_DEPTH, 5> colorDepthSize({{
|
||||
{1, COLOR_DEPTH::COLOR_DEPTH_8_BIT_COLOR},
|
||||
{2, COLOR_DEPTH::COLOR_DEPTH_16_BIT_COLOR},
|
||||
{4, COLOR_DEPTH::COLOR_DEPTH_32_BIT_COLOR},
|
||||
{8, COLOR_DEPTH::COLOR_DEPTH_64_BIT_COLOR},
|
||||
{16, COLOR_DEPTH::COLOR_DEPTH_128_BIT_COLOR},
|
||||
}});
|
||||
blitCmd.setFillColor(pattern);
|
||||
blitCmd.setColorDepth(depth);
|
||||
|
||||
blitCmd.setFillColor(blitProperties.fillPattern);
|
||||
blitCmd.setColorDepth(colorDepthSize.lookUp(blitProperties.fillPatternSize));
|
||||
|
||||
uint64_t sizeToFill = blitProperties.copySize.x / blitProperties.fillPatternSize;
|
||||
uint64_t offset = blitProperties.dstOffset.x;
|
||||
uint64_t sizeToFill = size / patternSize;
|
||||
while (sizeToFill != 0) {
|
||||
auto tmpCmd = blitCmd;
|
||||
tmpCmd.setDestinationBaseAddress(ptrOffset(blitProperties.dstAllocation->getGpuAddress(), static_cast<size_t>(offset)));
|
||||
tmpCmd.setDestinationBaseAddress(ptrOffset(dstAlloc->getGpuAddress(), static_cast<size_t>(offset)));
|
||||
uint64_t height = 0;
|
||||
uint64_t width = 0;
|
||||
if (sizeToFill <= maxWidth) {
|
||||
|
@ -293,15 +283,15 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(const BlitProperties
|
|||
}
|
||||
tmpCmd.setDestinationX2CoordinateRight(static_cast<uint32_t>(width));
|
||||
tmpCmd.setDestinationY2CoordinateBottom(static_cast<uint32_t>(height));
|
||||
tmpCmd.setDestinationPitch(static_cast<uint32_t>(width * blitProperties.fillPatternSize));
|
||||
tmpCmd.setDestinationPitch(static_cast<uint32_t>(width * patternSize));
|
||||
|
||||
appendBlitMemoryOptionsForFillBuffer(blitProperties.dstAllocation, tmpCmd, rootDeviceEnvironment);
|
||||
appendBlitFillCommand(blitProperties, tmpCmd);
|
||||
appendBlitMemoryOptionsForFillBuffer(dstAlloc, tmpCmd, rootDeviceEnvironment);
|
||||
appendBlitFillCommand(tmpCmd);
|
||||
|
||||
auto cmd = linearStream.getSpaceForCmd<XY_COLOR_BLT>();
|
||||
*cmd = tmpCmd;
|
||||
auto blitSize = width * height;
|
||||
offset += (blitSize * blitProperties.fillPatternSize);
|
||||
offset += (blitSize * patternSize);
|
||||
sizeToFill -= blitSize;
|
||||
}
|
||||
}
|
||||
|
@ -564,14 +554,25 @@ template <typename GfxFamily>
|
|||
void BlitCommandsHelper<GfxFamily>::adjustControlSurfaceType(const BlitProperties &blitProperties, typename GfxFamily::XY_BLOCK_COPY_BLT &blitCmd) {}
|
||||
|
||||
template <typename GfxFamily>
|
||||
void BlitCommandsHelper<GfxFamily>::appendBlitFillCommand(const BlitProperties &blitProperties, typename GfxFamily::XY_COLOR_BLT &blitCmd) {}
|
||||
void BlitCommandsHelper<GfxFamily>::appendBlitFillCommand(typename GfxFamily::XY_COLOR_BLT &blitCmd) {}
|
||||
|
||||
template <typename GfxFamily>
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryColorFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
if (blitProperties.fillPatternSize == 1) {
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryByteFill(blitProperties, linearStream, rootDeviceEnvironment);
|
||||
} else {
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(blitProperties, linearStream, rootDeviceEnvironment);
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryColorFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, size_t patternSize, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
switch (patternSize) {
|
||||
case 1:
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryByteFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment);
|
||||
break;
|
||||
case 2:
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment, COLOR_DEPTH::COLOR_DEPTH_16_BIT_COLOR, 2);
|
||||
break;
|
||||
case 4:
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment, COLOR_DEPTH::COLOR_DEPTH_32_BIT_COLOR, 4);
|
||||
break;
|
||||
case 8:
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment, COLOR_DEPTH::COLOR_DEPTH_64_BIT_COLOR, 8);
|
||||
break;
|
||||
default:
|
||||
NEO::BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment, COLOR_DEPTH::COLOR_DEPTH_128_BIT_COLOR, 16);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
namespace NEO {
|
||||
|
||||
template <typename GfxFamily>
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryByteFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryByteFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
using MEM_SET = typename Family::MEM_SET;
|
||||
auto blitCmd = Family::cmdInitMemSet;
|
||||
|
||||
|
@ -23,20 +23,19 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryByteFill(const BlitPropert
|
|||
blitCmd.setDestinationMOCS(mocs);
|
||||
|
||||
uint32_t compressionFormat = 0;
|
||||
if (blitProperties.dstAllocation->isCompressionEnabled()) {
|
||||
auto resourceFormat = blitProperties.dstAllocation->getDefaultGmm()->gmmResourceInfo->getResourceFormat();
|
||||
if (dstAlloc->isCompressionEnabled()) {
|
||||
auto resourceFormat = dstAlloc->getDefaultGmm()->gmmResourceInfo->getResourceFormat();
|
||||
compressionFormat = static_cast<uint32_t>(rootDeviceEnvironment.getGmmClientContext()->getSurfaceStateCompressionFormat(resourceFormat));
|
||||
}
|
||||
|
||||
appendBlitMemSetCompressionFormat(&blitCmd, blitProperties.dstAllocation, compressionFormat);
|
||||
appendBlitMemSetCompressionFormat(&blitCmd, dstAlloc, compressionFormat);
|
||||
|
||||
blitCmd.setFillData(*blitProperties.fillPattern);
|
||||
blitCmd.setFillData(*pattern);
|
||||
|
||||
auto sizeToFill = blitProperties.copySize.x;
|
||||
uint64_t offset = blitProperties.dstOffset.x;
|
||||
auto sizeToFill = size;
|
||||
while (sizeToFill != 0) {
|
||||
auto tmpCmd = blitCmd;
|
||||
tmpCmd.setDestinationStartAddress(ptrOffset(blitProperties.dstAllocation->getGpuAddress(), static_cast<size_t>(offset)));
|
||||
tmpCmd.setDestinationStartAddress(ptrOffset(dstAlloc->getGpuAddress(), static_cast<size_t>(offset)));
|
||||
size_t height = 0;
|
||||
size_t width = 0;
|
||||
if (sizeToFill <= BlitterConstants::maxBlitSetWidth) {
|
||||
|
@ -53,7 +52,7 @@ void BlitCommandsHelper<GfxFamily>::dispatchBlitMemoryByteFill(const BlitPropert
|
|||
tmpCmd.setFillHeight(static_cast<uint32_t>(height));
|
||||
tmpCmd.setDestinationPitch(static_cast<uint32_t>(width));
|
||||
|
||||
appendBlitMemSetCommand(blitProperties, &tmpCmd);
|
||||
appendBlitMemSetCommand(&tmpCmd);
|
||||
|
||||
auto cmd = linearStream.getSpaceForCmd<MEM_SET>();
|
||||
*cmd = tmpCmd;
|
||||
|
|
|
@ -367,10 +367,7 @@ void BlitCommandsHelper<GfxFamily>::dispatchDummyBlit(LinearStream &linearStream
|
|||
|
||||
appendTilingEnable(blitCmd);
|
||||
appendBlitMemoryOptionsForFillBuffer(dummyAllocation, blitCmd, *rootDeviceEnvironment);
|
||||
|
||||
BlitProperties blitProperties = {};
|
||||
|
||||
appendBlitFillCommand(blitProperties, blitCmd);
|
||||
appendBlitFillCommand(blitCmd);
|
||||
|
||||
auto cmd = linearStream.getSpaceForCmd<XY_COLOR_BLT>();
|
||||
*cmd = blitCmd;
|
||||
|
|
|
@ -13,18 +13,6 @@
|
|||
|
||||
namespace NEO {
|
||||
|
||||
BlitProperties BlitProperties::constructPropertiesForMemoryFill(GraphicsAllocation *dstAllocation, size_t size, uint32_t *pattern, size_t patternSize, size_t offset) {
|
||||
return {
|
||||
.blitDirection = BlitterConstants::BlitDirection::fill,
|
||||
.dstAllocation = dstAllocation,
|
||||
.fillPattern = pattern,
|
||||
.copySize = {size, 1, 1},
|
||||
.dstOffset = {offset, 0, 0},
|
||||
.srcOffset = {0, 0, 0},
|
||||
.fillPatternSize = patternSize,
|
||||
.isSystemMemoryPoolUsed = MemoryPoolHelper::isSystemMemoryPool(dstAllocation->getMemoryPool())};
|
||||
}
|
||||
|
||||
BlitProperties BlitProperties::constructPropertiesForReadWrite(BlitterConstants::BlitDirection blitDirection,
|
||||
CommandStreamReceiver &commandStreamReceiver,
|
||||
GraphicsAllocation *memObjAllocation,
|
||||
|
|
|
@ -43,7 +43,6 @@ struct BlitSyncProperties {
|
|||
};
|
||||
|
||||
struct BlitProperties {
|
||||
static BlitProperties constructPropertiesForMemoryFill(GraphicsAllocation *dstAllocation, size_t size, uint32_t *pattern, size_t patternSize, size_t offset);
|
||||
static BlitProperties constructPropertiesForReadWrite(BlitterConstants::BlitDirection blitDirection,
|
||||
CommandStreamReceiver &commandStreamReceiver,
|
||||
GraphicsAllocation *memObjAllocation,
|
||||
|
@ -76,7 +75,6 @@ struct BlitProperties {
|
|||
GraphicsAllocation *dstAllocation = nullptr;
|
||||
GraphicsAllocation *srcAllocation = nullptr;
|
||||
GraphicsAllocation *clearColorAllocation = nullptr;
|
||||
uint32_t *fillPattern = nullptr;
|
||||
uint64_t dstGpuAddress = 0;
|
||||
uint64_t srcGpuAddress = 0;
|
||||
|
||||
|
@ -88,7 +86,6 @@ struct BlitProperties {
|
|||
size_t dstSlicePitch = 0;
|
||||
size_t srcRowPitch = 0;
|
||||
size_t srcSlicePitch = 0;
|
||||
size_t fillPatternSize = 0;
|
||||
Vec3<size_t> dstSize = 0;
|
||||
Vec3<size_t> srcSize = 0;
|
||||
size_t bytesPerPixel = 1;
|
||||
|
|
|
@ -70,10 +70,9 @@ enum class BlitDirection : uint32_t {
|
|||
bufferToHostPtr,
|
||||
hostPtrToBuffer,
|
||||
bufferToBuffer,
|
||||
fill,
|
||||
hostPtrToImage,
|
||||
imageToHostPtr,
|
||||
imageToImage,
|
||||
imageToImage
|
||||
};
|
||||
|
||||
enum PostBlitMode : int32_t {
|
||||
|
|
|
@ -150,8 +150,8 @@ void BlitCommandsHelper<Family>::appendBlitCommandsBlockCopy(const BlitPropertie
|
|||
}
|
||||
|
||||
template <>
|
||||
void BlitCommandsHelper<Family>::dispatchBlitMemoryByteFill(const BlitProperties &blitProperties, LinearStream &linearStream, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
NEO::BlitCommandsHelper<Family>::dispatchBlitMemoryFill(blitProperties, linearStream, rootDeviceEnvironment);
|
||||
void BlitCommandsHelper<Family>::dispatchBlitMemoryByteFill(NEO::GraphicsAllocation *dstAlloc, uint64_t offset, uint32_t *pattern, LinearStream &linearStream, size_t size, RootDeviceEnvironment &rootDeviceEnvironment) {
|
||||
NEO::BlitCommandsHelper<Family>::dispatchBlitMemoryFill(dstAlloc, offset, pattern, linearStream, size, rootDeviceEnvironment, COLOR_DEPTH::COLOR_DEPTH_8_BIT_COLOR, 1);
|
||||
}
|
||||
|
||||
template <>
|
||||
|
|
|
@ -253,10 +253,7 @@ HWTEST_F(BlitTests, givenMemoryWhenFillPatternWithBlitThenCommandIsProgrammed) {
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), pattern, sizeof(uint32_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, pattern, sizeof(uint32_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -273,9 +270,7 @@ HWTEST_F(BlitTests, givenMemorySizeBiggerThanMaxWidthButLessThanTwiceMaxWidthWhe
|
|||
reinterpret_cast<void *>(0x1234), 0x1000, 0, (2 * BlitterConstants::maxBlitWidth) - 1,
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), pattern, sizeof(uint32_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, pattern, sizeof(uint32_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -295,10 +290,7 @@ HWTEST_F(BlitTests, givenMemoryPointerOffsetVerifyCorrectDestinationBaseAddress)
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), pattern, sizeof(uint32_t), 0x234);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0x234, pattern, sizeof(uint32_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -324,10 +316,7 @@ HWTEST_F(BlitTests, givenMemorySizeTwiceBiggerThanMaxWidthWhenFillPatternWithBli
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, (2 * BlitterConstants::maxBlitWidth * sizeof(uint32_t)),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), pattern, sizeof(uint32_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, pattern, sizeof(uint32_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -354,10 +343,7 @@ HWTEST_F(BlitTests, givenMemorySizeIsLessThanTwicenMaxWidthWhenFillPatternWithBl
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, ((BlitterConstants::maxBlitWidth + 1) * sizeof(uint32_t)),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), pattern, sizeof(uint32_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, pattern, sizeof(uint32_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
#include "shared/source/execution_environment/execution_environment.h"
|
||||
#include "shared/source/gmm_helper/gmm_helper.h"
|
||||
#include "shared/source/helpers/blit_commands_helper.h"
|
||||
#include "shared/source/helpers/blit_properties.h"
|
||||
#include "shared/source/helpers/definitions/command_encoder_args.h"
|
||||
#include "shared/test/common/cmd_parse/gen_cmd_parse.h"
|
||||
#include "shared/test/common/fixtures/device_fixture.h"
|
||||
|
@ -54,9 +53,7 @@ class GivenLinearStreamWhenCallDispatchBlitMemoryColorFillThenCorrectDepthIsProg
|
|||
canonizedGpuAddress);
|
||||
uint32_t patternToCommand[4];
|
||||
memset(patternToCommand, 4, patternSize);
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), patternToCommand, patternSize, 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, device->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, patternToCommand, patternSize, stream, mockAllocation.getUnderlyingBufferSize(), device->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
|
|
@ -25,10 +25,7 @@ HWTEST2_F(BlitTests, givenOneBytePatternWhenFillPatternWithBlitThenCommandIsProg
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -44,10 +41,7 @@ HWTEST2_F(BlitTests, givenDeviceWithoutDefaultGmmWhenAppendBlitCommandsForVillBu
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -70,10 +64,8 @@ HWTEST2_F(BlitTests, givenGmmWithDisabledCompresionWhenAppendBlitCommandsForVill
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
mockAllocation.setGmm(gmm.get(), 0u);
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -98,10 +90,7 @@ HWTEST2_F(BlitTests, givenGmmWithEnabledCompresionWhenAppendBlitCommandsForVillB
|
|||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
mockAllocation.setGmm(gmm.get(), 0u);
|
||||
auto &rootDeviceEnvironment = pDevice->getRootDeviceEnvironmentRef();
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, rootDeviceEnvironment);
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), rootDeviceEnvironment);
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -129,8 +118,7 @@ HWTEST2_F(BlitTests, givenOverridedMocksValueWhenAppendBlitCommandsForVillBuffer
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -153,10 +141,7 @@ HWTEST2_F(BlitTests, givenEnableStatelessCompressionWithUnifiedMemoryAndSystemMe
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -187,9 +172,7 @@ HWTEST2_F(BlitTests, givenEnableStatelessCompressionWithUnifiedMemoryAndLocalMem
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::localMemory, MemoryManager::maxOsContextCount);
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -210,9 +193,7 @@ HWTEST2_F(BlitTests, givenMemorySizeBiggerThanMaxWidthButLessThanTwiceMaxWidthWh
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, (2 * BlitterConstants::maxBlitSetWidth) - 1,
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -232,10 +213,7 @@ HWTEST2_F(BlitTests, givenMemorySizeTwiceBiggerThanMaxWidthWhenFillPatternWithBl
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, (2 * BlitterConstants::maxBlitSetWidth),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
|
|
@ -25,10 +25,7 @@ HWTEST2_F(BlitTests, givenOneBytePatternWhenFillPatternWithBlitThenCommandIsProg
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -48,10 +45,7 @@ HWTEST2_F(BlitTests, givenOverridedMocksValueWhenAppendBlitCommandsForVillBuffer
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -75,10 +69,7 @@ HWTEST2_F(BlitTests, givenEnableStatelessCompressionWithUnifiedMemoryAndSystemMe
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -102,10 +93,7 @@ HWTEST2_F(BlitTests, givenEnableStatelessCompressionWithUnifiedMemoryAndLocalMem
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, sizeof(uint32_t),
|
||||
MemoryPool::localMemory, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -125,10 +113,7 @@ HWTEST2_F(BlitTests, givenMemorySizeBiggerThanMaxWidthButLessThanTwiceMaxWidthWh
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, (2 * BlitterConstants::maxBlitSetWidth) - 1,
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -148,10 +133,7 @@ HWTEST2_F(BlitTests, givenMemorySizeTwiceBiggerThanMaxWidthWhenFillPatternWithBl
|
|||
MockGraphicsAllocation mockAllocation(0, 1u /*num gmms*/, AllocationType::internalHostMemory,
|
||||
reinterpret_cast<void *>(0x1234), 0x1000, 0, (2 * BlitterConstants::maxBlitSetWidth),
|
||||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, pDevice->getRootDeviceEnvironmentRef());
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), pDevice->getRootDeviceEnvironmentRef());
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
@ -176,9 +158,7 @@ HWTEST2_F(BlitTests, givenGmmWithEnabledCompresionWhenAppendBlitCommandsForFillB
|
|||
MemoryPool::system4KBPages, MemoryManager::maxOsContextCount);
|
||||
mockAllocation.setGmm(gmm.get(), 0u);
|
||||
auto &rootDeviceEnvironment = pDevice->getRootDeviceEnvironmentRef();
|
||||
auto blitProperties = BlitProperties::constructPropertiesForMemoryFill(&mockAllocation, mockAllocation.getUnderlyingBufferSize(), &pattern, sizeof(uint8_t), 0);
|
||||
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(blitProperties, stream, rootDeviceEnvironment);
|
||||
BlitCommandsHelper<FamilyType>::dispatchBlitMemoryColorFill(&mockAllocation, 0, &pattern, sizeof(uint8_t), stream, mockAllocation.getUnderlyingBufferSize(), rootDeviceEnvironment);
|
||||
GenCmdList cmdList;
|
||||
ASSERT_TRUE(FamilyType::Parse::parseCommandBuffer(
|
||||
cmdList, ptrOffset(stream.getCpuBase(), 0), stream.getUsed()));
|
||||
|
|
Loading…
Reference in New Issue