[Mesa-dev] [PATCH 5/7] radv: Expose transfer format features.

2017-01-26 Thread Andres Rodriguez
From: Bas Nieuwenhuizen Signed-off-by: Bas Nieuwenhuizen --- src/amd/vulkan/radv_formats.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/src/amd/vulkan/radv_formats.c b/src/amd/vulkan/radv_formats.c index f56f67c..c968cef 100644 --- a/src/amd/vulkan/radv_formats.c +++ b/src/a

[Mesa-dev] [PATCH 3/7] radv: use new error codes for AllocateDescriptorSets

2017-01-26 Thread Andres Rodriguez
There is a new error code in Maintenance1 that is more specific to the situation: VK_ERROR_OUT_OF_POOL_MEMORY_KHR Fixes CTS test case: dEQP-VK.api.descriptor_pool.out_of_pool_memory --- src/amd/vulkan/radv_descriptor_set.c | 2 +- src/amd/vulkan/radv_util.c | 1 + 2 files changed, 2 ins

[Mesa-dev] [PATCH 1/7] radv: add trim command pool stub

2017-01-26 Thread Andres Rodriguez
--- src/amd/vulkan/radv_cmd_buffer.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c index c62d275..0b090b7 100644 --- a/src/amd/vulkan/radv_cmd_buffer.c +++ b/src/amd/vulkan/radv_cmd_buffer.c @@ -1895,6 +1895,13 @@ VkR

[Mesa-dev] [PATCH] radv: drop support for VK_AMD_NEGATIVE_VIEWPORT_HEIGHT

2017-01-26 Thread Andres Rodriguez
This extension was not correctly supported, and it conflicts with the VK_KHR_MAINTENANCE1 spec. --- src/amd/vulkan/radv_device.c | 4 1 file changed, 4 deletions(-) diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c index 7f68cdc..9f05dd6 100644 --- a/src/amd/vulkan/rad

[Mesa-dev] [PATCH] radv/winsys: fix leaking resources from bo's imported by fd

2018-04-30 Thread Andres Rodriguez
A bo's ref_count was not being initialized when imported from an fd. Therefore, we would fail to free the resource during VkFreeMemory(). This patch fixes applications like hifi VR in threaded mode, which perform frequent imports/releases of IPC shared memory. Signed-off-by: Andres Rodrigue

[Mesa-dev] [PATCH] radv: disable DCC for shareable images on GFX9+

2018-05-09 Thread Andres Rodriguez
This seems to be broken at the moment for opengl interop. Which is used by steamvr opengl applications. --- Not sure if we want to merge this or not. It fixes steamvr opengl applications on vega, but the proper solution is probably in some metadata bug. Mailing it out mostly as an awareness noti

Re: [Mesa-dev] [PATCH] radv: drop wrong initialization of COMPUTE_RESOURCE_LIMITS

2018-08-21 Thread Andres Rodriguez
On 2018-08-21 01:54 PM, Marek Olšák wrote: Note that WAVES_PER_SH should be 0x3ff on the compute ring for the ring priorities to be applied. Correct, we would need to set WAVES_PER_SH during pipeline creation. I don't know if you need to do the same thing for the gfx ring. You can ask Andre

[Mesa-dev] [PATCH] radv: only emit ZPASS_DONE for timestamp queries on gfx queues

2018-09-24 Thread Andres Rodriguez
A ZPASS_DONE packet doesn't make sense for the compute queue. It will result in a gpu hang. This change resolves a gpu hang for SteamVR+Vega. Cc: mesa-sta...@lists.freedesktop.org Fixes: 1f616a840eac02241c585d28e9dac8f19a297f39 "radv: emit a dummy ..." Signed-off-by: Andres Rodr

Re: [Mesa-dev] [PATCH 0/5] nir, spirv: Fix bugs uncovered by spirv-opt

2018-09-27 Thread Andres Rodriguez
This series fixes the assert I was encountering with SteamVR here: https://bugs.freedesktop.org/show_bug.cgi?id=108065 Thanks for the fixes. -Andres On 2018-09-22 05:39 PM, Jason Ekstrand wrote: This little series fixes three bugs encountered while running the Vulkan CTS with SPIR-V optimizat

[Mesa-dev] [PATCH 00/20] Add support for GL_EXT_semaphore v3

