new syntax - a provocation

Robert Virding robert.virding@REDACTED
Sat Oct 18 23:40:52 CEST 2003

----- Original Message ----- 
From: "Richard A. O'Keefe" <ok@REDACTED>
To: <erlang-questions@REDACTED>
Sent: Thursday, September 25, 2003 8:38 AM
Subject: Re: new syntax - a provocation

> Joe Armstrong <joe@REDACTED> discussed two ways of implementing
> atoms without a (permanent) atom table.
> I don't understand what Mod and Index are.
> The question is "what do we want a global atom table _for_?"
> Mainly, so that atom equal/not-equal testing can be O(1).
> Now, suppose an atom is a tagged pointer to a
>     [hash,size,data]
> block.  You only compare the data if the hash and size are the same.
> Most Erlang atoms are fairly short, so while this would be slower than
> whatever it is now, it wouldn't get _that_ much slower.
> The hash value would be used for indexing in clause/case selection.

This probably the best solution if you don't want an atom table. It is
simple and it works. Joes other suggestions are much more complex
and difficult to get right.


More information about the erlang-questions mailing list