Commit graph

157808 commits

Author SHA1 Message Date
Bas Nieuwenhuizen
040aeb5a23 radv: Add asserts in radeon_emit{,_array}.
Also add an unsafe helper for some winsys stuff that can't really
use the reservation mechanism (e.g. chaining between cmdbuffers).

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20152>
2023-04-30 22:33:52 +02:00
Bas Nieuwenhuizen
7893040f80 radv: Add stricter space checks.
The check for max_dw means that none of checks triggered reliably
when we had an issue. Use a stricter reserved dw measure to increase
the probability of catching issues.

Adds a radeon_check_space to some places after cs_create as they
previously relied on the min. cs size, but that would still trigger
the checks.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20152>
2023-04-30 22:33:52 +02:00
Bas Nieuwenhuizen
4c204db0a7 radv: Reserve space in the ACE pre/postambles.
Since we check reservations now.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20152>
2023-04-30 22:33:52 +02:00
Bas Nieuwenhuizen
17a7c55ea7 radv: Reserve space for indirect descriptor set address writes.
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20152>
2023-04-30 22:33:52 +02:00
Pavel Ondračka
775e42e6b8 r300: remove simple duplicate ARL instructions
Removes duplicate ARL reads from the same source when the original ADDR
register is still live. This is the remaining low-hanging fruit from #7723
Should account for most of the potential improvements and is also
trivial as no source or destination rewrite is needed.

RV530:
total instructions in shared programs: 132447 -> 131488 (-0.72%)
instructions in affected programs: 33396 -> 32437 (-2.87%)
helped: 331
HURT: 0
total temps in shared programs: 17035 -> 17015 (-0.12%)
temps in affected programs: 361 -> 341 (-5.54%)
helped: 30
HURT: 10

RV370:
total instructions in shared programs: 83555 -> 82659 (-1.07%)
instructions in affected programs: 28310 -> 27414 (-3.16%)
helped: 312
HURT: 0
total temps in shared programs: 12418 -> 12426 (0.06%)
temps in affected programs: 302 -> 310 (2.65%)
helped: 21
HURT: 29

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/22752>
2023-04-29 18:10:11 +00:00
Erik Faye-Lund
c5b3d488f9 mesa/main: make ffvertex output nir
There's little point in going from fixed-function to ARB progs just to
convert it to NIR in the end. So let's emit NIR code directly here
instead.

This all made sense back when we had DRI drivers that didn't use NIR at
all in the tree, but these days we unconditionally call prog_to_nir.

Since we're no longer generating something that resembles ARM asm
shaders, we also no longer pass is_arb_asm as true to NewProgram. But
we still require legacy math rules, so we set use_legacy_math_rules in
the shader_info instead. This should do the same thing, but
communicates exactly what we actually need rather than having a half-
truth about the source of the shader.

Acked-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22520>
2023-04-29 12:39:18 +00:00
Erik Faye-Lund
7610747e94 mesa/main: allow passing nir-shaders to st_program_string_notify
This will enable us to emit NIR directly for fixed-function vertex
shaders.

Acked-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22520>
2023-04-29 12:39:18 +00:00
Erik Faye-Lund
fdd20b9469 mesa/main: drop disasm-code from ffvertex_prog.c
We're about to rewrite this code to emit NIR directly, so let's drop
this needless logic.

Acked-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22520>
2023-04-29 12:39:18 +00:00
Erik Faye-Lund
972c923592 mesa/main: clean up white-space in ffvertex_prog.c
We're about to change this file, so let's clean up the whitespace a bit
first.

