[Mesa-dev] [PATCH 32/84] st/nine: Move pipe and cso to nine_context

2016-12-07 Thread Axel Davy
Part of the refactor to move all gallium calls to nine_state.c, and have all internal states required for those calls in nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 32 +++ src/gallium/state_trackers/nine/device9.h| 2 - src/gallium

[Mesa-dev] [PATCH 14/84] st/nine: Back current index buffer to nine_context

2016-12-07 Thread Axel Davy
Part of the refactor to move all gallium calls to nine_state.c, and have all internal states required for those calls in nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 16 ++- src/gallium/state_trackers/nine/nine_state.c | 29

[Mesa-dev] [PATCH 54/84] st/nine: Upload Managed buffers just before draw call using them

2016-12-07 Thread Axel Davy
Previously we were uploading Managed buffers at the next draw call after they were set dirty. This is not the expected behaviour. Instead upload just before draw call needing the content. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/buffer9.c | 19 --- src

[Mesa-dev] [PATCH 53/84] st/nine: Track bindings for buffers

2016-12-07 Thread Axel Davy
Similar code than for textures. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/buffer9.h | 18 ++ src/gallium/state_trackers/nine/device9.c | 9 +-- src/gallium/state_trackers/nine/stateblock9.c | 34 +++ 3 files changed, 55

[Mesa-dev] [PATCH 68/84] st/nine: Do not bind the container if forward is false

2016-12-07 Thread Axel Davy
This doesn't make sense to bind the container in that specific case. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/iunknown.h | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/gallium/state_trackers/nine/iunknown.h b/src/gallium/state_tra

[Mesa-dev] [PATCH 46/84] st/nine: Implement gallium nine CSMT

2016-12-07 Thread Axel Davy
From: Patrick Rudolph Use an offloading thread for all nine_context functions. Macros are used to ease the reading of the code. Signed-off-by: Patrick Rudolph Signed-off-by: Axel Davy --- src/gallium/auxiliary/os/os_thread.h | 11 + src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 45/84] st/nine: Pass size of memory to nine_state

2016-12-07 Thread Axel Davy
From: Patrick Rudolph Required for CSMT. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/device9.c| 20 ++-- src/gallium/state_trackers/nine/nine_state.c | 18 ++ src/gallium/state_trackers/nine/nine_state.h | 6 ++ 3 files changed, 3

[Mesa-dev] [PATCH 16/84] st/nine: Back scissor to nine_context

2016-12-07 Thread Axel Davy
Part of the refactor to move all gallium calls to nine_state.c, and have all internal states required for those calls in nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 7 +- src/gallium/state_trackers/nine/nine_state.c | 32

[Mesa-dev] [PATCH 48/84] st/nine: Add NINE_DEBUG=tid to turn threadid on or off

2016-12-07 Thread Axel Davy
From: Patrick Rudolph To ease debugging. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/nine_debug.c | 14 +- src/gallium/state_trackers/nine/nine_debug.h | 1 + 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/gallium/state_trackers/nine/nin

[Mesa-dev] [PATCH 57/84] st/nine: Implement Fast path for dynamic buffers and csmt

2016-12-07 Thread Axel Davy
Use the secondary pipe for DISCARD/NOOVERWRITE, which avoids stalling to get the pipe from the worker thread. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/buffer9.c | 62 ++ src/gallium/state_trackers/nine/buffer9.h | 7 ++- src/gallium

[Mesa-dev] [PATCH 39/84] st/nine: Reimplement nine_context_apply_stateblock

2016-12-07 Thread Axel Davy
The new version uses nine_context functions instead of applying the changes directly to nine_context. This will enable it to work with CSMT. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 205 +++ 1 file changed, 205 insertions(+) diff --git

[Mesa-dev] [PATCH 73/84] st/nine: Implement nine_context_box_upload

2016-12-07 Thread Axel Davy
This function will be used for surface and volume uploads Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 39 src/gallium/state_trackers/nine/nine_state.h | 11 2 files changed, 50 insertions(+) diff --git a/src/gallium

[Mesa-dev] [PATCH 42/84] st/nine: Create pipe_surfaces on resource creation.

