use IR_MAX_ARGS when writing out ir

This commit is contained in:
Anthony Pesch 2017-11-19 15:43:57 -05:00
parent 0d7d036968
commit 3655298935
1 changed files with 1 additions and 1 deletions

View File

@ -159,7 +159,7 @@ static void ir_write_instr(struct ir_writer *w, const struct ir_instr *instr,
int need_space = 1;
int need_comma = 0;
for (int i = 0; i < 3; i++) {
for (int i = 0; i < IR_MAX_ARGS; i++) {
const struct ir_value *arg = instr->arg[i];
if (!arg) {