platform/upstream/mesa.git
19 months agoradv: Clean up emitting zero mesh shader draw id.
Timur Kristóf [Mon, 27 Mar 2023 23:07:39 +0000 (01:07 +0200)]
radv: Clean up emitting zero mesh shader draw id.

When task shaders are also used,
the draw id is undefined in mesh shaders.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22139>

19 months agoradv: Remove first_task and ib_addr/ib_stride.
Timur Kristóf [Mon, 27 Mar 2023 14:23:53 +0000 (16:23 +0200)]
radv: Remove first_task and ib_addr/ib_stride.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22139>

19 months agoradv: Remove NV_mesh_shader API entrypoints.
Timur Kristóf [Mon, 27 Mar 2023 14:09:08 +0000 (16:09 +0200)]
radv: Remove NV_mesh_shader API entrypoints.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22139>

19 months agoradv: Don't expose NV_mesh_shader and don't use it in CI.
Timur Kristóf [Mon, 27 Mar 2023 13:38:47 +0000 (15:38 +0200)]
radv: Don't expose NV_mesh_shader and don't use it in CI.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22139>

19 months agoiris: implement recommended flush/wait of AUX-TT invalidation
Lionel Landwerlin [Wed, 29 Mar 2023 08:12:01 +0000 (11:12 +0300)]
iris: implement recommended flush/wait of AUX-TT invalidation

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22183>

19 months agoanv: implement recommended flush/wait of AUX-TT invalidation
Lionel Landwerlin [Wed, 29 Mar 2023 08:06:13 +0000 (11:06 +0300)]
anv: implement recommended flush/wait of AUX-TT invalidation

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22183>

19 months agopvr: Mark all normalized formats as supporting with_packed_usc_channel
Jarred Davies [Mon, 6 Mar 2023 00:15:05 +0000 (00:15 +0000)]
pvr: Mark all normalized formats as supporting with_packed_usc_channel

Avoids assert seen in dEQP-VK.api.smoke.triangle

Signed-off-by: Jarred Davies <jarred.davies@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22174>

19 months agodocs: drop reference to modindex
Erik Faye-Lund [Mon, 20 Mar 2023 10:02:55 +0000 (11:02 +0100)]
docs: drop reference to modindex

We don't render such a page, so there's no point in linking to it.

Acked-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22022>

19 months agoradv: replace pipeline->force_vrs_per_vertex during cmdbuf recording
Samuel Pitoiset [Wed, 22 Mar 2023 16:48:02 +0000 (17:48 +0100)]
radv: replace pipeline->force_vrs_per_vertex during cmdbuf recording

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: replace pipeline->is_ngg occurrences during cmdbuf recording
Samuel Pitoiset [Wed, 22 Mar 2023 16:17:51 +0000 (17:17 +0100)]
radv: replace pipeline->is_ngg occurrences during cmdbuf recording

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: move user_data_0 to the shader info pass
Samuel Pitoiset [Mon, 27 Mar 2023 17:05:06 +0000 (19:05 +0200)]
radv: move user_data_0 to the shader info pass

Using the next stage is enough to determine the base reg.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: determine and store the next graphics stage to radv_shader_info
Samuel Pitoiset [Mon, 27 Mar 2023 16:50:51 +0000 (18:50 +0200)]
radv: determine and store the next graphics stage to radv_shader_info

This will be useful in many cases.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: copy bound shaders to the cmdbuf state
Samuel Pitoiset [Wed, 22 Mar 2023 11:49:33 +0000 (12:49 +0100)]
radv: copy bound shaders to the cmdbuf state

To stop relying on the pipeline everywhere.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: move dirtying flags for mesh shading to radv_bind_pre_rast_shader()
Samuel Pitoiset [Mon, 27 Mar 2023 16:39:29 +0000 (18:39 +0200)]
radv: move dirtying flags for mesh shading to radv_bind_pre_rast_shader()

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: stop using last_vgt_api_stage_{locs} during cmdbuf recording
Samuel Pitoiset [Mon, 27 Mar 2023 07:43:35 +0000 (09:43 +0200)]
radv: stop using last_vgt_api_stage_{locs} during cmdbuf recording

Use the last VGT shader instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: determine the last VGT shader at pipeline bind time
Samuel Pitoiset [Mon, 27 Mar 2023 12:39:42 +0000 (14:39 +0200)]
radv: determine the last VGT shader at pipeline bind time

