mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-27 19:10:14 +01:00
llvmpipe/linear: don't allow linear path for shader output with location frac
This has been broken for a while, but we weren't hitting the linear paths in CI This fixes: tests/spec/arb_enhanced_layouts/execution/component-layout/fs-output.shader_test. Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Cc: mesa-stable Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24083>
This commit is contained in:
parent
fb925c9260
commit
f9c1948a21
1 changed files with 8 additions and 1 deletions
|
|
@ -367,8 +367,15 @@ llvmpipe_nir_fn_is_linear_compat(const struct nir_shader *shader,
|
|||
nir_foreach_block(block, impl) {
|
||||
nir_foreach_instr_safe(instr, block) {
|
||||
switch (instr->type) {
|
||||
case nir_instr_type_deref:
|
||||
case nir_instr_type_deref: {
|
||||
nir_deref_instr *deref = nir_instr_as_deref(instr);
|
||||
if (deref->deref_type != nir_deref_type_var)
|
||||
return false;
|
||||
if (deref->var->data.mode == nir_var_shader_out &&
|
||||
deref->var->data.location_frac != 0)
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
case nir_instr_type_load_const: {
|
||||
nir_load_const_instr *load = nir_instr_as_load_const(instr);
|
||||
if (!check_load_const_in_zero_one(load)) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue