Mesa (master): clover: implement CL_IMAGE_ELEMENT_SIZE

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Feb 25 10:34:29 UTC 2021


Module: Mesa
Branch: master
Commit: 60173853c25026d3e6ba165678772f9cf602afe2
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=60173853c25026d3e6ba165678772f9cf602afe2

Author: Aaron Watry <awatry at gmail.com>
Date:   Sun Oct 11 21:33:19 2020 +0200

clover: implement CL_IMAGE_ELEMENT_SIZE

v2 (Karol Herbst): extracted from other commit

Signed-off-by: Karol Herbst <kherbst at redhat.com>
Reviewed-by: Serge Martin <edb at sigluy.net>
Reviewed-by: Francisco Jerez <currojerez at riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9212>

---

 src/gallium/frontends/clover/api/memory.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/frontends/clover/api/memory.cpp b/src/gallium/frontends/clover/api/memory.cpp
index 5014e7e48c1..5a1d3b87aae 100644
--- a/src/gallium/frontends/clover/api/memory.cpp
+++ b/src/gallium/frontends/clover/api/memory.cpp
@@ -418,7 +418,7 @@ clGetImageInfo(cl_mem d_mem, cl_image_info param,
       break;
 
    case CL_IMAGE_ELEMENT_SIZE:
-      buf.as_scalar<size_t>() = 0;
+      buf.as_scalar<size_t>() = img.pixel_size();
       break;
 
    case CL_IMAGE_ROW_PITCH:



More information about the mesa-commit mailing list