And replace streamout_shader by last_vgt_shader which is similar.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: keep track of active stages as part of the cmdbuf state
Samuel Pitoiset [Mon, 27 Mar 2023 07:33:14 +0000 (09:33 +0200)]
radv: keep track of active stages as part of the cmdbuf state

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: add an assertion about shader stage to radv_bind_pre_rast_shader()
Samuel Pitoiset [Mon, 27 Mar 2023 07:23:44 +0000 (09:23 +0200)]
radv: add an assertion about shader stage to radv_bind_pre_rast_shader()

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: add radv_bind_shader() helper
Samuel Pitoiset [Fri, 24 Mar 2023 15:12:16 +0000 (16:12 +0100)]
radv: add radv_bind_shader() helper

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: pass a shaders array to radv_get_shader()
Samuel Pitoiset [Mon, 27 Mar 2023 12:18:57 +0000 (14:18 +0200)]
radv: pass a shaders array to radv_get_shader()

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agoradv: pass shader/base_reg to radv_emit_view_index_per_stage
Samuel Pitoiset [Wed, 22 Mar 2023 11:55:01 +0000 (12:55 +0100)]
radv: pass shader/base_reg to radv_emit_view_index_per_stage

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22128>

19 months agokmsro: sort drivers alphabetically
Eric Engestrom [Mon, 27 Mar 2023 17:43:10 +0000 (18:43 +0100)]
kmsro: sort drivers alphabetically

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agokmsro: uniformize renderonly creation
Eric Engestrom [Mon, 27 Mar 2023 16:33:51 +0000 (17:33 +0100)]
kmsro: uniformize renderonly creation

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agovc4: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:23:42 +0000 (17:23 +0100)]
vc4: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agov3d: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:22:51 +0000 (17:22 +0100)]
v3d: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agopanfrost: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:21:40 +0000 (17:21 +0100)]
panfrost: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agolima: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:20:11 +0000 (17:20 +0100)]
lima: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agofreedreno: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:18:48 +0000 (17:18 +0100)]
freedreno: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agoetnaviv: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:15:23 +0000 (17:15 +0100)]
etnaviv: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agoasahi: change create_renderonly signature to uniformize it
Eric Engestrom [Mon, 27 Mar 2023 16:13:10 +0000 (17:13 +0100)]
asahi: change create_renderonly signature to uniformize it

Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22144>

19 months agozink: stop leaking separate shader nir
Mike Blumenkrantz [Tue, 28 Mar 2023 20:50:24 +0000 (16:50 -0400)]
zink: stop leaking separate shader nir

this is a huge memleak

Fixes: e3b746e3a31 ("zink: use GPL to handle (simple) separate shader objects")

Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22175>

19 months agoci/zink: Update the tgl manual run xfails.
Emma Anholt [Mon, 27 Mar 2023 16:43:30 +0000 (09:43 -0700)]
ci/zink: Update the tgl manual run xfails.

These have been consistent for 3 runs.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22146>

19 months agoci/etnaviv: Polish the gc2000 xfails a bit.
Emma Anholt [Mon, 27 Mar 2023 16:39:15 +0000 (09:39 -0700)]
ci/etnaviv: Polish the gc2000 xfails a bit.

These were consistent in the last 3 CI runs.  The rest of the failures in
those runs were flakes spread all around the general shader tests, which
are correlated with GPU hangs.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22146>

19 months agoci/crocus: Fix 1.3.5.0 xfails.
Emma Anholt [Mon, 27 Mar 2023 16:34:14 +0000 (09:34 -0700)]
ci/crocus: Fix 1.3.5.0 xfails.

Whoops, copy and pasted the wrong lines from another board, this GPU is
GL4.6 not 4.5.

Fixes: ecca3b9655db ("ci/crocus: Update expectations from VK CTS 1.3.5.0.")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22146>

19 months agoanv: Fix stride mismatch in mesa and minigbm
Sai Teja Pottumuttu [Tue, 28 Mar 2023 10:13:05 +0000 (10:13 +0000)]
anv: Fix stride mismatch in mesa and minigbm

It is observed that in display resolutions where width is not equal to
stride, vulkan rendering is being distorted. This is happening due to
stride calculation mismatch between minigbm and mesa.

This fix makes sure that the stride calculated in minigbm is passed to
anv and isl.

