Mike Blumenkrantz [Mon, 24 Apr 2023 15:19:57 +0000 (11:19 -0400)]
nir/gs: fix array type copying for passthrough gs
same mechanics as in zink passes
Fixes:
d0342e28b32 ("nir: Add helper to create passthrough GS shader")
Reviewed-by: Antonino Maniscalco <antonino.maniscalco@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22669>
Jesse Natalie [Mon, 24 Apr 2023 14:19:24 +0000 (07:19 -0700)]
dzn: Align-up heap sizes when allocating memory
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8895
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22666>
Samuel Pitoiset [Fri, 21 Apr 2023 09:51:29 +0000 (11:51 +0200)]
radv: do not overallocate the CS array during submissions
Preambles/postambles are no longer added to the CS array.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22653>
André Almeida [Sun, 23 Apr 2023 20:43:11 +0000 (17:43 -0300)]
radv: Search for guilty contexts at radv_check_status
When a GPU hung happens, all contexts are notified. They will receive
INNOCENT_CONTEXT if they are not the context that triggered the reset,
or GUILTY_CONTEXT otherwise.
At radv_check_status(), we return on the first context that was notified
as [GUILTY, INNOCENT]_CONTEXT, without further checks. This can make an
app think that it's innocent if the guilty context is not the first one
on the list of hw_ctx to be checked.
Check every context for a guilty one before returning CONTEXT_INNOCENT.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Signed-off-by: André Almeida <andrealmeid@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22648>
Luca Weiss [Sun, 23 Apr 2023 18:09:22 +0000 (20:09 +0200)]
freedreno: Enable A506
Enable the Adreno 506 that is found in SoCs such as Snapdragon 450,
Snapdragon 625 or Snapdragon 632 (msm8953 family).
Signed-off-by: Luca Weiss <luca@z3ntu.xyz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22647>
Mike Blumenkrantz [Thu, 20 Apr 2023 19:49:00 +0000 (15:49 -0400)]
zink: add a driver workaround to disable background compiles
it's stupid to do optimized background compiles if the driver is going
to create the exact same pipeline, so add a workaround to disable
this behavior
should improve ci runtimes on lavapipe by some amount
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22613>
Juan A. Suarez Romero [Thu, 13 Apr 2023 16:57:39 +0000 (18:57 +0200)]
v3d: add support for ARB_texture_cube_map_array
This implements support for texture cubemap arrays.
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22482>
Mike Blumenkrantz [Thu, 20 Apr 2023 18:03:19 +0000 (14:03 -0400)]
zink: add z32s8 as mandatory GL3.0 profile attachment format
fixes #8616
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22608>
Mike Blumenkrantz [Thu, 20 Apr 2023 17:21:28 +0000 (13:21 -0400)]
zink: don't pin flush queue threads if no threads exist
Fixes:
270f9c0b063 ("zink: add ZINK_DEBUG=flushsync")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22611>
Karol Herbst [Thu, 13 Apr 2023 19:14:33 +0000 (21:14 +0200)]
rusticl: don't set size_t-is-usize for >=bindgen-0.65
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8827
Fixes:
20c90fed5a0 ("rusticl: added")
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22484>
Martin Roukala (né Peres) [Mon, 24 Apr 2023 05:51:31 +0000 (08:51 +0300)]
zink/ci: mark 77 multisample-related tests as fixed
Reference: #6302
Fixes:
a004825266fd ("zink: don't render with multisampling when it is disabled")
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Acked-by: David Heidelberg <david.heidelberg@collabora.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22650>
Karol Herbst [Thu, 20 Apr 2023 10:58:19 +0000 (12:58 +0200)]
ac/llvm: support shifts on 16 bit vec2
In OpenCL we can actually end up with those.
Fixes `basic astype` and those `integer_ops` OpenCL CTS tests:
integer_hadd
integer_rhadd
integer_upsample
quick_short_shift
quick_ushort_shift
Cc: mesa-stable
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22597>
Karol Herbst [Tue, 15 Nov 2022 23:34:29 +0000 (00:34 +0100)]
radeonsi: lower mul_high
Fixes `integer_mad_hi` and `integer_mul_hi` `integer_ops` tests
Cc: mesa-stable
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22597>
Sergi Blanch Torne [Wed, 29 Mar 2023 07:21:50 +0000 (09:21 +0200)]
Revert "ci: disable Collabora's LAVA lab for maintance"
This reverts commit https://gitlab.freedesktop.org/mesa/mesa/-/commit/
def1d097c9e1637923f5315820586b06de2f28d0
Signed-off-by: Sergi Blanch Torne <sergi.blanch.torne@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22182>
Eric Engestrom [Mon, 24 Apr 2023 09:23:36 +0000 (10:23 +0100)]
v3d: document that `V3D_DEBUG=shaderdb` is *not* for shader-db
Signed-off-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22659>
Iago Toral Quiroga [Thu, 20 Apr 2023 10:49:22 +0000 (12:49 +0200)]
broadcom/compiler: fix incorrect check for SFU op
Before testing the waddr for SFU we should first validate this
is indeed a valid (not NOP) magic write. Use the helper we have for
this which gets this right.
total instructions in shared programs:
12898957 ->
12850958 (-0.37%)
instructions in affected programs: 4328937 -> 4280938 (-1.11%)
helped: 19974
HURT: 439
Instructions are helped.
total max-temps in shared programs: 2211503 -> 2210893 (-0.03%)
max-temps in affected programs: 12924 -> 12314 (-4.72%)
helped: 509
HURT: 20
Max-temps are helped.
total sfu-stalls in shared programs: 22233 -> 21975 (-1.16%)
sfu-stalls in affected programs: 722 -> 464 (-35.73%)
helped: 297
HURT: 54
Sfu-stalls are helped.
total inst-and-stalls in shared programs:
12921190 ->
12872933 (-0.37%)
inst-and-stalls in affected programs: 4337977 -> 4289720 (-1.11%)
helped: 20015
HURT: 404
Inst-and-stalls are helped.
total nops in shared programs: 333743 -> 305911 (-8.34%)
nops in affected programs: 86902 -> 59070 (-32.03%)
helped: 14545
HURT: 76
Nops are helped.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22593>
Iago Toral Quiroga [Mon, 24 Apr 2023 06:51:47 +0000 (08:51 +0200)]
broadcom/compiler: add a v3d_qpu_instr_is_legacy_sfu helper
This checks for the deprecated, old-style SFU instructions triggered by
magic writes.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22593>
Iago Toral Quiroga [Mon, 24 Apr 2023 06:48:39 +0000 (08:48 +0200)]
broadcom/compiler: fix v3d_qpu_uses_sfu
We should check that the alu op is valid before testing the
write address.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22593>
antonino [Tue, 4 Apr 2023 16:55:52 +0000 (18:55 +0200)]
zink: fix line strip offsets in pv mode emulation
Offsets for line strips don't need to alternate like they do for
triangle strips.
Fixes:
5a4083349f3 ("zink: add provoking vertex mode lowering")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22599>
antonino [Tue, 4 Apr 2023 15:00:53 +0000 (17:00 +0200)]
zink: fix exit condition on pv emulation loop
The exit condition was not correct causing the pv emulation lowering
pass to emit garbage for incomplete primitives.
Fixes:
5a4083349f3 ("zink: add provoking vertex mode lowering")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22599>
antonino [Tue, 4 Apr 2023 14:49:57 +0000 (16:49 +0200)]
zink: use ring buffer to preserve last element
Previously, whenever a vertex was emitted immediately after emitting a
primitive, that vertex would not use the attributes that where assigned
last because the position variable got set.
Now the temporary attributes array is treated as a ring buffer and
whenever the position is set to 0 it's previous value is used as an
offset when accessing it. This way when a new primitive is created the
attributes at index 0 correspond to the last attributes written.
Fixes:
5a4083349f3 ("zink: add provoking vertex mode lowering")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22599>
antonino [Tue, 4 Apr 2023 10:20:37 +0000 (12:20 +0200)]
zink: fix pv mode lowring index calculation
The provoking vertex mode pass was calculating an offset and then using
it directly instead of adding it to the base index.
Fixes:
5a4083349f3 ("zink: add provoking vertex mode lowering")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22599>
Marcin Ślusarz [Fri, 21 Apr 2023 10:51:47 +0000 (12:51 +0200)]
anv: move nir_shader_gather_info to anv_pipeline_nir_preprocess
Fixes dEQP-VK.mesh_shader.ext.misc.custom_attributes*.
Fixes:
16c7c377186 ("anv: move preprocessing of NIR right before compilation")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22629>
SoroushIMG [Wed, 19 Apr 2023 21:10:15 +0000 (22:10 +0100)]
zink: refcount the correct query pool
otherwise the pool is freed before the query and zink will
give the vulkan driver NULL query pool which can make it crash.
this was seen when running the following cases with
primitivesGeneratedQueryWithRasterizerDiscard and color write
features disabled:
dEQP-GL45.functional.tessellation.invariance.outer_triangle_set.triangles_fractional_odd_spacing
dEQP-GL45.functional.tessellation.invariance.outer_triangle_set.triangles_fractional_even_spacing
dEQP-GL45.functional.tessellation.invariance.outer_triangle_set.quads_equal_spacing
dEQP-GL45.functional.tessellation.invariance.outer_triangle_set.quads_fractional_odd_spacing
dEQP-GL45.functional.tessellation.invariance.outer_triangle_set.quads_fractional_even_spacing
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_equal_spacing_ccw
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_equal_spacing_ccw_point_mode
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_equal_spacing_cw
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_equal_spacing_cw_point_mode
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_fractional_odd_spacing_ccw
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_fractional_odd_spacing_ccw_point_mode
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_fractional_odd_spacing_cw
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_fractional_odd_spacing_cw_point_mode
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_fractional_even_spacing_ccw
dEQP-GL45.functional.tessellation.invariance.tess_coord_component_range.triangles_fractional_even_spacing_ccw_point_mode
Fixes:
e5d517f3622 ("zink: rework query pool overflow")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22575>
SoroushIMG [Thu, 16 Feb 2023 09:43:40 +0000 (09:43 +0000)]
zink: fix incorrect line mode check for bresenham
the line requirement check logic was assuming mode index 0
is bresenhamLines, but it is actually rectangularLines.
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22575>
SoroushIMG [Mon, 17 Apr 2023 17:44:50 +0000 (18:44 +0100)]
zink: take location_frac into account in lower_line_smooth_gs
blender-demo-cube_diorama trace in traces-db hits this.
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22575>
SoroushIMG [Mon, 3 Apr 2023 13:29:01 +0000 (14:29 +0100)]
zink: do not emit line stipple dynamic state when emulating
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22575>
Samuel Pitoiset [Fri, 21 Apr 2023 13:44:56 +0000 (15:44 +0200)]
radv: add the perf counters BO to the preambles BO list
If the submission isn't chained for any reasons, we might end by
submitting the performance counter preambles without a command
buffer that added this BO to its list.
Found by inspection.
Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22627>
Sergi Blanch Torne [Wed, 29 Mar 2023 07:18:53 +0000 (09:18 +0200)]
ci: disable Collabora's LAVA lab for maintance
This is to inform you of some planned downtime in the LAVA lab as follows:
Start: 2023-04-24 08:00 GMT
End: 2023-04-24 12:00 GMT
Signed-off-by: Sergi Blanch Torne <sergi.blanch.torne@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22181>
Mike Blumenkrantz [Thu, 20 Apr 2023 20:35:36 +0000 (16:35 -0400)]
zink: add validation exceptions for shader object extension enable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 20:40:43 +0000 (16:40 -0400)]
zink: use EXT_shader_object to (re)implement separate shaders
this reimplements the same functionality that exists already, but
using shader object instead of GPL
it must be disabled by default, as this extension is not (currently)
compatible with feedback loops
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Mon, 10 Apr 2023 22:18:16 +0000 (18:18 -0400)]
zink: remove redundant compute program batch ref
this is already handled in the function above
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 7 Apr 2023 16:18:19 +0000 (12:18 -0400)]
zink: run bo lowering passes for separate shader compile with uniform inlining
this is otherwise unable to pass ntv
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 22:17:07 +0000 (18:17 -0400)]
zink: add a 'separate' flag to shader module compile to indicate separate shaders
not used yet
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 20:04:31 +0000 (16:04 -0400)]
zink: move separate shader dsl creation to compiler function
no functional changes, just reordering
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 20:04:17 +0000 (16:04 -0400)]
zink: minor whitespace cleanup
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 19:52:46 +0000 (15:52 -0400)]
zink: use zink_shader_object for precompiled separate shaders
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 19:48:40 +0000 (15:48 -0400)]
zink: more zink_shader_object conversion
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 19:39:45 +0000 (15:39 -0400)]
zink: make zink_shader_spirv_compile static
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 19:00:24 +0000 (15:00 -0400)]
zink: wrap return of compile_module()
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 18:56:11 +0000 (14:56 -0400)]
zink: wrap zink_shader_compile_separate() return
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 31 Mar 2023 18:53:39 +0000 (14:53 -0400)]
zink: hook up EXT_shader_object
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Mon, 10 Apr 2023 17:01:19 +0000 (13:01 -0400)]
zink: use tes to generate tcs
this makes more sense considering the tcs will be stored onto the tes
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22612>
Mike Blumenkrantz [Fri, 21 Apr 2023 14:41:34 +0000 (10:41 -0400)]
draw: fix viewmask iterating
the frontend has to be flushed and setup again if only
the viewmask has changed since the last draw
Fixes:
03cbb7b104e ("draw: add view_mask rendering support")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22628>
Thomas H.P. Andersen [Sun, 4 Jul 2021 09:41:52 +0000 (11:41 +0200)]
nir/nir_lower_vec3_to_vec4: Use the nir_shader_instructions_pass() helper
Extracts some per-impl code to nir_lower_vec3_to_vec4 and then
converts to use the nir_shader_instructions_pass helper.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Thu, 19 Jan 2023 16:27:31 +0000 (17:27 +0100)]
nir/nir_lower_to_source_mods: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Sun, 4 Jul 2021 09:25:50 +0000 (11:25 +0200)]
nir/nir_lower_two_sided_color: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Sat, 3 Jul 2021 13:10:05 +0000 (15:10 +0200)]
nir/nir_lower_uniforms_to_ubo: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Thu, 19 Jan 2023 16:28:13 +0000 (17:28 +0100)]
nir/nir_lower_var_copies: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Thu, 1 Jul 2021 23:16:13 +0000 (01:16 +0200)]
nir/nir_lower_viewport_transform: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Thu, 1 Jul 2021 23:15:23 +0000 (01:15 +0200)]
nir/nir_lower_wpos_ytransform: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Thomas H.P. Andersen [Thu, 1 Jul 2021 16:02:37 +0000 (18:02 +0200)]
nir/nir_lower_wpos_center: Use the nir_shader_instructions_pass() helper
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11683>
Axel Davy [Sun, 2 Apr 2023 15:35:53 +0000 (17:35 +0200)]
frontend/nine: fix wfog
When wfog support is advertised, unless an orthogonal
projection matrix is detected, w is supposed to be used
instead of z for the fog equation when done in the pixel
shader.
Due to the spec being ambiguous, and tests being incomplete,
it seems we had got things wrong.
New tests confirm the behaviour.
For the explanation we will denote z_vs and w_vs the position
output's z and w channels in the vertex shader, and
z_ps, w_ps the position input z and w channels in the pixel shader.
w_ps = 1/w_vs
z_ps = z_vs/w_vs
In the programmable pixel shader, we used z_ps/w_ps, thus z_vs.
As basically z_vs and w_vs are usually in the same range, we didn't
notice an obvious difference with the correct behaviour.
In the ff pixel shader, we used z_ps for zfog and w_vs else.
z_ps was always used if a programmable vertex shader was detected.
This latter behaviour led to issue
https://gitlab.freedesktop.org/mesa/mesa/-/issues/8341
While using z_ps/w_ps like for programmable ps fixes the issue visually
for the same reason as it did for programmable ps, it breaks
wine tests using XYZRHW. These tests show that when passing
pre-transformed vertices and an orthogonal projection matrix,
z_vs is used, and due to the XYZRHW property, this is not
recovered by the z_ps/w_ps computation (instead z_ps=z_vs).
For the game affected by the issue, the projection matrix set
is not orthogonal.
The direct3D spec indicates that the projection matrix must be
set correctly for fog to work properly, even if we do not use the
transformation pipeline (could be related to xyzrhw, or programmable vs
or both). Previous tests had shown that the projection matrix
has the last two values of the last column tested against 0 and 1,
in order to activate zfog or wfog.
The R500 spec indicates that either z or 1/1/w can be used as source
for the fog computation, but it is not clear whether this is z_vs or
z_ps.
Tests confirmed the intuition that the correct behaviour
is to use z_ps (zfog) when an orthogonal projection matrix is set
(the spec spirit being that in that case z_ps=z_vs),
and 1/w_ps (wfog) else (even if programmable shaders are used).
This patch introduces this behaviour.
Fixes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8341
Signed-off-by: Axel Davy <davyaxel0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22583>
Axel Davy [Thu, 13 Apr 2023 17:44:04 +0000 (19:44 +0200)]
frontend/nine: fix fog key overflow
FOGTABLEMODE is 2 bits. It could thus
overwrite the part of the ps key reserved
for centroid interpolation.
Fix the size of FOGTABLEMODE and the key
Signed-off-by: Axel Davy <davyaxel0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22583>
Axel Davy [Thu, 21 Jul 2022 16:44:56 +0000 (18:44 +0200)]
frontend/nine: Apply writemask to pointsize
Seen when working on the code.
It seems like a sane thing to do, but it
might be wrong.
Signed-off-by: Axel Davy <davyaxel0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22583>
Axel Davy [Thu, 21 Jul 2022 16:42:02 +0000 (18:42 +0200)]
frontend/nine: Fix missing clamping of pointsize for ff
Seen while working on this code.
It seems to be a sane thing to do.
Signed-off-by: Axel Davy <davyaxel0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22583>
Juan A. Suarez Romero [Sat, 22 Apr 2023 17:42:19 +0000 (19:42 +0200)]
v3dv/ci: rename waiver test
Apparently dEQP-VK.draw.inverted_depth_ranges.nodepthclamp_deltazero was
renamed to dEQP-VK.draw.renderpass.inverted_depth_ranges.nodepthclamp_deltazero.
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22641>
Gert Wollny [Tue, 11 Apr 2023 12:17:40 +0000 (14:17 +0200)]
r600/sfn: make sure f2u32 is lowered late and correctly for 64 bit floats
With the latest changes in opt_algebraic we got f2u32 in the final code
that should be lowered before conversion to assembly.
Fixes:
b3685f3ba7fddbe73f363ff4d53ca734841e4b06
nir/algebraic: insert patterns inside optimizations list
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22640>
Tatsuyuki Ishi [Mon, 17 Apr 2023 13:41:43 +0000 (22:41 +0900)]
util: Add mesa_blake3 wrappers.
The wrappers mirrors the mesa_sha1 API to ease migration.
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22387>
Tatsuyuki Ishi [Mon, 10 Apr 2023 02:44:54 +0000 (11:44 +0900)]
util/blake3: Patch with hidden visibility for asm symbols.
For Unix platforms, the symbol visibility needs to be hidden to avoid
exposing them in driver shared objects.
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22387>
Tatsuyuki Ishi [Thu, 30 Mar 2023 07:21:57 +0000 (16:21 +0900)]
util: Add a copy of BLAKE3 hash library.
The files are copied from upstream repo, with a few modifications to fix
build errors, as described in the README.
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22387>
Dylan Baker [Fri, 21 Apr 2023 18:36:35 +0000 (11:36 -0700)]
docs: update calendar for 23.0.3
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Fri, 21 Apr 2023 18:36:34 +0000 (11:36 -0700)]
docs: update calendar for 23.0.2
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Fri, 21 Apr 2023 18:36:33 +0000 (11:36 -0700)]
docs: update calendar for 23.0.1
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Thu, 20 Apr 2023 23:32:10 +0000 (16:32 -0700)]
docs: Add sha256 sum for 23.0.3
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Thu, 20 Apr 2023 23:06:54 +0000 (16:06 -0700)]
docs: add release notes for 23.0.3
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Fri, 7 Apr 2023 17:10:13 +0000 (10:10 -0700)]
docs: Add sha256 sum for 23.0.2
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Fri, 7 Apr 2023 16:22:42 +0000 (09:22 -0700)]
docs: add release notes for 23.0.2
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Sat, 25 Mar 2023 05:42:38 +0000 (22:42 -0700)]
docs: Add sha256 sum for 23.0.1
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Dylan Baker [Sat, 25 Mar 2023 03:04:38 +0000 (20:04 -0700)]
docs: add release notes for 23.0.1
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22635>
Rob Clark [Wed, 19 Apr 2023 20:36:58 +0000 (13:36 -0700)]
freedreno: Inline single-caller helpers
Now that we don't have the batch_reset() path, we can inline
batch_init() and batch_fini().
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22602>
Rob Clark [Wed, 19 Apr 2023 20:22:42 +0000 (13:22 -0700)]
freedreno: Remove unused fd_batch_reset()
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22602>
Gert Wollny [Fri, 21 Apr 2023 08:17:44 +0000 (10:17 +0200)]
r600/sfn: Lower tess levels to vectors in TCS
Thanks @anholt for pointing me in the right direction
Fixes:
84006587 glsl: Delete the lower_tess_level
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8884
v2: replace direct call to lowering pass with nir compiler option
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22622>
Hans-Kristian Arntzen [Fri, 21 Apr 2023 15:22:47 +0000 (17:22 +0200)]
wsi/x11: Fix present ID signal when IDLE comes before COMPLETE.
It appears to be possible that IDLE is observed before COMPLETE.
In this case, an application may access present_id in subsequent
QueuePresentKHR and race against the fence worker reading present_id.
Solve this by adding a separate signal_present_id that is used when
completing to avoid the race.
Signed-off-by: Hans-Kristian Arntzen <post@arntzen-software.no>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22633>
Samuel Pitoiset [Fri, 21 Apr 2023 09:53:30 +0000 (11:53 +0200)]
Revert "ci/radv: Demote navi21 to manual until recent flakiness resolves."
This reverts commit
2a9b990fa3ed003354f4ee68105e4f0cbf8ce0b3.
This should be fixed now.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22625>
Samuel Pitoiset [Fri, 21 Apr 2023 08:11:36 +0000 (10:11 +0200)]
radv/amdgpu: fix adding continue preambles and postambles BOs to the list
Previously, continue preambles and postambles were added directly to
the CS array which means all BOs were correctly added to the BO list,
and this has been broken recently. IB BOs need to be added to the list.
When a BO isn't added to the list as part of a submission, it might
randomly VM faults.
This fixes VM faults and random GPU hangs on NAVI21 in Mesa CI.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8849
Fixes:
41a9bced313 ("radv: Fill continue preambles and postambles properly.")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22625>
Harri Nieminen [Thu, 20 Apr 2023 10:15:05 +0000 (13:15 +0300)]
broadcom: fix typos
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22591>
antonino [Fri, 21 Apr 2023 13:09:32 +0000 (15:09 +0200)]
zink/ci: remove xt_framebuffer_multisample-interpolation fail
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22626>
antonino [Fri, 21 Apr 2023 11:25:33 +0000 (13:25 +0200)]
zink: don't render with multisampling when it is disabled
Previously zink ignored whether multisampling was enabled and rendered
with mulisampling whenever the target buffer had multiple samples.
This change now will only render with multisampling when it is enabled
and will use a lowering pass to make sure this case is handled correcly.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22626>
antonino [Fri, 21 Apr 2023 13:11:28 +0000 (15:11 +0200)]
zink: add to multisample field to `zink_gfx_pipeline_state`
This field will store whether multisample is enabled, this is needed to
manage the case where a multisampling buffer is used with multisampling
disabled.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22626>
antonino [Thu, 20 Apr 2023 13:18:23 +0000 (15:18 +0200)]
zink: add `single_sample` to fs key
This key will be 1 when a multisampled buffer is used without
multisampling enabled. This requires a lowering pass.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22626>
Mike Blumenkrantz [Thu, 13 Apr 2023 20:28:16 +0000 (16:28 -0400)]
mesa: fix ms fallback texture creation
when a ms fallback texture is created, it has to actually be a ms texture
in order to be consistent with driver expectations for a given sampler in
a shader
this adds sample querying to both ends of the fallback creation to ensure
that a sample count is passed to the driver
affects:
KHR-GL46.sample_variables.position.fixed.samples_0
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22492>
Mike Blumenkrantz [Mon, 17 Apr 2023 17:01:08 +0000 (13:01 -0400)]
mesa/st: try to block multisampled texsubimage from doing cpu writes
this is only hit when populating multisampled fallback textures, so
don't assert if it fails since some drivers are able to handle it
d3d12 can't, however, and this should be enough to work around that issue
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22492>
Lionel Landwerlin [Wed, 19 Apr 2023 19:58:16 +0000 (22:58 +0300)]
anv: rework Wa_14017076903 to only apply with occlusion queries
Fixes KHR-GL46.transform_feedback.* tests with zink+anv on DG2
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Fixes:
c34916f841d3 ("anv: implement occlusion query related Wa_14017076903")
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22586>
Samuel Pitoiset [Fri, 21 Apr 2023 11:03:40 +0000 (13:03 +0200)]
radv/ci: remove one expected test failure on PITCAIRN
After a bunch of runs, this one seems to always pass.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22623>
Patrick Lerda [Sat, 25 Mar 2023 01:14:32 +0000 (02:14 +0100)]
r600/sfn: fix memory leak related to sh_info->arrays
For instance, with "piglit/bin/shader_runner tests/spec/glsl-1.10/execution/glsl-vs-arrays-2.shader_test -auto -fbo":
Direct leak of 12 byte(s) in 1 object(s) allocated from:
#0 0x7f33c3f3d097 in operator new[](unsigned long) (/usr/lib64/libasan.so.6+0xb3097)
#1 0x7f33b9af1e5b in r600::ValueFactory::get_shader_info(r600_shader*) ../src/gallium/drivers/r600/sfn/sfn_valuefactory.cpp:1056
#2 0x7f33b9a96860 in r600::Shader::get_shader_info(r600_shader*) ../src/gallium/drivers/r600/sfn/sfn_shader.cpp:1445
#3 0x7f33b99ddd07 in r600_shader_from_nir ../src/gallium/drivers/r600/sfn/sfn_nir.cpp:1032
#4 0x7f33b9c3e701 in r600_pipe_shader_create ../src/gallium/drivers/r600/r600_shader.c:231
Fixes:
79ca456b4837 ("r600/sfn: rewrite NIR backend")
Signed-off-by: Patrick Lerda <patrick9876@free.fr>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22262>
Martin Roukala (né Peres) [Thu, 20 Apr 2023 17:55:49 +0000 (20:55 +0300)]
zink/ci: document that some tests no longer fail
This is likely to have been fixed by
6a39d35df062 ("aco: fix nir_f2u64
translation") (thanks @DadSchoorse!).
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22596>
Martin Roukala (né Peres) [Thu, 20 Apr 2023 12:21:02 +0000 (15:21 +0300)]
radv/ci: only reboot on hangs for vkcts-navi10-valve
vkcts-navi10-valve has the nasty habit on hanging the GPU, so we
introduced an auto-retry... but for every radv job. Let's stop doing
that, and instead limit the auto-retry to vkcts-navi10-valve only.
Additionally, let's increase the number of attempts to 3 (2 retries),
as sometimes, it may still fail and we don't want to flag it as a
fail in nightly runs.
Let's hope we'll get to the bottom of this hang sooner rather than
later, so that we can remove this hack!
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22596>
Martin Roukala (né Peres) [Thu, 20 Apr 2023 12:20:04 +0000 (15:20 +0300)]
ci/b2c: allow not specifying a reboot condition
This will allow us to only enable this feature where we need it.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22596>
Martin Roukala (né Peres) [Thu, 20 Apr 2023 12:02:33 +0000 (15:02 +0300)]
radv/ci: document all the flakes we hit while I was away
Closes: 8817
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22596>
Martin Roukala (né Peres) [Thu, 20 Apr 2023 07:23:36 +0000 (10:23 +0300)]
radv/ci: disable the vkcts-navi21-llvm-valve job
It is badly-broken and until someone actually fixes it, it provides
no additional value to other developers.
We'll keep the job around, as a courtesy to the developer that will
be trying to fix it.
Closes: #8799
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22596>
Juan A. Suarez Romero [Thu, 20 Apr 2023 15:04:20 +0000 (17:04 +0200)]
v3d/ci: annotate failure
The test requires a fix already submitted to piglit.
Reviewed-by: Emma Anholt <emma@anholt.net>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22607>
Juan A. Suarez Romero [Thu, 20 Apr 2023 14:56:22 +0000 (16:56 +0200)]
v3d: use primitive type to get stream output offset
So far we were only considering the number of vertices to draw to
compute the offset in a stream output buffer.
But this is not correct, as it depends on the primitive type too. For
instance, with 4 vertices, if we use a triangle strip primitive, then 2
triangles are generated from those 4 vertices, so 6 vertices will be
captured.
This fixes spec@!opengl es
3.0@gles-3.0-transform-feedback-uniform-buffer-object.
CC: 23.1
Reviewed-by: Emma Anholt <emma@anholt.net>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22607>
Sergi Blanch Torne [Thu, 13 Apr 2023 09:51:29 +0000 (11:51 +0200)]
ci: Move Vulkan CTS patches to their own directory
VulkanCTS can receive patches from a reference to an upstream commit or by a
file stored in Mesa. Those locally stored patches for VulkanCTS should be
stored in the specific directory for patches with a prefix like skqp does.
The schema of how both sources apply patches has received a slight
modification to resemble each other.
Signed-off-by: Sergi Blanch Torne <sergi.blanch.torne@collabora.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Acked-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22463>
xurui [Thu, 20 Apr 2023 09:32:39 +0000 (17:32 +0800)]
zink: Add some printfs when initialization fails
Signed-off-by: xurui <xurui@kylinos.cn>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22592>
Michel Zou [Thu, 20 Apr 2023 17:10:56 +0000 (19:10 +0200)]
mesa/draw: fix -Wformat warning
fixes:
5791826b
cc @pepp @mareko
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22605>
Rob Clark [Thu, 20 Apr 2023 18:57:31 +0000 (11:57 -0700)]
freedreno/a6xx: Fix valid_format_cast logic for newer a6xx
Fixes a pile of
dEQP-GLES31.functional.copy_image.non_compressed.viewclass_32_bits.*
on a6xx gen2 and later.
Fixes:
87978c39334 ("freedreno/a6xx: Allow z24s8 format casts")
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22610>
Jesse Natalie [Thu, 20 Apr 2023 17:38:49 +0000 (10:38 -0700)]
dzn: Support aniso-with-point-mip samplers
Also rework the sampler translation logic to take advantage of the
fact that the D3D12 filter types are bitfields. No need to loop over
a sparse enum space like we were doing.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22606>
Jesse Natalie [Thu, 20 Apr 2023 17:21:55 +0000 (10:21 -0700)]
dzn: Use narrow quadrilateral lines when supported
This lets us follow the Vulkan spec requirements for MSAA line
rasterization, using a width of 1.0 instead of D3D's proscribed
width of 1.4. There's no reason to predicate this on MSAA being
enabled, since quadrilateral lines with a width of 1.0 are actually
the most desired type of line rasterization for Vulkan.
Follow-ups:
- We can probably turn on 'strict lines' when this is supported.
- We should enable the line rasterization mode extension.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22606>
Jesse Natalie [Thu, 20 Apr 2023 17:15:09 +0000 (10:15 -0700)]
dzn: Support dynamic depth bias via command list instead of PSO
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22606>