5 ms·
> Good luck writing misra-compliant web browser. I'd be delighted to see one. Statically pre-allocating a large continuous chunk of memory for the whole browse
by sklogic 11y ago
> Good luck writing misra-compliant web browser.
I'd be delighted to see one. Statically pre-allocating a large continuous chunk of memory for the whole browser process lifetime would have been great.
- quonn 11y agoAnd then, what do you do with that chunk? Since the amount of memory you need depends on the website (e.g. some might need memory for a canvas, others might display large tables, etc.), presumably you take parts of it and allocate them for the various tasks you need to do? So you just write your own dynamic memory allocator.
- sklogic 11y ago> So you just write your own dynamic memory allocator. If the entire pool is reclaimed once page is rendered (and there is a way to handle the running out of space condition) it may not count as a rule violation, no more than incrementing an array index counter. And, browser is hardly a mission-critical appliance.