The issue was found while debugging the following android cts tests and
thus fixes them as well.
android.graphics.cts.VulkanPreTransformTest#testVulkanPreTransformNotSetToMatchCurrentTransform
android.graphics.cts.VulkanPreTransformTest#testVulkanPreTransformSetToMatchCurrentTransform

Signed-off-by: Sai Teja Pottumuttu <sai.teja.pottumuttu@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22163>

19 months agoanv: use primitive ID override when shader does not supply it
Tapani Pälli [Tue, 28 Mar 2023 16:07:22 +0000 (19:07 +0300)]
anv: use primitive ID override when shader does not supply it

Patch moves over this fix from iris driver.

Fixes following test on DG2:
   dEQP-VK.rasterization.culling.primitive_id

Cc: mesa-stable
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Ivan Briano <ivan.briano@intel.com> [v1]
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22130>

19 months agoradv: stop using the pipeline for emitting shaders
Samuel Pitoiset [Thu, 23 Mar 2023 16:26:35 +0000 (17:26 +0100)]
radv: stop using the pipeline for emitting shaders

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: pass the ES shader to radv_pipeline_emit_hw_ngg()
Samuel Pitoiset [Fri, 24 Mar 2023 07:15:05 +0000 (08:15 +0100)]
radv: pass the ES shader to radv_pipeline_emit_hw_ngg()

This allows to remove the radv_pipeline dependency.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: use the ES type to apply a workaround for NGG on GFX10
Samuel Pitoiset [Fri, 24 Mar 2023 07:23:24 +0000 (08:23 +0100)]
radv: use the ES type to apply a workaround for NGG on GFX10

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: use the shader info stage to simplify emitting NGG shaders
Samuel Pitoiset [Fri, 24 Mar 2023 07:05:56 +0000 (08:05 +0100)]
radv: use the shader info stage to simplify  emitting NGG shaders

Instead of relying on the pipeline.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: stop using the pipeline for emitting PS inputs
Samuel Pitoiset [Thu, 23 Mar 2023 17:16:50 +0000 (18:16 +0100)]
radv: stop using the pipeline for emitting PS inputs

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: add radv_get_last_vgt_shader() helper
Samuel Pitoiset [Thu, 23 Mar 2023 17:15:59 +0000 (18:15 +0100)]
radv: add radv_get_last_vgt_shader() helper

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: emit the GS copy shader outside of radv_pipeline_emit_hw_gs()
Samuel Pitoiset [Thu, 23 Mar 2023 16:22:45 +0000 (17:22 +0100)]
radv: emit the GS copy shader outside of radv_pipeline_emit_hw_gs()

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agoradv: stop using get_vs_output_info() when emitting VS/NGG shaders
Samuel Pitoiset [Tue, 21 Mar 2023 13:01:30 +0000 (14:01 +0100)]
radv: stop using get_vs_output_info() when emitting VS/NGG shaders

It's always the current shader outinfo struct.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22095>

19 months agopvr: fix segfault in dEQP-VK.ycbcr.query.*
Luigi Santivetti [Thu, 9 Mar 2023 15:54:35 +0000 (15:54 +0000)]
pvr: fix segfault in dEQP-VK.ycbcr.query.*

Signed-off-by: Luigi Santivetti <luigi.santivetti@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22061>

19 months agoaco: clean up to_mad_mix
Georg Lehmann [Fri, 24 Mar 2023 11:43:35 +0000 (12:43 +0100)]
aco: clean up to_mad_mix

These instructions are 32bit, so they don't support opsel anyway.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22103>

19 months agoradv/ci: update CI lists for Polaris10 and Pitcairn
Samuel Pitoiset [Mon, 27 Mar 2023 07:52:29 +0000 (09:52 +0200)]
radv/ci: update CI lists for Polaris10 and Pitcairn

Recent ac/surface changes fixed those.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22127>

19 months agozink: use c++ template to deduplicate image barrier functions
Mike Blumenkrantz [Tue, 21 Mar 2023 14:54:16 +0000 (10:54 -0400)]
zink: use c++ template to deduplicate image barrier functions

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22057>

19 months agozink: minor tweaks for image barriers
Mike Blumenkrantz [Tue, 21 Mar 2023 14:43:37 +0000 (10:43 -0400)]
zink: minor tweaks for image barriers

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22057>

19 months agozink: use c++ template to deduplicate all the buffer barrier code
Mike Blumenkrantz [Tue, 21 Mar 2023 14:38:51 +0000 (10:38 -0400)]
zink: use c++ template to deduplicate all the buffer barrier code

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22057>

