diff --git a/src/amd/compiler/aco_register_allocation.cpp b/src/amd/compiler/aco_register_allocation.cpp index 81e4072a2b7..2561baefc1a 100644 --- a/src/amd/compiler/aco_register_allocation.cpp +++ b/src/amd/compiler/aco_register_allocation.cpp @@ -456,6 +456,7 @@ std::pair get_subdword_definition_info(Program *program, con default: break; } + bytes_written = bytes_written > 4 ? align(bytes_written, 4) : bytes_written; bytes_written = MAX2(bytes_written, instr_info.definition_size[(int)instr->opcode] / 8u); if (can_use_SDWA(chip, instr)) {