Mesa (staging/21.0): cso: set index_bounds_valid = true for arrays draws
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Jan 20 17:22:35 UTC 2021
Module: Mesa
Branch: staging/21.0
Commit: 9fc330f27ba9a3c906f1e1342ed2ca03ef08ba23
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=9fc330f27ba9a3c906f1e1342ed2ca03ef08ba23
Author: Ilia Mirkin <imirkin at alum.mit.edu>
Date: Sun Jan 17 12:46:03 2021 -0500
cso: set index_bounds_valid = true for arrays draws
The min/max indices are valid. Set the bit to true to indicate that.
Fixes glClear (+ clear_with_quads) on nouveau.
Fixes: 72ff53098c64 (gallium: add pipe_draw_info::index_bounds_valid)
Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
Reported-by: Simon Ser <contact at emersion.fr>
Tested-by: Simon Ser <contact at emersion.fr>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8546>
(cherry picked from commit 111c0733eaef2b3bfe9abaea2bb7880b5976dde6)
---
.pick_status.json | 2 +-
src/gallium/auxiliary/cso_cache/cso_context.c | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/.pick_status.json b/.pick_status.json
index 77959cb1aee..f6446b83af0 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -409,7 +409,7 @@
"description": "cso: set index_bounds_valid = true for arrays draws",
"nominated": true,
"nomination_type": 1,
- "resolution": 0,
+ "resolution": 1,
"master_sha": null,
"because_sha": "72ff53098c648ea5513fc2b150349b5b9ae58667"
},
diff --git a/src/gallium/auxiliary/cso_cache/cso_context.c b/src/gallium/auxiliary/cso_cache/cso_context.c
index 69077fcf2be..38ab603ade5 100644
--- a/src/gallium/auxiliary/cso_cache/cso_context.c
+++ b/src/gallium/auxiliary/cso_cache/cso_context.c
@@ -1718,6 +1718,7 @@ cso_draw_arrays(struct cso_context *cso, uint mode, uint start, uint count)
util_draw_init_info(&info);
info.mode = mode;
+ info.index_bounds_valid = true;
info.min_index = start;
info.max_index = start + count - 1;
@@ -1738,6 +1739,7 @@ cso_draw_arrays_instanced(struct cso_context *cso, uint mode,
util_draw_init_info(&info);
info.mode = mode;
+ info.index_bounds_valid = true;
info.min_index = start;
info.max_index = start + count - 1;
info.start_instance = start_instance;
More information about the mesa-commit
mailing list