swr: allocate all scratch space in one go for vertex buffers
authorIlia Mirkin <imirkin@alum.mit.edu>
Sun, 20 Nov 2016 21:34:59 +0000 (16:34 -0500)
committerIlia Mirkin <imirkin@alum.mit.edu>
Tue, 22 Nov 2016 02:11:26 +0000 (21:11 -0500)
commitd48740568faff4aad78a46c67f73ea3c5ea3bd0c
tree89fe35fa10263d279d4a3dd7becbff1c89d3ffc5
parent16d42f2f3dcc8bec8d75b53d1e9e9cf5af6e528c
swr: allocate all scratch space in one go for vertex buffers

Multiple buffers may reference client arrays. When this happens, we
might reach for scratch space multiple times, which could cause later
arrays to invalidate the pointers allocated for the earlier ones.

This fixes copyteximage 2D_ARRAY.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
src/gallium/drivers/swr/swr_scratch.cpp
src/gallium/drivers/swr/swr_state.cpp