Skip to content

Commit

Permalink
x64: hotfix scaling issue on ARRAY_ACCESS
Browse files Browse the repository at this point in the history
  • Loading branch information
RealNeGate committed Oct 31, 2023
1 parent 884f0c3 commit 1670f18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tb/src/x64/x64.c
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ static Inst* isel_addr(Ctx* restrict ctx, TB_Node* n, int dst, int store_op, int

// we can't fit this into an LEA, might as well just do a shift
SUBMIT(inst_op_rri(SHL, TB_TYPE_I64, dst, index, scale));
index = dst, scale = 1;
index = dst, scale = 0;
}
} else {
// needs a proper multiply (we may wanna invest in a few special patterns
Expand Down

0 comments on commit 1670f18

Please sign in to comment.