Module: Mesa
Branch: main
Commit: 6932827a47afaf9f92e27905a59681dcf5832854
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=6932827a47afaf9f92e27905a59681dcf5832854

Author: Kenneth Graunke <kenn...@whitecape.org>
Date:   Tue Sep 26 02:37:53 2023 -0700

iris: Use 64K BOs for the shader uploader

16K was apparently a little unrealistic - Unigine Superposition has
individual shaders that are larger than 16K.  Yikes.  Moving to 64K
also puts shaders into the same cache bucket as other allocations.

Reviewed-by: José Roberto de Souza <jose.so...@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25447>

---

 src/gallium/drivers/iris/iris_program_cache.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/gallium/drivers/iris/iris_program_cache.c 
b/src/gallium/drivers/iris/iris_program_cache.c
index b5cdc7279f3..481f575b511 100644
--- a/src/gallium/drivers/iris/iris_program_cache.c
+++ b/src/gallium/drivers/iris/iris_program_cache.c
@@ -264,11 +264,13 @@ iris_init_program_cache(struct iris_context *ice)
       _mesa_hash_table_create(ice, keybox_hash, keybox_equals);
 
    ice->shaders.uploader_driver =
-      u_upload_create(&ice->ctx, 16384, PIPE_BIND_CUSTOM, PIPE_USAGE_IMMUTABLE,
+      u_upload_create(&ice->ctx, 64 * 1024,
+                      PIPE_BIND_CUSTOM, PIPE_USAGE_IMMUTABLE,
                       IRIS_RESOURCE_FLAG_SHADER_MEMZONE |
                       IRIS_RESOURCE_FLAG_DEVICE_MEM);
    ice->shaders.uploader_unsync =
-      u_upload_create(&ice->ctx, 16384, PIPE_BIND_CUSTOM, PIPE_USAGE_IMMUTABLE,
+      u_upload_create(&ice->ctx, 64 * 1024,
+                      PIPE_BIND_CUSTOM, PIPE_USAGE_IMMUTABLE,
                       IRIS_RESOURCE_FLAG_SHADER_MEMZONE |
                       IRIS_RESOURCE_FLAG_DEVICE_MEM);
 }

Reply via email to