StablePtr / StableName ?

Simon Peyton Jones simonpj at
Tue Jan 24 10:26:34 UTC 2017

Add this conversation to #13165?

From: ghc-devs [mailto:ghc-devs-bounces at] On Behalf Of Simon Marlow
Sent: 24 January 2017 09:38
To: Johannes Waldmann <johannes.waldmann at>
Cc: ghc-devs at
Subject: Re: StablePtr / StableName ?

StableNames do use the RTS hash table implementation, but StablePtr does *not*, the ticket is incorrect.  But to be clear, nothing has changed - StableName has always used this hash table implementation.  No doubt it could be faster if we used a better hash table, but whether it matters to you or not depends on what else your application is doing - is StableName in the inner loop? You'd have to measure it.


On 22 January 2017 at 16:09, Johannes Waldmann <johannes.waldmann at<mailto:johannes.waldmann at>> wrote:
Dear ghc devs,

would the StablePtr performance issue (slow hash table)
also affect StableNames?

Could making 10^5 stable names, and accessing each just once,
take noticeable time? Where would this show up in a profile?

I guess there's no easy way to change the ersatz library
(StableName this is the fundamental mechanism for detecting sharing)
but if these issues are related, then ersatz provides a
performance test case.

Thanks, Johannes.
ghc-devs mailing list
ghc-devs at<mailto:ghc-devs at><>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the ghc-devs mailing list