Messed up KHash calculation