OpenCL-CTS icon indicating copy to clipboard operation
OpenCL-CTS copied to clipboard

Extend testing of CL_UNORM_INT_101010_2

Open gorazd-sumkovski-arm opened this issue 1 year ago • 1 comments

All existing tests in test_image_streams, that are capable of testing image formats using the CL_UNORM_INT_101010_2 data type, now do so.

gorazd-sumkovski-arm avatar Aug 01 '24 12:08 gorazd-sumkovski-arm

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Aug 01 '24 12:08 CLAassistant

  1. get_32_bit_image_format() - Added (although this function isn't used anywhere).
  2. compare_scanlines() - As you suggested, no need for a special case because all 32 bits in CL_UNORM_INT_101010_2 are used.
  3. get_format_max_int() - Added.
  4. get_format_min_int() - Added.
  5. read_image_pixel<T>() - Already present in read_image_pixel_float(). Seems like read_image_pixel<T>() is used for int and uint while float has a separate function. As a side note, it looks like the cases for 101010, 555 and 565 in read_image_pixel<T>() are wrong, they are missing the normalisation divisions.
  6. get_pixel_bytes() - Added.

gorazd-sumkovski-arm avatar Aug 12 '24 14:08 gorazd-sumkovski-arm

Any objections to merging this PR ahead of the next teleconference? It is blocking the addition of testing for the 2_101010 format added by https://github.com/KhronosGroup/OpenCL-Docs/pull/1223.

kpet avatar Sep 16 '24 09:09 kpet

I'm going to go ahead and merge this. Since these are purely additions I think the risk of problems for implementations that do not support the 101010_2 format is low. If we find problems we can always revert it.

@lakshmih FYI.

bashbaug avatar Sep 16 '24 15:09 bashbaug

Thanks!

kpet avatar Sep 16 '24 16:09 kpet