[tint] Replace existing hasher with MurmurHash3 derived one The existing hash implementation has pathological interactions with our block allocation and containers, which leads to the vast majority of slots in hash sets, etc not being used and a very high rate of collisions. Replacing it with an implementation derived from MumurHash3, which is public domain has good distribution/easy to implement. In the micro-benchmark this improves the average case from 16.8ms (+- 0.6) to 2.11 (+- 0.07), and improves the catastrophic case from 295ms (+- 2.80) to a similar runtime. So on top of substantial performance improvements also doesn't demonstrate a slow down in the previous known slow case. For the original fuzzer test case that started this investigation, the runtime goes from ~15s to less than 1s. This test case was pretty tailored to exploit this issue, so I don't expect to see massive runtime improvements in general, but I don't expect to see any regressions. Fixes: 577830526 Change-Id: Ie253126d2ba57d0815d29d2c7fa4452d2303e784 Include-Ci-Only-Tests: ci:dawn-linux-x64-nvidia-gtx1660-rel,ci:dawn-mac-arm64-apple-m2-rel,ci:dawn-win-x64-nvidia-gtx1660-rel|litert_lm_benchmark Cq-Include-Trybots: luci.dawn.try:dawn-try-linux-x64-nvidia-gtx1660-rel,dawn-try-mac-arm64-apple-m2-rel,dawn-try-win-x64-nvidia-gtx1660-rel Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/354176 Reviewed-by: dan sinclair <dsinclair@chromium.org> Commit-Queue: dan sinclair <dsinclair@chromium.org> Auto-Submit: Ryan Harrison <rharrison@chromium.org>
Dawn is an open-source and cross-platform implementation of the WebGPU standard. More precisely it implements webgpu.h that is a one-to-one mapping with the WebGPU IDL. Dawn is meant to be integrated as part of a larger system and is the underlying implementation of WebGPU in Chromium.
Dawn provides several WebGPU building blocks:
webgpu.h version that Dawn implements.webgpu.h.Helpful links:
Developer documentation:
User documentation: (TODO, figure out what overlaps with the webgpu.h docs)
BSD 3-Clause License, please see LICENSE.
This is not an officially supported Google product.