Acked-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22520>
2023-04-29 12:39:17 +00:00
Jesse Natalie
5c1a8d3b77 meson: Don't use masm with VS backend
Fixes: 77826e83 ("util: Add a copy of BLAKE3 hash library.")
Reviewed-by: Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22740>
2023-04-29 05:23:15 +00:00
antonino
b7f815117e Revert "zink: add single_sample to fs key"
This reverts commit 420f2c0878.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22753>
2023-04-29 04:59:11 +00:00
antonino
e7b03fa3dc Revert "zink: add to multisample field to zink_gfx_pipeline_state"
This reverts commit 14d5892609.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22753>
2023-04-29 04:59:11 +00:00
antonino
8cbd6acf12 Revert "zink: don't render with multisampling when it is disabled"
This reverts commit a004825266.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22753>
2023-04-29 04:59:11 +00:00
antonino
6b9f1a540d Revert "zink/ci: remove xt_framebuffer_multisample-interpolation fail"
This reverts commit 177c92fe7c.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22753>
2023-04-29 04:59:11 +00:00
antonino
9a8a397294 Revert "zink: set when pipeline dirty flag when multisample changes"
This reverts commit 5969541123.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22753>
2023-04-29 04:59:11 +00:00
Mike Blumenkrantz
0b64c73779 zink: add extendedDynamicState3DepthClipNegativeOneToOne to profile
Fixes: 3017d01c9d ("zink: check for extendedDynamicState3DepthClipNegativeOneToOne for ds3 support")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22765>
2023-04-29 04:39:20 +00:00
Mike Blumenkrantz
8e664816fc zink: update amdpro fails
how is this driver still so broken

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22761>
2023-04-29 04:19:33 +00:00
Mike Blumenkrantz
e9864d7f39 llvmpipe: fix native vector width init
this otherwise causes infinite loops in subgroup tests
and kills ci

Fixes: 4a056807bc ("gallivm: break out native vector width calc for reuse")

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22767>
2023-04-29 03:36:19 +00:00
Dave Airlie
78ea6220a7 gallivm: reorder some texture/image members.
This just aligns texture/image a bit more, shouldn't have much
affect, but might make things easier going forward.

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18265>
2023-04-29 02:57:19 +00:00
Dave Airlie
d32aa2686c gallium: consolidate jit image types between draw/llvmpipe
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18265>
2023-04-29 02:57:19 +00:00
Dave Airlie
d3ed01d5eb gallivm: consolidate llvmpipe/draw sampler types.
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18265>
2023-04-29 02:57:19 +00:00
Dave Airlie
fd2902a1cf gallivm: consolidate draw/lp texture type.
This just makes the type creation, struct and fields the same.

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18265>
2023-04-29 02:57:19 +00:00
Dave Airlie
5f22f35590 lp_jit: use pipe max for the lp_jit texture levels.
Align this with draw, so we the structs can be shared.

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18265>
2023-04-29 02:57:19 +00:00
Mike Blumenkrantz
af214c233b ci: disable all a306/a530/a630 jobs
these have been dead and timing out all day

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22768>
2023-04-28 22:27:04 -04:00
David Heidelberg
4f1716ebca ci/dzn: add flaking test
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22766>
2023-04-28 22:35:21 +02:00
Ruijing Dong
b07f575a91 radeonsi/vcn: correct cropping for hevc case
reason:

corect cropping calculation error.

If no cropping from the external, then it will
need to calculate cropping size internally, the
padding size on left and top should be zero.

Cc: mesa-stable
Fixes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7171
Reviewed-by: Thong Thai <thong.thai@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22758>
2023-04-28 18:07:42 +00:00
Samuel Pitoiset
faf27fa0a2 ac/nir: fix 8-bit/10-bit PS exports clamping
This broke many tests on GFX6 (Pitcairn).

Fixes: c182154456 ("ac/nir: add ac_nir_lower_ps")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22756>
2023-04-28 17:38:06 +00:00
Samuel Pitoiset
559d3b0f9a ac,radv,radeonsi: rename thread_trace to sqtt everywhere
SQTT stands for SQ Thread Trace but it's shorter.
Note that environment variables aren't renamed because this might
break external applications.

