Closed hackedy closed 1 year ago
This is ready for review. Instead of rewriting all the old functions I renamed them to le_original_name
to indicate they are little endian and wrote big-endian versions under original_name
by using List.rev
and le_original_name
. This made the proofs easy to fix.
I think it is OK as long as lemmas are consistency.
Yeah all the old lemmas are still there and I proved big endian versions of them by using the old lemmas and some facts about List.rev.
I discovered while fixing some STF tests that the poulet4 conversions between Coq N/Z values and bitvectors appear to be little endian (but, thankfully, consistently so). This PR flips the endianness to big endian, so that the value 1 encodes to a 4-bit bitvector as [0; 0; 0; 1].
Not ready to merge, I broke a bunch of proofs which show the conversions are consistent. So I will have to repair those and the type soundness proofs that depend on them.