Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » U++ Developers corner » New hash folding function...
Re: New hash folding function... [message #13689 is a reply to message #13686] Tue, 22 January 2008 11:31 Go to previous message
gprentice is currently offline  gprentice
Messages: 260
Registered: November 2005
Location: New Zealand
Experienced Member
gprentice wrote on Tue, 22 January 2008 20:55


Why do you call it "hash-fold" if it doesn't actually reduce the range of values
- or if
return (h >> 23) - (h >> 9) - (h >> 15) - h;
does reduce the range of values, how does it do that, since it's unsigned arithmetic?



Never mind, I found the answer - which is that hash folding means that all bits of the computed hash value participate in the final table index value.

Graeme

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: RMI
Next Topic: Code reformatting
Goto Forum:
  


Current Time: Thu Jun 26 20:55:25 CEST 2025

Total time taken to generate the page: 0.03988 seconds