[erlang-questions] Benchmarking Erlang: Deathmatch of gb_trees, dict, ets, mnesia ... and registered names
Ulf Wiger (TN/EAB)
Thu Oct 9 14:05:54 CEST 2008
Joel Reymont skrev:
> lookup(N) ->
> P = global:whereis_name(N),
> true = is_process_alive(P),
> lookup(N - 1).
> This should be enough for error checking, right?
> ()4> c(map7).
> ()5> map7:test(100000).
> Populate: 265.2531
> Lookup: 0.0831
> The timings are not much off!
How many nodes did you have there?
> I thought I'd test with 4 nodes...
> ()2> nodes().
> ()3> map7:test(100000).
> Populate: 165.2079
> Lookup: 0.0641
> Not much of a difference, still super-efficient!
It seems as if you have quite a large variation on
the populate benchmark - esp if the first test above
is with only one node.
Anyway, the worst part of global's algorithm is the
random backoff at lock conflicts, but that shouldn't
affect you in this particular case.
More information about the erlang-questions