Skip to content

Commit

Permalink
Add a basic integration test that excercises the polynomial
Browse files Browse the repository at this point in the history
arithmetic primitives and the `rme` proof method.
  • Loading branch information
robdockins committed Oct 28, 2020
1 parent da4dee8 commit 7f57175
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
13 changes: 13 additions & 0 deletions intTests/test0063_polyarith/test.saw
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
let {{

thm : {n,m} (fin n, fin m, n > m, m >= 1) => [n] -> [m] -> Bit
thm x y = y != 0 ==>
pmult y (pdiv x y) ^ (zero # pmod x y) == zero`{[m-1]}#x

}};

print_term (rewrite (cryptol_ss ())
(unfold_term ["thm"] {{ thm`{16,4} }}));

prove_print rme {{ thm`{16,8} }};
prove_print rme {{ thm`{20,10} }};
1 change: 1 addition & 0 deletions intTests/test0063_polyarith/test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
$SAW test.saw

0 comments on commit 7f57175

Please sign in to comment.