On 19 March 2014 21:14, Alex Miller <a...@puredanger.com> wrote:

> Rich just pushed a change to the String hashing to address this. We're
> going to grab the string hashcode (which is cached after first call) and
> murmur the result of that. This gives us constant time hashcode after first
> call with better distribution for combinations in nested collections.  Will
> be in presumed RC2.
>

If I understand correctly, this means that keywords and symbols use
String.hashCode-based hashing in this commit. They are, however, capable of
caching their Murmur3 hashes, so I was wondering if it might be better to
have them use Murmur3 to hash name & ns?

Rationale: murmuring hashCode results in collisions whenever hashCode does,
plus possibly some additonal collisions if ints collide under murmur;
murmur is better all around.

Potential problems: not sure if things like case depend on symbol/keyword
hashes being directly based on string hashes; hopefully not?

Cheers,
Michał



>
>
> On Wednesday, March 19, 2014 11:26:51 AM UTC-5, Stefan Kamphausen wrote:
>>
>>
>>
>> On Wednesday, March 19, 2014 4:34:45 PM UTC+1, Alex Miller wrote:
>>>
>>> Thanks, this is all really useful. I would appreciate any more detailed
>>> info.
>>>>
>>>>
>>>>
>> * No atoms, agents, refs
>> * Almost purely functional plus logging and I/O
>> * Multi-threaded using latest core.async with thread, no go
>> * JVisualVM reports top methods in CPU sampling c.l.LazySeq.sval,
>> c.c$promise$reify_6310.deref, c.l.LazySeq.seq no notable difference for me
>> to see.
>>
>> A few experiments on two data-sets (dat1 and dat2) using either a call to
>> set or to doall:
>>
>>    Clojure Op Time (dat1) Time (dat1) Average dat1 Time (dat2)  1.5.1 set
>> 19,1 19 19,05 323  1.5.1 doall 19 19,4 19,2 330  1.6.0-RC1 set 19,5 19,8
>> 19,65 350  1.6.0-RC1 doall 20,2 19,8 20 351
>>
>>
>>
>>
>>   --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to