2016-12-07 Thread Axel Davy
Create the pipe_surfaces on renderable resources creation. This enables to avoid creating them on the fly. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/surface9.c | 9 + src/gallium/state_trackers/nine/surface9.h | 5 ++--- 2 files changed, 11 insertions(+), 3 deletions

[Mesa-dev] [PATCH 79/84] st/nine: Idem for nine_context_gen_mipmap

2016-12-07 Thread Axel Davy
Will enable to use the bind count as an information for whether the surface/volume is used in the worker thread. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/basetexture9.c | 3 ++- src/gallium/state_trackers/nine/nine_state.c | 4 src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 47/84] st/nine: Print threadid in debug log

2016-12-07 Thread Axel Davy
From: Patrick Rudolph To ease debugging. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/nine_debug.c | 24 ++-- 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_debug.c b/src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 78/84] st/nine: Bind destination for surface/volume uploads

2016-12-07 Thread Axel Davy
Will enable to use the bind count as an information for whether the surface/volume is used in the worker thread. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 4 src/gallium/state_trackers/nine/nine_state.h | 1 + src/gallium/state_trackers/nine/surface9.c

[Mesa-dev] [PATCH 55/84] st/nine: Add nine_context_get_pipe_acquire/release

2016-12-07 Thread Axel Davy
See commit for description. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_queue.c | 9 src/gallium/state_trackers/nine/nine_queue.h | 3 ++ src/gallium/state_trackers/nine/nine_state.c | 67 src/gallium/state_trackers/nine/nine_state.h

[Mesa-dev] [PATCH 41/84] st/nine: Back swvp in nine_context

2016-12-07 Thread Axel Davy
Part of the refactor to move all gallium calls to nine_state.c, and have all internal states required for those calls in nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 3 ++- src/gallium/state_trackers/nine/nine_state.c| 14 -- src

[Mesa-dev] [PATCH 67/84] st/nine: Comment and simplify iunknown

2016-12-07 Thread Axel Davy
The behaviour is a bit less obscure now. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/iunknown.c | 9 ++--- src/gallium/state_trackers/nine/iunknown.h | 30 -- 2 files changed, 18 insertions(+), 21 deletions(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 63/84] st/nine: Avoid flushing the queue for queries GetData

2016-12-07 Thread Axel Davy
Use the newly introduced counter to know when we don't need synchronization. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 33 +++- src/gallium/state_trackers/nine/nine_state.h | 6 ++--- src/gallium/state_trackers/nine/query9.c

[Mesa-dev] [PATCH 33/84] st/nine: Integrate nine_pipe_context_clear to nine_context_clear

2016-12-07 Thread Axel Davy
Part of the refactor to move all gallium calls to nine_state.c, and have all internal states required for those calls in nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 7 ++- src/gallium/state_trackers/nine/device9ex.c | 3 +-- src/gallium

[Mesa-dev] [PATCH 49/84] st/nine: Use nine_context for blit

2016-12-07 Thread Axel Davy
From: Patrick Rudolph Enables to offload it with CSMT. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/device9.c| 5 +++-- src/gallium/state_trackers/nine/nine_state.c | 8 src/gallium/state_trackers/nine/nine_state.h | 4 3 files changed, 15 insertions(+),

[Mesa-dev] [PATCH 59/84] st/nine: Simplify ColorFill

2016-12-07 Thread Axel Davy
For render targets, NineSurface9_GetSurface is not expected to fail. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 38/84] st/nine: Decompose nine_context_set_texture

2016-12-07 Thread Axel Davy
Part of the refactor to move all gallium calls to nine_state.c, and have all internal states required for those calls in nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 73 ++-- 1 file changed, 48 insertions(+), 25 deletions

[Mesa-dev] [PATCH 43/84] st/nine: Add nine_queue

2016-12-07 Thread Axel Davy
From: Patrick Rudolph This queue mechanism will be used for CSMT. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/Makefile.sources | 2 + src/gallium/state_trackers/nine/nine_queue.c | 251 +++ src/gallium/state_trackers/nine/nine_queue.h | 48

[Mesa-dev] [PATCH 44/84] st/nine: Add struct nine_clipplane

2016-12-07 Thread Axel Davy
From: Patrick Rudolph Required to know the size exact size of the plane. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/device9.c| 2 +- src/gallium/state_trackers/nine/nine_state.c | 4 ++-- src/gallium/state_trackers/nine/nine_state.h | 5 - 3 files changed, 7 ins