19 months agozink: move all barrier-related functions to c++
Mike Blumenkrantz [Tue, 21 Mar 2023 14:18:22 +0000 (10:18 -0400)]
zink: move all barrier-related functions to c++

this will enable a lot of deduplication

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22057>

19 months agozink: break out a src region barrier check for reuse
Mike Blumenkrantz [Mon, 27 Mar 2023 13:19:38 +0000 (09:19 -0400)]
zink: break out a src region barrier check for reuse

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22057>

19 months agozink: fix some type mismatches for c++ compilation
Mike Blumenkrantz [Tue, 21 Mar 2023 14:17:21 +0000 (10:17 -0400)]
zink: fix some type mismatches for c++ compilation

no functional changes

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22057>

19 months agoasahi: Don't lie about seamless cube maps
Alyssa Rosenzweig [Fri, 24 Mar 2023 22:22:28 +0000 (18:22 -0400)]
asahi: Don't lie about seamless cube maps

Now that mesa/st is setting seamless_cube_map properly we don't need to play any
games here. Remove the hack workaround.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21978>

19 months agomesa/st: Normalize wrap modes for seamless cubes
Alyssa Rosenzweig [Sat, 11 Mar 2023 23:58:34 +0000 (18:58 -0500)]
mesa/st: Normalize wrap modes for seamless cubes

The OpenGL specification requires that seamless cube maps ignore the wrap mode,
but some hardware may try to respect the wrap mode even for seamless cubes
contrary to the spec. Since OpenGL maps samplers 1:1 to textures (at least
without bindless texture support...), it's easy to override the wrap mode for
seamless cubes to something that works for the hardware.

I'm not sure if there is value in gating this behaviour behind a CAP. On one
hand, there is a tiny bit of extra CPU overhead added to change samplers. On the
other hand, normalizing wrap modes might improve CSO caching, and normalizing to
a non-BORDER mode avoids the expensive border colour code later in the function.

We will need a different workaround in our Vulkan driver. Potentially, we'll
have to duplicate *every* sampler to have a cubemap version and a non-cubemap
version, selecting a sampler in the shader based on the texture opcode. That
sucks and implementing it would depend on subtle details of how we implement
descriptor sets, so it's not like we would share that code with the GL driver
anyway. In the mean time, let's get this right for GL without the performance
hit of duplication.

Fixes dEQP-GLES3.functional.texture.filtering.cube.* on Asahi, as well as a
smattering of dEQP-GLES31.functional.texture.filtering.cube_array.* fails on
softpipe.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Reviewed-by: Juan A. Suarez <jasuarez@igalia.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21978>

19 months agomesa/st: Only set seamless for GLES3
Alyssa Rosenzweig [Fri, 24 Mar 2023 22:18:26 +0000 (18:18 -0400)]
mesa/st: Only set seamless for GLES3

6148e3aae7e ("mesa: Fix ctx->Texture.CubeMapSeamless") introduced a hack, where
seamless cube maps would be requested even for GLES2 contexts despite the spec,
on the assumption that GLES2 gallium drivers would ignore the bit. But that
requires Gallium drivers to know what GLES version they advertise, which is a
horrible layering violation. When the commit was written 8 years ago, there were
classic drivers to contend with so it made sense as a fix to get GLES 3.0 up and
running. With classic drivers gone, it's time to sunset the hack and restore the
intended behaviour by setting ctx->Texture.CubeMapSeamless only once we know the
version.

In addition to fixing a semantic issue in the Gallium contract and preventing a
regression from the next commit, this fixes cube maps on Mali-T720 under
Panfrost. In general, Panfrost supports GLES3 (and honours the seamless flag
everywhere) but on T720 we only advertise GLES2 due to missing MRT support on
older Midgard devices, so we need the flag set properly to distinguish these
cases.

Cc: mesa-stable
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Reviewed-by: Juan A. Suarez <jasuarez@igalia.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21978>

19 months agodriconf: add a workaround for Kaiju-A-Gogo
Paul Gofman [Mon, 27 Mar 2023 20:36:12 +0000 (14:36 -0600)]
driconf: add a workaround for Kaiju-A-Gogo

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22152>

