Modified kernel code to correspond to the Image declared format (CL_UNSIGNED_INT8) (#2512)

**For mutable_dispatch_image_1d_arguments &
mutable_dispatch_image_2d_arguments:**
As the images are created using CL_UNSIGNED_INT8, the kernel does not
use correct instructions, as they are designed for signed variable. This
fix consists of modifying the kernel code to use unsigned instructions
and auxiliary variables .
This commit is contained in:
Sergiu Bogdan Popescu
2025-10-28 17:01:42 +01:00
committed by GitHub
parent 580fde7501
commit d63cc8ce5d

View File

@@ -70,9 +70,9 @@ struct MutableDispatchImage1DArguments : public BasicMutableCommandBufferTest
{ {
int offset = get_global_id(0); int offset = get_global_id(0);
int4 color = read_imagei( source, sampler, offset ); uint4 color = read_imageui( source, sampler, offset );
write_imagei( dest, offset, color ); write_imageui( dest, offset, color );
})"; })";
cl_int error; cl_int error;
@@ -260,9 +260,9 @@ struct MutableDispatchImage2DArguments : public BasicMutableCommandBufferTest
int x = get_global_id(0); int x = get_global_id(0);
int y = get_global_id(1); int y = get_global_id(1);
int4 color = read_imagei( source, sampler, (int2) (x, y) ); uint4 color = read_imageui( source, sampler, (int2) (x, y) );
write_imagei( dest, (int2) (x, y), color ); write_imageui( dest, (int2) (x, y), color );
})"; })";
cl_int error; cl_int error;