Konstantin Seurer
723922b6f1
gallium/nir: Handle unified atomics in nir_to_tgsi_info
...
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23016 >
2023-05-15 14:15:02 +00:00
Alyssa Rosenzweig
508b7bba7a
radv: Use common GetPhysicalDeviceFeatures2
...
This is a big delete-the-code win. Tested by diff'ing vulkaninfo output
before/after the patch and confirming no changes (other than the driverInfo git
sha and the pipelineCacheUUID).
Note: removes handling for VkDeviceMemoryOverallocationCreateInfoAMD. This was
surely added as a mistake.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22999 >
2023-05-15 13:42:55 +00:00
Alyssa Rosenzweig
83bc32d55d
radv: Constify radv_device_supports_etc
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22999 >
2023-05-15 13:42:55 +00:00
Luigi Santivetti
a229f6cd2e
pvr: fixup stack overflow in {start,end}_sub_cmd
...
Signed-off-by: Luigi Santivetti <luigi.santivetti@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22955 >
2023-05-15 12:42:52 +00:00
Mike Blumenkrantz
b563bfb4ee
zink: add some ci flakes
...
roundup from recent ci jobs
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23021 >
2023-05-15 12:07:16 +00:00
Rhys Perry
811f3843d9
amd/drm-shim: add navi10
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22989 >
2023-05-15 11:32:07 +00:00
Rhys Perry
3a04a38320
amd/drm-shim: add vega10
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22989 >
2023-05-15 11:32:06 +00:00
Rhys Perry
0f2220fb22
amd/drm-shim: add polaris10
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22989 >
2023-05-15 11:32:06 +00:00
Rhys Perry
9ed3e0db5d
amd/drm-shim: move device list to external file
...
This is already pretty large.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22989 >
2023-05-15 11:32:06 +00:00
antonino
71107b6dc8
zink: don't create invalid inputs in zink_create_quads_emulation_gs
...
The helper was creating input locations for some builtin bariables.
This caused validation errors in zink because those builtins can't be
used as input.
Fixes: e2220ee55e ("zink: filled quad emulation gs generation function")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
antonino
b5818e2e4f
nir: make var arrays large enough in nir_create_passthrough_gs
...
Because each location has 4 possible different values for location_frac
the arrays need to br 4x the size.
Fixes: d0342e28 ("nir: Add helper to create passthrough GS shader")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
antonino
474d93719e
zink: handle interface blocks in copy_vars
...
Fixes: edaf49160e ("zink: fix array copying in pv lowering")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
antonino
8f22669f9b
nir: handle interface blocks in copy_vars
...
Fixes: 99121c9b77 ("nir/gs: fix array type copying for passthrough gs")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
antonino
a4113fd021
zink: don't replace non generated gs
...
Zink replaced the gs emulation shader when the primitive type changes,
however it didn't check whether the gs being replaced was generated.
Fixes: eedbf9046e ("zink: handle switching between primitives")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
antonino
83692bfe30
nir: don't create invalid inputs in nir_create_passthrough_gs
...
The helper was creating input locations for some builtin bariables.
This caused validation errors in zink because those builtins can't be
used as input.
Fixes: d0342e28b3 ("nir: Add helper to create passthrough GS shader")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
antonino
78d59ef4b1
nir: use nir_variable_clone in nir_create_passthrough_gs
...
Some stream out properties where not being copied causing problems in
zink.
Use the appropiate helper instead of copying fields by hand.
Fixes: d0342e28b3 ("nir: Add helper to create passthrough GS shader")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22871 >
2023-05-15 11:04:41 +00:00
Matt Coster
59ec79a2b8
pvr: Remove unneeded assert in pvr_get_hw_clear_color()
...
Fixes: dEQP-VK.synchronization.op.single_queue.fence
.write_draw_read_image_compute.image_128x128_r8_unorm
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reported-by: James Glanville <james.glanville@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22868 >
2023-05-15 10:31:28 +00:00
Matt Coster
fa3b7ef943
pvr: Fix off-by-one in pvr_cmd_buffer_upload_desc_set_table() assert
...
Fixes: dEQP-VK.pipeline.monolithic.dynamic_offset.compute.multiset
.uniform_buffer.numcmdbuffers_1.sameorder.numdescriptorsetbindings_1
.numdynamicbindings_2.numnondynamicbindings_1
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reported-by: James Glanville <james.glanville@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22868 >
2023-05-15 10:31:28 +00:00
Matt Coster
e90deac3d8
pvr: Correctly compile graphics pipelines without a fragment shader
...
Fixes: dEQP-VK.pipeline.monolithic.stencil.nocolor.format.s8_uint
.states.fail_keep.pass_keep.dfail_repl.comp_greater_or_equal
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reported-by: James Glanville <james.glanville@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22868 >
2023-05-15 10:31:28 +00:00
Matt Coster
36db17dfa5
pvr: Initialize aspect_mask when creating buffer views
...
Fixes random aborts in CSB handling.
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reported-by: James Glanville <james.glanville@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22868 >
2023-05-15 10:31:28 +00:00
Matt Coster
5f8320bd04
pvr: Actually check for depth load when setting up load op constants
...
Fixes: Assorted tests in dEQP-VK.draw.renderpass.*
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Reported-by: James Glanville <james.glanville@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22868 >
2023-05-15 10:31:28 +00:00
Samuel Pitoiset
8939b80bf5
radv: stop using the pipeline for determining the null export workaround
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22981 >
2023-05-15 09:32:58 +00:00
Samuel Pitoiset
d73b6ce1c7
radv: remove unused pipeline param in radv_generate_ps_epilog_key()
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22981 >
2023-05-15 09:32:58 +00:00
Samuel Pitoiset
def2ac22b3
radv: reset the emitted PS epilog when a new fragment shader is bound
...
When a new fragment shader is bound, the PS epilog needs to be
re-emitted, and this allows us to avoid tracking if the pipeline is
dirty.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22981 >
2023-05-15 09:32:58 +00:00
David Heidelberg
297859c56b
panvk: drop path from panvk_physical_device struct
...
Unnecessary. Only produces warning:
```
../src/panfrost/vulkan/panvk_device.c:437:4: warning: 'strncpy' specified bound 20 equals destination size [-Wstringop-truncation]
437 | strncpy(device->path, path, ARRAY_SIZE(device->path));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22880 >
2023-05-15 09:15:59 +00:00
Konstantin Seurer
a94f089865
radv/ci: Test ray tracing pipelines
...
Since we expose them for a few games by default now, it would make sense
to have test coverage for them.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Acked-by: Martin Roukala <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21638 >
2023-05-15 08:37:48 +00:00
Samuel Pitoiset
10d1073aa6
radv: advertise VK_EXT_tooling_info
...
This small extension just returns active tools running like RGP.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22954 >
2023-05-15 08:13:18 +00:00
Iago Toral Quiroga
66b3d34633
broadcom/compiler: use unified atomics
...
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22939 >
2023-05-15 07:43:09 +00:00
Samuel Pitoiset
9fa9782c17
radv: stop compiling a noop FS when the application doesn't provide a FS
...
This is unnecessary because the hardware doesn't execute a FS when it
has no effect and it's possible to execute pre-rasterization stages
without a FS.
This might improve depth-only pass performance very slightly because
the number of packets emitted is reduced a bit.
No fossils-db changes.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22848 >
2023-05-15 07:09:56 +00:00
Samuel Pitoiset
7f47886cf1
radv: allow to determine NGG settings with a NULL fragment shader
...
This shouldn't change anything because a noop FS doesn't read any
inputs.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22848 >
2023-05-15 07:09:56 +00:00
Samuel Pitoiset
d91cb1bbfa
radv: rework the checks for implicit exports with GPL
...
No logical changes but this allows us to distinguish between noop FS
and unknown FS with GPL.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22848 >
2023-05-15 07:09:56 +00:00
Samuel Pitoiset
333c8773a4
radv: handle NULL fragment shaders when creating graphics pipelines
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22848 >
2023-05-15 07:09:55 +00:00
Samuel Pitoiset
87245c6e8e
radv: handle NULL fragment shaders when recording cmdbuf
...
This will be useful for shader objects and also because creating and
emitting a noop FS is useless, the hardware doesn't execute it.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22848 >
2023-05-15 07:09:55 +00:00
Samuel Pitoiset
c51c68ba4b
radv: implement dynamic sample locations enable
...
VK_EXT_sample_locations is only supported on < GFX10 due to some weird
issues on recent GPUs. extendedDynamicState3SampleLocationsEnable is
only enabled on GFX6-GFX9 for the same reason.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22947 >
2023-05-15 08:14:31 +02:00
Filip Gawin
4a379f7637
glx: fix build with APPLEGL
...
fixes: 1eab7e69e2
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8885
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22621 >
2023-05-15 03:50:30 +00:00
Qiang Yu
d1dd36a74e
radeonsi: be able to use aco compiler for mono ps
...
Need to set AMD_DEBUG=useaco environment variable.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
288adae512
radeonsi: fixup sampler desc for tg4 in nir
...
For ACO which won't do this for us. But we still can't
remove the same code in llvm because non-uniform sampler
is keept as index in nir.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
521cbcb588
ac/llvm,radeonsi: enable lower_array_layer_round_even
...
ACO need this to be done in nir. Remove the llvm round code
because both radv and radeonsi do this in nir for both aco
and llvm.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
38e064b674
radeonsi: clamp shadow texture reference in nir for aco
...
This is ported from the LLVM ac_shader_abi->clamp_shadow_reference
code.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
b5409131ef
radeonsi: pass use_aco to ac_nir_lower_ps
...
For dual source blend code emition in aco.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
7180b16afc
radeonsi: adjust ps args for aco
...
aco need explicite args including PS arg compaction and
scratch_offset.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
474ddeffe6
radeonsi: resolve aco scratch addr symbols
...
Used for scratch buffer operation and reg spill when aco.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
7aac3508dc
radeonsi: add symbols to si_shader_binary
...
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
6a360e4a71
radeonsi: add initial aco compile code
...
Only for monolithic PS.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
91c91bb972
radeonsi: lower non uniform texture access when aco
...
aco need all resource have been lowered to descriptor.
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/22573 >
2023-05-15 02:01:11 +00:00
Qiang Yu
f859436b55
radeonsi: add has_non_uniform_tex_access shader info
...
Can be used to skip nir_lower_non_uniform_access pass.
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/22573 >
2023-05-15 02:01:10 +00:00
Qiang Yu
563bdcc7fc
radeonsi: lower vector const to scalar at last for aco
...
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/22573 >
2023-05-15 02:01:10 +00:00
Qiang Yu
e252d87816
radeonsi: lower some 64bit ops aco does not support
...
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/22573 >
2023-05-15 02:01:10 +00:00
Qiang Yu
9bc1fb4c07
ac/llvm,radeonsi: lower nir_fpow for aco and llvm
...
aco does not implement fpow, need nir to lower it
first. llvm will do by itself in the same way, so
we always lower fpow in nir now.
Remove the llvm fpow implementation that has special
handling for the muliplication. It's not used any
more and does not match GLSL spec as fpow(0,0)=NaN
but here we get 0.
There's some pixel changes for gl-radeonsi-stoney:
ror-default 2 (no tolerance), 0 (1% tol.)
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/22573 >
2023-05-15 02:01:10 +00:00
Qiang Yu
19a8626f86
ac/llvm,radeonsi: lower some pack/unpack ops not supported by aco
...
aco only support the split vertion of these instructions.
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/22573 >
2023-05-15 02:01:10 +00:00