Only add definitions for used registers
This patch makes the BHive to Exegesis conversion script only include definitions for registers needed by the snippet rather than a random set. This makes the outputs cleaner and will help keep things clean later on when setting a loop register (and also make information available to determine if/where there are conflicts).
should it have a test?
Existing tests have been updated (which should be enough coverage here) now that testing infrastructure is in place.
I accidentally merged in #52 into this branch (tried to do stacked PRs and forgot how the DAG was setup while being overly zealous with the merge button). I can probably fix this if it's really necessary but the only changes from that PR (which was approved) are json.test, and lines 305-314.
This is now part of a PR stack, depending on #71.
This is now part of a PR stack, depending on #71.
SG, let's get #71 merged first.
I'll wait with reviewing until #71 is merged and we have this based just on main.
I'll wait with reviewing until https://github.com/google/gematria/pull/71 is merged and we have this based just on main.
I've merge main into the branch, so the diff should be clean now.