[Mesa-dev] [PATCH 64/84] st/nine: Simplify ARG_BIND_REF

2016-12-07 Thread Axel Davy
Remove some noop operations. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_csmt_helper.h | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_csmt_helper.h b/src/gallium/state_trackers/nine/nine_csmt_helper.h

[Mesa-dev] [PATCH 50/84] st/nine: Use nine_context for resource_copy_region

2016-12-07 Thread Axel Davy
From: Patrick Rudolph Use nine_context wrapper for resource_copy_region. Enables to offload it with CSMT. Signed-off-by: Patrick Rudolph --- src/gallium/state_trackers/nine/device9.c| 6 ++ src/gallium/state_trackers/nine/nine_state.c | 17 + src/gallium/state_trackers

[Mesa-dev] [PATCH 75/84] st/nine: Fix leak with cubetexture dtor

2016-12-07 Thread Axel Davy
The last level was not released. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/cubetexture9.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/cubetexture9.c b/src/gallium/state_trackers/nine/cubetexture9.c index 0a834eb

[Mesa-dev] [PATCH 40/84] st/nine: Change the way nine_shader gets the pipe

2016-12-07 Thread Axel Davy
The change is required with csmt, where depending on the thread you don't access the pipe the same way. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_shader.c | 3 +-- src/gallium/state_trackers/nine/nine_shader.h | 4 +++- src/gallium/state_trackers/nine/pixelsh

[Mesa-dev] [PATCH 52/84] st/nine: Fix BASETEX_REGISTER_UPDATE

2016-12-07 Thread Axel Davy
BASETEX_REGISTER_UPDATE was adding the texture to the list of textures to upload in too many cases. tex->base.base.bind will be set to true if the texture is in a stateblock, whereas we want to upload only if bound to the device, which is what bind_count is for. Signed-off-by: Axel Davy ---

[Mesa-dev] [PATCH 72/84] st/nine: Use nine_context_gen_mipmap in BaseTexture9

2016-12-07 Thread Axel Davy
Generate mipmaps in the worker thread. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/basetexture9.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/gallium/state_trackers/nine/basetexture9.c b/src/gallium/state_trackers/nine/basetexture9.c

[Mesa-dev] [PATCH 66/84] st/nine: Detach buffers in swapchain dtor.

2016-12-07 Thread Axel Davy
BackBuffers can survive swapchain dtor if the user has a reference on them. The swapchain itself has no reference on the buffer. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/swapchain9.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 31/84] st/nine: Rename pipe to pipe_data in nine_context

2016-12-07 Thread Axel Davy
This patch it to avoid name conflict when device->pipe will be moved to nine_context. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c| 20 +++ src/gallium/state_trackers/nine/nine_state.c | 90 ++-- src/gallium/state_trackers/n

[Mesa-dev] [PATCH 80/84] st/nine: Add arguments to context's blit and copy_region

2016-12-07 Thread Axel Davy
The new arguments enable to reference the objects while the function hasn't run. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 14 -- src/gallium/state_trackers/nine/nine_state.c | 10 ++ src/gallium/state_trackers/nine/nine_state.h | 4 ++

[Mesa-dev] [PATCH 61/84] st/nine: Use nine_context_clear_render_target

2016-12-07 Thread Axel Davy
Enables to not wait for the worker thread for ColorFill. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 7 +-- src/gallium/state_trackers/nine/nine_state.c | 17 + src/gallium/state_trackers/nine/nine_state.h | 9 + src/gallium

[Mesa-dev] [PATCH 83/84] st/nine: Allow non-zero resource offset for vertex buffers

2016-12-07 Thread Axel Davy
Next patches will introduce an offset. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c| 15 +-- src/gallium/state_trackers/nine/vertexbuffer9.c | 3 ++- src/gallium/state_trackers/nine/vertexbuffer9.h | 2 +- 3 files changed, 12 insertions(+), 8

[Mesa-dev] [PATCH 77/84] st/nine: Use nine_context_box_upload for volumes

