We are reliant primarily on the examples for testing at this point. It would be good to "stress" the allocator because I would be (pleasantly) surprised if it's bug-free.
More extensive unit testing
Integration test under tests/ that (for example) uses the max number of registers of a given kind and confirms the register allocator doesn't fall over
More specifically, handling of "casting" is a little ugly. It would be good to have a test that stresses this specifically. Perhaps, something that allocates 16 virtual general purpose registers and then accesses all sub-registers. This is clearly a possible allocation, but I could imagine the allocator messing up.
We are reliant primarily on the examples for testing at this point. It would be good to "stress" the allocator because I would be (pleasantly) surprised if it's bug-free.
tests/
that (for example) uses the max number of registers of a given kind and confirms the register allocator doesn't fall overUnit tests right now are trivial:
https://github.com/mmcloughlin/avo/blob/775226218cf92a1bd779beafb8bd3144cb4371f0/pass/alloc_test.go#L9-L46