summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/util
diff options
context:
space:
mode:
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>2021-09-16 11:18:49 -0400
committerMarge Bot <eric+marge@anholt.net>2021-09-17 12:32:29 +0000
commit5eb59a03ec6eaa0bfab5ebf6eb600a22cac07f12 (patch)
tree0438a23f9c509b26b15006ad8d415a764e09d3a0 /src/gallium/auxiliary/util
parent85305b2d61f784729dbb664e7e9851dac72300be (diff)
util/tc: rename tc_replace_buffer_storage_func::num_rebinds and document
this parameter is only a hint, as tc provides no method for tracking cases when a buffer is bound multiple times to the same site (e.g., multiple vertex buffer slots will be counted as 1 bind), so rename to "minimum" to be more clear Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12898>
Diffstat (limited to 'src/gallium/auxiliary/util')
-rw-r--r--src/gallium/auxiliary/util/u_threaded_context.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/u_threaded_context.h b/src/gallium/auxiliary/util/u_threaded_context.h
index 0e1189d7f70..2436608b45b 100644
--- a/src/gallium/auxiliary/util/u_threaded_context.h
+++ b/src/gallium/auxiliary/util/u_threaded_context.h
@@ -145,6 +145,10 @@
* the threaded context wants to replace a resource's backing storage with
* another resource's backing storage. The threaded context uses it to
* implement buffer invalidation. This call is always queued.
+ * Note that 'minimum_num_rebinds' specifies only the minimum number of rebinds
+ * which must be managed by the driver; if a buffer is bound multiple times in
+ * the same binding point (e.g., vertex buffer slots 0,1,2), this will be counted
+ * as a single rebind.
*
*
* Optional resource busy callbacks for better performance
@@ -290,7 +294,7 @@ enum tc_binding_type {
typedef void (*tc_replace_buffer_storage_func)(struct pipe_context *ctx,
struct pipe_resource *dst,
struct pipe_resource *src,
- unsigned num_rebinds,
+ unsigned minimum_num_rebinds,
uint32_t rebind_mask,
uint32_t delete_buffer_id);
typedef struct pipe_fence_handle *(*tc_create_fence_func)(struct pipe_context *ctx,