rust-performance: introduce FastHashMap type alias for HashMap
Rust's default hashing is slow, because it is meant for preventing collision
attacks.
For all of the current Rust code, we don't care about those attacks, because
if an person with bad intentions has write access to your repo, you have other
issues.
I've chosen to use the TwoXHash crate because it was made by a reputable member
of the Rust community and has very good benchmarks.
For now it does not seem to improve performance by much for the current code,
but it's something else to not worry about when benchmarking code: in a
previous experiment with copytracing in Rust, it accounted for more than 10%
of the time of the entire script.
Differential Revision: https://phab.mercurial-scm.org/D7116
syntax: glob
*.elc
*.tmp
*.orig
*.rej
*~
*.mergebackup
*.o
*.so
*.dll
*.exe
*.pyd
*.pyc
*.pyo
*$py.class
*.swp
*.prof
*.zip
\#*\#
.\#*
tests/artifacts/cache/big-file-churn.hg
tests/.coverage*
tests/.testtimes*
tests/.hypothesis
tests/hypothesis-generated
tests/annotated
tests/exceptions
tests/*.err
tests/htmlcov
build
contrib/chg/chg
contrib/hgsh/hgsh
contrib/vagrant/.vagrant
dist
packages
doc/common.txt
doc/*.[0-9]
doc/*.[0-9].txt
doc/*.[0-9].gendoc.txt
doc/*.[0-9].{x,ht}ml
MANIFEST
MANIFEST.in
patches
mercurial/__modulepolicy__.py
mercurial/__version__.py
mercurial/hgpythonlib.h
mercurial.egg-info
.DS_Store
tags
cscope.*
.idea/*
.asv/*
.pytype/*
i18n/hg.pot
locale/*/LC_MESSAGES/hg.mo
hgext/__index__.py
rust/target/
rust/*/target/
# Generated wheels
wheelhouse/
syntax: regexp
^\.pc/
^\.(pydev)?project
# hackable windows distribution additions
^hg-python
^hg.py$