botw/tools/viking
Léo Lam 6e30bbea32
tools: Add a new, optimized check tool
Reimplements tools/check.py in a faster language (picked Rust to learn
and play with the language and because installing dependencies is way
easier than with C++)

On my machine, a full run takes ~160ms with this new implementation
and 49s (!) with check.py.

The main performance improvements come from not having to use
pyelftools and the Python bindings of Capstone (which are both insanely
slow and perhaps less efficient than they could be). Function checking
is now also performed in parallel rather than sequentially for yet
another significant performance boost.

Other tweaks include editing Capstone and the bindings to avoid
computing expensive things that we don't actually need and avoiding
dynamic memory allocations in hot paths as much as possible.

check.py will be removed after the setup instructions are updated.
2021-07-30 23:52:55 +02:00
..
src tools: Add a new, optimized check tool 2021-07-30 23:52:55 +02:00
.gitignore tools: Add a new, optimized check tool 2021-07-30 23:52:55 +02:00
Cargo.lock tools: Add a new, optimized check tool 2021-07-30 23:52:55 +02:00
Cargo.toml tools: Add a new, optimized check tool 2021-07-30 23:52:55 +02:00
LICENSE tools: Add a new, optimized check tool 2021-07-30 23:52:55 +02:00