diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml index 1db2f868e..6d4fa94c0 100644 --- a/.github/workflows/codespell.yml +++ b/.github/workflows/codespell.yml @@ -5,7 +5,6 @@ on: branches: - main - V3 - - yshekel/V3 jobs: spelling-checker: diff --git a/.github/workflows/cpp.yml b/.github/workflows/cpp.yml index fbd72c101..0a1f8a5f9 100644 --- a/.github/workflows/cpp.yml +++ b/.github/workflows/cpp.yml @@ -4,10 +4,11 @@ on: pull_request: branches: - V3 - - yshekel/V3 # TODO remove when merged to V3 + - main push: branches: - V3 + - main concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 42e9c103c..55097a9c8 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -4,6 +4,7 @@ on: push: branches: - main + - V3 paths: - 'docs/**' diff --git a/.github/workflows/examples.yml b/.github/workflows/examples.yml index c5240e6db..782c844fe 100644 --- a/.github/workflows/examples.yml +++ b/.github/workflows/examples.yml @@ -10,10 +10,11 @@ on: pull_request: branches: - V3 - - yshekel/V3 # TODO remove when merged to V3 + - main push: branches: - V3 + - main concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/golang.yml b/.github/workflows/golang.yml index 997728a0c..6cb6196b4 100644 --- a/.github/workflows/golang.yml +++ b/.github/workflows/golang.yml @@ -4,10 +4,11 @@ on: pull_request: branches: - V3 - - yshekel/V3 # TODO remove when merged to V3 + - main push: branches: - - V3 + - V3 + - main concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -43,7 +44,7 @@ jobs: needs: [check-changed-files, check-format, extract-cuda-backend-branch] strategy: matrix: - curve: + curve: - name: bn254 build_args: - name: bls12_381 @@ -82,7 +83,7 @@ jobs: CURVE=$(echo ${{ matrix.curve.name }} | sed -e 's/_//g') export ICICLE_BACKEND_INSTALL_DIR=/usr/local/lib go test ./$CURVE/tests -count=1 -failfast -p 2 -timeout 60m -v - + build-fields-linux: name: Build and test fields on Linux runs-on: [self-hosted, Linux, X64, icicle] diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index da1332470..c8c194c3f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -16,7 +16,7 @@ on: jobs: release: name: Release - runs-on: ubuntu-latest + runs-on: [self-hosted, Linux, X64, icicle] steps: - name: Checkout uses: actions/checkout@v4 diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index fd96fc9b9..d9ff91216 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -4,10 +4,11 @@ on: pull_request: branches: - V3 - - yshekel/V3 # TODO remove when merged to V3 + - main push: branches: - V3 + - main concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/test-deploy-docs.yml b/.github/workflows/test-deploy-docs.yml index 47550b2db..ae9f3094a 100644 --- a/.github/workflows/test-deploy-docs.yml +++ b/.github/workflows/test-deploy-docs.yml @@ -4,6 +4,7 @@ on: pull_request: branches: - main + - V3 paths: - 'docs/**' diff --git a/README.md b/README.md index a2bf0c134..5350562b6 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,7 @@ This guide will help you get started with ICICLE in C++, Rust, and Go. > **Developers**: We highly recommend reading our [documentation](https://dev.ingonyama.com/) for a comprehensive explanation of ICICLE’s capabilities. > [!TIP] -> Try out ICICLE by running some [examples] available in C++, Rust, and Go bindings. Check out our install-and-use examples in [C++](https://github.com/ingonyama-zk/icicle/tree/yshekel/V3/examples/c%2B%2B/install-and-use-icicle), [Rust](https://github.com/ingonyama-zk/icicle/tree/yshekel/V3/examples/rust/install-and-use-icicle) and [Go](TODO) +> Try out ICICLE by running some [examples] available in C++, Rust, and Go bindings. Check out our install-and-use examples in [C++](https://github.com/ingonyama-zk/icicle/tree/main/examples/c%2B%2B/install-and-use-icicle), [Rust](https://github.com/ingonyama-zk/icicle/tree/main/examples/rust/install-and-use-icicle) and [Go](TODO) ### Prerequisites diff --git a/docs/docs/icicle/arch_overview.md b/docs/docs/icicle/arch_overview.md index 5529ba4cb..a45f96a9b 100644 --- a/docs/docs/icicle/arch_overview.md +++ b/docs/docs/icicle/arch_overview.md @@ -1,34 +1,27 @@ # Architecture Overview -## Introduction -ICICLE V3 is designed with flexibility and extensibility in mind, offering a robust framework that supports multiple compute backends and accommodates various cryptographic needs. This section provides an overview of ICICLE's architecture, highlighting its open and closed components, multi-device support, and extensibility. +ICICLE v3 is designed with flexibility and extensibility in mind, offering a robust framework that supports multiple compute backends and accommodates various cryptographic needs. This section provides an overview of ICICLE's architecture, highlighting its open and closed components, multi-device support, and extensibility. -## Open Frontend and CPU Backend +### Frontend and CPU Backend - **Frontend (FE):** The ICICLE frontend is open-source and designed to provide a unified API across different programming languages, including C++, Rust, and Go. This frontend abstracts the complexity of working with different backends, allowing developers to write backend-agnostic code that can be deployed across various platforms. - **CPU Backend:** ICICLE includes an open-source CPU backend that allows for development and testing on standard hardware. This backend is ideal for prototyping and for environments where specialized hardware is not available. -## Closed CUDA Backend +## CUDA Backend - **CUDA Backend:** ICICLE also includes a high-performance CUDA backend that is closed-source. This backend is optimized for NVIDIA GPUs and provides significant acceleration for cryptographic operations. - **Installation and Licensing:** The CUDA backend needs to be downloaded and installed. Refer to the [installation guide](./install_cuda_backend.md) for detailed instructions. -## Extensible Design - -ICICLE is designed to be extensible, allowing developers to integrate new backends or customize existing ones to suit their specific needs. The architecture supports: - -- **Custom Backends:** Developers can create their own backends to leverage different hardware or optimize for specific use cases. The process of building and integrating a custom backend is documented in the [Build Your Own Backend](./build_your_own_backend.md) section. -- **Pluggable Components:** ICICLE's architecture allows for easy integration of additional cryptographic primitives or enhancements, ensuring that the framework can evolve with the latest advancements in cryptography and hardware acceleration. - ## Multi-Device Support - **Scalability:** ICICLE supports multi-device configurations, enabling the distribution of workloads across multiple GPUs or other hardware accelerators. This feature allows for scaling ZK proofs and other cryptographic operations across larger data centers or high-performance computing environments. ---- -### Conclusion +## Build Your Own Backend + +ICICLE is designed to be extensible, allowing developers to integrate new backends or customize existing ones to suit their specific needs. The architecture supports: -The architecture of ICICLE V3 is built to be flexible, scalable, and extensible, making it a powerful tool for developers working with zero-knowledge proofs and other cryptographic operations. Whether you're working with open-source CPU backends or closed-source CUDA backends, ICICLE provides the tools and flexibility needed to achieve high performance and scalability in cryptographic computations. +- **Custom Backends:** Developers can create their own backends to leverage different hardware or optimize for specific use cases. The process of building and integrating a custom backend is documented in the [Build Your Own Backend](./build_your_own_backend.md) section. +- **Pluggable Components:** ICICLE's architecture allows for easy integration of additional cryptographic primitives or enhancements, ensuring that the framework can evolve with the latest advancements in cryptography and hardware acceleration. -Explore the following sections to learn more about building your own backend, using ICICLE across multiple devices, and integrating it into your projects. diff --git a/docs/docs/icicle/build_from_source.md b/docs/docs/icicle/build_from_source.md index 8e0f3fcbf..c8f439506 100644 --- a/docs/docs/icicle/build_from_source.md +++ b/docs/docs/icicle/build_from_source.md @@ -175,6 +175,5 @@ Make sure to install icicle libs when installing a library/application that depe ### Go: Build, Test, and Install (TODO) -## Install cuda backend - -[Install CUDA Backend (and License)](./install_cuda_backend.md#installation) \ No newline at end of file +--- +**To install CUDA backend and license click [here](./install_cuda_backend.md#installation)** diff --git a/docs/docs/icicle/getting_started.md b/docs/docs/icicle/getting_started.md index 4476ef08b..3ca043aad 100644 --- a/docs/docs/icicle/getting_started.md +++ b/docs/docs/icicle/getting_started.md @@ -24,21 +24,19 @@ Future releases will also include support for macOS and other systems. Each ICICLE release includes a tar file named `icicle30-.tar.gz`, where `icicle30` indicates version 3.0. This tar file contains ICICLE frontend build artifacts and headers for a specific distribution. The tar file structure includes: -- **`./icicle/include/`**: This directory contains all the necessary header files for using the Icicle library from C++. +- **`./icicle/include/`**: This directory contains all the necessary header files for using the ICICLE library from C++. - **`./icicle/lib/`**: - - **Icicle Libraries**: All the core Icicle libraries are located in this directory. Applications linking to Icicle will use these libraries. + - **Icicle Libraries**: All the core ICICLE libraries are located in this directory. Applications linking to ICICLE will use these libraries. - **Backends**: The `./icicle/lib/backend/` directory houses backend libraries, including the CUDA backend (not included in this tar). - **CUDA backend** comes as separate tar `icicle30--cuda122.tar.gz` - - per distribution, for icicle-frontend V3.0 and CUDA 12.2. + - per distribution, for ICICLE-frontend v3.0 and CUDA 12.2. -## installing and using icicle +## Installing and using ICICLE -- [Full C++ example](https://github.com/ingonyama-zk/icicle/tree/yshekel/V3/examples/c++/install-and-use-icicle) -- [Full Rust example](https://github.com/ingonyama-zk/icicle/tree/yshekel/V3/examples/rust/install-and-use-icicle) -- [Full Go example](https://github.com/ingonyama-zk/icicle/tree/yshekel/V3/examples/golang/install-and-use-icicle) - -*(TODO update links to main branch when merged) +- [Full C++ example](https://github.com/ingonyama-zk/icicle/tree/main/examples/c++/install-and-use-icicle) +- [Full Rust example](https://github.com/ingonyama-zk/icicle/tree/main/examples/rust/install-and-use-icicle) +- [Full Go example](https://github.com/ingonyama-zk/icicle/tree/main/examples/golang/install-and-use-icicle) 1. **Extract and install the Tar Files**: - [Download](https://github.com/ingonyama-zk/icicle/releases) the appropriate tar files for your distribution (Ubuntu 20.04, Ubuntu 22.04, or UBI 8,9 for RHEL compatible binaries). @@ -106,7 +104,7 @@ Each ICICLE release includes a tar file named `icicle30-.tar.gz`, **Rust** - When building the ICICLE crates, ICICLE frontend libs are built from source, along with the Rust bindings. They are installed to `target//deps/icicle`, and Cargo will link them correctly. Note that you still need to install the CUDA backend if you have a CUDA GPU. - - Simply use `cargo build` or `cargo run` and it should link to icicle libs. + - Simply use `cargo build` or `cargo run` and it should link to ICICLE libs. **Go** - TODO diff --git a/docs/docs/icicle/golang-bindings/multi-gpu.md b/docs/docs/icicle/golang-bindings/multi-gpu.md index 186c02018..7f0a66257 100644 --- a/docs/docs/icicle/golang-bindings/multi-gpu.md +++ b/docs/docs/icicle/golang-bindings/multi-gpu.md @@ -1,6 +1,6 @@ # Multi GPU APIs -To learn more about the theory of Multi GPU programming refer to [this part](../multi-gpu.md) of documentation. +To learn more about the theory of Multi GPU programming refer to [this part](../multi-device.md) of documentation. Here we will cover the core multi GPU apis and an [example](#a-multi-gpu-example) diff --git a/docs/docs/icicle/install_cuda_backend.md b/docs/docs/icicle/install_cuda_backend.md index 32c76793d..f47dec7f0 100644 --- a/docs/docs/icicle/install_cuda_backend.md +++ b/docs/docs/icicle/install_cuda_backend.md @@ -3,7 +3,7 @@ ## Overview -The CUDA backend in ICICLE V3 is a high-performance, closed-source component designed to accelerate cryptographic computations using NVIDIA GPUs. This backend includes specialized libraries optimized for various cryptographic fields and curves, providing significant speedups for operations such as MSM, NTT, and elliptic curve operations. +The CUDA backend in ICICLE v3 is a high-performance, closed-source component designed to accelerate cryptographic computations using NVIDIA GPUs. This backend includes specialized libraries optimized for various cryptographic fields and curves, providing significant speedups for operations such as MSM, NTT, and elliptic curve operations. ## Installation @@ -12,7 +12,7 @@ The CUDA backend is a closed-source component that requires a license. [To insta ### Licensing :::note -Currently, the CUDA backend is free to use via Ingonyama’s icicle-cuda-backend-license server. By default, the CUDA backend will attempt to access this server. For more details, please contact support@ingonyama.com. +Currently, the CUDA backend is free to use via Ingonyama’s backend license server. By default, the CUDA backend will attempt to access this server. For more details, please contact support@ingonyama.com. ::: The CUDA backend requires a valid license to function. There are two types of CUDA backend licenses: diff --git a/docs/docs/icicle/libraries.md b/docs/docs/icicle/libraries.md index 00c561e16..2a6a2f475 100644 --- a/docs/docs/icicle/libraries.md +++ b/docs/docs/icicle/libraries.md @@ -8,7 +8,7 @@ ICICLE is composed of two main logical parts: The ICICLE device library serves as an abstraction layer for interacting with various hardware devices. It provides a comprehensive interface for tasks such as setting the active device, querying device-specific information like free and total memory, determining the number of available devices, and managing memory allocation. Additionally, it offers functionality for copying data to and from devices, managing task queues (streams) for efficient device utilization, and abstracting the complexities of device management away from the user. -See programmers guide for more details. [C++](./programmers_guide/cpp#device-management), [Rust](./programmers_guide/rust#device-management), [Go TODO](./programmers_guide/go) +See programmers guide for more details. [C++](./programmers_guide/cpp#device-management), [Rust](./programmers_guide/rust#device-management), [Go](./programmers_guide/go) ## ICICLE Core diff --git a/docs/docs/icicle/migrate_from_v2.md b/docs/docs/icicle/migrate_from_v2.md index 792f3b435..acb2ff482 100644 --- a/docs/docs/icicle/migrate_from_v2.md +++ b/docs/docs/icicle/migrate_from_v2.md @@ -1,7 +1,7 @@ -# Migration from Icicle V2 to V3 +# Migration from ICICLE v2 to v3 -Icicle V3 introduces a unified interface for high-performance computing across various devices, extending the functionality that was previously limited to GPUs in Icicle V2. This guide will assist you in transitioning from Icicle V2 to V3 by highlighting the key changes and providing examples for both C++ and Rust. +ICICLE v3 introduces a unified interface for high-performance computing across various devices, extending the functionality that was previously limited to GPUs in Icicle V2. This guide will assist you in transitioning from ICICLE v2 to v3 by highlighting the key changes and providing examples for both C++ and Rust. ## Key Conceptual Changes @@ -10,20 +10,20 @@ Icicle V3 introduces a unified interface for high-performance computing across v - **Unified API**: The APIs are now standardized across all devices, ensuring consistent usage and reducing the complexity of managing different hardware backends. :::warning -When migrating from V2 to V3, it is important to note that, by default, your code now executes on the CPU. This contrasts with V2, which was exclusively a CUDA library. For details on installing and using CUDA GPUs, refer to the [CUDA backend guide](./install_cuda_backend.md). +When migrating from v2 to v3, it is important to note that, by default, your code now executes on the CPU. This contrasts with V2, which was exclusively a CUDA library. For details on installing and using CUDA GPUs, refer to the [CUDA backend guide](./install_cuda_backend.md). ::: ## Migration Guide for C++ ### Replacing CUDA APIs with Icicle APIs -In Icicle V3, CUDA-specific APIs have been replaced with Icicle APIs that are designed to be backend-agnostic. This allows your code to run on different devices without requiring modifications. +In ICICLE v3, CUDA-specific APIs have been replaced with Icicle APIs that are designed to be backend-agnostic. This allows your code to run on different devices without requiring modifications. -- **Device Management**: Use Icicle's device management APIs instead of CUDA-specific functions. For example, instead of `cudaSetDevice()`, you would use `icicle_set_device()`. +- **Device Management**: Use ICICLE's device management APIs instead of CUDA-specific functions. For example, instead of `cudaSetDevice()`, you would use `icicle_set_device()`. -- **Memory Management**: Replace CUDA memory management functions such as `cudaMalloc()` and `cudaFree()` with Icicle's `icicle_malloc()` and `icicle_free()`. +- **Memory Management**: Replace CUDA memory management functions such as `cudaMalloc()` and `cudaFree()` with ICICLE's `icicle_malloc()` and `icicle_free()`. -- **Stream Management**: Replace `cudaStream_t` with `icicleStreamHandle` and use Icicle's stream management functions. +- **Stream Management**: Replace `cudaStream_t` with `icicleStreamHandle` and use ICICLE's stream management functions. For a detailed overview and examples, please refer to the [Icicle C++ Programmer's Guide](./programmers_guide/cpp.md) for full API details. @@ -55,7 +55,7 @@ icicle_free(device_ptr); ### Replacing `icicle_cuda_runtime` with `icicle_runtime` -In Icicle V3, the `icicle_cuda_runtime` crate is replaced with the `icicle_runtime` crate. This change reflects the broader support for different devices beyond just CUDA-enabled GPUs. +In ICICLE v3, the `icicle_cuda_runtime` crate is replaced with the `icicle_runtime` crate. This change reflects the broader support for different devices beyond just CUDA-enabled GPUs. - **Device Management**: Use `icicle_runtime`'s device management functions instead of those in `icicle_cuda_runtime`. The `Device` struct remains central, but it's now part of a more generalized runtime. diff --git a/docs/docs/icicle/multi-device.md b/docs/docs/icicle/multi-device.md index 07f690a8d..05e8b3776 100644 --- a/docs/docs/icicle/multi-device.md +++ b/docs/docs/icicle/multi-device.md @@ -17,7 +17,9 @@ There are many [different strategies](https://github.com/NVIDIA/multi-gpu-progra This approach typically involves a single or multiple CPUs managing threads that read from and write to multiple devices, such as GPUs, CPUs, or accelerators. You can think of it as a scaled-up HOST-Device model. -![Multi-Device Server Approach](image.png) +

+ Multi-Device Server Approach +

This approach doesn't necessarily allow for tackling larger computation sizes, but it does enable the simultaneous computation of tasks that wouldn't fit on a single device. @@ -33,7 +35,7 @@ This approach requires redesigning the algorithm at the software level to be com Currently, ICICLE adopts a Device Server approach, where we assume you have a machine with multiple devices (GPUs, CPUs, etc.) and wish to run computations on each device. -Each thread needs to set a device. Following api calls (including memory management and compute apis) will execute on that device, for this thread. +Each thread needs to set a device. Following API calls (including memory management and compute APIs) will execute on that device, for this thread. ### C++ ```cpp diff --git a/docs/docs/icicle/overview.md b/docs/docs/icicle/overview.md index 49fb67ecc..d65e75432 100644 --- a/docs/docs/icicle/overview.md +++ b/docs/docs/icicle/overview.md @@ -5,8 +5,14 @@ title: ICICLE Overview # ICICLE Overview +

+ Untitled design (29) +

+ + ## What is ICICLE? + [![GitHub Release](https://img.shields.io/github/v/release/ingonyama-zk/icicle)](https://github.com/ingonyama-zk/icicle/releases) [ICICLE](https://github.com/ingonyama-zk/icicle) is a cryptography library designed to accelerate zero-knowledge proofs (ZKPs) using multiple compute backends, including GPUs, CPUs, and potentially other platforms. ICICLE's key strength lies in its ability to implement blazing-fast cryptographic primitives, enabling developers to significantly reduce proving times with minimal effort. @@ -19,9 +25,9 @@ title: ICICLE Overview - **Backend Agnosticism:** Develop on CPU and deploy on various backends, including GPUs, specialized hardware, and other emerging platforms, depending on your project's needs. - **Extensibility:** Designed for easy integration and extension, allowing you to build and deploy custom backends and cryptographic primitives. -## Evolution from V2 to V3 +## Evolution from v2 to v3 -Originally, ICICLE was focused solely on GPU acceleration. With the release of V3, ICICLE now supports multiple backends, making it more versatile and adaptable to different hardware environments. Whether you're leveraging the power of GPUs or exploring other compute platforms, ICICLE V3 is designed to fit your needs. +Originally, ICICLE was focused solely on GPU acceleration. With the release of v3, ICICLE now supports multiple backends, making it more versatile and adaptable to different hardware environments. Whether you're leveraging the power of GPUs or exploring other compute platforms, ICICLE v3 is designed to fit your needs. ## Who Uses ICICLE? @@ -69,9 +75,9 @@ ICICLE is also well-suited for prototyping and developing small-scale projects. ## Get Started with ICICLE -Explore the full capabilities of ICICLE by diving into the [Architecture](./arch_overview.md), [Getting Started Guide](./getting_started.md) and the [programmers guide](./programmers_guide/general.md) to learn how to integrate, deploy, and extend ICICLE across different backends. +Explore the full capabilities of ICICLE by diving into the [Architecture](./arch_overview.md), [Getting Started Guide](./getting_started.md) and the [Programmer's Guide](./programmers_guide/general.md) to learn how to integrate, deploy, and extend ICICLE across different backends. -If you have any questions or need support, feel free to reach out on [Discord] or [GitHub](https://github.com/ingonyama-zk). We're here to help you accelerate your ZK development with ICICLE. +If you have any questions or need support, feel free to reach out on [Discord], [GitHub](https://github.com/ingonyama-zk) or . We're here to help you accelerate your ZK development with ICICLE. [ICICLE-OVERVIEW]: ./icicle/overview.md -[Discord]: https://discord.gg/6vYrE7waPj \ No newline at end of file +[Discord]: https://discord.gg/6vYrE7waPj diff --git a/docs/docs/icicle/primitives/Icicle_Release_README.md b/docs/docs/icicle/primitives/Icicle_Release_README.md index 4d3a76e89..510a4de7c 100644 --- a/docs/docs/icicle/primitives/Icicle_Release_README.md +++ b/docs/docs/icicle/primitives/Icicle_Release_README.md @@ -19,8 +19,6 @@ Each Icicle release includes a tar file containing the build artifacts for a spe Currently, the CUDA backend is included in every installation tar file, even on machines without a GPU. This ensures consistency across installations but results in additional files being installed that may not be used. -**TODO**: Consider splitting the release into two separate tar files—one with the CUDA backend and one without—depending on the target machine’s hardware capabilities. - ## Build Docker Image To build the Docker images for each distribution and CUDA version, use the following commands: diff --git a/docs/docs/icicle/primitives/overview.md b/docs/docs/icicle/primitives/overview.md index 4fe315144..fbbc0006e 100644 --- a/docs/docs/icicle/primitives/overview.md +++ b/docs/docs/icicle/primitives/overview.md @@ -8,4 +8,4 @@ This section of the documentation is dedicated to the main APIs provided by ICIC - [NTT](./ntt.md) - [Vector Operations](./vec_ops.md) - [Polynomials](../polynomials/overview.md) -- Hashing and commitment schemes coming soon +- _Hashing and commitment schemes coming soon_ diff --git a/docs/docs/icicle/primitives/poseidon.md b/docs/docs/icicle/primitives/poseidon.md index df2af0930..37ea7455a 100644 --- a/docs/docs/icicle/primitives/poseidon.md +++ b/docs/docs/icicle/primitives/poseidon.md @@ -62,7 +62,7 @@ So for Poseidon of arity 2 and input of size 1024 * 2, we would expect 1024 elem Poseidon is extremely customizable and using different constants will produce different hashes, security levels and performance results. -We support pre-calculated and optimized constants for each of the [supported curves](../core#supported-curves-and-operations).The constants can be found [here](https://github.com/ingonyama-zk/icicle/tree/main/icicle/include/poseidon/constants) and are labeled clearly per curve `_poseidon.h`. +We support pre-calculated and optimized constants for each of the [supported curves](../libraries#supported-curves-and-operations).The constants can be found [here](https://github.com/ingonyama-zk/icicle/tree/main/icicle/include/poseidon/constants) and are labeled clearly per curve `_poseidon.h`. If you wish to generate your own constants you can use our python script which can be found [here](https://github.com/ingonyama-zk/icicle/tree/main/icicle/include/poseidon/constants/generate_parameters.py). diff --git a/docs/docs/icicle/primitives/poseidon2.md b/docs/docs/icicle/primitives/poseidon2.md index fcb2a7e06..622fc2a85 100644 --- a/docs/docs/icicle/primitives/poseidon2.md +++ b/docs/docs/icicle/primitives/poseidon2.md @@ -20,7 +20,7 @@ For example, for Poseidon2 of width 16, input rate 8, output elements 8 and inpu Poseidon2 is also extremely customizable and using different constants will produce different hashes, security levels and performance results. -We support pre-calculated constants for each of the [supported curves](../core#supported-curves-and-operations). The constants can be found [here](https://github.com/ingonyama-zk/icicle/tree/main/icicle/include/poseidon2/constants) and are labeled clearly per curve `_poseidon2.h`. +We support pre-calculated constants for each of the [supported curves](../libraries#supported-curves-and-operations). The constants can be found [here](https://github.com/ingonyama-zk/icicle/tree/main/icicle/include/poseidon2/constants) and are labeled clearly per curve `_poseidon2.h`. You can also use your own set of constants as shown [here](https://github.com/ingonyama-zk/icicle/blob/main/wrappers/rust/icicle-fields/icicle-babybear/src/poseidon2/mod.rs#L290) diff --git a/docs/docs/icicle/programmers_guide/cpp.md b/docs/docs/icicle/programmers_guide/cpp.md index bd534da1e..b8f1f285f 100644 --- a/docs/docs/icicle/programmers_guide/cpp.md +++ b/docs/docs/icicle/programmers_guide/cpp.md @@ -2,12 +2,12 @@ ## Overview -This guide covers the usage of Icicle's C++ API, including device management, memory operations, data transfer, synchronization, and compute APIs. +This guide covers the usage of ICICLE's C++ API, including device management, memory operations, data transfer, synchronization, and compute APIs. ## Device Management :::note -See all icicle runtime APIs in [runtime.h](https://github.com/ingonyama-zk/icicle/blob/yshekel/V3/icicle/include/icicle/runtime.h) +See all ICICLE runtime APIs in [runtime.h](https://github.com/ingonyama-zk/icicle/blob/main/icicle/include/icicle/runtime.h) ::: ### Loading a Backend diff --git a/docs/docs/icicle/programmers_guide/general.md b/docs/docs/icicle/programmers_guide/general.md index 3d2062c56..b02cd2f9c 100644 --- a/docs/docs/icicle/programmers_guide/general.md +++ b/docs/docs/icicle/programmers_guide/general.md @@ -3,7 +3,7 @@ ## Compute APIs -Icicle offers a variety of compute APIs, including Number Theoretic Transforms (NTT), Multi Scalar Multiplication (MSM), vector operations, Elliptic Curve NTT (ECNTT), polynomials, and more. These APIs follow a consistent structure, making it straightforward to apply the same usage patterns across different operations. +ICICLE offers a variety of compute APIs, including Number Theoretic Transforms (NTT), Multi Scalar Multiplication (MSM), vector operations, Elliptic Curve NTT (ECNTT), polynomials, and more. These APIs follow a consistent structure, making it straightforward to apply the same usage patterns across different operations. [Check out all details about compute APIs here](../primitives/overview.md). @@ -74,7 +74,7 @@ Having said that, it is not an error to pass options to a backend that is not aw ## Device Abstraction -Icicle provides a device abstraction layer that allows you to interact with different compute devices such as CPUs and GPUs seamlessly. The device abstraction ensures that your code can work across multiple hardware platforms without modification. +ICICLE provides a device abstraction layer that allows you to interact with different compute devices such as CPUs and GPUs seamlessly. The device abstraction ensures that your code can work across multiple hardware platforms without modification. ### Device Management @@ -83,7 +83,7 @@ Icicle provides a device abstraction layer that allows you to interact with diff ## Streams -Streams in Icicle allow for asynchronous execution and memory operations, enabling parallelism and non-blocking execution. Streams are associated with specific devices, and you can create, destroy, and synchronize streams to manage your workflow. +Streams in ICICLE allow for asynchronous execution and memory operations, enabling parallelism and non-blocking execution. Streams are associated with specific devices, and you can create, destroy, and synchronize streams to manage your workflow. :::note For compute APIs, streams go into the `config.stream` field along with the `is_async=true` config flag. diff --git a/docs/docs/icicle/programmers_guide/go.md b/docs/docs/icicle/programmers_guide/go.md index 1cd6bec11..d869c98f0 100644 --- a/docs/docs/icicle/programmers_guide/go.md +++ b/docs/docs/icicle/programmers_guide/go.md @@ -2,12 +2,12 @@ ## Overview -This guide covers the usage of Icicle's Golang API, including device management, memory operations, data transfer, synchronization, and compute APIs. +This guide covers the usage of ICICLE's Golang API, including device management, memory operations, data transfer, synchronization, and compute APIs. ## Device Management :::note -See all ICICLE runtime APIs in [runtime.go](https://github.com/ingonyama-zk/icicle/blob/yshekel/V3/wrappers/golang/runtime/runtime.go) +See all ICICLE runtime APIs in [runtime.go](https://github.com/ingonyama-zk/icicle/blob/main/wrappers/golang/runtime/runtime.go) ::: ### Loading a Backend diff --git a/docs/docs/icicle/programmers_guide/rust.md b/docs/docs/icicle/programmers_guide/rust.md index c3f89f514..af5caa5a8 100644 --- a/docs/docs/icicle/programmers_guide/rust.md +++ b/docs/docs/icicle/programmers_guide/rust.md @@ -3,7 +3,7 @@ ## Overview -This guide covers the usage of Icicle’s Rust API, including device management, memory operations, data transfer, synchronization, and compute APIs. +This guide covers the usage of ICICLE’s Rust API, including device management, memory operations, data transfer, synchronization, and compute APIs. ## Build the Rust Application and Execute diff --git a/docs/docs/icicle/rust-bindings/multi-gpu.md b/docs/docs/icicle/rust-bindings/multi-gpu.md index 29cee1aba..527e780ee 100644 --- a/docs/docs/icicle/rust-bindings/multi-gpu.md +++ b/docs/docs/icicle/rust-bindings/multi-gpu.md @@ -2,7 +2,7 @@ TODO update for V3 -To learn more about the theory of Multi GPU programming refer to [this part](../multi-gpu.md) of documentation. +To learn more about the theory of Multi GPU programming refer to [this part](../multi-device.md) of documentation. Here we will cover the core multi GPU apis and a [example](#a-multi-gpu-example) diff --git a/docs/docusaurus.config.js b/docs/docusaurus.config.js index f420ca7da..83074b4cb 100644 --- a/docs/docusaurus.config.js +++ b/docs/docusaurus.config.js @@ -83,30 +83,16 @@ const config = { respectPrefersColorScheme: false, }, algolia: { - // The application ID provided by Algolia appId: 'PZY4KJBBBK', - - // Public API key: it is safe to commit it apiKey: '2cc940a6e0ef5c117f4f44e7f4e6e20b', - indexName: 'ingonyama', - - // Optional: see doc section below contextualSearch: true, - - // Optional: Specify domains where the navigation should occur through window.location instead on history.push. Useful when our Algolia config crawls multiple documentation sites and we want to navigate with window.location.href to them. externalUrlRegex: 'external\\.com|domain\\.com', - - // Optional: Replace parts of the item URLs from Algolia. Useful when using the same search index for multiple deployments using a different baseUrl. You can use regexp or string in the `from` param. For example: localhost:3000 vs myCompany.com/docs replaceSearchResultPathname: { - from: '/docs/', // or as RegExp: /\/docs\// + from: '/docs/', to: '/', }, - - // Optional: Algolia search parameters searchParameters: {}, - - // Optional: path for search page that enabled by default (`false` to disable it) searchPagePath: 'search', }, navbar: { @@ -169,8 +155,8 @@ const config = { announcementBar: { id: 'announcement', // Any value that will identify this message. content: - '🎉 Read our paper on the Polynomials API in ICICLE v2 by clicking here! 🎉', - backgroundColor: '#ADD8E6', // Light blue background color. + '❄️🎉 New Release! ICICLE v3! Click here to read article 🎉❄️', + backgroundColor: '#64f5ef', // Light blue background color. textColor: '#000000', // Black text color. isCloseable: true, // Defaults to `true`. }, @@ -178,3 +164,4 @@ const config = { }; module.exports = config; + diff --git a/docs/sidebars.js b/docs/sidebars.js index c23d9b836..675fcc804 100644 --- a/docs/sidebars.js +++ b/docs/sidebars.js @@ -28,6 +28,32 @@ module.exports = { label: "Build ICICLE from source", id: "icicle/build_from_source", }, + { + type: "category", + label: "Programmers guide", + link: { + type: `doc`, + id: "icicle/programmers_guide/general", + }, + collapsed: false, + items: [ + { + type: "doc", + label: "C++", + id: "icicle/programmers_guide/cpp", + }, + { + type: "doc", + label: "Rust", + id: "icicle/programmers_guide/rust", + }, + { + type: "doc", + label: "Go", + id: "icicle/programmers_guide/go", + } + ], + }, ], }, { @@ -46,7 +72,7 @@ module.exports = { }, { type: "doc", - label: "Multi Device Support", + label: "Multi-Device Support", id: "icicle/multi-device", }, { @@ -61,32 +87,6 @@ module.exports = { label: "ICICLE libraries", id: "icicle/libraries", }, - { - type: "category", - label: "Programmers guide", - link: { - type: `doc`, - id: "icicle/programmers_guide/general", - }, - collapsed: false, - items: [ - { - type: "doc", - label: "C++", - id: "icicle/programmers_guide/cpp", - }, - { - type: "doc", - label: "Rust", - id: "icicle/programmers_guide/rust", - }, - { - type: "doc", - label: "Go", - id: "icicle/programmers_guide/go", - } - ], - }, { type: "category", label: "Compute API", @@ -197,18 +197,18 @@ module.exports = { label: "Polynomials", id: "icicle/rust-bindings/polynomials", }, - { - type: "doc", - label: "Multi GPU Support (TODO)", - id: "icicle/rust-bindings/multi-gpu", - }, + // { + // type: "doc", + // label: "Multi GPU Support (TODO)", + // id: "icicle/rust-bindings/multi-gpu", + // }, ], }, ], }, { type: "doc", - label: "Migrate from ICICLE V2", + label: "Migrate from ICICLE v2", id: "icicle/migrate_from_v2", }, { diff --git a/examples/rust/install-and-use-icicle/Cargo.toml b/examples/rust/install-and-use-icicle/Cargo.toml index c1c83c0b5..191ae9599 100644 --- a/examples/rust/install-and-use-icicle/Cargo.toml +++ b/examples/rust/install-and-use-icicle/Cargo.toml @@ -4,8 +4,8 @@ version = "1.2.0" edition = "2018" [dependencies] -icicle-runtime = { git = "https://github.com/ingonyama-zk/icicle.git", branch="yshekel/V3" } -icicle-core = { git = "https://github.com/ingonyama-zk/icicle.git", branch="yshekel/V3" } -icicle-babybear = { git = "https://github.com/ingonyama-zk/icicle.git", branch="yshekel/V3" } +icicle-runtime = { git = "https://github.com/ingonyama-zk/icicle.git", branch="main" } +icicle-core = { git = "https://github.com/ingonyama-zk/icicle.git", branch="main" } +icicle-babybear = { git = "https://github.com/ingonyama-zk/icicle.git", branch="main" } [features]