mirror of
https://github.com/azalea-rs/simdnbt.git
synced 2025-08-02 15:36:03 +00:00
an unnecessarily fast nbt decoder
|
||
---|---|---|
benches | ||
examples | ||
src | ||
tests | ||
.gitignore | ||
Cargo.toml | ||
LICENSE | ||
README.md |
simdnbt
an unnecessarily fast nbt decoder. like seriously you probably don't need this unless you're trying to win benchmarks.
simdnbt currently makes use of simd instructions for two things:
- swapping the endianness of int arrays
- checking if a string is plain ascii for faster mutf8 to utf8 conversion
simdnbt might be the fastest nbt decoder currently in existence. however to achieve this silly speed, it takes a couple of shortcuts:
- it requires a reference to the original data (to avoid cloning)
- it doesn't validate/decode the mutf-8 strings at decode-time
here's a benchmark comparing simdnbt against a few of the other fastest nbt crates (though without actually accessing the data):
and here's a benchmark where it accesses the data and makes it owned: