[qfcc] "Use" the correct operands

The problem was a missed change when switching the internal statement
format to Ruamoko: I "used" the statement's operands directly rather
than the rotated ones when emitting v6p progs. Fixes a compile segfault
when NOT optimizing.
This commit is contained in:
Bill Currie 2022-01-23 00:59:38 +09:00
parent 861e98725c
commit ec5830f70b

View file

@ -203,11 +203,11 @@ emit_statement (statement_t *statement)
op_c = statement->opc;
}
def_a = get_operand_def (statement->expr, op_a);
use_tempop (statement->opa, statement->expr);
use_tempop (op_a, statement->expr);
def_b = get_operand_def (statement->expr, op_b);
use_tempop (statement->opb, statement->expr);
use_tempop (op_b, statement->expr);
def_c = get_operand_def (statement->expr, op_c);
use_tempop (statement->opc, statement->expr);
use_tempop (op_c, statement->expr);
inst = opcode_find (opcode, op_a, op_b, op_c);
if (!inst) {