[erlang-questions] gen:call({global, Name}, ...)

Geoff Cant <>
Wed Mar 30 03:19:59 CEST 2011

Hi all, I discovered today that gen:call({global, Name}, Label, Request,
Timeout) calls global:safe_whereis_name(Name) to determine the Pid to
look up globally registered names.

global:safe_whereis_name/1 doesn't seem to offer any particular safety
and more importantly, serializes all global name lookups on a node. (Using
global:whereis_name/1 instead is just an ets lookup).

Can we safely make a change like
in gen.erl and improve call time and reduce the load on
global_name_server at a stroke?

This git repo contains the patch I'm thinking of:
git fetch git://github.com/archaelus/otp.git gen_where

Geoff Cant

More information about the erlang-questions mailing list