Commit Graph

155503 Commits

Author SHA1 Message Date
Erik Faye-Lund 2c43044507 vulkan/util: assume c11
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16908>
2022-06-14 15:08:37 +00:00
Erik Faye-Lund ec9d7872ac glcpp: remove outdated msvc hack
While MSVC doesn't do __STDC_VERSION__ correctly for C99, it does for
C11, which is what we now require. So we can remove this hack.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16908>
2022-06-14 15:08:37 +00:00
Erik Faye-Lund 3a62badb2e util: use c11 alignof instead of our own
...with an exception for MSVC, which doesn't have stdalign.h, so let's
add a definition for that.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16908>
2022-06-14 15:08:37 +00:00
Erik Faye-Lund e83f13c04e c99_compat.h: assume c99 support
Reviewed-By: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16908>
2022-06-14 15:08:37 +00:00
Erik Faye-Lund ffd26b1c3b llvmpipe: assume c99
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16908>
2022-06-14 15:08:37 +00:00
Erik Faye-Lund 5dc30f9342 util: sort includes
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16908>
2022-06-14 15:08:37 +00:00
Erik Faye-Lund 7c864499eb dzn: enable two more exts
These are already implemented, so let's turn them on!

Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17027>
2022-06-14 14:55:27 +00:00
Erik Faye-Lund b45f1e24ae dzn: use a null-rtv to handle no-attachment
This fixes a crash in this test:
dEQP-VK.renderpass2.suballocation.simple.color_unused_omit_blend_state

Fixes: 2d0798440b ("dzn: Add support for dynamic rendering")
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17027>
2022-06-14 14:55:27 +00:00
Boris Brezillon bd4c8f562c microsoft/compiler: Truncate function names when needed
DXIL metadata strings and function names have a limited size. Truncate
the name when they don't fit. This is a quick&dirty workaround since it
doesn't address the problem for all kind of strings, and doesn't ensure
there's no collision in the function names after the truncation. That's
not an issue right now because I don't think we have implementations
keeping more than one function (the entrypoint), but it might be a
problem at some point.

Acked-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16961>
2022-06-14 14:15:55 +00:00
Boris Brezillon 69339066fc microsoft/compiler: Pick a type that matches interpolation mode for structs
We can't use linear interpolation on integer types, and varyings using
a struct type might actually contain only fp32 members, in which case
interpolation should happen as requested.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16961>
2022-06-14 14:15:55 +00:00
Alejandro Piñeiro 51bdac4846 v3dv/pipeline: expand nir_optimize, drop st_nir_opts
Right now we had two methods that tries to optimize the nir shader,
nir_optimize and st_nir_opts. The latter is being used when we are
linking, but again, it has basically the same purpose that
nir_optimize.

So this commit adds more lowerings to nir_optimize_nir, add some extra
comments on the method, and replaces st_nir_opts with nir_optimize.

Ideally we would like to just use the already existing
v3d_optimize_nir that we have at the backend But:
   * Using it leads to some regressions on Vulkan CTS tests, due some
     lowerings that are already there.
   * We would need to move to the backend some additional
     lowerings/optimizations that are used on the Vulkan
     frontend. That would require to check that we are not getting any
     regression or performance drop on OpenGL

So for now we are keeping a Vulkan specific nir_optimize method.

Additionally this fixes the following test:
dEQP-VK.graphicsfuzz.cov-loop-condition-clamp-vec-of-ones

Shaderdb stats, using some well known Vulkan apps (ue4 demos, Quake3e,
etc):

 total instructions in shared programs: 124974 -> 125108 (0.11%)
 instructions in affected programs: 50328 -> 50462 (0.27%)
 helped: 4
 HURT: 79

 total uniforms in shared programs: 19019 -> 19020 (<.01%)
 uniforms in affected programs: 60 -> 61 (1.67%)
 helped: 0
 HURT: 1

 total max-temps in shared programs: 13438 -> 13444 (0.04%)
 max-temps in affected programs: 85 -> 91 (7.06%)
 helped: 0
 HURT: 2

 total inst-and-stalls in shared programs: 125715 -> 125849 (0.11%)
 inst-and-stalls in affected programs: 50429 -> 50563 (0.27%)
 helped: 4
 HURT: 79

 total nops in shared programs: 8203 -> 8204 (0.01%)
 nops in affected programs: 732 -> 733 (0.14%)
 helped: 7
 HURT: 9

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16986>
2022-06-14 13:12:46 +00:00
Alejandro Piñeiro 36c547342a v3dv/pipeline: call nir_lower_explicit_io after first nir optimization loop
That is what most others Vulkan drivers do (radv, anv, turnip at
least).

The origin of this change cames from a CTS test where the loop
unrolling converted a ubo index defined inside a loop from constant to
non constant. That is not desiderable on any driver, but a problem on
v3dv, as v3dv doesn't support that case.

Although we initially tried to fix it on the loop unroll, we discarded
that approach, and focused on the existing nir lowerings/optimizations
as this was not happening with other drivers.

We noted that in other drivers this case of a ubo index going from
const to non-const were also happening with nir_lower_explicit_io, but
in that case it was able to be converted back to a const on following
lowerings. The only difference with other drivers is that we were
calling it before the first nir optimization loop.

So this change helps with fixing the following CTS test (for that we
also need to run additional lowerings, which we do in a later patch):
   dEQP-VK.graphicsfuzz.cov-loop-condition-clamp-vec-of-ones

You can get further details on the following issue and RFC merge
request, specially the merge request:
  https://gitlab.freedesktop.org/mesa/mesa/-/issues/6051
  https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15391

We also made some shaderdb stats with our usual Vulkan apps (ue4
demos, quake3, etc):

 Total instructions in shared programs: 125014 -> 124974 (-0.03%)
 instructions in affected programs: 7544 -> 7504 (-0.53%)
 helped: 7
 HURT: 4

 total uniforms in shared programs: 19026 -> 19019 (-0.04%)
 uniforms in affected programs: 514 -> 507 (-1.36%)
 helped: 5
 HURT: 0

 total max-temps in shared programs: 13430 -> 13438 (0.06%)
 max-temps in affected programs: 270 -> 278 (2.96%)
 helped: 0
 HURT: 8

 total sfu-stalls in shared programs: 739 -> 741 (0.27%)
 sfu-stalls in affected programs: 30 -> 32 (6.67%)
 helped: 0
 HURT: 2

 total inst-and-stalls in shared programs: 125753 -> 125715 (-0.03%)
 inst-and-stalls in affected programs: 7685 -> 7647 (-0.49%)
 helped: 7
 HURT: 4

 total nops in shared programs: 8228 -> 8203 (-0.30%)
 nops in affected programs: 546 -> 521 (-4.58%)
 helped: 9
 HURT: 2

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16986>
2022-06-14 13:12:46 +00:00
Alejandro Piñeiro 481df13f27 nir: get res binding using component 0, instead of asssumig an uint
Needed to be able to call nir_opt_gcm on the v3dv driver. This change
is needed as on v3dv we honor vulkan resource index returning a vec2.

See commit 21b0a4c80c for more info.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16986>
2022-06-14 13:12:46 +00:00
Christian Gmeiner d364d445ad isaspec: Handle patterns bigger then 64 bit
Currently uint64_t_to_bitmask(..) is used in combination with
the pattern 'match'. This only works for values smaller then
64 bit. Add support for bigger isa sizes.

Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16996>
2022-06-14 12:35:39 +00:00
Christian Gmeiner 119d8488dd isaspec: Extend split_bits(..) to accept a bitsize
Make split_bits(..) more generic.

Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16996>
2022-06-14 12:35:39 +00:00
David Heidelberg 96f0944a69 ci/panfrost: add Blender, Warzone2100, Freedoom and Unvanquished traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg 2f474462f9 ci/crocus: add Blender, Warzone2100, Freedoom and Unvanquished traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg df298cff15 ci/virgl: iris: disable Counter Strike 1.6 trace flaking
Changes very often, but does look correct.

Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg bb1af12b8a ci/virgl: add Blender, Warzone2100, Freedoom and Unvanquished traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg f58168850f ci/iris: add Blender, Warzone2100, Freedoom and Unvanquished traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg de9378e701 ci/llvmpipe: add Blender, Warzone2100, Freedoom and Unvanquished traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg a7f7f2a1dd ci/freedreno: fix A530 glmark2@ideas:speed=10000 trace
Just one-pixel change in rendering, look correct to me.

Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
David Heidelberg e8cf79f664 ci/freedreno: add Blender, Warzone2100, Freedoom and Unvanquished traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16909>
2022-06-14 11:52:45 +00:00
Iago Toral Quiroga 4a7446e4e4 v3dv: handle barriers at the end of a command buffer
Since we only consume barriers at the beginning of a new job, if
a command buffer ends with a barrier we will not handle it. Fix
this by emitting a noop job  in that case to consume it. Ideally,
we could do better and check the pending barrier state to fine
tune the noop job so we don't wait on all queues, but for now
this fixes flakyness with some CTS pipeline barrier tests that
started to show up after we optimized binning sync barriers. It
is likely that the additional sync we had before that change was
enough to prevent the problem from showing up.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17020>
2022-06-14 11:30:33 +00:00
Iago Toral Quiroga d6702b99a2 v3dv: merge pending secondary barrier state into primary command buffers
When we switched to using structs to track barrier state we made a mistake
and started to overwrite barrier state in primary command buffers with
the pending state from secondary command buffers executed inside them, when we
should've been merging the state instead.

