OSDN Git Service

lima: fix ppir spill stack allocation
authorErico Nunes <nunes.erico@gmail.com>
Fri, 23 Aug 2019 04:34:36 +0000 (06:34 +0200)
committerErico Nunes <nunes.erico@gmail.com>
Sun, 25 Aug 2019 18:08:59 +0000 (20:08 +0200)
commit27e7603c344a31d5b2f0ef45ac54ee4c643910fc
tree2581cc500ada9aa29502200a2c3909912803c387
parentf58e0405b6ca15d9b82122d82311e8b82f4a0939
lima: fix ppir spill stack allocation

The previous spill stack was fixed and too small, and caused instability
in programs requiring spilling for roughly more than one value.
This patch adds a dynamic calculation of the buffer size based on stack
utilization and switches it to a separate allocation at flush time that
will fit the shader that requires the largest buffer.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Reviewed-by: Qiang Yu <yuq825@gmail.com>
src/gallium/drivers/lima/lima_context.h
src/gallium/drivers/lima/lima_draw.c
src/gallium/drivers/lima/lima_program.c
src/gallium/drivers/lima/lima_screen.h