public static final int keyHash(final Object o,final boolean compareValues){
  int h=compareValues ? o.hashCode() : System.identityHashCode(o);
  h+=(h << 15) ^ 0xffffcd7d;
  h^=(h >>> 10);
  h+=(h << 3);
  h^=(h >>> 6);
  h+=(h << 2) + (h << 14);
  return h ^ (h >>> 16);
}

public static final int keyHash ( final Object o , final boolean compareValues ) { int h = compareValues ? o . hashCode ( ) : System . identityHashCode ( o ) ; h += ( h << 15 ) ^ 0xffffcd7d ; h ^= ( h > > > 10 ) ; h += ( h << 3 ) ; h ^= ( h > > > 6 ) ; h += ( h << 2 ) + ( h << 14 ) ; return h ^ ( h > > > 16 ) ; }
applies a supplemental hash function to a given hashcode , which defends against poor quality hash functions . this is critical because concurrenthashmap uses power - of - two length hash tables , that otherwise encounter collisions for hashcodes that do not differ in lower or upper bits .
