Descriptor prefetches may be generated for instructions in control flow.
This means we cannot simply emit prefetches at the end of the preamble
because that may not be dominated by all their sources. This commit uses
the helpers introduced by e7ac1094f6 ("ir3: rematerialize preamble defs
in block dominated by sources") to find the correct block to insert
prefetches.
Fixes NIR validation errors in Dying Light 2.
Signed-off-by: Job Noorman <jnoorman@igalia.com>
Fixes: 4e2a0a5ad0 ("ir3: Add descriptor prefetching optimization on a7xx")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36885>
../src/compiler/glsl/ast_function.cpp
..\src\util/u_cpu_detect.h(168): error C2220: the following warning is treated as an error
..\src\util/u_cpu_detect.h(168): warning C4197: 'uint32_t *volatile ': top-level volatile in cast is ignored
[325/1703] Compiling C++ object src/compiler/glsl/libglsl.a.p/builtin_functions.cpp.obj
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36863>
v3d_bo_set_reference, v3d_bo_unreference_locked_timed and
v3d_wait_seqno functions available since first v3d commit
45bb8f2957 ("broadcom: Add V3D 3.3 gallium driver called "vc5",
for BCM7268.") are not used since the beginning or since the
removal of its usage at 85f26828fe ("broadcom: only support
v42 and v71") and b225cdcecc ("broadcom/vc5: Update the UABI
for in/out syncobjs").
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36012>
Name the register, which is actually an array, and initialize it
programmatically using the same table as the per-primitive case. This
should produce the same value as the old hardcoded constant.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36892>
We had an extra 16 entries in the VK-to-HW table that were clearly
unnecessary because Vulkan does not allow values greater than 16 for the
primitive shading rate. This appears to be an extra debug/test thing
added by the blob. Similarly there were unused entries in the HW-to-VK
table that shouldn't be necessary. Delete them.
The HW-to-VK table was also inconsistent about whether invalid values
should be 0 or 11, fix that too.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36892>
This is allowed by the specification, as the following VUIDs state:
VUID-vkCmdResolveImage-srcImage-04446
If dstImage is of type VK_IMAGE_TYPE_3D, then for each element of
pRegions, srcSubresource.layerCount must be 1
VUID-vkCmdResolveImage-srcImage-04447
If dstImage is of type VK_IMAGE_TYPE_3D, then for each element of
pRegions, dstSubresource.baseArrayLayer must be 0 and
dstSubresource.layerCount must be 1
New tests coming for it: dEQP-VK.pipeline.*.multisample.3d.*
Reviewed-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/36895>
A tu_bo object can be in the process of being dumped during queue submit
while also being destroyed on a separate thread. During destruction, tu_bo
should be removed from the device's dump_bo_list before unmapping, this
way the mapping of any given tu_bo won't disappear while it's being dumped.
Signed-off-by: Zan Dobersek <zdobersek@igalia.com>
Reviewed-by: Mark Collins <mark@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36904>
When checking the readport config for a number of sources that
would be used in a multi-slot instruction, then return the index
of the source for which readport allocation fails.
With that we can later add a mov instruction to change the source
channels configuration.
In addition pass a std::array instead of a C-array to make the interface
more c++-like and prepare for the next patch.
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36860>
This has gotten complicated enough that we need somewhere outside of the
driver itself to give an overall flow of how the feature is implemented.
This includes a few things that are enabled in the subsequent commits,
specifically the LRZ parts.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36475>
This might actually fixes a couple of things because needed dynamic
states are computed before radv_emit_graphics_pipeline(), so dirtying
them too late doesn't make much sense.
This doesn't fix anything known.
Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36900>
Venus renderer side has strict entry points sanitization based on the
app requested app api version + physical device api version. So on the
driver, we should follow the same for legacy client apps.
Meanwhile, VK_PIPELINE_STAGE_NONE can't be used when we hit the sync2
emulation path, so we swap it with VK_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT
placeholder for the 2nd sync scope there.
Fixes: 07cee75c39 ("venus: layer vkQueueSubmit2 over vkQueueSubmit w/o sync2")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36830>