radeonsi: rework compute scratch buffer
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Sat, 2 Apr 2016 11:04:18 +0000 (13:04 +0200)
committerBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Tue, 19 Apr 2016 16:10:31 +0000 (18:10 +0200)
commitba1f66a73d493c49a3a329d9f3882ddbae4147b0
treea99285ca2bda0fb5c026787cf337b5afaeb5663d
parent107f4d3538e6eeab396bf41a4d4334950adf81ac
radeonsi: rework compute scratch buffer

Instead of having a scratch buffer per program, have one per
context.

Also removed the per kernel wave count calculations, but
that only helped if the total number of waves in the dispatch
was smaller than sctx->scratch_waves.

v2: Fix style issue.

Signed-off-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/gallium/drivers/radeonsi/si_compute.c
src/gallium/drivers/radeonsi/si_pipe.c
src/gallium/drivers/radeonsi/si_pipe.h