
6 Jul
2007
6 Jul
'07
8:24 a.m.
Hello Daniel, it seems like a good proposal for general-purpose library Friday, July 6, 2007, 4:12:49 AM, you wrote:
Presumably it's possible to do a piece-meal app-level hash consing of values by defining an appropriate identity memoisation. Though maybe the optimiser is so cunning it figures out you're returning an equal value and skips it.
It'd be nice if there were system wide hash consing memoisations that could be called when substantial sharing was anticipated. Maybe an easy approximation is keeping your String trie, or whatever, in a global IORef.
Or what about hash consing after an equality test? Less opportunity but perhaps less cost.
-- Best regards, Bulat mailto:Bulat.Ziganshin@gmail.com