Commit Graph

183432 Commits

Author SHA1 Message Date
Samuel Pitoiset
3a776f036f radv: use radv_shader_stage_key directly with pre-existing fields
More fields will be moved to radv_shader_stage_key but start using it
with pre-existing fields.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27007>
2024-01-15 11:49:04 +00:00
Samuel Pitoiset
28e330c245 radv: add radv_shader_stage_key to radv_shader_stage
For storing the per-stage key information like robustness etc. This
will fit well with ESO as well.

For pipelines, they are copied from radv_pipeline_key, similarly to
the radv_pipeline_layout/radv_shader_layout pair.

This will also allow us to kill radv_pipeline_key for compute/rt
pipelines.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27007>
2024-01-15 11:49:04 +00:00
Samuel Pitoiset
cff2a3aafc radv: move radv_pipeline_key::mesh_fast_launch_2 to the per-device cache key
This is a global thing.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27007>
2024-01-15 11:49:04 +00:00
Samuel Pitoiset
d74150fc66 radv: remove one unused parameter in radv_fill_shader_info_ngg()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27007>
2024-01-15 11:49:04 +00:00
Samuel Pitoiset
138ce72860 radv/nir: remove useless struct for nir_shader typedef
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27007>
2024-01-15 11:49:04 +00:00
Samuel Pitoiset
18349692d0 radv/nir: pass radv_shader_stage to some radv_nir_xxx() functions
Instead of passing separate parameters for args, layout, info etc.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27007>
2024-01-15 11:49:04 +00:00
Lionel Landwerlin
7e111268f1 intel/hang_viewer: add aux-tt view
Allows you to visualize the AUX-TT.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27058>
2024-01-15 11:16:40 +00:00
Lionel Landwerlin
78a881af43 intel/genxml: add GAM done register description
Useful if you encounter some kind of pagefault (including with
AUX-TT).

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27058>
2024-01-15 11:16:40 +00:00
Lionel Landwerlin
547c2f3d3f intel/genxml: add CCS_INSTDONE register
Gives us the ability to check whether the compute command streamer is
hung.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27058>
2024-01-15 11:16:40 +00:00
Lionel Landwerlin
f78fac623a intel/decoder: don't ignore BT entries at offset 0
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27058>
2024-01-15 11:16:40 +00:00
Lionel Landwerlin
7107ed55c0 intel/decoder: make vertex data decoding optional
When capturing INTEL_DEBUG=capture-all and the application has like
1Gb of vertex data, you might not want to actually decode it when
looking at the error state.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27058>
2024-01-15 11:16:40 +00:00
Lucas Stach
e481c1269c etnaviv: disable 64bpp render/sampler formats
Vivante hardware handles 64bpp render targets and samplers in a odd way
by splitting the buffer and using a pair of texture samplers or a pair
of MRT outputs to access those resources. This isn't implemented in the
driver right now, so we should not advertise support for those formats.

CC: mesa-stable
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26982>
2024-01-15 10:01:27 +00:00
Samuel Pitoiset
6febec12e4 radv: correctly return VK_ERROR_OUT_OF_DEVICE_MEMORY when mapping a BO fails
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27039>
2024-01-15 09:41:55 +00:00
Samuel Pitoiset
4fe5f06d40 radv/rt: re-use radv_ray_tracing_stage::sha1 for hashing RT pipelines
radv_ray_tracing_stage::sha1 is radv_pipeline_key+shader_sha1 which
should be similar to what the code was doing.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27030>
2024-01-15 08:58:37 +00:00
Samuel Pitoiset
bb86fc0359 radv: constify stages in radv_rt_fill_group_info()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27030>
2024-01-15 08:58:37 +00:00
Tapani Pälli
36f428f1de anv: check for wa 16013994831 in emit_so_memcpy_end
We are toggling preemption on/off during streamout, this is also
happening on gfx12 platforms, not just dg2.

Cc: mesa-stable
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27002>
2024-01-15 08:36:29 +00:00
Vinson Lee
73835874a8 intel/disasm: Remove duplicate variable reg_file
Fix defects reported by Coverity Scan.

Evaluation order violation (EVALUATION_ORDER)
write_write_typo: In reg_file = reg_file = brw_inst_dpas_3src_dst_reg_file(devinfo, inst),
reg_file is written twice with the same value.

