Files
archy/core/target/debug/deps/libfnv-7c1a0ae1a9224d7c.rlib
T

120 lines
12 KiB
Plaintext
Raw Normal View History

!<arch>
#1/12 0 0 0 0 28 `
__.SYMDEF#1/12 0 0 0 644 11092 `
lib.rmetaÏúíþ ˜*8*.rmeta__DWARF*82 @+@+ Prust
(#rustc 1.93.0 (254b59607 2026-01-19)Áõ…·fÊ ¦%g--c48c539199cbc88bÁ³VOÐêùÿ²?ÑL¼§Ì±-a7a40eb546f9e2b0Áá\ƒ¦è3$|]åŒ[IÚ tæ-14b12edc9f8cd90bÁë&Gf·Ã ¬ëñq:¤»b-bb76018b1173caf6Áà 9m Ù„«ÐÒþá•cB;-030c5b0bba47cc8fÁrustc_std_workspace_coreÁÛ¹þÓ7>H%¸ÚÉ­-4b81d37a5530864dÁüÃùs<Uß7VyóHr#QÏ-c66cc7807550ce25Á miniz_oxideÁõFÖˆÚ™ª‹"ÞXzLVª-62cbc7af83058505Áadler2Á—wÉD‘嵯|6¨%Œ
+-2f171dd2394b4b62Á hashbrownÁ,ïcV¼¨ø¢:Ê\'È߈-9571ba9e0f6c7a90Árustc_std_workspace_allocÁ%¥Èxµù·¼5Ä3Bœ-aac566ad65903fa4Á
std_detectÁMmáýZ^9õ Îà§e˜÷e-2edb296e590136d8Árustc_demangleÁ@¼§VÉNb˜æ¨fHÌ+V3-53b132e4a2fa6e26Ácfg_ifÁfÝv.Å"ÒÜuPp¹ˆ¶-f76b385d7d4d7f3eÁ addr2lineÁÕú-WiúQVÓ¬
µT§5-fe25100bd73e48e4ÁgimliÁ¹xLáÇí÷‘o±Ñ8£Å-265ba9e6e4f70b3fÁobjectÁÔ³ÝzÓÿ¶ò°öM›¼òü`-9ae0d1f8ea52a318ÁmemchrÁRÎ÷׎™te~QÓ¿ØC\Ò-0bff3c8e8f4e489eÁ  –©HtGNÏ·ˆ!á-d69228d077d46f36Áá<,|Œ€Œóª|­Œ¬BuildHasherDefaultÁ”Ù531/1àà FnvHasherÁ

ì
>with_keyÁfinishÁwriteÁFnvBuildHasherÁ
FnvHashMapÁ
FnvHashSetÁ


Ä

 œ  ì ¥°3˜53ÃbÌ 


Ä
Ãbì‰

”“%#"„äœòˬüåGÌ 

ôü¯EÌ ½ ¿keyÁ0½ Ôü¦.½ º Ì  / ½ 
–q`Ê
±JÙiÙiIterÁÜi÷ ®iÝi
end_or_lenÁ®iÞi_markerÁ®it¸N(å¡}ø¾ƒš©®
àK¿ÇË × é
 å 
 
½ äå   $–ü– d›
÷Ë(³½ Ü›

¼Ëéü'Müèü”Õoü×j Ì  
å½ u=qMø°ú°û°Ðü°ý°þ°ìHˈXêE> ¤Å½ ³½  å½ ½ Ì F½ [×bytesÁÜ¢U£ !byteÁB
PßpŠJ°Pङ

 #Ì .½ 5<J

_ kÌ v½ }
ÄÆª4‹Ãb®”“ëb§<ׯ©´  üê•üHE An implementation of the [Fowler–Noll–Vo hash function][chongo].ÁIËdM ## AboutÁZËü^JG The FNV hash function is a custom `Hasher` implementation that is moreÁü©$! efficient for smaller hash keys.ÁÎËüÒNK [The Rust FAQ states that][faq] while the default `Hasher` implementation,Áü¡NK SipHash, is good in many cases, it is notably slower than other algorithmsÁüðMJ with short keys, such as when you have a map of integers to other values.Áü¾>; In cases like these, [FNV is demonstrably faster][graphs].ÁýËüFC Its disadvantages are that it performs badly on larger inputs, andÁüÈLI provides no protection against collision attacks, where a malicious userÁü•GD can craft specific keys designed to slow a hasher down. Thus, it isÁüÝMJ important to profile your program to ensure that you are using small hashÁü«LI keys, and be certain that your program could not be exposed to maliciousÁüø0- inputs (including being a networked server).Á©Ëü­A> The Rust compiler itself uses FNV, as it is not worried aboutÁüïMJ denial-of-service attacks, and can assume that its inputs are going to beÁü½'$ small—a perfect use case for FNV.ÁåË¡ Š ä
## Using FNV in a `HashMap`
The `FnvHashMap` type alias is the easiest way to use the standard library’s
`HashMap` with FNV.
```rust
use fnv::FnvHashMap;
let mut map = FnvHashMap::default();
map.insert(1, "one");
map.insert(2, "two");
map = FnvHashMap::with_capacity_and_hasher(10, Default::default());
map.insert(1, "one");
map.insert(2, "two");
```
Note, the standard library’s `HashMap::new` and `HashMap::with_capacity`
are only implemented for the `RandomState` hasher, so using `Default` to
get the hasher is the next best option.
## Using FNV in a `HashSet`
Similarly, `FnvHashSet` is a type alias for the standard library’s `HashSet`
with FNV.
```rust
use fnv::FnvHashSet;
let mut set = FnvHashSet::default();
set.insert(1);
set.insert(2);
set = FnvHashSet::with_capacity_and_hasher(10, Default::default());
set.insert(1);
set.insert(2);
```
Á !üŒ éü† ïøËüüB? [chongo]: http://www.isthe.com/chongo/tech/comp/fnv/index.htmlÁü¿OL [faq]: https://www.rust-lang.org/en-US/faq.html#why-are-rusts-hashmaps-slowÁü63 [graphs]: https://cglab.ca/~abeinges/blah/hash-rs/Á


Ä0
ƪ
Ãb®
ëb§
Æ©
´  ¬Ì
üÿ'u
x
h
k
üÄ$`
c
S
V
_
üï>; An implementation of the Fowler–Noll–Vo hash function.Á®Ëü²?< See the [crate documentation](index.html) for more details.ÁÌ ¥°3˜53 ½ Ì _
1½ Ì 

®

½ ÔµÌ ÅÌåÌ 

Ì ü¯&üÅ<9 Create an FNV hasher starting with a state correspondingÁ´† to the hash `key`.ÁD¶½ Ì 
¾ 4ÌøÌ ÄbÅb¼¦ Ì ½  °
üè! Ì  ¤ ñ
þ) ¼”üí&# A builder for default FNV hashers.Átëbëbìb®îbì‡b Cþãð9Ì Ì’üÎ+( A `HashMap` using a default FNV hasher.Á»ü ÿ 8<€ ˆ7¼úT›
Ÿ
©â
¦©âŸ
©ÆÆ§ÊbaseÁµ®`§L]ýB¸4Ë4ä2PRJL´’üÎ+( A `HashSet` using a default FNV hasher.Á»ü ÿ 8<€ ˆ7¼úT›©â ¦´ ´ ©· è3¢ >D“Úüx«
¼6ä268×÷
÷