19 months agoradeonsi: monolithic PS emit epilog in nir directly
Qiang Yu [Sun, 26 Feb 2023 08:40:12 +0000 (16:40 +0800)]
radeonsi: monolithic PS emit epilog in nir directly

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agoac/nir: add ac_nir_lower_ps
Qiang Yu [Sat, 25 Feb 2023 13:14:52 +0000 (21:14 +0800)]
ac/nir: add ac_nir_lower_ps

Lower ps output to nir_export_amd.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agonir: add nir_fisnan helper function
Qiang Yu [Sat, 25 Feb 2023 13:13:50 +0000 (21:13 +0800)]
nir: add nir_fisnan helper function

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agonir,radeonsi: add and implement nir_load_alpha_reference_amd
Qiang Yu [Fri, 24 Feb 2023 06:39:17 +0000 (14:39 +0800)]
nir,radeonsi: add and implement nir_load_alpha_reference_amd

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agoaco: implement float16 nir_op_pack_(s|u)norm_2x16
Qiang Yu [Fri, 24 Feb 2023 06:22:08 +0000 (14:22 +0800)]
aco: implement float16 nir_op_pack_(s|u)norm_2x16

Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agoac/llvm: implement float16 nir_op_pack_(s|u)norm_2x16
Qiang Yu [Fri, 24 Feb 2023 06:17:07 +0000 (14:17 +0800)]
ac/llvm: implement float16 nir_op_pack_(s|u)norm_2x16

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agonir: pack_(s|u)norm_2x16 support float16 as input
Qiang Yu [Fri, 24 Feb 2023 05:57:33 +0000 (13:57 +0800)]
nir: pack_(s|u)norm_2x16 support float16 as input

For AMD GPU which has instruction to normalize and pack two float16
inputs, and used when fragment shader export color output.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21552>

19 months agointel: Allocate mesh shader URB space before task shader
José Roberto de Souza [Fri, 24 Feb 2023 18:58:36 +0000 (10:58 -0800)]
intel: Allocate mesh shader URB space before task shader

A future platform requires that mesh shader URB space be allocated
before task shader URB space.

If task shader is enabled, it will align the mesh shader URB size to
8Kb and give the remaning back to task shader. Otherwise, no aligment
is needed, and mesh shader will have all the URB space.

BSpec: 56229, 56230
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21603>

19 months agoradv/rt: Refactor rq_load lowering
Konstantin Seurer [Tue, 21 Feb 2023 10:45:09 +0000 (11:45 +0100)]
radv/rt: Refactor rq_load lowering

This just gets rid of all the bcsel emissions.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21455>

19 months agoaux/trace: fix GALLIUM_TRACE_NIR handling
Mike Blumenkrantz [Wed, 22 Mar 2023 16:58:57 +0000 (12:58 -0400)]
aux/trace: fix GALLIUM_TRACE_NIR handling

this now correctly doesn't dump nir when the counter is zero

Fixes: f99eab23ad6 ("aux/trace: delete GALLIUM_TRACE_NIR log message")

Reviewed-by: Matti Hämäläinen <ccr@tnsp.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22164>

19 months agoaux/trace: dump blend states with enums
Mike Blumenkrantz [Wed, 22 Mar 2023 16:58:50 +0000 (12:58 -0400)]
aux/trace: dump blend states with enums

this is more readable

Reviewed-by: Matti Hämäläinen <ccr@tnsp.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22164>

19 months agoradv: add RADV_DEBUG=extra_md
Pierre-Eric Pelloux-Prayer [Fri, 24 Mar 2023 09:18:17 +0000 (10:18 +0100)]
radv: add RADV_DEBUG=extra_md

This enables the use of UMD metadata v2. This allows tools (eg umr)
import buffers.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21984>

19 months agoradeonsi: don't use si_decompress_dcc if the blitter is running
Pierre-Eric Pelloux-Prayer [Wed, 22 Mar 2023 14:24:28 +0000 (15:24 +0100)]
radeonsi: don't use si_decompress_dcc if the blitter is running

Otherwise this will cause a blitter recursion which will crash at
some point.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21984>

19 months agoradeonsi: add AMD_DEBUG=extra_md
Pierre-Eric Pelloux-Prayer [Tue, 21 Mar 2023 09:46:53 +0000 (10:46 +0100)]
radeonsi: add AMD_DEBUG=extra_md

When this debug flag is set, the driver sets the umd metadata for
all color textures and enables the use of extended metadata.

