List of Phobos functions that allocate memory?

Ola Fosheim Grøstad" <ola.fosheim.grostad+dlang at gmail.com> Ola Fosheim Grøstad" <ola.fosheim.grostad+dlang at gmail.com>
Fri Feb 7 12:59:13 PST 2014


On Friday, 7 February 2014 at 20:41:01 UTC, Adam D. Ruppe wrote:
> yeah, preallocating exceptions might be a really good idea.

I wonder if it would be possible to get better unwinding speed by 
only throwing a single type of exception class and only a single 
catch. Then do pattern matching on an embedded typefield.

I.e.:

if (e.id & MASK_5xx) {}
if (e.id & MASK_409) {}

etc.

After looking at the code for stack unwinding it seems like 
keeping the loops short is essential.


More information about the Digitalmars-d mailing list