Fixes: 1c92dad5cb ("intel/disasm: Disassembly support for DPAS")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27056>
2024-01-15 07:46:12 +00:00
Dmitry Osipenko
e84aa455e5 iris: Use Mesa internal drm-uapi headers
Iris driver includes system DRM UAPI header before the Mesa's internal
ones, which makes Iris to use the system headers. Correct the included
header for consistency with the rest of the Intel driver code by changing
the inclusion order, like it's done by the rest of the Intel driver code.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27043>
2024-01-15 07:06:33 +00:00
Lionel Landwerlin
a34a113059 anv: hide vendor ID for The Finals
XeSS workaround.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10436
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27057>
2024-01-15 08:08:56 +02:00
Lionel Landwerlin
ff6041afdf intel/aux_map: fix fallback unmapping range on failure
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Fixes: 7c6faa1efe ("intel/aux_map: introduce ref count of L1 entries")
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27057>
2024-01-15 08:08:21 +02:00
Marek Olšák
33b77ec774 cso: don't unbind vertex buffers when enabling/disabling u_vbuf
The next set_vertex_buffers call always overwrites all slots anyway.

Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26309>
2024-01-14 21:55:19 +00:00
Marek Olšák
eb20ef9277 gallium: remove unbind_trailing_count from set_vertex_buffers
It should implicitly unbind all bound buffers after "count".
This also slightly simplies u_vbuf.

This is a cleanup suggested by:
    https://gitlab.freedesktop.org/mesa/mesa/-/issues/8142

Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> (asahi & panfrost)
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26309>
2024-01-14 21:55:19 +00:00
Marek Olšák
2725b095ea gallium/u_vbuf: replace unnecessary dst_index with "i"
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26309>
2024-01-14 21:55:19 +00:00
Faith Ekstrand
cfba24ccb5 nvk: Add a couple more features to features.txt
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10429
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27061>
2024-01-14 18:36:45 +00:00
Eric Engestrom
27a1b4e4f3 ci/deqp: ensure that in default builds, wayland + x11 + xcb are all built
If someone were to remove the libraries that are needed for these,
`default` would simply not enable these tests, and the only thing we
could notice is that test jobs would suddenly take less time to run.

Instead, let's have a check to make sure dEQP's cmake has detected
everything and enabled these platforms.

Reviewed-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27041>
2024-01-14 17:10:25 +00:00
Faith Ekstrand
3c7460c023 nvk: Advertise variableMultisampleRate and EDS3RasterizationSamples
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9665
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27025>
2024-01-13 18:25:20 +00:00
Faith Ekstrand
0e33dba625 nvk: Move SET_HYBRID_ANTI_ALIAS_CONTROL to draw time
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27025>
2024-01-13 18:25:20 +00:00
Faith Ekstrand
148ea7792f nvk: Emit SET_ANTI_ALIAS at draw time when no render targets are bound
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27025>
2024-01-13 18:25:20 +00:00
George Ouzounoudis
48d510ac57 vulkan: Fix null pointer dereferencing on sample locations state
In the case both sample locations and rasterization samples is supported by a
driver as dynamic state, there is a case vk_multisample_sample_locations_state_init()
does not fill ms->sample_locations at all. In this case we need to check
this pointer when dereferencing it in vk_dynamic_graphics_state_init_ms().

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27025>
2024-01-13 18:25:20 +00:00
Georg Lehmann
e36235e6d5 aco: reassign split vector to SOPC
Foz-DB Navi21:
Totals from 2669 (3.42% of 78112) affected shaders:
Instrs: 3570360 -> 3562026 (-0.23%)
CodeSize: 19049784 -> 19017092 (-0.17%)
Latency: 25343555 -> 25337767 (-0.02%); split: -0.03%, +0.00%
InvThroughput: 6191344 -> 6191079 (-0.00%); split: -0.01%, +0.00%
VClause: 90803 -> 90802 (-0.00%)
SClause: 114858 -> 114842 (-0.01%); split: -0.03%, +0.01%
Copies: 269287 -> 260999 (-3.08%)

Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27046>
2024-01-13 11:03:09 +00:00
Faith Ekstrand
94d96dac60 nak: Add explicit padding to nak_shader_info
This ensures that the padding bits stay zero, even as we copy the
structure around through multiple languages.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27049>
2024-01-12 23:58:11 +00:00
Faith Ekstrand
d280160a13 nak: Disallow gl_FragData and set MRT correctly
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27049>
2024-01-12 23:58:11 +00:00
Faith Ekstrand
005b5b1464 nvk: Set a minimum of one patch control point
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27049>
2024-01-12 23:58:11 +00:00
Faith Ekstrand
2cab67a9f1 nvk: Invalidate state after secondary command buffers
Today, the only thing that this really affects is descriptor sets and
dynamic state as everything else is re-emitted almost every time.
However, as we add more dirtying, we'll need to be more and more careful
about stale state leaking across secondary command buffer executions.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27049>
2024-01-12 23:58:11 +00:00
Faith Ekstrand
bc36dfdb5d nvk: Handle missing descriptor sets in nvk_nir_lower_descriptors
For VK_EXT_graphics_pipeline_library, we need to be able to handle
missing descriptor sets.  THis screws up dynamic buffers because we're
no longer guaranteed to be able to statically compute the index into
nvk_root_descriptor_table::dynamic_buffers while lowering descriptors.
Instead, we may need to look up the start index for the set in
nvk_root_descriptor_table::set_dynamic_buffer_start and compute from
there.