2018-01-23 Thread Andres Rodriguez
Rebased on latest mesa and dropped the gallium fence->semaphore rename. Andres Rodriguez (20): gallium: add type parameter to create_fence_fd gallium: introduce PIPE_CAP_SEMAPHORE_SIGNAL gallium: introduce PIPE_FD_TYPE_SYNCOBJ gallium: add fence_server_signal() u_threaded_context:

[Mesa-dev] [PATCH 06/20] mesa/st: introduce EXT_semaphore and EXT_semaphore_fd v2

2018-01-23 Thread Andres Rodriguez
Guarded by PIPE_CAP_SEMAPHORE_SIGNAL v2: corresponding changes for PIPE_CAP_SEMAPHORE_SIGNAL rename Signed-off-by: Andres Rodriguez --- src/mesa/main/extensions_table.h | 2 ++ src/mesa/main/mtypes.h | 2 ++ src/mesa/state_tracker/st_extensions.c | 2 ++ 3 files changed

[Mesa-dev] [PATCH 02/20] gallium: introduce PIPE_CAP_SEMAPHORE_SIGNAL

2018-01-23 Thread Andres Rodriguez
Protects semaphore signaling functionality required by GL_EXT_semaphore. Signed-off-by: Andres Rodriguez --- src/gallium/docs/source/screen.rst | 2 ++ src/gallium/drivers/etnaviv/etnaviv_screen.c | 1 + src/gallium/drivers/freedreno/freedreno_screen.c | 1 + src/gallium

[Mesa-dev] [PATCH 03/20] gallium: introduce PIPE_FD_TYPE_SYNCOBJ

2018-01-23 Thread Andres Rodriguez
Denotes that a fd is backed by a synobj. For example, radv shared semaphores. Signed-off-by: Andres Rodriguez --- src/gallium/include/pipe/p_defines.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h index

[Mesa-dev] [PATCH 01/20] gallium: add type parameter to create_fence_fd

2018-01-23 Thread Andres Rodriguez
An fd can potentially have different types of objects backing it. Specifying the type helps us make sure we treat the FD correctly. This is in preparation to allow importing syncobj fence FDs in addition to native sync FDs. Signed-off-by: Andres Rodriguez --- src/gallium/auxiliary/util

[Mesa-dev] [PATCH 07/20] mesa: add support for semaphore object creation/import/delete v3

2018-01-23 Thread Andres Rodriguez
Used by EXT_semmaphore and EXT_semaphore_fd v2: Removed unnecessary dummy callback initialization v3: Fixed attempting to free the DummySemaphoreObject Signed-off-by: Andres Rodriguez --- src/mesa/main/dd.h | 34 ++ src/mesa/main/externalobjects.c | 134

[Mesa-dev] [PATCH 08/20] mesa/st: add support for semaphore object create/import/delete v2

2018-01-23 Thread Andres Rodriguez
Add basic semaphore object operations. v2: s/semaphore/fence for pipe objects Signed-off-by: Andres Rodriguez --- src/mesa/Makefile.sources | 2 + src/mesa/meson.build| 2 + src/mesa/state_tracker/st_cb_semaphoreobjects.c | 55

[Mesa-dev] [PATCH 09/20] mesa: add semaphore parameter stub v2

2018-01-23 Thread Andres Rodriguez
EXT_semaphore and EXT_semaphore_fd define no pnames. Therefore there isn't much to do besides determining the correct error code. v2: removed useless return Signed-off-by: Andres Rodriguez --- src/mesa/main/externalobjects.c | 22 ++ 1 file changed, 22 insertions(+)

[Mesa-dev] [PATCH 12/20] mesa: implement buffer/texture barriers for semaphore signal/wait v2

2018-01-23 Thread Andres Rodriguez
Make sure memory is accessible to the external client, for the specified memory object, before the signal/after the wait. v2: fixed flush order with respect to wait/signal emission Signed-off-by: Andres Rodriguez --- src/mesa/main/dd.h | 14 ++- src/mesa/main

[Mesa-dev] [PATCH 10/20] mesa: add support for semaphore object signal/wait v2

