Don't use BCS for NV12 images

Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
Related-To: NEO-4692
This commit is contained in:
Kamil Kopryk
2021-06-10 12:53:07 +00:00
committed by Compute-Runtime-Automation
parent 6ea3f57849
commit a9fe74c98d
3 changed files with 20 additions and 0 deletions

View File

@ -1353,6 +1353,23 @@ TEST(CommandQueue, givenMipMappedImageWhenCallingBlitEnqueueImageAllowedThenCorr
EXPECT_FALSE(queue.blitEnqueueImageAllowed(correctOrigin, correctRegion, image));
}
TEST(CommandQueue, givenNV12ImageWhenCallingBlitEnqueueImageAllowedThenCorrectResultIsReturned) {
DebugManagerStateRestore restorer;
DebugManager.flags.EnableBlitterForReadWriteImage.set(1);
MockContext context{};
MockCommandQueue queue(&context, context.getDevice(0), 0);
size_t correctRegion[3] = {10u, 10u, 0};
size_t correctOrigin[3] = {1u, 1u, 0};
MockImageBase image;
image.imageFormat.image_channel_order = CL_NV12_INTEL;
EXPECT_FALSE(queue.blitEnqueueImageAllowed(correctOrigin, correctRegion, image));
image.imageFormat.image_channel_order = CL_RGBA;
EXPECT_TRUE(queue.blitEnqueueImageAllowed(correctOrigin, correctRegion, image));
}
TEST(CommandQueue, givenSupportForOperationWhenValidatingSupportThenReturnSuccess) {
MockCommandQueue queue{};

View File

@ -17,6 +17,7 @@ namespace NEO {
struct MockImageBase : public Image {
using Image::imageDesc;
using Image::imageFormat;
MockGraphicsAllocation *graphicsAllocation = nullptr;
MockImageBase() : Image(