Also remove ahash and use hashbrown's default-hasher crate feature as replacement. This allows to drop yet another wasmparser dependency.
Note
hashbrown started using foldhash as its default-hasher starting in v0.15.0. From what I know it should be an improvement over ahash.
hashbrown by default is using foldhash-f and not foldhash-q where foldhash-f is the "fast" version and foldhash-q is the hash-DOS resistant version. It seems that foldhash-f is more DOS-resistant than fxhash but less than both foldhash-q and ahash. Maybe this is a reason to not use hashbrown's default hasher. For Wasmi my stance is that if you want DOS-resistance, you simply do not use hash-tables at all by disabling hash-collections feature.
Q: Are there any other workspace crates that need adjustment?
hashbrown
v0.15.1.ahash
and use hashbrown'sdefault-hasher
crate feature as replacement. This allows to drop yet anotherwasmparser
dependency.Note
hashbrown
started usingfoldhash
as its default-hasher starting inv0.15.0
. From what I know it should be an improvement overahash
.hashbrown
by default is usingfoldhash-f
and notfoldhash-q
wherefoldhash-f
is the "fast" version andfoldhash-q
is the hash-DOS resistant version. It seems thatfoldhash-f
is more DOS-resistant thanfxhash
but less than bothfoldhash-q
andahash
. Maybe this is a reason to not usehashbrown
's default hasher. For Wasmi my stance is that if you want DOS-resistance, you simply do not use hash-tables at all by disablinghash-collections
feature.Q: Are there any other workspace crates that need adjustment?
Background: I did the same in Wasmi and found it to be a good solution so far.