This was missing for the READ case. This improves glBegin/End performance.
(vbo maps with WRITE | READ | UNSYCHRONIZED)
Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Mathias Fröhlich <Mathias.Froehlich@web.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4153>
/* Handle CPU reads trivially. */
if (usage & PIPE_TRANSFER_READ) {
+ if (usage & PIPE_TRANSFER_UNSYNCHRONIZED)
+ usage |= TC_TRANSFER_MAP_THREADED_UNSYNC; /* don't sync */
+
/* Drivers aren't allowed to do buffer invalidations. */
return usage & ~PIPE_TRANSFER_DISCARD_WHOLE_RESOURCE;
}