From c50611790812ba94c052ec51364e13d773d5c64a Mon Sep 17 00:00:00 2001 From: Jason Gross Date: Thu, 30 Aug 2018 20:56:50 -0400 Subject: Improve documentation of binaries --- README.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 697eaceed..05fe28067 100644 --- a/README.md +++ b/README.md @@ -31,13 +31,15 @@ The binaries generating these C files can be made with make standalone +or `make standalone-haskell` or `make standalone-ocaml` for binaries generated with just one compiler. + The binaries are located in src/Experiments/NewPipeline/ExtractionOCaml/ or - src/Experiments/NewPipeline/ExtractionOCaml/ + src/Experiments/NewPipeline/ExtractionHaskell/ The binaries are: @@ -45,8 +47,17 @@ The binaries are: - `unsaturated_solinas` - `word_by_word_montgomery` -See the Makefile for examples of how to invoke these binaries. +Passing no arguments, or passing `-h` or `--help` (or any other invalid arguments) will result in a usage message being printed. These binaries output C code on stdout. + +Here are some examples of ways to invoke the binaries (from the directories that they live in): + + # Generate code for 2^255-19 + ./unsaturated_solinas '25519' '5' '2^255' '1,19' '64' carry_mul carry_square carry_scmul121666 carry add sub opp selectznz to_bytes from_bytes > curve25519_64.c + ./unsaturated_solinas '25519' '10' '2^255' '1,19' '32' carry_mul carry_square carry_scmul121666 carry add sub opp selectznz to_bytes from_bytes > curve25519_32.c + # Generate code for NIST-P256 (2^256 - 2^224 + 2^192 + 2^96 - 1) + ./word_by_word_montgomery 'p256' '2^256' '2^224,1;2^192,-1;2^96,-1;1,1' '32' > p256_32.c + ./word_by_word_montgomery 'p256' '2^256' '2^224,1;2^192,-1;2^96,-1;1,1' '64' > p256_64.c Old Pipeline ---- -- cgit v1.2.3