Extended metadata allows umr to import textures and setting these
on all color texture allows to import non-exported textures
(eg: dGPU draw surface when DRI_PRIME=1 is used).

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21984>

19 months agoac/surface: introduce umd metadata v2
Pierre-Eric Pelloux-Prayer [Tue, 21 Mar 2023 09:46:39 +0000 (10:46 +0100)]
ac/surface: introduce umd metadata v2

Update the metadata format. For gfx8- chips nothing change.

For gfx9 chips:
* for textures without a valid modifier a dw is added at index=10
  containing the stride
* for textures with a valid modifier the modifier is stored at
  index 10 and 11. Then the number of planes is stored at 12.
  Then for each plane the offset and the stride are stored.

The goal here is to be able to create textures from dmabuf from
umr - without these changes this is impossible because these
values can't be guessed.

The new layout is compatible with version=1 so old/new UMD can
be used together without issues and isn't used by default.
For radeonsi, it will be possible to use it with a AMD_DEBUG=...
option.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21984>

19 months agoamd/surface: rename metadata functions
Pierre-Eric Pelloux-Prayer [Tue, 21 Mar 2023 09:54:16 +0000 (10:54 +0100)]
amd/surface: rename metadata functions

Use more specific verbs to avoid confusion:
   set -> apply
   get -> compute

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21984>

19 months agomesa: fix CopyImageSubDataOES with GL_TEXTURE_EXTERNAL_OES
Pierre-Eric Pelloux-Prayer [Fri, 17 Mar 2023 12:57:00 +0000 (13:57 +0100)]
mesa: fix CopyImageSubDataOES with GL_TEXTURE_EXTERNAL_OES

GL_TEXTURE_EXTERNAL_OES is allowed on GLES (any version) and glCopyImageSubDataOES
is implemented as an alias of CopyImageSubData.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21984>

19 months agoanv: call nir_shader_gather_info early
Marcin Ślusarz [Tue, 7 Mar 2023 09:41:10 +0000 (10:41 +0100)]
anv: call nir_shader_gather_info early

Shader info is needed for mesh in linking (in nir_lower_io_to_scalar_early,
see commit 5e144454) and will be needed once MR !17622 (anv: work around
for per-prim attributes corruption) lands.

We still need to call nir_shader_gather_info in anv_pipeline_lower_nir,
because the information got stale between anv_graphics_pipeline_load_nir
and anv_pipeline_lower_nir. Some examples:
- some FS inputs were marked as per-primitive during linking
  (brw_nir_link_shaders) affecting per_primitive_inputs mask
- some inputs and outputs were removed, because they are not used
  (nir_remove_unused_varyings) affecting outputs_written and inputs_read

This fixes func.mesh.ext.outputs.per_primitive.unused crucible test on DG2.
(I didn't know this test wasn't fixed by 5e144454, because I was testing
with !17622 merged-in, which added its own nir_shader_gather_info before
nir_lower_io_to_scalar_early).

Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21787>

19 months agoCI: Disable freedreno
Daniel Stone [Tue, 28 Mar 2023 10:10:10 +0000 (11:10 +0100)]
CI: Disable freedreno

The proxy has been broken ever since the network went down.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22161>

19 months agoaco/util: override default assignment operator for bitfield helpers
Georg Lehmann [Mon, 27 Mar 2023 21:35:57 +0000 (23:35 +0200)]
aco/util: override default assignment operator for bitfield helpers

Otherwise, the default assignment operator copies the whole uint,
not just few bits we are interested in.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Fixes: e7559da7570 ("aco: add bitfield array helper classes")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22154>

19 months agoaco/ir: fix copy paste bug in convert_to_SDWA
Georg Lehmann [Mon, 27 Mar 2023 21:32:54 +0000 (23:32 +0200)]
aco/ir: fix copy paste bug in convert_to_SDWA

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Fixes: 60cd3ba39f1 ("aco: copy abs/neg with assignment")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22154>

19 months agoaco: Swap operands for v_and_b32 in RT prolog
Friedrich Vock [Mon, 27 Mar 2023 16:10:20 +0000 (18:10 +0200)]
aco: Swap operands for v_and_b32 in RT prolog

The second operand must be a VGPR, only the first can be a literal.
With a literal, this code was wrongly assembled and resulted in artifacts on GFX11.

Fixes: 6446b791681 ("aco: implement select_rt_prolog()")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8642
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22142>

