commit d0e1e4271a0eb7dc1765b2ee3586050a14b02c13
parent ba9f776d658f090cbb611a411e1394289930e0a5
Author: Ryan Sepassi <rsepassi@gmail.com>
Date: Sat, 25 Apr 2026 16:15:53 -0700
M1pp: bump TEXT_CAP 512KB -> 640KB, log text/output usage in native build
scheme1.P1pp's added eval_setbang and the cond => arrow path push the
text-buffer past the prior 512KB budget on amd64 (where the larger
backend table also consumes more of the arena). The shifted BSS
offsets keep total BSS under the 8MB memsz from the vendor ELF seeds.
M1pp.c now prints text_used / output_used on stderr after a successful
run -- the boot binary lacks line numbers, so the native oracle is
the way to spot incoming buffer pressure before it overflows.
Diffstat:
2 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/M1pp/M1pp.P1 b/M1pp/M1pp.P1
@@ -29,7 +29,7 @@
DEFINE M1PP_INPUT_CAP 0000040000000000
DEFINE M1PP_OUTPUT_CAP 0000040000000000
-DEFINE M1PP_TEXT_CAP 0000080000000000
+DEFINE M1PP_TEXT_CAP 00000a0000000000
## source_tokens cap: 2 MB / 32-byte tokens = 65536 tokens.
DEFINE M1PP_TOKENS_END 0000200000000000
## Macro record is 296 bytes: name (16) + param_count (8) + params[16]*16 (256)
@@ -135,12 +135,12 @@ DEFINE OFF_arg_ends 0006000000000000
DEFINE OFF_input_buf 8006000000000000
DEFINE OFF_output_buf 8006080000000000
DEFINE OFF_text_buf 80060c0000000000
-DEFINE OFF_source_tokens 8006140000000000
-DEFINE OFF_macros 8006340000000000
-DEFINE OFF_macro_body_tokens 80463d0000000000
-DEFINE OFF_streams 80465d0000000000
-DEFINE OFF_expand_pool 00495d0000000000
-DEFINE OFF_expr_frames 00497d0000000000
+DEFINE OFF_source_tokens 8006160000000000
+DEFINE OFF_macros 8006360000000000
+DEFINE OFF_macro_body_tokens 80463f0000000000
+DEFINE OFF_streams 80465f0000000000
+DEFINE OFF_expand_pool 00495f0000000000
+DEFINE OFF_expr_frames 00497f0000000000
## --- Runtime shell: argv, read input, call pipeline, write output, exit ------
diff --git a/M1pp/M1pp.c b/M1pp/M1pp.c
@@ -1895,5 +1895,6 @@ int main(int argc, char **argv)
return 1;
}
fclose(out);
+ fprintf(stderr, "text_used=%d output_used=%d\n", text_used, output_used);
return 0;
}