Even if the driver doesn't *use* trivial blend shaders, building and compiling
blend shaders is expensive. We shouldn't be building blend shaders that should
never be used.
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/17841>
.equation = state->rts[rt].equation,
};
+ /* Blend shaders should only be used for blending on Bifrost onwards */
+ assert(dev->arch <= 5 || !pan_blend_is_opaque(state->rts[rt].equation));
+ assert(state->rts[rt].equation.color_mask != 0);
+
struct hash_entry *he = _mesa_hash_table_search(dev->blend_shaders.shaders, &key);
struct pan_blend_shader *shader = he ? he->data : NULL;