2016-12-07 Thread Axel Davy
Use nine_context_box_upload for uploads: . systemmem volume to default volume . managed volume internal content to its resource. Check the uploads are executed before any action that can alter the data, that is LockBox and volume destruction. Signed-off-by: Axel Davy --- src/gallium

[Mesa-dev] [PATCH 69/84] st/nine: Implement nine_context_range_upload

2016-12-07 Thread Axel Davy
Will be used to upload buffers. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 11 +++ src/gallium/state_trackers/nine/nine_state.h | 8 2 files changed, 19 insertions(+) diff --git a/src/gallium/state_trackers/nine/nine_state.c b/src/gallium

[Mesa-dev] [PATCH 82/84] st/nine: Do not wait for DEFAULT lock for volumes when we can

2016-12-07 Thread Axel Davy
If the volumes (and the texture container) are not referenced, then they are no pending operations on them. We can lock directly. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/volume9.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 81/84] st/nine: Do not wait for DEFAULT lock for surfaces when we can

2016-12-07 Thread Axel Davy
If the surfaces (and the texture container) are not referenced, then they are no pending operations on them. We can lock directly. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/surface9.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 74/84] st/nine: Use nine_context_box_upload for surfaces

2016-12-07 Thread Axel Davy
: Axel Davy --- src/gallium/state_trackers/nine/surface9.c | 63 +++--- src/gallium/state_trackers/nine/surface9.h | 2 + 2 files changed, 33 insertions(+), 32 deletions(-) diff --git a/src/gallium/state_trackers/nine/surface9.c b/src/gallium/state_trackers/nine/surface9.c

[Mesa-dev] [PATCH 58/84] st/nine: use get_pipe_acquire/release when possible

2016-12-07 Thread Axel Davy
Use the acquire/release semantic when we don't need to wait for any pending command. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/basetexture9.c | 8 ++-- src/gallium/state_trackers/nine/buffer9.c | 4 +++- src/gallium/state_trackers/nine/nine_state.c

[Mesa-dev] [PATCH 56/84] st/nine: Add secondary pipe for device

2016-12-07 Thread Axel Davy
The secondary pipe will be used for operations that don't need synchronization. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 4 +++- src/gallium/state_trackers/nine/device9.h | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ga

[Mesa-dev] [PATCH 70/84] st/nine: Optimize managed buffer upload

2016-12-07 Thread Axel Davy
Do the upload in the other thread. Usually managed buffers are used once per frame. It is then very likely pending_upload is 0 at Lock time. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/buffer9.c | 3 +++ src/gallium/state_trackers/nine/buffer9.h | 12 +++- 2 files

[Mesa-dev] [PATCH 84/84] st/nine: Implement new buffer upload path

2016-12-07 Thread Axel Davy
This new buffer upload path enables to lock faster than the normal path when using DISCARD/NOOVERWRITE. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/Makefile.sources | 2 + src/gallium/state_trackers/nine/buffer9.c | 75 +- src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 71/84] st/nine: Implement nine_context_gen_mipmap

2016-12-07 Thread Axel Davy
To offload mipmap generation as well. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 15 +++ src/gallium/state_trackers/nine/nine_state.h | 7 +++ 2 files changed, 22 insertions(+) diff --git a/src/gallium/state_trackers/nine/nine_state.c b/src

[Mesa-dev] [PATCH 76/84] st/nine: Fix leak with volume dtor

2016-12-07 Thread Axel Davy
The last level was not released. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/volumetexture9.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/volumetexture9.c b/src/gallium/state_trackers/nine/volumetexture9.c index 4908ed7

[Mesa-dev] [PATCH 03/36] st/nine: Remove useless call to nine_update_state

2016-12-07 Thread Axel Davy
The call was not needed. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c index 055e71d..7bdf19f 100644 --- a/src/gallium

[Mesa-dev] [PATCH 09/36] st/nine: Remove useless check in surface9 ctor

2016-12-07 Thread Axel Davy
Textures already have the check in BaseTexture9. Non-Textures cannot be in the MANAGED Pool. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/surface9.c | 4 1 file changed, 4 deletions(-) diff --git a/src/gallium/state_trackers/nine/surface9.c b/src/gallium/state_trackers

[Mesa-dev] [PATCH 24/36] driconf: Fix missing gettext