2018-01-23 Thread Andres Rodriguez
Memory synchronization is left for a future patch. v2: flush vertices/bitmaps moved to mesa/main Signed-off-by: Andres Rodriguez --- src/mesa/main/dd.h | 14 ++ src/mesa/main/externalobjects.c | 38 ++ 2 files changed, 52 insertions

[Mesa-dev] [PATCH 04/20] gallium: add fence_server_signal()

2018-01-23 Thread Andres Rodriguez
Calling this function will emit a fence signal operation into the GPU's command stream. Signed-off-by: Andres Rodriguez --- src/gallium/docs/source/context.rst | 31 +++ src/gallium/include/pipe/p_context.h | 6 ++ 2 files changed, 37 insertions(+) diff

[Mesa-dev] [PATCH 15/20] radeonsi: implement semaphore_server_signal v2

2018-01-23 Thread Andres Rodriguez
Syncobj based waits or signals only happen at submission boundaries. In order to guarantee that the requested signal event will occur when the state tracker requested it, we must issue a flush. v2: s/fence/semaphore for pipe objects Signed-off-by: Andres Rodriguez --- src/gallium/drivers

[Mesa-dev] [PATCH 14/20] radeonsi: add support for importing PIPE_FD_TYPE_SYNCOBJ semaphores

2018-01-23 Thread Andres Rodriguez
Hook up importing semaphores of type PIPE_FD_TYPE_SYNCOBJ Signed-off-by: Andres Rodriguez --- src/gallium/drivers/radeonsi/si_fence.c | 26 -- 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_fence.c b/src/gallium/drivers

[Mesa-dev] [PATCH 05/20] u_threaded_context: add support for fence_server_signal v2

2018-01-23 Thread Andres Rodriguez
v2: s/semaphore/fence Signed-off-by: Andres Rodriguez --- src/gallium/auxiliary/util/u_threaded_context.c | 20 .../auxiliary/util/u_threaded_context_calls.h| 1 + 2 files changed, 21 insertions(+) diff --git a/src/gallium/auxiliary/util/u_threaded_context.c

[Mesa-dev] [PATCH 17/20] radeonsi: advertise support for GL_EXT_semaphore

2018-01-23 Thread Andres Rodriguez
Expose the feature only when we have syncobj support available Signed-off-by: Andres Rodriguez --- src/gallium/drivers/radeonsi/si_get.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeonsi/si_get.c b/src/gallium/drivers/radeonsi/si_get.c index

[Mesa-dev] [PATCH 11/20] mesa/st: add support for semaphore object signal/wait v3

2018-01-23 Thread Andres Rodriguez
Bits to implement ServerWaitSemaphoreObject/ServerSignalSemaphoreObject v2: - corresponding changes for gallium fence->semaphore rename - flushing moved to mesa/main v3: s/semaphore/fence for pipe objects Signed-off-by: Andres Rodriguez --- src/mesa/state_tracker/st_cb_semaphoreobject

[Mesa-dev] [PATCH 16/20] radeonsi: fix fence_server_sync() holding up extra work v2

2018-01-23 Thread Andres Rodriguez
fence dependency. v2: s/semaphore/fence Signed-off-by: Andres Rodriguez --- src/gallium/drivers/radeonsi/si_fence.c | 49 + 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_fence.c b/src/gallium/drivers/radeonsi

[Mesa-dev] [PATCH 18/20] mesa: fix error codes for importing memory/semaphore FDs

2018-01-23 Thread Andres Rodriguez
This fixes the following piglit tests: spec/ext_semaphore_fd/api-errors/import-semaphore-fd-bad-enum spec/ext_memory_object_fd/api-errors/import-memory-fd-bad-enum Signed-off-by: Andres Rodriguez --- src/mesa/main/externalobjects.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

[Mesa-dev] [PATCH 13/20] winsys/amdgpu: add support for syncobj signaling v3

2018-01-23 Thread Andres Rodriguez
Add the ability to signal a syncobj when a cs completes execution. v2: corresponding changes for gallium fence->semaphore rename v3: s/semaphore/fence for pipe objects Signed-off-by: Andres Rodriguez --- src/gallium/drivers/radeon/radeon_winsys.h | 12 + src/gallium/winsys/amdgpu/

[Mesa-dev] [PATCH 20/20] mesa: check for invalid index on UUID glGet queries

