25 Commits

Author SHA1 Message Date
Alex Ozdemir
1224730215 bugfix: type error in obliv (#203) 2024-07-01 15:09:41 -07:00
Alex Ozdemir
913da600ab fix doc gen and add to CI (#201) 2024-06-24 19:14:04 -07:00
Alex Ozdemir
aa318e55a5 opts and tests from the memory project (#195) 2024-06-11 16:50:35 -07:00
Alex Ozdemir
2ebd0a11fa Fix spartan (and include its tests in CI) (#184)
Spartan bit-rotted because CI was misconfigured.
2024-01-31 16:20:16 -08:00
Alex Ozdemir
4c5dafee95 A Waksman-based RAM permutation argument (#171)
This allows folks to use the RAM machinery while sticking with (non-interactive) R1CS output.

We're going to need this anyway when we benchmark our new approach.
2023-09-19 02:39:24 -07:00
Edward Chen
bd9cec31fb Replaced third party dependencies with binaries to reduce CI build times (#162)
To reduce CI build time:
- Replaced ABY dependency with corresponding binary.
- Removed dependencies on KaHIP and KaHyPar for now because these dependencies aren't used upstream.
Minor updates:
- Updated ABY source to Public branch
Note: 
- The aby_interpreter binary will only work on Linux. We can rebuild the binary from this repo.
2023-06-14 14:58:39 -04:00
Alex Ozdemir
706405fd4f Committed witnesses & randomness in Z# (& tests) (#154)
A basic implementation of committed witnesses & volatile RAM extraction in the Z# front-end.

The passes in question are still a bit brittle, so I left them behind a flag.
2023-03-15 16:28:19 -07:00
Edward Chen
bb8e6e3673 KaHIP and kahypar binaries for MPC backend (#147)
- Upgraded ci pipeline to [v3](https://github.com/actions/cache/blob/main/README.md)
- Included installation and build scripts  for KaHIP and kahypar in driver.py
- Used absolute paths for caching in ci pipeline (relative paths don't work). 

Average ci time brought down from 15 minutes to 8 minutes!
2023-02-27 12:31:35 -05:00
Alex Ozdemir
77e7040047 Mirage, variable rounds, randomness, zk opt (#146)
Adds:

    an implementation of the Mirage proof system
        generalized to multiple round of interaction
    a notion of rounds for variables
    a notion of randomness for variables
    to the R1CS layer:
        committed witnesses
        rounds
    new witness computation machinery (to support multiple rounds)
2023-02-06 09:58:19 -08:00
Edward Chen
c06e938c41 Introducing SV Comp-style tests for C Frontend (#140)
Integrating SV comp tests for C Frontend

---------

Co-authored-by: Alex Ozdemir <aozdemir@hmc.edu>
2023-01-29 21:30:55 -05:00
Alex Ozdemir
5e36d4ba03 features: add bellman, spartan, aby (#139)
Also, add ./driver --check-all, which checks every single-feature build.
2023-01-19 00:13:09 -08:00
Alex Ozdemir
d15db74f04 change metadata serialization & representation (#137)
In the new approach, all variable metadata is stored per-variable.

This makes it easier to add new kinds of metadata, and to serialize that metadata.
2023-01-18 11:22:43 -08:00
Alex Ozdemir
838b8a6791 Include Anna's test cases and fix (#131)
The first bug is a disagreement between our bellman circuit and our bellman
verify function. The circuit omit unused variables (public or private). The
verify function includes unused public variables.

Now, the circuit includes unused public variables.

The second bug is related to large BV comparisons. The fix is to emit a
bitwise comparator. We could optimize further in the future.

closes #125
2023-01-09 23:00:35 -08:00
Alex Ozdemir
be8741c615 Configuration system. Kill DFL_T (#127)
* Configuration system. Kill DFL_T

* add circ::cfg::CircCfg that holds cfg info
   * it's constructible from circ_opt::CircOpt
      * implements clap::Args, so you can set it from your compiler's
        CLI/envvars
      * defined in external crate to keep clap out of our main build
      * organized by circ module, but not feature gated
         *  no point: the build wouldn't meaningfully change
      * includes a way to set the default field
* added circ::cfg::set and circ::cfg::cfg
   * also circ::cfg::set_default and circ::cfg::set_cfg
   * access a sync::once_cell, static configuration
* killed DFL_T

* workflows
   * unit-tested component probably need to not read circ::cfg::cfg.
   * compilers need to call circ::cfg::set or circ::cfg::set_default.

* rm dead features
2022-12-25 20:53:27 -08:00
Jess Woods
25773910e5 Spartan Backend (#70) 2022-11-07 10:11:58 -08:00
Edward Chen
f1dbab65ab Function Abstractions (#113)
Initial commit for support function abstractions.

`Computations` are maps of function names `str` to computation `Computation`. 

Updates:
- Frontend `Gen` returns `Computations` with only a single main `Computation`.
- Optimizations take in `Computations` instead of a single `Computation`. Optimizations are applied to each `Computation`. 
- Backends take in only the main `Computation`.
2022-10-18 21:27:58 -04:00
Alex Ozdemir
0658102675 RAM extraction (#88) 2022-06-23 07:33:34 -07:00
Alex Ozdemir
c1293464d2 Precomputations (or, as-known-for-proofs, witness extension) (#80)
Co-authored-by: Riad S. Wahby <rsw@jfet.org>
2022-05-17 08:54:04 -07:00
Alex Ozdemir
fa671673a8 Bugfix: non-recursive type-checking for Op::Map (#82)
Credits to @kwantam for noticing the bug. Thank you!
2022-05-07 12:31:37 -07:00
Edward Chen
63e3bea1b8 Adding benchmark scripts and logging for ABY backend (#72) 2022-04-06 04:04:52 -04:00
Riad S. Wahby
8c8e704914 field flexibility ; add limit for linearity reduction (#66)
Co-authored-by: Alex Ozdemir <aozdemir@hmc.edu>
2022-03-25 15:03:09 -07:00
Edward Chen
13f9a092b5 Updated ABY VM to include IN bytecode instruction (#65)
- updated ABY interpreter to include IN gates
- Added tqdm requirement
2022-03-24 15:53:44 -04:00
Alex Ozdemir
0d61d45a65 add flamegraph action (#59) 2022-03-10 09:16:40 -08:00
Edward Chen
8fed29bd32 ABY VM and Interpreter (#47)
Updated ABY testing framework with an ABY bytecode and interpreter
2022-02-28 19:47:50 -05:00
Edward Chen
b9526234ac Updating build system (#44)
`python3 driver.py -h`
2022-02-25 17:13:10 -05:00