From d5f0cac74721863a91b0a799256b62c0b7b2a3c1 Mon Sep 17 00:00:00 2001 From: eunhhu Date: Sun, 18 Oct 2026 17:45:16 +0100 Subject: Module executor: a kept list's lists through steps of their own (027's stage 3): the load gives ITEM_GET and ITEM_SET of a kept list's list field, and LIST_APPEND, LIST_INSERT and APPEND_IN of a kept list whose record holds lists, numbers past the module's (OP_KEPT_*, after verifying and planning: no module holds them, the JIT leaves their blocks to the executor), so the instructions' own steps are as before stage 3; the list module holds a list field's value as bytes (PURE_CELL_LIST only in images' headers and layouts) and text_field is a text's alone again: the stage 3 commit had cost BFS 1.4% of its instructions with batches and 1.7% without (its millions of appends asking each field twice), the five works now within 0.04% of before it --- core/module-jit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core/module-jit.c') diff --git a/core/module-jit.c b/core/module-jit.c index ae0f24c..328a69f 100644 --- a/core/module-jit.c +++ b/core/module-jit.c @@ -5763,7 +5763,7 @@ static bool worth(const PureModule *m, PureBlock block) { int input = tier_input(m, block); for (uint32_t pc = block.start; pc < block.start + block.length; pc = after(&m->code[pc], pc)) { const PureOp *op = &m->code[pc]; - if (op->op == PURE_OP_CALL) return false; /* the executor's frames (module.c's run_calls) */ + if (op->op == PURE_OP_CALL || op->op >= PURE_OP_COUNT) return false; /* the executor's frames, a kept list's steps */ if ((op->op == PURE_OP_LOCAL_LOAD || op->op == PURE_OP_LOCAL_STORE) && (op->arg >> 8 & 0xFF) == 4) return false; /* a list */ if (op->op == PURE_OP_EACH || op->op == PURE_OP_LOOP) { loops = true; -- cgit v1.2.3