This renames:
- ac_thread_trace_data to ac_sqtt (this is the main struct)
- ac_thread_trace_info to ac_sqtt_data_info
- ac_thread_trace_se to ac_sqtt_data_se
- ac_thread_trace to ac_sqtt_trace (this contains trace only)

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22732>
2023-04-28 16:55:13 +00:00
Samuel Pitoiset
c2d312c401 ac/rgp: remove ac_thread_trace_data from ac_thread_trace
We only need the RGP objects.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22732>
2023-04-28 16:55:13 +00:00
Samuel Pitoiset
3a19c36618 radv: do not abort when the SQTT buffer resize failed
This seems to much. While we are at it, update the error msg.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22732>
2023-04-28 16:55:12 +00:00
Samuel Pitoiset
1202d8b0f9 ac/sqtt: add ac_sqtt_get_trace() helper
It can be shared between RADV and RadeonSI. The only difference is
that RadeonSI can't auto-resize the SQTT BO.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22732>
2023-04-28 16:55:12 +00:00
Samuel Pitoiset
d0a11c5b9e ac/sqtt: add ac_sqtt_se_is_disabled() helper
It can be shared between RADV and RadeonSI.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22732>
2023-04-28 16:55:12 +00:00
Matt Coster
a031bfdb9d pvr: Fixup format features
Fixes: dEQP-VK.api.info.format_features.*

Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22749>
2023-04-28 15:37:59 +00:00
Matt Coster
37f202a54a pvr: Remove false assumption from pvr_write_draw_indirect_vdm_stream()
Partially reverts: bd51305943
  pvr: Minor cleanup around pvr_emit_vdm_index_list()

Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22751>
2023-04-28 15:21:08 +00:00
Eric Engestrom
5d11e50367 v3d: fix various minor issues in gen_pack_header.py
Signed-off-by: Eric Engestrom <eric@igalia.com>
Acked-by: Juan A. Suarez <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22742>
2023-04-28 14:53:10 +00:00
José Roberto de Souza
ec6d520eb9 iris: Allow shared scanout buffer to be placed in smem as well
i915 and Xe kmd allows scanout to display of prime buffers placed
in smem.

Allowing shared and scanout bos to be placed in smem and lmem allows
the dma buf to work in some cases that only lmem is not enough.

Fixes: c10ff19704 ("iris: Place scanout buffers only into lmem for discrete GPUs")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8867
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8766
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Tested-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22665>
2023-04-28 14:29:14 +00:00
Gert Wollny
8b52c9bab7 r600/sfn: Tie in address load splitting
Add R600_NIR_DEBUG flag "noaddrsplit" to disable the behaviour and use the
old code path.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
4beefbe074 r600/sfn: prepare for emitting AR loads
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
5da9f08657 r600/sfn: factor out index loading for non-alu instructions
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
9f39531743 r600/sfn: Can't use an indirect array access as source to AR load
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
ae55668f77 r600/sfn: print failing block when scheduling fails
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
fdec18640a r600/sfn: Add more tests and update to use address splits
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
7fdb056277 r600/sfn: scheduled instructions are always ready
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
5d6b80bf5b r600/sfn: Fix copy-prop with array access
We will have to check whether there is access to an array between the
instructions involved with the copy prop, so for now do not allow it.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
062188de16 r600/sfn: Override Array access handling in backend assembler
Since we do thi sin the scheduler, there is no need to do this in the
backend again.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
e57643cf54 r600/sfn: Add handling for R600 indirect access alias handling
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
d955633319 r600/sfn: Add chip family to shader class
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
4d5859a524 r600/sfn: Start a new ALU CF on index use, not on index emission
With that we can use the two IDX registers in parallel any might
save some CF instructions.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
557dc14944 r600/sfn: set CF force flag always when starting a new block
There is no reason not to do this, because we only start a new
block if a new CF block must be started.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00
Gert Wollny
e9e1806a2e r600/sfn: Add test for multiple index load
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21347>
2023-04-28 13:13:55 +00:00