2016-12-07 Thread Axel Davy
DRI_CONF_NINE_OVERRIDEVENDOR was missing gettext for the description. Signed-off-by: Axel Davy --- src/mesa/drivers/dri/common/xmlpool/t_options.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/common/xmlpool/t_options.h b/src/mesa/drivers/dri/common

[Mesa-dev] [PATCH 06/36] st/nine: Fix ps multisample check

2016-12-07 Thread Axel Davy
We want to use centroid for nonmaskable multisampling as well. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/pixelshader9.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/pixelshader9.h b/src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 15/36] st/nine: Correctly release sw cursor image

2016-12-07 Thread Axel Davy
cursor.image is used for software cursor emulation. It wasn't released. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c index a7

[Mesa-dev] [PATCH 13/36] st/nine: Avoid crash on empty Draw*Up

2016-12-07 Thread Axel Davy
Ignore empty draw calls. Avoid assertion fault when such draw calls happen in u_upload_mgr. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine

[Mesa-dev] [PATCH 08/36] st/nine: Fix bad light initialization in stateblocks

2016-12-07 Thread Axel Davy
src was initialized instead of dst. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/stateblock9.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/state_trackers/nine/stateblock9.c b/src/gallium/state_trackers/nine/stateblock9.c index 16e60ef

[Mesa-dev] [PATCH 04/36] st/nine: Don't update stream_usage_mask in sw path

2016-12-07 Thread Axel Davy
The variable is used only in the hw path. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_state.c b/src/gallium/state_trackers/nine/nine_state.c index 57f7b2d..69f0cff 100644

[Mesa-dev] [PATCH 28/36] st/nine: Do not saturate illumination coefficients in ff

2016-12-07 Thread Axel Davy
Fixes bad rendering of a test app. Wine has the same behaviour. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 4 1 file changed, 4 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_ff.c b/src/gallium/state_trackers/nine/nine_ff.c index 8b6f442

[Mesa-dev] [PATCH 33/36] st/nine: Fix two special cases in ff ps

2016-12-07 Thread Axel Davy
if first alpha stage is disabled and writes to temp, diffuse alpha is written to temp. Last stage always writes to current. Behaviour was deduced by tests with a test app. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 20 1 file changed, 20

[Mesa-dev] [PATCH 35/36] st/nine: Fix ff texture coordinate selection

2016-12-07 Thread Axel Davy
The code was wrongly detecting which texture coordinates to generate when the coordinate index was different to the stage index. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 20/36] d3dadapter/present: Add precision for WaitBufferReleased

2016-12-07 Thread Axel Davy
Add precision on the behaviour of WaitBufferReleased. All implementers and users of the API were expecting that behaviour. Signed-off-by: Axel Davy --- include/d3dadapter/present.h | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/d3dadapter/present.h b/include

[Mesa-dev] [PATCH 01/36] st/nine: Improve doc of D3DPMISCCAPS_POSTBLENDSRGBCONVERT

2016-12-07 Thread Axel Davy
The cap should be advertised for d3d10 able cards, but only for Ex contexts. Unfortunately at this point Mesa has no way to know if Ex is used or not (the info is got later). Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/adapter9.c | 2 +- 1 file changed, 1 insertion(+), 1

[Mesa-dev] [PATCH 17/36] st/nine: Do not generate gallium NOP on d3d NOP

2016-12-07 Thread Axel Davy
Some drivers crash if NOP is generated. Besides there is no point to generate NOP. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_shader.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/nine_shader.c b/src/gallium

[Mesa-dev] [PATCH 31/36] st/nine: Fix ff cases when stages should be disabled

2016-12-07 Thread Axel Davy
When a texture is read by a stage for colorop, it should be disabled, and disable following stages. When a texture is read for alphaop, 1.0f is read for the input, which is the behaviour for a dummy texture. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 22

[Mesa-dev] [PATCH 30/36] st/nine: Always initialize current in ff ps

2016-12-07 Thread Axel Davy
The check was not catching all possible cases. NVE4 should be fine. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 25 + 1 file changed, 1 insertion(+), 24 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_ff.c b/src/gallium

[Mesa-dev] [PATCH 19/36] d3dadapter/present: Add new API to ID3DPresent

