mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 02:38:04 +02:00
panfrost: Lower clip_fs late
This pass works both early and late, so this is an easy one to sink down. Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20906>
This commit is contained in:
parent
2745daa05a
commit
21ad75d4b9
1 changed files with 6 additions and 4 deletions
|
|
@ -104,10 +104,6 @@ panfrost_shader_compile(struct panfrost_screen *screen, const nir_shader *ir,
|
|||
NIR_PASS_V(s, nir_lower_texcoord_replace, key->fs.sprite_coord_enable,
|
||||
true /* point coord is sysval */, false /* Y-invert */);
|
||||
}
|
||||
|
||||
if (key->fs.clip_plane_enable) {
|
||||
NIR_PASS_V(s, nir_lower_clip_fs, key->fs.clip_plane_enable, false);
|
||||
}
|
||||
} else if (s->info.stage == MESA_SHADER_VERTEX) {
|
||||
inputs.fixed_varying_mask = fixed_varying_mask;
|
||||
|
||||
|
|
@ -118,6 +114,12 @@ panfrost_shader_compile(struct panfrost_screen *screen, const nir_shader *ir,
|
|||
util_dynarray_init(&out->binary, NULL);
|
||||
pan_shader_preprocess(s, inputs.gpu_id);
|
||||
|
||||
if (s->info.stage == MESA_SHADER_FRAGMENT) {
|
||||
if (key->fs.clip_plane_enable) {
|
||||
NIR_PASS_V(s, nir_lower_clip_fs, key->fs.clip_plane_enable, false);
|
||||
}
|
||||
}
|
||||
|
||||
if (dev->arch <= 5 && s->info.stage == MESA_SHADER_FRAGMENT) {
|
||||
NIR_PASS_V(s, pan_lower_framebuffer, key->fs.rt_formats,
|
||||
pan_raw_format_mask_midgard(key->fs.rt_formats), 0,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue