[Issue 13410] Performance problem with associative array byKey/byValue
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Mon Sep 1 03:48:59 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=13410
Ketmar Dark <ketmar at ketmar.no-ip.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ketmar at ketmar.no-ip.org
--- Comment #2 from Ketmar Dark <ketmar at ketmar.no-ip.org> ---
Created attachment 1407
--> https://issues.dlang.org/attachment.cgi?id=1407&action=edit
simple 'first used bucket' caching for AAs
adding 'first used bucket' caching to aa halves execution time for the sample.
seems that we can't do better with current AAs and without hurting overall AA
performance. aa.remove() hurts caching and there is no sense to recalculate
cache on each remove.
p.s. please note that this patch is not heavily tested, it's just a quick
'hack-in'.
--
More information about the Digitalmars-d-bugs
mailing list