ttn: Set nir->info.separate_shader

TGSI has no legitimate[1] notion of linked shaders, which means tgsi_to_nir
should conservatively assume everything all shaders are separable. This requires
setting nir->info.separate_shader to warn drivers that shader CSOs might be
mixed and matched. Otherwise, the driver might enable optimizations that
are invalid for separate shaders, causing issues when the shaders are
later treated as separable.

This will fix varying linking with u_blitter's shaders on Panfrost (Bifrost and
older), when util_blitter_clear is used with Panfrost.

[1] There was a TGSI property added recently to forward
nir->info.separate_shader up to virglrenderer, but it's not actually used for
anything in virglrenderer and I am still struggling to understand what the use
case would be. My gut says we should revert b6340305 ("tgsi: Add
SEPARABLE_PROGRAM property"), but I'm not interested in fighting that yak right
now. Notably, the u_blitter and hud shaders are separable but are not marked
with this property.

Signed-off-by: Alyssa Rosenzweig <>
Reviewed-by: Emma Anholt <>
Reviewed-by: Timothy Arceri <>
Cc: mesa-stable
Part-of: <!17282>
158 jobs for !17282 with tgsi/separable-fix in 53 minutes and 8 seconds (queued for 9 seconds)
latest merge request