Re: Memory de-allocation question

new topic     » goto parent     » topic index » view thread      » older message » newer message
petelomax said...

As yet, Phix never actually returns any memory to the OS except at program termination, though I doubt that's really an issue...

I think it does matter for my use case. BZScript currently builds several large intermediates before execution (file chars -> grouped tokens -> full AST). Once execution starts, those early structures are dead weight. By my rough estimate I could be holding up to ~30x the source size in transient data at peak, plus thousands of small short-lived chunks. Phix will reuse those, which is good, but the peak still sets a high-water mark in the process.

Takeaway: I need to rework the front end to stream and reuse buffers so only the final AST and symbols survive. Your note helped me catch this before it bites. Thanks.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu