st/nine: Implement new buffer upload path
authorAxel Davy <axel.davy@ens.fr>
Sun, 4 Dec 2016 19:34:59 +0000 (20:34 +0100)
committerAxel Davy <axel.davy@ens.fr>
Tue, 20 Dec 2016 22:47:08 +0000 (23:47 +0100)
commitbad7f7cc638391acc93f070fce3e1b7035dc48f8
treedfc3dc7cad2a96efa3b131a803294c5599330d41
parent8960be0e939bc6c0f9f34c5d4a16891af7e325fd
st/nine: Implement new buffer upload path

This new buffer upload path enables to lock
faster than the normal path when using
DISCARD/NOOVERWRITE.

v2: Diverse cleanups and fixes.
v3: Fix allocation size for 'lone' buffers and
add more debug info.
v4: Rewrite of the path to handle when DISCARD/NOOVERWRITE
is not used anymore. The resource content is copied to the
new resource used.
v5: flush for safety after unmap (not sure it is really required
here, but safer to flush).
v6: Do not use the path if persistent coherent mapping is unavailable.
Fix buffer creation flags.
v7: Do not flush since it is not needed.

Signed-off-by: Axel Davy <axel.davy@ens.fr>
src/gallium/state_trackers/nine/Makefile.sources
src/gallium/state_trackers/nine/buffer9.c
src/gallium/state_trackers/nine/buffer9.h
src/gallium/state_trackers/nine/device9.c
src/gallium/state_trackers/nine/device9.h
src/gallium/state_trackers/nine/indexbuffer9.c
src/gallium/state_trackers/nine/indexbuffer9.h
src/gallium/state_trackers/nine/nine_buffer_upload.c [new file with mode: 0644]
src/gallium/state_trackers/nine/nine_buffer_upload.h [new file with mode: 0644]
src/gallium/state_trackers/nine/vertexbuffer9.c