# [−][src]Crate fxhash

# Fx Hash

This hashing algorithm was extracted from the Rustc compiler. This is the same hashing algoirthm used for some internal operations in FireFox. The strength of this algorithm is in hashing 8 bytes at a time on 64-bit platforms, where the FNV algorithm works on one byte at a time.

## Disclaimer

It is **not a cryptographically secure** hash, so it is strongly recommended that you do
not use this hash for cryptographic purproses. Furthermore, this hashing algorithm was
not designed to prevent any attacks for determining collisions which could be used to
potentially cause quadratic behavior in `HashMap`

s. So it is not recommended to expose
this hash in places where collissions or DDOS attacks may be a concern.

## Structs

FxHasher | This hashing algorithm was extracted from the Rustc compiler. This is the same hashing algoirthm used for some internal operations in FireFox. The strength of this algorithm is in hashing 8 bytes at a time on 64-bit platforms, where the FNV algorithm works on one byte at a time. |

FxHasher32 | This hashing algorithm was extracted from the Rustc compiler. This is the same hashing algoirthm used for some internal operations in FireFox. The strength of this algorithm is in hashing 4 bytes at a time on any platform, where the FNV algorithm works on one byte at a time. |

FxHasher64 | This hashing algorithm was extracted from the Rustc compiler. This is the same hashing algoirthm used for some internal operations in FireFox. The strength of this algorithm is in hashing 8 bytes at a time on any platform, where the FNV algorithm works on one byte at a time. |

## Functions

hash | A convenience function for when you need a quick usize hash. |

hash32 | A convenience function for when you need a quick 32-bit hash. |

hash64 | A convenience function for when you need a quick 64-bit hash. |

## Type Definitions

FxBuildHasher | A builder for default Fx hashers. |

FxHashMap | A |

FxHashSet | A |