From: Daniel Schürmann Date: Wed, 25 Mar 2020 10:03:33 +0000 (+0100) Subject: aco: validate uninitialized operands X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=799bb103283d3324075af1277c41d44d90201034;p=mesa.git aco: validate uninitialized operands Reviewed-by: Rhys Perry Reviewed-By: Timur Kristóf Part-of: --- diff --git a/src/amd/compiler/aco_validate.cpp b/src/amd/compiler/aco_validate.cpp index 0fc80e68008..469d8c069be 100644 --- a/src/amd/compiler/aco_validate.cpp +++ b/src/amd/compiler/aco_validate.cpp @@ -154,6 +154,8 @@ void validate(Program* program, FILE * output) (flat && i == 1) || (instr->format == Format::MIMG && i == 1) || ((instr->format == Format::MUBUF || instr->format == Format::MTBUF) && i == 1); check(can_be_undef, "Undefs can only be used in certain operands", instr.get()); + } else { + check(instr->operands[i].isFixed() || instr->operands[i].isTemp() || instr->operands[i].isConstant(), "Uninitialized Operand", instr.get()); } }