| Commit message (Collapse) | Author | Age |
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
It'll be needed for generic reification and uncurrying
|
|
|
|
| |
This way we will have a faster build of reification things
|
| |
|
| |
|
|
|
|
|
| |
We don't have working word code yet, because the reification code currently
does spurious word->N->Z->N->word conversions everywhere. So we use Z instead.
|
| |
|
|
|
|
|
| |
As per
https://github.com/mit-plv/fiat-crypto/pull/86#issuecomment-255839706
|
| |
|
| |
|
|
|
|
| |
(cc @andres-erbsen)
|
| |
|
|
|
|
| |
Note that the old version did not need phi', but the new version does
|
| |
|
|
|
|
| |
We no longer store the type of proofs of [<=] in the term itself; this makes it amenable to vm_compute
|
|
|
|
| |
Not sure how I missed this...
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
GF25519BoundedInstantiation
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Boundedness is axiomatized as
```coq
Axiom ExprBinOp : Type.
Axiom ExprUnOp : Type.
Axiom interp_bexpr : ExprBinOp -> Specific.GF25519.fe25519 ->
Specific.GF25519.fe25519 -> Specific.GF25519.fe25519.
Axiom interp_uexpr : ExprUnOp -> Specific.GF25519.fe25519 ->
Specific.GF25519.fe25519.
Axiom radd : ExprBinOp.
Axiom rsub : ExprBinOp.
Axiom rmul : ExprBinOp.
Axiom ropp : ExprUnOp.
Axiom rinv : ExprUnOp.
Axiom radd_correct : forall x y, interp_bexpr radd x y = carry_add x y.
Axiom rsub_correct : forall x y, interp_bexpr rsub x y = carry_sub x y.
Axiom rmul_correct : forall x y, interp_bexpr rmul x y = mul x y.
Axiom ropp_correct : forall x, interp_uexpr ropp x = carry_opp x.
Axiom rinv_correct : forall x, interp_uexpr rinv x = inv x.
Axiom check_bbounds : ExprBinOp -> bool.
Axiom check_ubounds : ExprUnOp -> bool.
Axiom radd_bounded : check_bbounds radd = true.
Axiom rsub_bounded : check_bbounds rsub = true.
Axiom rmul_bounded : check_bbounds rmul = true.
Axiom ropp_bounded : check_ubounds ropp = true.
Axiom rinv_bounded : check_ubounds rinv = true.
Axiom bbounds_correct
: forall rexpr, check_bbounds rexpr = true
-> forall x y, is_bounded x = true
-> is_bounded y = true
-> is_bounded (interp_bexpr rexpr x y)
= true.
Axiom ubounds_correct
: forall rexpr, check_ubounds rexpr = true
-> forall x, is_bounded x = true
-> is_bounded (interp_uexpr rexpr x) =
true.
```
Questions:
- Some of this is very general and probably doesn't belong in this file
(e.g., [correct_le_le]). Should it stay, or move elsewhere?
- There's a lot of type munging that could be generalized to arbitrary
heterogenous lists; should it be generalized?
- How do we do [div] on bounded things? Currently, I have
```coq
Axiom div : forall (f g : fe25519), fe25519.
Axiom div_correct : forall a b : fe25519,
ModularBaseSystem.eq (proj1_fe25519 (div a b))
(ModularBaseSystem.div (proj1_fe25519 a)
(proj1_fe25519 b)).
```
|
|
|
|
| |
pointed out
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|