[erlang-questions] Re: ets traversal time

Joel Reymont <>
Thu Jul 16 12:09:06 CEST 2009


On Jul 16, 2009, at 1:11 AM, Jim Morris wrote:

> Have you tried ets:foldl which is tail recursive (presumably as it
> does not specify in the docs, but it is in lists:foldl) or is there a
> reason to use foldr?


I'm not seeing much of a different with ets:foldl

info: [{memory,283357},
        {owner,<0.2316.0>},
        {heir,none},
        {name,subs},
        {size,20000},
        {node,''},
        {named_table,false},
        {type,set},
        {keypos,1},
        {protection,protected}]
time: 957.305
info: [{memory,283357},
        {owner,<0.2316.0>},
        {heir,none},
        {name,subs},
        {size,20000},
        {node,''},
        {named_table,false},
        {type,set},
        {keypos,1},
        {protection,protected}]
time: 1014.135

	Thanks, Joel

---
Mac hacker with a performance bent
http://www.linkedin.com/in/joelreymont



More information about the erlang-questions mailing list