We also rework nvk_nir_lower_descriptors to take an array of (possibly
NULL) descriptor sets.  This ensures that we don't make any assumptions
about the pipeline layout.  It's also the interface we'll want for
implementing VK_EXT_shader_object.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27048>
2024-01-12 23:42:39 +00:00
Faith Ekstrand
3197aff4e8 nvk: Make dynamic cbuf indices relative to the descriptor set
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27048>
2024-01-12 23:42:38 +00:00
Faith Ekstrand
e0d907f56f nvk: Rework descriptor set binding
This prepares us for VK_EXT_graphics_pipeline_library by allowing null
descriptor sets to be bound and handling holes in pipeline layouts.  We
also add a set_dynamic_buffer_start map to the root descriptor table
which says where in dynamic_buffers each set starts.  This can be used
by the pipeline layout lowering in the case where we can't statically
the dynamic buffer index for a binding.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27048>
2024-01-12 23:42:38 +00:00
Faith Ekstrand
a11adbe408 nvk: Use s instead of set_idx in CmdBindDescriptorSets
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27048>
2024-01-12 23:42:38 +00:00
Faith Ekstrand
2d5c04ee4a nvk: Return an nvk_cbuf_map from nvk_lower_nir()
There's no need to pass in the whole shader when the only part we're
going to write is the cbuf map.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27048>
2024-01-12 23:42:38 +00:00
Faith Ekstrand
f62b5582ea nvk: Add an explicit mapping from shader stages to cbuf bindings
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27048>
2024-01-12 23:42:38 +00:00
Juan A. Suarez Romero
8120360358 Revert "v3d: show warning on creating a v3d screen on real hw"
There are paths were a v3d screen can be created instead of vc4 screen,
in a real rpi4 hardware. For instance, in the CI itself.

So assuming that it was only possible with the simulator was wrong.

This reverts commit c31be1f4ba.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27047>
2024-01-12 23:03:06 +00:00
Jesse Natalie
4cb9c77e8e mesa: Consider mesa format in addition to internal format for mip/cube completeness
Prior to 06b526de, the mesa format was used for these completeness checks.
That was to address the case where a *different* internal format selected
the *same* mesa format, and the texture shouldn't be considered compatible.
But this didn't address the case where the *same* internal format selected
a *different* mesa format, e.g. because the type passed to the TexImage
API was different.

An old WGL demo app called TexFilter.exe tries to redefine a mipped RGBA16
texture as RGBA8. This incorrect logic caused Mesa to try to copy the RGBA16
data from the smaller mips into the newly created RGBA8 data, because it
thought that the texture was still mip-complete, despite the format changing.

Cc: mesa-stable
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27023>
2024-01-12 22:26:27 +00:00
Karol Herbst
75ff6ca470 clc: add support for the native spir-v backend
This allows us to easily test if the LLVM SPIR-V backend is viable to
replace the translator.

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26955>
2024-01-12 21:58:37 +00:00
Karol Herbst
22fa315ee0 clc: use spirv triple starting with llvm-17
It's supported since a while and shouldn't regress anything.

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26955>
2024-01-12 21:58:37 +00:00
José Roberto de Souza
49fe060b5f anv: Fix PAT entry for userptr in integrated GPUs
Fixes: 060439bdf0 ("anv: Add ANV_BO_ALLOC_IMPORTED")
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27040>
2024-01-12 21:32:49 +00:00
Mike Blumenkrantz
8929257352 zink: use maint6 for multi-layer compressed surface creation
this should speed up multi-layer copying

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26953>
2024-01-12 21:05:26 +00:00
Mike Blumenkrantz
33282e7504 zink: hook up maint6
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26953>
2024-01-12 21:05:26 +00:00
Mike Blumenkrantz
4ccc91de17 zink: use local screen variable in surface creation
no functional changes

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26953>
2024-01-12 21:05:26 +00:00
Caio Oliveira
1a31970946 intel/compiler/xe2: Implement instruction compaction for DPAS.
These use different tables but map to the same bits, so it is just
a matter of picking the right tables for the instruction.

Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26860>
2024-01-12 20:18:03 +00:00
Francisco Jerez
6e56a4b474 intel/compiler/xe2: Fix for the removal of AccWrCtrl.
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26860>
2024-01-12 20:18:03 +00:00