The legacy::PassManager is only required to run backend optimizations
and for code generation. It should be deprecated when the new PM
can handle code generation on its own.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30506>
quiet a big pile of:
TU: error: ../src/freedreno/vulkan/tu_knl_drm_virtio.cc:1299: could not get connect vdrm: No such file or directory (VK_ERROR_INCOMPATIBLE_DRIVER)
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31243>
number of log splat would be proportional to # of enabled vdrm drivers
otherwise. silences a pile of
MESA: info: wrong context_type: 2
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31243>
On GFX6-8, there are some cases where the view must use mip0 and
minified image sizes. Otherwise, samplers use BASE_LEVEL=level and
image sizes.
Note that CB/DS surfaces use minified image sizes because the mip
level can't be set in registers.
This fixes an issue uncovered by c87ce78d10 ("ac/surface: enable
thick tiling for 3D textures for better perf on gfx6-8"). But it
also fixes a bunch of Zink failures specific to GFX6-8.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11112
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31363>
When processing the last instruction prior to the block terminator,
ir3_shader_folding can append a new instruction prior to the
terminator, so the `current_instruction->next == new_instruciton`
instead of `current_instruction->next == terminator` which leads
to the assert in `foreach_instr` being hit, so use
`foreach_instr_safe`.
Signed-off-by: Karmjit Mahil <karmjit.mahil@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31478>
Moves most of the implementation of CmdDispatchBase into a new static
function cmd_dispatch which will also be used by CmdDispatchIndirect
once implemented.
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31370>
The basic logic is taken form npx's linux-imx git repository (branch lf-6.1.1-1.0.0).
I have removed the support for 16 MRTs (gcv880/0x5124/0x103) and the gcv900/0x5250 case
for 8 MRTs.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
We want to use some render targets for internal use. For instance, the
blob uses two render targets for GL_RGBA32F emulation.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
I have not seen any usage of TS when MRTs are used in my traces for
GC2000. I think that this is related to gcvFEATURE_MRT_TILE_STATUS_BUFFER
found in some galcore kernel headers.
We need to take extra care as those render targets might already have valid
TS state, because they have been fast cleared or have been rendered to with
a state that did allow TS usage.
Fixes piglit's related to MRTs on GC2000.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
The mapping between fragment shader output and and render target is not
fixed and depends on the framebuffer state. Apply the mapping during the
linking of the shaders.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
Accessing the color with an index that will be in range of
[0..nr_cbus) is wrong. Just pass the clear color down to
the callee.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
Adds also the handling of independent_blend_enable that is supported by
HALTI5+ GPUs.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
We do not need to emit states for render targets 1..7 as
the GPU only processes up to VIVS_PS_CONTROL_RT_COUNT(..) ones.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
Sadly there is quite some use if's as the TS config values are different
for rt0 and the rest.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>
The GPU needs all the active (non-null) render targets in a
contiguous representation. For instance, if fb->nr_cbufs is 4 but
fb->cbufs[0] and fb->cbufs[1] are null we need to program the GPU that
fb->cbufs[2] is configured via PE_COLOR_FORMAT and friends and
fb->cbufs[3] via PE_RT_CONFIG[0] and friends.
We need to keep track which render target is used as we need to update
the fragment shader output mapping.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26565>