Merge branch 'master' into v2.1

This commit is contained in:
Mike Pall
2022-12-22 00:52:04 +01:00
15 changed files with 43 additions and 40 deletions

View File

@@ -1894,7 +1894,7 @@ static void asm_arithov(ASMState *as, IRIns *ir)
lj_assertA(!irt_is64(ir->t), "bad usage");
if (irref_isk(ir->op2)) {
int k = IR(ir->op2)->i;
if (ir->o == IR_SUBOV) k = -k;
if (ir->o == IR_SUBOV) k = (int)(~(unsigned int)k+1u);
if (checki16(k)) { /* (dest < left) == (k >= 0 ? 1 : 0) */
left = ra_alloc1(as, ir->op1, RSET_GPR);
asm_guard(as, k >= 0 ? MIPSI_BNE : MIPSI_BEQ, RID_TMP, RID_ZERO);