diff options
| author | bors <bors@rust-lang.org> | 2022-06-17 15:10:04 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-06-17 15:10:04 +0000 |
| commit | 43c47db0b04627dbd0e16a1e7cad14a4a5a60d3a (patch) | |
| tree | 39e03aaf205309abd4b2a5f70f3ad0276af594b1 /compiler/rustc_mir_transform/src/coverage/spans.rs | |
| parent | 949a64ab20b9d5d4516416c4735b134e0496855a (diff) | |
| parent | 61dc08037551330f3cdb9ca97736d661c9e939dc (diff) | |
| download | rust-43c47db0b04627dbd0e16a1e7cad14a4a5a60d3a.tar.gz rust-43c47db0b04627dbd0e16a1e7cad14a4a5a60d3a.zip | |
Auto merge of #98097 - lqd:const-alloc-hash, r=oli-obk
ctfe: limit hashing of big const allocations when interning Const allocations are only hashed for interning. However, they can be large, making the hashing expensive especially since it uses `FxHash`: it's better suited to short keys, not potentially big buffers like the actual bytes of allocation and the associated 1/8th sized `InitMask`. We can partially hash these fields when they're large, hashing the length, and head and tail of these buffers, to limit possible collisions while avoiding most of the hashing work. r? `@ghost`
Diffstat (limited to 'compiler/rustc_mir_transform/src/coverage/spans.rs')
0 files changed, 0 insertions, 0 deletions