19 months agoradv: Fix swizzled VS input loads when some components are unused.
Timur Kristóf [Sun, 26 Mar 2023 21:49:23 +0000 (23:49 +0200)]
radv: Fix swizzled VS input loads when some components are unused.

Fix how out-of-bounds loads are decided.
It was incorrect because it mismatched the swizzle.
The decision is now made using the loaded num_components.

Fixes: 27c81319780d4a9693ef609b6a891981d1417b70
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8712
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22124>

19 months agoradv/rt: bind the pipeline stack when it's not dynamic
Samuel Pitoiset [Fri, 24 Mar 2023 16:45:47 +0000 (17:45 +0100)]
radv/rt: bind the pipeline stack when it's not dynamic

This overwrites the rt_stack_size cmdbuf state when a new rt pipeline
with a static stack size is bound.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22126>

19 months agoasahi: Convert to SPDX headers
Alyssa Rosenzweig [Wed, 15 Mar 2023 21:36:17 +0000 (17:36 -0400)]
asahi: Convert to SPDX headers

Also drop my email address in the copyright lines and fix some "Copyright 208
Alyssa Rosenzweig" lines, I'm not *that* old. Together this drops a lot of
boilerplate without losing any meaningful licensing information. SPDX is already
in use for the MIT-licensed code in turnip, venus, and a few other scattered
parts of the tree, so this should be ok from a Mesa licensing standpoint.

This reduces friction to create new files, by parsing the copy/paste boilerplate
and being short enough you can easily type it out if you want.  It makes new
files seem less daunting: 20 lines of header for 30 lines of code is
discouraging, but 2 lines of header for 30 lines of code is reasonable for a
simple compiler pass. This has technical effects, as lowering the barrier to
making new files should encourage people to split code into more modular files
with (hopefully positive) effects on project compile time.

This helps with consistency between files. Across the tree we have at least a
half dozen variants of the MIT license text (probably more), plus code that uses
SPDX headers instead. I've already been using SPDX headers in Asahi manually, so
you can tell old vs new code based on the headers.

Finally, it means less for reviewers to scroll through adding files. Minimal
actual cognitive burden for reviewers thanks to banner blindness, but the big
headers still bloat diffs that add/delete files.

I originally proposed this in December (for much more of the tree) but someone
requested I wait until January to discuss. I've been trying to get in touch with
them since then. It is now almost April and, with still no response, I'd like to
press forward with this. So with a joint sign-off from the major authors of the
code in question, let's do this.

Signed-off-by: Asahi Lina <lina@asahilina.net>
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Acked-by: Emma Anholt <emma@anholt.net>
Acked-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Rose Hudson <rose@krx.sh>
Acked-by: Lyude Paul [over IRC: "yes I'm fine with that"]
Meh'd-by: Rob Clark <robdclark@chromium.org>

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22062>

19 months agomailmap: Add Lina's new google.com address
Lina Versace [Mon, 27 Mar 2023 21:33:37 +0000 (14:33 -0700)]
mailmap: Add Lina's new google.com address

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22153>

19 months agodocs/svga3d: Fix typo
Harri Nieminen [Mon, 27 Mar 2023 19:15:54 +0000 (22:15 +0300)]
docs/svga3d: Fix typo

Found by codespell

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22149>

19 months agodocs/panfrost: Fix typo
Harri Nieminen [Mon, 27 Mar 2023 19:14:55 +0000 (22:14 +0300)]
docs/panfrost: Fix typo

Found by codespell

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22149>

19 months agodocs/freedreno: Fix typos
Harri Nieminen [Mon, 27 Mar 2023 19:13:50 +0000 (22:13 +0300)]
docs/freedreno: Fix typos

Found by codespell

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22149>

19 months agodocs/gallium: Fix typos
Harri Nieminen [Mon, 27 Mar 2023 19:13:06 +0000 (22:13 +0300)]
docs/gallium: Fix typos

Found by codespell

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22149>

19 months agodocs/specs: Fix typos
Harri Nieminen [Mon, 27 Mar 2023 19:09:52 +0000 (22:09 +0300)]
docs/specs: Fix typos

Found by codespell

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22149>

19 months agocrocus: don't quantize the clear value
Filip Gawin [Mon, 27 Mar 2023 11:44:46 +0000 (13:44 +0200)]
crocus: don't quantize the clear value

