don't use EXTU
This commit is contained in:
parent
16b4f5b4c2
commit
d454d4fa50
@ -55,7 +55,7 @@ static void* mmX_allocN(usz sz, u8 type) { assert(sz>=16); return mmX_allocL(BSZ
|
|||||||
#else
|
#else
|
||||||
#define POS_UPD
|
#define POS_UPD
|
||||||
#endif
|
#endif
|
||||||
#define INS NOINLINE
|
#define INS NOINLINE __attribute__ ((aligned(64), hot)) // idk man
|
||||||
INS void i_POPS(B x) {
|
INS void i_POPS(B x) {
|
||||||
dec(x);
|
dec(x);
|
||||||
}
|
}
|
||||||
@ -247,23 +247,20 @@ static OptRes opt(u32* bc0) {
|
|||||||
if (!isFun(f.v) || v(f.v)->type!=t_funBI) goto defIns;
|
if (!isFun(f.v) || v(f.v)->type!=t_funBI) goto defIns;
|
||||||
RM(f.p); cact = 3;
|
RM(f.p); cact = 3;
|
||||||
TSADD(data, (u64) c(Fun, f.v)->c1);
|
TSADD(data, (u64) c(Fun, f.v)->c1);
|
||||||
goto defStk;
|
goto defIns;
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
case FN2C: { S(f,1)
|
case FN2C: { S(f,1)
|
||||||
if (!isFun(f.v) || v(f.v)->type!=t_funBI) goto defIns;
|
if (!isFun(f.v) || v(f.v)->type!=t_funBI) goto defIns;
|
||||||
cact = 3; RM(f.p);
|
cact = 3; RM(f.p);
|
||||||
TSADD(data, (u64) c(Fun, f.v)->c2);
|
TSADD(data, (u64) c(Fun, f.v)->c2);
|
||||||
goto defStk;
|
goto defIns;
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
case FN2O: { S(f,1)
|
case FN2O: { S(f,1)
|
||||||
if (!isFun(f.v) || v(f.v)->type!=t_funBI) goto defIns;
|
if (!isFun(f.v) || v(f.v)->type!=t_funBI) goto defIns;
|
||||||
cact = 4; RM(f.p);
|
cact = 4; RM(f.p);
|
||||||
TSADD(data, (u64) c(Fun, f.v)->c1);
|
TSADD(data, (u64) c(Fun, f.v)->c1);
|
||||||
TSADD(data, (u64) c(Fun, f.v)->c2);
|
TSADD(data, (u64) c(Fun, f.v)->c2);
|
||||||
goto defStk;
|
goto defIns;
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
case OP1D: { S(f,0) S(m,1)
|
case OP1D: { S(f,0) S(m,1)
|
||||||
if (f.p==-1 | m.p==-1) goto defIns;
|
if (f.p==-1 | m.p==-1) goto defIns;
|
||||||
@ -307,7 +304,6 @@ static OptRes opt(u32* bc0) {
|
|||||||
cact = 1;
|
cact = 1;
|
||||||
goto defIns;
|
goto defIns;
|
||||||
default: defIns:;
|
default: defIns:;
|
||||||
defStk:
|
|
||||||
TSSIZE(stk)-= stackConsumed(sbc);
|
TSSIZE(stk)-= stackConsumed(sbc);
|
||||||
i32 added = stackAdded(sbc);
|
i32 added = stackAdded(sbc);
|
||||||
for (i32 i = 0; i < added; i++) TSADD(stk, SREF(bi_optOut, -1))
|
for (i32 i = 0; i < added; i++) TSADD(stk, SREF(bi_optOut, -1))
|
||||||
|
|||||||
2
src/vm.c
2
src/vm.c
@ -186,7 +186,7 @@ Block* compileBlock(B block, Comp* comp, bool* bDone, u32* bc, usz bcIA, B block
|
|||||||
for (i32 i = depth; i < cdepth; i++) if (!(csc = csc->psc)) thrM("VM compiler: LOC_ has an out-of-bounds depth");
|
for (i32 i = depth; i < cdepth; i++) if (!(csc = csc->psc)) thrM("VM compiler: LOC_ has an out-of-bounds depth");
|
||||||
if (cpos >= csc->varAm) {
|
if (cpos >= csc->varAm) {
|
||||||
cpos-= csc->varAm;
|
cpos-= csc->varAm;
|
||||||
ins = ins==LOCO? EXTO : ins==LOCM? EXTM : EXTU;
|
ins = ins==LOCO? EXTO : ins==LOCM? EXTM : EXTO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
TSADD(nBCT, ins);
|
TSADD(nBCT, ins);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user