Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use alt-ergo 2.5 #33

Merged
merged 2 commits into from
Mar 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
- name: Update OPAM & EasyCrypt dependencies
run: |
opam update
opam pin alt-ergo 2.5.2
opam pin add -n easycrypt easycrypt
opam install --deps-only easycrypt
- name: Compile & Install EasyCrypt
Expand Down
78 changes: 0 additions & 78 deletions config/alt-ergo.nix

This file was deleted.

2 changes: 1 addition & 1 deletion easycrypt.project
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[general]
timeout = 30

provers = Alt-Ergo@2.4
provers = Alt-Ergo@2.5
provers = [email protected]
provers = [email protected]

Expand Down
4 changes: 2 additions & 2 deletions proof/correctness/Montgomery.ec
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,8 @@ rewrite /barrett_pred /barrett_pred_low /barrett_pred_high /barrett_fun /barrett
move : (brt a H); move => [#] brtl brth.
rewrite !modzDm.
case (0 <= a).
+ move => agt0; rewrite !(modz_small (a * (2 ^ bits %/ SignedReductions.q + 1)));
1: by smt(expr2 gtr0_norm ltr_pmul).
+ move => agt0; rewrite !(modz_small (a * (2 ^ bits %/ SignedReductions.q + 1)));
1: by rewrite expr2 gtr0_norm 1:/#; smt(ltr_pmul).
have -> /= : !(2 ^ k ^ 2 %/ 2 <= a * (2 ^ bits %/ SignedReductions.q + 1)).
+ rewrite ltr_geF; last by done.
rewrite expr2 mulrC div_mulr; 1: by rewrite -{1}(expr1 2); apply dvdz_exp2l; smt(gt2_k).
Expand Down
6 changes: 3 additions & 3 deletions shell.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{ pkgs ?
import (fetchTarball {
url = https://github.com/NixOS/nixpkgs/archive/53fbe41cf76b6a685004194e38e889bc8857e8c2.tar.gz;
sha256 = "sha256:1fyc4kbhv7rrfzya74yprvd70prlcsv56b7n0fv47kn7rznvvr2b";
url = https://github.com/NixOS/nixpkgs/archive/51063ed4f2343a59fdeebb279bb81d87d453942b.tar.gz;
sha256 = "sha256:0my8bdc7js7gdcl8z8ik49sl9gccqz39xg8q335sharf5qxq13ww";
}) {}
, full ? true
}:
Expand Down Expand Up @@ -30,7 +30,7 @@ let
ocamlPackages = oc;
why3 = why;
};
altergo = callPackage ./config/alt-ergo.nix { ocamlPackages = oc; } ;
altergo = alt-ergo.override { ocamlPackages = oc; } ;
in

mkShell ({
Expand Down