HashFP simply moves entropy from the most significant 48 bits of the fingerprint into the least significant 16 bits (by XORing) so that a simple MOD on the result can be used to pick a mutex while still making use of changes in more significant bits of the fingerprint. (The fast fingerprinting funct
(fp model.Fingerprint)
| 10 | // really want to make use of every change in the fingerprint to vary mutex |
| 11 | // selection.) |
| 12 | func HashFP(fp model.Fingerprint) uint32 { |
| 13 | return uint32(fp ^ (fp >> 32) ^ (fp >> 16)) |
| 14 | } |
no outgoing calls
no test coverage detected