2016-12-07 Thread Axel Davy
The API will enable better support for the commonly used DISCARD swapchain parameter. Signed-off-by: Axel Davy --- include/d3dadapter/present.h | 24 1 file changed, 24 insertions(+) diff --git a/include/d3dadapter/present.h b/include/d3dadapter/present.h index 187843f

[Mesa-dev] [PATCH 05/36] st/nine: Fix useless swapchain init checks

2016-12-07 Thread Axel Davy
In NineDevice9_SetDefaultState we can assume the implicit swapchain is properly initialized. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 21 +++-- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/src/gallium/state_trackers/nine/device9

[Mesa-dev] [PATCH 14/36] st/nine: Handle when cursor stride is not what is expected

2016-12-07 Thread Axel Davy
SetCursor assumes for now a 32x32 argb cursor with pitch 128. 32x32 argb doesn't have pitch 128 on all hw, thus use a temporary surface with the correct pitch when needed. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 20 ++-- src/ga

[Mesa-dev] [PATCH 00/36] Some gallium nine fixes

2016-12-07 Thread Axel Davy
proposed behaviour (which is equivalent to the 'opengl triple buffering'). Axel Davy (36): st/nine: Improve doc of D3DPMISCCAPS_POSTBLENDSRGBCONVERT st/nine: Add validation to SetSamplerState st/nine: Remove useless call to nine_update_state st/nine: Don't update stream_usage_

[Mesa-dev] [PATCH 02/36] st/nine: Add validation to SetSamplerState

2016-12-07 Thread Axel Davy
Check value validity and mimick Win behaviour. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 9 --- src/gallium/state_trackers/nine/nine_limits.h | 36 +++ src/gallium/state_trackers/nine/nine_state.c | 2 ++ src/gallium

[Mesa-dev] [PATCH 16/36] st/nine: Fix leak in user constant upload path

2016-12-07 Thread Axel Davy
The new code properly releases the previous buffers allocated. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c| 22 +++-- src/gallium/state_trackers/nine/nine_state.c | 46 2 files changed, 39 insertions(+), 29 deletions(-) diff

[Mesa-dev] [PATCH 11/36] st/nine: Add missing changed states to pixel stateblocks

2016-12-07 Thread Axel Davy
Some states were not properly recorded in pixel stateblocks. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c

[Mesa-dev] [PATCH 23/36] st/nine: Add new driconf options to control DISCARD behaviour

2016-12-07 Thread Axel Davy
See the patch for the new controls added. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/adapter9.h | 2 ++ src/gallium/state_trackers/nine/swapchain9.c| 4 ++-- src/gallium/targets/d3dadapter9/drm.c | 17 + src/mesa/drivers/dri/common/xmlpool

[Mesa-dev] [PATCH 25/36] st/nine: Ignore MULTISAMPLEMASK when RT is not multisampled

2016-12-07 Thread Axel Davy
We were ignoring MULTISAMPLEMASK for non-maskable multisample modes, but we were missing the non-multisampled case. Fixes a crash in Halo. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 4 ++-- src/gallium/state_trackers/nine/nine_state.c | 2 +- 2 files changed, 3

[Mesa-dev] [PATCH 18/36] st/nine: Silent warnings with guid_str

2016-12-07 Thread Axel Davy
In non-debug build, the variables are unused, and thus trigger a compilation warning. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/iunknown.c | 8 src/gallium/state_trackers/nine/surface9.c | 2 ++ src/gallium/state_trackers/nine/volume9.c | 2 ++ 3 files changed, 12

[Mesa-dev] [PATCH 29/36] st/nine: Fix check for ff specular

2016-12-07 Thread Axel Davy
Fix the check for computing ff specular. This seems to match the opengl behavior, and give the correct output on windows. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 36/36] st/nine: Implement WFOG properly

2016-12-07 Thread Axel Davy
We were advertising support for WFOG (like all win drivers), but we weren't implementing it. This patch implements the behaviour. See comments. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 42 +-- 1 file changed, 35 insertions(

[Mesa-dev] [PATCH 10/36] st/nine: Add some debug info in stateblocks

2016-12-07 Thread Axel Davy
This is useful to check what is exactly recorded. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/stateblock9.c | 5 + 1 file changed, 5 insertions(+) diff --git a/src/gallium/state_trackers/nine/stateblock9.c b/src/gallium/state_trackers/nine/stateblock9.c index a2b281e

