b89e0fa226
this (conceptually) flattens out the batches into a wrapping id which
is used to determine whether a resource has in-flight work pending
the code cleanup is nice, but evaluating performance of this is difficult.
in testing a heavy use case of unsynchronized subdata:
* 10% fewer driver flushes (good)
* 20% fewer direct unsynchronized uploads (bad? or possibly hidden race conditions fixed...)
Fixes: 9cc06f817c ("tc: allow unsynchronized texture_subdata calls where possible")
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35026>