2018-01-23 Thread Andres Rodriguez
This fixes the piglit test: spec/ext_semaphore/api-errors/usigned-byte-i-v-bad-value Signed-off-by: Andres Rodriguez --- src/mesa/main/get.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/main/get.c b/src/mesa/main/get.c index 34970b8e16..302cece3ef 100644 --- a/src/mesa/main

[Mesa-dev] [PATCH 19/20] mesa: fix glGet for ext_external_objects parameters

2018-01-23 Thread Andres Rodriguez
This allows the client to actually query the enums specified in the ext_external_objects spec. Signed-off-by: Andres Rodriguez --- src/mesa/main/get.c | 3 +++ src/mesa/main/get_hash_params.py | 5 + 2 files changed, 8 insertions(+) diff --git a/src/mesa/main/get.c b/src/mesa

Re: [Mesa-dev] [PATCH 00/20] Add support for GL_EXT_semaphore v3

2018-01-23 Thread Andres Rodriguez
On 2018-01-23 01:04 PM, Andres Rodriguez wrote: Rebased on latest mesa and dropped the gallium fence->semaphore rename. There is also a new bugfix on patch 7. See v3 notes there. Andres Rodriguez (20): gallium: add type parameter to create_fence_fd gallium: introd

[Mesa-dev] [PATCH] Revert "radv: Initialize DCC on transition from preinitialized."

2018-01-23 Thread Andres Rodriguez
nsfer dest." Signed-off-by: Andres Rodriguez --- src/amd/vulkan/radv_cmd_buffer.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c index 172f95e7c9..67799a13cc 100644 --- a/src/amd/vulkan/radv_cmd_buff

[Mesa-dev] [PATCH 10/20] mesa: add support for semaphore object signal/wait v3

2018-01-23 Thread Andres Rodriguez
Memory synchronization is left for a future patch. v2: flush vertices/bitmaps moved to mesa/main v3: removed spaces before/after braces Signed-off-by: Andres Rodriguez --- src/mesa/main/dd.h | 14 ++ src/mesa/main/externalobjects.c | 38

Re: [Mesa-dev] [PATCH 00/20] Add support for GL_EXT_semaphore v3

2018-01-23 Thread Andres Rodriguez
Also, the associated piglit patches: https://lists.freedesktop.org/archives/piglit/2017-December/023600.html On 2018-01-23 01:13 PM, Andres Rodriguez wrote: On 2018-01-23 01:04 PM, Andres Rodriguez wrote: Rebased on latest mesa and dropped the gallium fence->semaphore rename. There

Re: [Mesa-dev] [PATCH] mesa: fix incorrect size/error test in _mesa_GetUnsignedBytevEXT()

2018-01-29 Thread Andres Rodriguez
Reviewed-by: Andres Rodriguez Thanks. On 2018-01-29 04:42 PM, Brian Paul wrote: get_value_size() returns -1 for an error. The similar check in _mesa_GetUnsignedBytei_vEXT() is correct. Found by chance. There are apparently no Piglit tests which exercise glGetUnsignedBytei_vEXT() or

Re: [Mesa-dev] [PATCH 00/20] Add support for GL_EXT_semaphore v3

2018-01-30 Thread Andres Rodriguez
On 2018-01-29 02:02 PM, Marek Olšák wrote: On Tue, Jan 23, 2018 at 10:16 PM, Andres Rodriguez wrote: Also, the associated piglit patches: https://lists.freedesktop.org/archives/piglit/2017-December/023600.html You can just push the piglit patches if you get no review there. Thanks for

[Mesa-dev] [PATCH] docs/features: mark EXT_semaphore(_fd) as DONE

2018-01-30 Thread Andres Rodriguez
Support for these extensions is available in radeonsi. Signed-off-by: Andres Rodriguez --- docs/features.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/features.txt b/docs/features.txt index 2e110d9994..1672460a2f 100644 --- a/docs/features.txt +++ b/docs

[Mesa-dev] [PATCH] docs/features: mark EXT_semaphore(_fd) as DONE v2

2018-01-31 Thread Andres Rodriguez
Support for these extensions is available in radeonsi. v2: also updated relnotes Signed-off-by: Andres Rodriguez --- Let me know if the formatting for the relnotes is what is expected. I based it on the previous versions. docs/features.txt | 4 ++-- docs/relnotes/18.1.0.html | 3

