aco: use Info::definition_size instead of definition's regclass
[mesa.git] / src / amd / compiler / aco_validate.cpp
index 6d7c0c3e7948e92dad550846232167c1bf9cf882..d4ba88e014a351c24ee6f6dd949823337e7486c1 100644 (file)
@@ -568,7 +568,7 @@ unsigned get_subdword_bytes_written(Program *program, const aco_ptr<Instruction>
       break;
    }
 
-   return chip >= GFX10 ? def.bytes() : 4;
+   return MAX2(chip >= GFX10 ? def.bytes() : 4, instr_info.definition_size[(int)instr->opcode] / 8u);
 }
 
 } /* end namespace */