mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
e05bd8f806
Replace per-symbol mrb_malloc() with a chunk-based string pool that batches allocations into 4KB chunks. This reduces malloc call count by ~12x (e.g. 909 vs 10,887 for 10k dynamic symbols) and eliminates per-allocation malloc metadata overhead (~16 bytes/symbol). Pool allocations are rounded up to even size to preserve LSB pointer tagging used for literal detection. Co-authored-by: Claude <noreply@anthropic.com>