Regex matching cause lots of _d_arrayliteralTX calls
Dmitry Olshansky
dmitry.olsh at gmail.com
Fri Sep 27 08:34:39 PDT 2013
27-Sep-2013 18:52, JR пишет:
>
> (I was of the notion that that enum merely translate to
> compile-time-evaluated constants.)
I've recently investigated similar problem w.r.t. performance of
std.regex on particular use-case/pattern. In fact it dig up an
interesting bug with inlining in the compiler along the way.
It took about 5 minutes to test that enum used instead of static
devastates performance but quite some time to figure out the actual
"infection chain". And indeed suspicious collections/d_array_literal is
what I've seen in what supposed to be GC-free loop (callgrind is awesome).
--
Dmitry Olshansky
More information about the Digitalmars-d-learn
mailing list