[Mesa-dev] [PATCH 27/36] st/nine: Fix ff COLOR0 w component computation

2016-12-07 Thread Axel Davy
The computation was wrong. COLOR0's last component should be equal to the material diffuse w component. The behaviour was checked with a test app on Windows. Wine has the same behaviour. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c

[Mesa-dev] [PATCH 34/36] st/nine: Convert redundant check to assert in ff ps

2016-12-07 Thread Axel Davy
We disable the alpha stage if the color stage is disabled. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_ff.c b/src/gallium/state_trackers/nine/nine_ff.c index

[Mesa-dev] [PATCH 32/36] st/nine: Remove useless code in ff ps

2016-12-07 Thread Axel Davy
Current is already initialized to Diffuse. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 5 - 1 file changed, 5 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_ff.c b/src/gallium/state_trackers/nine/nine_ff.c index 7a09986..c3245a3 100644 --- a

[Mesa-dev] [PATCH 22/36] st/nine: Rework buffer presentation path

2016-12-07 Thread Axel Davy
Use the new API for DISCARD. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/swapchain9.c | 180 --- 1 file changed, 132 insertions(+), 48 deletions(-) diff --git a/src/gallium/state_trackers/nine/swapchain9.c b/src/gallium/state_trackers/nine/swapchain9.c

[Mesa-dev] [PATCH 21/36] st/nine: Fix a leak in Swapchain dtor

2016-12-07 Thread Axel Davy
Count properly the number of backbuffers, and use the new info to release the correct number of buffers Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/swapchain9.c | 31 ++-- src/gallium/state_trackers/nine/swapchain9.h | 1 + 2 files changed, 16

[Mesa-dev] [PATCH 07/36] st/nine: Remove unused ff.changed.group

2016-12-07 Thread Axel Davy
It was unused. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_state.h | 1 - src/gallium/state_trackers/nine/stateblock9.c | 5 - 2 files changed, 6 deletions(-) diff --git a/src/gallium/state_trackers/nine/nine_state.h b/src/gallium/state_trackers/nine/nine_state.h

[Mesa-dev] [PATCH 12/36] st/nine: Capture texturestage states in pixel stateblocks

2016-12-07 Thread Axel Davy
pixels stateblocks need to capture these. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c index 5b4d2ae..8b03e9b

[Mesa-dev] [PATCH 26/36] st/nine: Fix specular enable for alpha

2016-12-07 Thread Axel Davy
Apparently specular enable doesn't affect the alpha channel. Fixes https://github.com/iXit/Mesa-3D/issues/253 Behaviour comfirmed looking in wine sources. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/nine_ff.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --

Re: [Mesa-dev] [PATCH 00/84] Introduce gallium nine internal multithreading

2016-12-07 Thread Axel Davy
On 08/12/2016 00:38, Dieter Nützel wrote: Am 07.12.2016 23:54, schrieb Axel Davy: This patch adds internal multithreading to gallium nine. The goal is to offload almost all gallium nine calls (and some other work) to a worker thread. Hello Axel, really nice job! 'But' show us th

Re: [Mesa-dev] [PATCH 84/84] st/nine: Implement new buffer upload path

2016-12-08 Thread Axel Davy
There seems to be a regression with this patch. I noticed one mistake: nine_upload_create_buffer should initialize buf->resource to NULL. However someone reports crash after GTT memory exhaustion. I can't find the mistake. Anyone ? Axel On 07/12/2016 23:55, Axel Davy wrote: This ne

[Mesa-dev] [PATCH 84/84 v2] st/nine: Implement new buffer upload path

2016-12-11 Thread Axel Davy
This new buffer upload path enables to lock faster than the normal path when using DISCARD/NOOVERWRITE. v2: Diverse cleanups and fixes. Signed-off-by: Axel Davy --- This patch needed a few cleanups, whih this new version adds. With this version, I wasn't able to reproduce the memory leak

[Mesa-dev] [PATCH 84/84 v3] st/nine: Implement new buffer upload path

2016-12-11 Thread Axel Davy
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. Signed-off-by: Axel Davy --- This fixes the reported 'leak' (which wa

[Mesa-dev] [PATCH] st/nine: SYSTEMMEM ignores DISCARD.

2016-12-13 Thread Axel Davy
Tests show SYSTEMMEM should ignore DISCARD. Prevents game bugs with following patches reimplementing DISCARD. Halo is affected. Signed-off-by: Axel Davy --- This patch prevents a regression on radeonsi for Halo (and probably other games) with "st/nine: Implement Fast path for dynamic bu

[Mesa-dev] [PATCH] st/nine: Dirty MANAGED buffers at Lock time

2016-12-13 Thread Axel Davy
Tests suggest MANAGED buffers are made dirty at Lock time, not at Unlock time. Signed-off-by: Axel Davy --- Dirtying MANAGED buffers at Unlock was a requirement of our previous implementation, since we were uploading all dirty MANAGED buffers as soon as a draw call was made. With the CSMT

[Mesa-dev] [PATCH 84/84 v4] st/nine: Implement new buffer upload path

2016-12-13 Thread Axel Davy
e resource content is copied to the new resource used. Signed-off-by: Axel Davy --- Still open for comments. src/gallium/state_trackers/nine/Makefile.sources | 2 + src/gallium/state_trackers/nine/buffer9.c | 90 ++- src/gallium/state_trackers/nine/buffer9.h | 9 +- s

[Mesa-dev] [PATCH 39/84 v2] st/nine: Reimplement nine_context_apply_stateblock

2016-12-15 Thread Axel Davy
The new version uses nine_context functions instead of applying the changes directly to nine_context. This will enable it to work with CSMT. v2: Fix nine_context_light_enable_stateblock. The memcpy arguments were wrong, and the state wasn't set dirty. Signed-off-by: Axel Davy --- src/ga

Re: [Mesa-dev] [PATCH 45/84] st/nine: Pass size of memory to nine_state

2016-12-15 Thread Axel Davy
This patch breaks build because it doesn't replace some calls. The replacements are introduced by the patch after. I suggest to just merge the two patches. I'm not so sure this patch makes sense alone. Axel On 07/12/2016 23:55, Axel Davy wrote: From: Patrick Rudolph Require

[Mesa-dev] [PATCH 03/84 v2] st/nine: Move draw calls to nine_state

2016-12-17 Thread Axel Davy
-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c | 210 -- src/gallium/state_trackers/nine/nine_ff.c | 84 +++ src/gallium/state_trackers/nine/nine_state.c| 278 +--- src/gallium/state_trackers/nine/nine_state.h| 41

[Mesa-dev] [PATCH] st/nine: Call GetPipe for implicit pipe usages

2016-12-18 Thread Axel Davy
With csmt, every usage of the pipe in the main thread has to be protected by calling GetPipe. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/device9.c| 6 ++ src/gallium/state_trackers/nine/swapchain9.c | 2 ++ 2 files changed, 8 insertions(+) diff --git a/src/gallium

[Mesa-dev] [PATCH 57/84 v2] st/nine: Implement Fast path for dynamic buffers and csmt

2016-12-18 Thread Axel Davy
-off-by: Axel Davy --- src/gallium/state_trackers/nine/buffer9.c | 65 ++ src/gallium/state_trackers/nine/buffer9.h | 7 ++- src/gallium/state_trackers/nine/indexbuffer9.c | 2 + 3 files changed, 64 insertions(+), 10 deletions(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 84/84 v5] st/nine: Implement new buffer upload path

2016-12-18 Thread Axel Davy
e 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). Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/Makefile.sources | 2 + src/gallium/state_trackers/nine/buffer9.c | 96 ++

[Mesa-dev] [PATCH 84/84 v6] st/nine: Implement new buffer upload path

2016-12-18 Thread Axel Davy
e 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. Signed-off-by: Axel Davy --- src/gallium/state_tra

[Mesa-dev] [PATCH 2/3] radeon: enable PIPE_CAP_THREAD_SAFE

2016-12-18 Thread Axel Davy
r600 and radeonsi are thread safe. Signed-off-by: Axel Davy --- src/gallium/drivers/r600/r600_pipe.c | 2 +- src/gallium/drivers/radeonsi/si_pipe.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600

<    1   2   3   4   5   6   7   8   9   10   >