Skip to content

turnip: fix render_components value

Jonathan Marek requested to merge flto/mesa:turnip0 into master

This fixes render_components being 0 when mrt_count=8, because shift by 32 is UB and in arm64 it ends up shifting by 0. This fixes tests with 8 MRTs.

Fixes the 3d path sysmem CmdClearAttachments to set RENDER_COMPONENTS, as it was previously relying on tu6_emit_mrt setting it, but it is now part of the pipeline state.

Also switch back to the previous behavior of not setting render components for VK_ATTACHMENT_UNUSED attachments: we don't update the MRT state for such attachments so we definitely don't want to be trying writing to those.

Fixes: 078aa9df ("tu: Move RENDER_COMPONENTS setting to pipeline state")

@anholt this should let you remove the 8 attachment fails in !5266 (merged) (attachment.8 and attachment_allocation cases)

Edited by Jonathan Marek

Merge request reports