Helps with:
spec@!opengl 1.0@depth-clear-precision-check@depth32f_stencil8,UnexpectedPass
spec@!opengl 3.0@clearbuffer-bug,UnexpectedPass

Cc: mesa-stable
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22137>

19 months agoamd/llvm: remove no-op code for vec3 loads in ac_build_tbuffer_load
Marek Olšák [Sat, 25 Mar 2023 00:46:39 +0000 (20:46 -0400)]
amd/llvm: remove no-op code for vec3 loads in ac_build_tbuffer_load

Formatted loads always support vec3, so this code didn't do anything.

Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22117>

19 months agoamd/llvm: fix handling of unsupported vec3 loads on gfx6
Marek Olšák [Fri, 24 Mar 2023 23:46:56 +0000 (19:46 -0400)]
amd/llvm: fix handling of unsupported vec3 loads on gfx6

VMEM loads promoted from vec3 to vec4 didn't trim the vector, thus
returning vec4 on gfx6 and vec3 on later generations, which callers
don't expect.

SMEM loads were adding an extra component on gfx6, causing same issues.

Fixes: 82919e2d - amd: lower subdword UBO loads in NIR
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8693

Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22117>

19 months agoaco: make .clang-format usable with tests
Georg Lehmann [Sun, 26 Mar 2023 18:27:14 +0000 (20:27 +0200)]
aco: make .clang-format usable with tests

Code between BEGIN_TEST and END_TEST should be indented,
and comments used by the test itself should not be reformatted.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22122>

19 months agov3dv: fix format swizzle for buffer views
Iago Toral Quiroga [Mon, 27 Mar 2023 09:42:23 +0000 (11:42 +0200)]
v3dv: fix format swizzle for buffer views

Fixes:
dEQP-VK.api.buffer_view.access.uniform_texel_buffer.b8g8r8a8_unorm

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22131>

19 months agov3dv: pause occlusion queries during vkCmdClearAttachments
Iago Toral Quiroga [Mon, 27 Mar 2023 09:11:24 +0000 (11:11 +0200)]
v3dv: pause occlusion queries during vkCmdClearAttachments

We implement this by emitting a draw call, which should not be registered
during occlusion query counting.

Fixes:
dEQP-VK.query_pool.occlusion_query*clear*

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22131>

19 months agoradv: move {esgs,gsvs}_ring_size to radv_legacy_gs_info
Samuel Pitoiset [Fri, 24 Mar 2023 10:03:42 +0000 (11:03 +0100)]
radv: move {esgs,gsvs}_ring_size to radv_legacy_gs_info

To update the ring info when a geometry shader is bound.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22134>

19 months agoradv: rename gfx9_gs_info to radv_legacy_gs_info
Samuel Pitoiset [Mon, 27 Mar 2023 11:44:45 +0000 (13:44 +0200)]
radv: rename gfx9_gs_info to radv_legacy_gs_info

This was misleading because it's also needed on GFX6-8.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22134>

19 months agopvr: Add robustness buffer support
Jarred Davies [Thu, 23 Feb 2023 05:16:48 +0000 (05:16 +0000)]
pvr: Add robustness buffer support

The robustness buffer is used when no vertex attribute can be loaded and
robustBufferAccess is enabled.

Signed-off-by: Jarred Davies <jarred.davies@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21579>

19 months agopvr: Rename pvr_xgl_pds.c to pvr_pipeline_pds.c
Jarred Davies [Thu, 23 Feb 2023 05:16:41 +0000 (05:16 +0000)]
pvr: Rename pvr_xgl_pds.c to pvr_pipeline_pds.c

Signed-off-by: Jarred Davies <jarred.davies@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21579>

19 months agopvr: Always mark robustBufferAccess as supported
Jarred Davies [Thu, 23 Feb 2023 05:16:16 +0000 (05:16 +0000)]
pvr: Always mark robustBufferAccess as supported

As per the Vulkan spec, this is a required feature for graphics implementations.

Signed-off-by: Jarred Davies <jarred.davies@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21579>

19 months agointel/vk/grl: don't install libgrl.a
Ilya K [Mon, 27 Mar 2023 11:41:35 +0000 (11:41 +0000)]
intel/vk/grl: don't install libgrl.a

It isn't used by anything at runtime and shouldn't be installed.
Saves about 3MB of space on the final artifacts on x86_64-linux.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8711
Fixes: 63966505 ("anv/grl: Build OpenCL kernels")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22133>