[erlang-questions] Benchmarking Erlang: Deathmatch of gb_trees, dict, ets, mnesia ... and registered names

Anders Nygren anders.nygren@REDACTED
Thu Oct 9 15:55:57 CEST 2008

On Thu, Oct 9, 2008 at 8:38 AM, Richard Carlsson <richardc@REDACTED> wrote:
> Joel Reymont wrote:
>> Richard, thank you for pointing out the flaw in my code. Still, note
>> that the lookup time is still very very low.
>> I'm not really concerned with the time to populate as my goal is to
>> grab a number from every incoming packet and map that to a process id
>> so that I can route the packet.
> The main thing was just that you will not get any sensible numbers from
> the lookup measurement unless you have made sure that the population of
> the table has finished first. Otherwise you'll be measuring the time to
> look up nonexisting stuff, and for that most storage methods will do
> equally well.

But since gen_server handles messages in a FIFO manner, all
inserts will be processed before the lookups. The only problem is that
the first lookup will have to wait for all inserts to finish. So the time for
lookups will include the time for the inserts to finish, but there will not
be a lot of lookups before the inserts have finished.


>    /Richard
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://www.erlang.org/mailman/listinfo/erlang-questions

More information about the erlang-questions mailing list