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.
The intention was to catch functional regressions in non-matching
functions but this doesn't actually work well because referenced
code and data may have moved after a function was dumped, in which
case the reference checker is unable to verify that function calls
and data references are still correct.
Considering this increases the amount of complexity in the checker
and makes the workflow more complicated for contributors, let's just
drop this mechanism. It isn't worth it.
Putting binary files in the repo is also pretty meh.
Using musl is required to match several functions that use <math.h>
floating point functions like isnan.
This also removes a dependency on devkitA64. We previously only needed
it because Clang insisted on using GCC to link the final executable
owing to the use of a "bare metal" target like aarch64-none-elf.
We can make Clang invoke the linker itself by using a Linux target.
The wrong overload of agl::utl::Parameter::init was being used.
The one that only takes a name will use the name string for the label
as well; this is not what the original function does, as the label
for all the parameters is set to "" (the empty string).