Fixes flakyness with some CTS barrier tests.

Fixes: f7ce42636c ('v3dv: use an explicit struct type to track barrier state')
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17020>
2022-06-14 11:30:33 +00:00
Iago Toral Quiroga a97f78eb14 broadcom/compiler: disable flags optimization for loop conditions
This is not safe because it may skip regenerating the flags for the
loop condition in the loop continue block and these flags may be
stomped in the loop body by other conditionals.

Fixes: 9909fe6ba ('broadcom/compiler: Skip bool_to_cond where possible')
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17020>
2022-06-14 11:30:33 +00:00
David Heidelberg 2b0e45b18e ci/etnaviv: gc2000: drop flakes from fails
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Signed-off-by: David Heidelberg <david@ixit.cz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17003>
2022-06-14 11:23:57 +00:00
David Heidelberg 93173a3a58 ci/etnaviv: add recent flakes for gc2000
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Signed-off-by: David Heidelberg <david@ixit.cz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17003>
2022-06-14 11:23:56 +00:00
David Heidelberg 7596c6d34e ci/etnaviv: disable tests which takes too long
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Signed-off-by: David Heidelberg <david@ixit.cz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17003>
2022-06-14 11:23:56 +00:00
David Heidelberg b02c88680e ci/etnaviv: add recent fails and remove 3 unexpected passes
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Signed-off-by: David Heidelberg <david@ixit.cz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17003>
2022-06-14 11:23:56 +00:00
David Heidelberg 016f9e89d4 ci/etnaviv: sort fails.txt
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Signed-off-by: David Heidelberg <david@ixit.cz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17003>
2022-06-14 11:23:56 +00:00
Erik Faye-Lund 4ab49e2530 dzn: handle stencil-attachment-optimal layout
We missed this one, whoops.

Fixes: a012b21964 ("microsoft: Initial vulkan-on-12 driver")
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16997>
2022-06-14 10:35:59 +00:00
Erik Faye-Lund 7dc5255469 dzn: correct assert-condition
This logic accidentally got flipped in a refactoring. Let's correct it!

Fixes: e293691a99 ("dzn: Get rid of the render pass logic")
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16997>
2022-06-14 10:35:59 +00:00
Martin Roukala (né Peres) 427c34eeca ci/valve: do not extract the install tarball on the runner
Until now, we have been extracing the install.tar image on the gitlab
runner before sharing it to the test machine through a MINIO bucket.

It turns out that hardlinks and symlinks do not get shared, so let's
just extract the tarball directly on the test machine to fix the issue.

Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16968>
2022-06-14 06:51:59 +00:00
Samuel Pitoiset cee1142fa3 ci: bump the hang-detection tool in the test image for Vulkan
I recently fixed one issue that triggered an assertion in the
Vulkan common code. This was because the tool allocated cmdbuf
from the wrong pool (in presence of multiple queues).

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Martin Roukala <martin.roukala@mupuf.org>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17002>
2022-06-14 08:02:37 +02:00
Pavel Ondračka fa645861af r300: expose PIPE_CAP_LEGACY_MATH_RULES
We are already doing the 0*anything = 0 by default and we are also
using the DX versions of math ops like RCP. It looks like R300 and
R400 can't do IEEE math anyway (but its hard to tell without docs).
For R500 we can do IEEE math, but testing showed that some apps
are dependent on the DX behavior, so considering we only advertise
GLSL 1.20 where this is left ot the driver, just keep the curent
status and expose PIPE_CAP_LEGACY_MATH_RULES so that nine can stop
emiting math workarounds.

Also fixes two Xnine tests.

Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17007>
2022-06-14 06:07:11 +00:00
Mike Blumenkrantz fbcf65bfea anv: VK_EXT_border_color_swizzle
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16992>
2022-06-14 01:52:50 +00:00
Mike Blumenkrantz efa58f6b47 lavapipe: VK_EXT_border_color_swizzle
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16992>
2022-06-14 01:52:50 +00:00
Marek Olšák 4c5f7b86ec gallium/u_threaded: fix buffer busyness tracking
The order of calls was incorrect.

Fixes: e9c41b3214 - gallium/u_threaded: add buffer lists - tracking of buffers referenced by tc
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5327

Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-By: Jonathan Strobl <jonathan.strobl@gmx.de>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16989>
2022-06-14 01:25:27 +00:00
Jason Ekstrand ce60195ecd anv: Use NIR_PASS(_, ...)
I don't know when this was added but it's really neat and we should use
it instead of NIR_PASS_V since NIR_DEBUG=print and a few validation
things will work better.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17014>
2022-06-13 22:31:25 +00:00
Jason Ekstrand 844a70f439 intel/compiler: Use NIR_PASS(_, ...)
I don't know when this was added but it's really neat and we should use
it instead of NIR_PASS_V since NIR_DEBUG=print and a few validation
things will work better.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17014>
2022-06-13 22:31:25 +00:00
David Heidelberg 65bafa2a35 ci: uprev piglit 2022-06-09
Reviewed-by: Emma Anholt <emma@anholt.net>
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16946>
2022-06-13 22:45:19 +02:00
Mike Blumenkrantz 399104f049 zink: fix up KILL to a more sensible log message
cc: mesa-stable

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17009>
2022-06-13 15:20:25 -04:00
Mike Blumenkrantz 23892bff6b zink: unset res->swapchain upon killing a swapchain
this otherwise causes the driver to make bad assumptions about
how the resource should be handled

cc: mesa-stable

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17009>
2022-06-13 15:20:25 -04:00
Mike Blumenkrantz ea9e30f9d2 zink: add implicit sync workaround for non-mesa drivers
implicit sync is hard, and many drivers get it wrong, so assume that
anyone who isn't mesa might need some hand-holding

cc: mesa-stable

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17009>
2022-06-13 15:20:21 -04:00
Renato Pereyra 2ef6b0aab1 Revert "wsi/x11: Avoid using xcb_wait_for_special_event in FIFO modes"
This reverts commit 44a20baeb8.

Signed-off-by: Renato Pereyra <renatopereyra@chromium.org>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16954>
2022-06-13 17:58:46 +00:00
Renato Pereyra ee587f202e Revert "wsi/x11: Don't leak xcb_get_geometry_reply_t."
This reverts commit 24049b8771.

Signed-off-by: Renato Pereyra <renatopereyra@chromium.org>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16954>
2022-06-13 17:58:46 +00:00
Mike Blumenkrantz 4bee678df3 zink: defer old swapchain destruction
ensure that swapchains that are about to be presented asynchronously
cannot be destroyed

Fixes: 8ade5588e3 ("zink: add kopper api")

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16932>
2022-06-13 17:44:27 +00:00
Mike Blumenkrantz 1dfa19c541 zink: keep a count of async presents occuring for a given swapchain
this provides info about whether a swapchain is in use in another thread

Fixes: 8ade5588e3 ("zink: add kopper api")

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16932>
2022-06-13 17:44:27 +00:00
Mike Blumenkrantz 892f42271f zink: use separate pointer for swapchain presents
this ensures that the same pointer is being accessed from the present
thread as was intended when the present was queued

Fixes: 8ade5588e3 ("zink: add kopper api")

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16932>
2022-06-13 17:44:27 +00:00