zink: add is_buffer param to zink_batch_resource_usage_set

this allows constants to be specified, reducing register pressure during
descriptor binds

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
This commit is contained in:
Mike Blumenkrantz
2022-08-09 07:55:20 -04:00
committed by Marge Bot
parent 0b56ac82eb
commit 16ae4fb8b7
4 changed files with 43 additions and 34 deletions

View File

@@ -529,7 +529,7 @@ zink_batch_reference_resource_rw(struct zink_batch *batch, struct zink_resource
!zink_resource_has_binds(res))
/* then it already has a batch ref and doesn't need one here */
zink_batch_reference_resource(batch, res);
zink_batch_resource_usage_set(batch, res, write);
zink_batch_resource_usage_set(batch, res, write, res->obj->is_buffer);
}
void