summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2021-10-19 06:40:24 +1000
committerMarge Bot <eric+marge@anholt.net>2021-10-19 01:03:58 +0000
commitcae1ef0a11a6846d3caafd7fcafeadd6fa7ca6d2 (patch)
tree2bb42f733320fbb306c61a241c13a918ff836d01
parentdfd0f5dbfd494cab04c9f436d3fcbfc804459c1d (diff)
clover: use max shader sampler view/images queries for clover.
This is probably sane than my last answer to this question Reviewed-by: Karol Herbst <kherbst@redhat.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13398>
-rw-r--r--src/gallium/frontends/clover/core/device.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gallium/frontends/clover/core/device.cpp b/src/gallium/frontends/clover/core/device.cpp
index 7ef66d50492..2e3d77d2bf3 100644
--- a/src/gallium/frontends/clover/core/device.cpp
+++ b/src/gallium/frontends/clover/core/device.cpp
@@ -221,12 +221,14 @@ device::vendor_id() const {
size_t
device::max_images_read() const {
- return PIPE_MAX_SHADER_SAMPLER_VIEWS;
+ return pipe->get_shader_param(pipe, PIPE_SHADER_COMPUTE,
+ PIPE_SHADER_CAP_MAX_SAMPLER_VIEWS);
}
size_t
device::max_images_write() const {
- return PIPE_MAX_SHADER_IMAGES;
+ return pipe->get_shader_param(pipe, PIPE_SHADER_COMPUTE,
+ PIPE_SHADER_CAP_MAX_SHADER_IMAGES);
}
size_t