diff options
Diffstat (limited to 'src/Specific/solinas32_2e416m2e208m1')
-rwxr-xr-x | src/Specific/solinas32_2e416m2e208m1/compiler.sh | 2 | ||||
-rwxr-xr-x | src/Specific/solinas32_2e416m2e208m1/compilerxx.sh | 2 | ||||
-rw-r--r-- | src/Specific/solinas32_2e416m2e208m1/feadd.v | 14 | ||||
-rw-r--r-- | src/Specific/solinas32_2e416m2e208m1/feaddDisplay.v | 4 | ||||
-rw-r--r-- | src/Specific/solinas32_2e416m2e208m1/fesub.v | 14 | ||||
-rw-r--r-- | src/Specific/solinas32_2e416m2e208m1/fesubDisplay.v | 4 |
6 files changed, 38 insertions, 2 deletions
diff --git a/src/Specific/solinas32_2e416m2e208m1/compiler.sh b/src/Specific/solinas32_2e416m2e208m1/compiler.sh index 48b3811df..93d374b29 100755 --- a/src/Specific/solinas32_2e416m2e208m1/compiler.sh +++ b/src/Specific/solinas32_2e416m2e208m1/compiler.sh @@ -1,4 +1,4 @@ #!/bin/sh set -eu -gcc -march=native -mtune=native -std=gnu11 -O3 -flto -fomit-frame-pointer -fwrapv -Wno-attributes -Dmodulus_limbs='16' -Dmodulus_bytes_val='26' -Dlimb_t=uint32_t -Dlimb_weight_gaps_array='{26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26}' -Dmodulus_array='{0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xfe,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff}' -Dq_mpz='(1_mpz<<416) - (1_mpz<<208) - 1' "$@" +gcc -march=native -mtune=native -std=gnu11 -O3 -flto -fomit-frame-pointer -fwrapv -Wno-attributes -Dmodulus_bytes_val='26' -Dlimb_t=uint32_t -Dq_mpz='(1_mpz<<416) - (1_mpz<<208) - 1' -Dmodulus_limbs='16' -Dlimb_weight_gaps_array='{26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26}' -Dmodulus_array='{0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xfe,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff}' "$@" diff --git a/src/Specific/solinas32_2e416m2e208m1/compilerxx.sh b/src/Specific/solinas32_2e416m2e208m1/compilerxx.sh index abd232b61..27703e817 100755 --- a/src/Specific/solinas32_2e416m2e208m1/compilerxx.sh +++ b/src/Specific/solinas32_2e416m2e208m1/compilerxx.sh @@ -1,4 +1,4 @@ #!/bin/sh set -eu -g++ -march=native -mtune=native -std=gnu++11 -O3 -flto -fomit-frame-pointer -fwrapv -Wno-attributes -Dmodulus_limbs='16' -Dmodulus_bytes_val='26' -Dlimb_t=uint32_t -Dlimb_weight_gaps_array='{26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26}' -Dmodulus_array='{0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xfe,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff}' -Dq_mpz='(1_mpz<<416) - (1_mpz<<208) - 1' "$@" +g++ -march=native -mtune=native -std=gnu++11 -O3 -flto -fomit-frame-pointer -fwrapv -Wno-attributes -Dmodulus_bytes_val='26' -Dlimb_t=uint32_t -Dq_mpz='(1_mpz<<416) - (1_mpz<<208) - 1' -Dmodulus_limbs='16' -Dlimb_weight_gaps_array='{26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26}' -Dmodulus_array='{0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xfe,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff}' "$@" diff --git a/src/Specific/solinas32_2e416m2e208m1/feadd.v b/src/Specific/solinas32_2e416m2e208m1/feadd.v new file mode 100644 index 000000000..e978ff228 --- /dev/null +++ b/src/Specific/solinas32_2e416m2e208m1/feadd.v @@ -0,0 +1,14 @@ +Require Import Crypto.Arithmetic.PrimeFieldTheorems. +Require Import Crypto.Specific.solinas32_2e416m2e208m1.Synthesis. + +(* TODO : change this to field once field isomorphism happens *) +Definition add : + { add : feBW_tight -> feBW_tight -> feBW_loose + | forall a b, phiBW_loose (add a b) = F.add (phiBW_tight a) (phiBW_tight b) }. +Proof. + Set Ltac Profiling. + Time synthesize_add (). + Show Ltac Profile. +Time Defined. + +Print Assumptions add. diff --git a/src/Specific/solinas32_2e416m2e208m1/feaddDisplay.v b/src/Specific/solinas32_2e416m2e208m1/feaddDisplay.v new file mode 100644 index 000000000..69310112a --- /dev/null +++ b/src/Specific/solinas32_2e416m2e208m1/feaddDisplay.v @@ -0,0 +1,4 @@ +Require Import Crypto.Specific.solinas32_2e416m2e208m1.feadd. +Require Import Crypto.Specific.Framework.IntegrationTestDisplayCommon. + +Check display add. diff --git a/src/Specific/solinas32_2e416m2e208m1/fesub.v b/src/Specific/solinas32_2e416m2e208m1/fesub.v new file mode 100644 index 000000000..9c7858457 --- /dev/null +++ b/src/Specific/solinas32_2e416m2e208m1/fesub.v @@ -0,0 +1,14 @@ +Require Import Crypto.Arithmetic.PrimeFieldTheorems. +Require Import Crypto.Specific.solinas32_2e416m2e208m1.Synthesis. + +(* TODO : change this to field once field isomorphism happens *) +Definition sub : + { sub : feBW_tight -> feBW_tight -> feBW_loose + | forall a b, phiBW_loose (sub a b) = F.sub (phiBW_tight a) (phiBW_tight b) }. +Proof. + Set Ltac Profiling. + Time synthesize_sub (). + Show Ltac Profile. +Time Defined. + +Print Assumptions sub. diff --git a/src/Specific/solinas32_2e416m2e208m1/fesubDisplay.v b/src/Specific/solinas32_2e416m2e208m1/fesubDisplay.v new file mode 100644 index 000000000..7413d6423 --- /dev/null +++ b/src/Specific/solinas32_2e416m2e208m1/fesubDisplay.v @@ -0,0 +1,4 @@ +Require Import Crypto.Specific.solinas32_2e416m2e208m1.fesub. +Require Import Crypto.Specific.Framework.IntegrationTestDisplayCommon. + +Check display sub. |