[Mesa-dev] [PATCH] mesa: remove usage of alloca in externalobjects.c

2018-01-31 Thread Andres Rodriguez
Don't want an overly large numBufferBarriers/numTextureBarriers to blow up the stack. Suggested-by: Emil Velikov Signed-off-by: Andres Rodriguez --- src/mesa/main/externalobjects.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/mesa

[Mesa-dev] [PATCH] mesa: remove usage of alloca in externalobjects.c v2

2018-01-31 Thread Andres Rodriguez
Don't want an overly large numBufferBarriers/numTextureBarriers to blow up the stack. v2: handle malloc errors Suggested-by: Emil Velikov Signed-off-by: Andres Rodriguez --- src/mesa/main/externalobjects.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git

Re: [Mesa-dev] [PATCH] mesa: remove usage of alloca in externalobjects.c v2

2018-01-31 Thread Andres Rodriguez
On 2018-01-31 01:25 PM, Andres Rodriguez wrote: Don't want an overly large numBufferBarriers/numTextureBarriers to blow up the stack. v2: handle malloc errors Someone forgot to update his patch correctly before sending it out... Suggested-by: Emil Velikov Signed-off-by: Andres Rodr

[Mesa-dev] [PATCH] mesa: remove usage of alloca in externalobjects.c v3

2018-01-31 Thread Andres Rodriguez
Don't want an overly large numBufferBarriers/numTextureBarriers to blow up the stack. v2: handle malloc errors v3: fix patch Suggested-by: Emil Velikov Signed-off-by: Andres Rodriguez --- src/mesa/main/externalobjects.c | 48 +++-- 1 file change

Re: [Mesa-dev] [PATCH] mesa: remove usage of alloca in externalobjects.c v3

2018-02-01 Thread Andres Rodriguez
On 2018-02-01 08:24 AM, Emil Velikov wrote: On 31 January 2018 at 19:03, Andres Rodriguez wrote: Don't want an overly large numBufferBarriers/numTextureBarriers to blow up the stack. v2: handle malloc errors v3: fix patch Suggested-by: Emil Velikov Signed-off-by: Andres Rodr

[Mesa-dev] [PATCH] mesa: fix incorrect type when allocating arrays

2018-02-07 Thread Andres Rodriguez
The array members are have type 'struct gl_buffer_object *' Found by coverity. Signed-off-by: Andres Rodriguez --- I think this should fix the issue, if I'm interpreting the coverity message correctly. src/mesa/main/externalobjects.c | 8 1 file changed, 4 i

Re: [Mesa-dev] [PATCH] mesa: fix incorrect type when allocating arrays

2018-02-07 Thread Andres Rodriguez
Pushed, thanks for the report. On 2018-02-07 02:47 PM, Matt Turner wrote: On Wed, Feb 7, 2018 at 11:46 AM, Andres Rodriguez wrote: The array members are have type 'struct gl_buffer_object *' Found by coverity. Signed-off-by: Andres Rodriguez --- I think this should fix the iss

[Mesa-dev] [PATCH] radv: fix check for perftest options size

2018-10-18 Thread Andres Rodriguez
It was using the debug options array size. CC: mesa-sta...@lists.freedesktop.org Reviewed-by: Bas Nieuwenhuizen --- src/amd/vulkan/radv_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c index 429d47325a3..976c

[Mesa-dev] [PATCH] radv: fix wmaybe-uninitialized in radv_meta_fast_clear.c

2018-07-18 Thread Andres Rodriguez
Assignment and usage of this variable both happen inside an if(rad_image_has_dcc()) {} blocks. It seems gcc plays it safe and assumes that both function calls could have different return values. But in this case we should be safe. --- src/amd/vulkan/radv_meta_fast_clear.c | 2 +- 1 file changed,

[Mesa-dev] [PATCH] radv: fix wmaybe-uninitialized in radv_meta_fast_clear.c

2018-07-18 Thread Andres Rodriguez
Assignment and usage of this variable both happen inside an if(rad_image_has_dcc()) {} blocks. It seems gcc plays it safe and assumes that both function calls could have different return values. But in this case we should be safe. --- src/amd/vulkan/radv_meta_fast_clear.c | 2 +- 1 file changed,

<    1   2   3