mirror of
https://github.com/arnaucube/poulpy.git
synced 2026-02-10 05:06:44 +01:00
Add & fix CI (#60)
This commit is contained in:
committed by
GitHub
parent
5d0d545f6a
commit
4c59733566
56
.github/workflows/ci.yml
vendored
56
.github/workflows/ci.yml
vendored
@@ -2,62 +2,36 @@ name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ main ]
|
||||
pull_request:
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
branches: [ main ]
|
||||
|
||||
jobs:
|
||||
build-and-test:
|
||||
name: Build & Test (stable, beta, nightly)
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
toolchain: [stable, beta, nightly]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions/setup-rust@v1
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
toolchain: ${{ matrix.toolchain }}
|
||||
components: clippy
|
||||
submodules: recursive
|
||||
|
||||
- name: Cache cargo registry
|
||||
uses: actions/cache@v3
|
||||
- name: Install Rust nightly
|
||||
uses: dtolnay/rust-toolchain@nightly
|
||||
|
||||
- name: Cache cargo dependencies
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/registry
|
||||
~/.cargo/git
|
||||
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
|
||||
target
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-cargo-registry-
|
||||
|
||||
- name: Cargo fmt check
|
||||
run: cargo fmt --all -- --check
|
||||
${{ runner.os }}-cargo-
|
||||
|
||||
- name: Build
|
||||
run: cargo build --all-targets --verbose
|
||||
run: cargo build --all-targets
|
||||
|
||||
- name: Run tests
|
||||
run: cargo test --all-targets --verbose
|
||||
|
||||
- name: Run Clippy
|
||||
run: cargo clippy --all-targets -- -D warnings
|
||||
|
||||
docs:
|
||||
name: Check Documentation
|
||||
runs-on: ubuntu-latest
|
||||
needs: build-and-test
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: actions/setup-rust@v1
|
||||
with:
|
||||
toolchain: stable
|
||||
|
||||
- name: Build docs
|
||||
run: cargo doc --all --no-deps --verbose
|
||||
run: cargo test --all
|
||||
@@ -4,6 +4,8 @@
|
||||
<img src="poulpy.png" />
|
||||
</p>
|
||||
|
||||
[](https://github.com/phantomzone-org/poulpy/actions/workflows/ci.yml)
|
||||
|
||||
**Poulpy** is a fast & modular FHE library that implements Ring-Learning-With-Errors based homomorphic encryption. It adopts the bivariate polynomial representation proposed in [Revisiting Key Decomposition Techniques for FHE: Simpler, Faster and More Generic](https://eprint.iacr.org/2023/771). In addition to simpler and more efficient arithmetic than the residue number system (RNS), this representation provides a common plaintext space for all schemes and allows easy switching between any two schemes. Poulpy also decouples the schemes implementations from the polynomial arithmetic backend by being built around a hardware abstraction layer (HAL). This enables user to easily provide or use a custom backend.
|
||||
|
||||
### Bivariate Polynomial Representation
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
pub fn build() {
|
||||
let dst: PathBuf = cmake::Config::new("src/implementation/cpu_spqlios/spqlios-arithmetic").build();
|
||||
let dst: PathBuf = cmake::Config::new("src/implementation/cpu_spqlios/spqlios-arithmetic").define("ENABLE_TESTING", "FALSE").build();
|
||||
|
||||
let lib_dir: PathBuf = dst.join("lib");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user