Skip to content

Commit

Permalink
Upgrade to Rust 1.80
Browse files Browse the repository at this point in the history
  • Loading branch information
akoshelev committed Jul 26, 2024
1 parent 1349aa6 commit 75f1650
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion ipa-core/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "ipa-core"
version = "0.1.0"
rust-version = "1.77.0"
rust-version = "1.80.0"
edition = "2021"
build = "build.rs"

Expand Down
2 changes: 1 addition & 1 deletion ipa-core/src/helpers/transport/in_memory/sharding.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ impl InMemoryShardNetwork {

pub fn reset(&self) {
for helper in &self.shard_network {
for shard in helper.iter() {
for shard in helper {
shard.reset();
}
}
Expand Down
4 changes: 2 additions & 2 deletions ipa-core/src/protocol/ipa_prf/boolean_ops/multiplication.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ use crate::{
/// X is assumed to be a positive number, so we will automatically pad with ZERO.
/// 2. Repeatedly multiply x with each digits of y, shift the result 1 digit up each time
/// 3. Add up the partial products using `integer_add`
/// x is assumed to be a positive number
/// y is assumed to be in two's complement and can be either signed or unsigned
/// x is assumed to be a positive number
/// y is assumed to be in two's complement and can be either signed or unsigned
#[allow(dead_code)]
pub async fn integer_mul<C, S, const N: usize>(
ctx: C,
Expand Down
20 changes: 12 additions & 8 deletions ipa-core/src/query/processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ use crate::{
///
/// Query processing consists of multiple steps:
/// - A new request to initiate a query arrives from an external party (report collector) to any of the
/// helpers.
/// helpers.
/// - Upon receiving that request, helper chooses a unique [`QueryId`] and assigns [`Role`] to every
/// helper. It informs other parties about it and awaits their response.
/// helper. It informs other parties about it and awaits their response.
/// - If all parties accept the proposed query, they negotiate shared randomness and signal that
/// - they're ready to receive inputs.
/// they're ready to receive inputs.
/// - Each party, upon receiving the input as a set of [`AdditiveShare`], immediately starts executing
/// IPA protocol.
/// IPA protocol.
/// - When helper party is done, it holds onto the results of the computation until the external party
/// that initiated this request asks for them.
/// that initiated this request asks for them.
///
/// [`AdditiveShare`]: crate::secret_sharing::replicated::semi_honest::AdditiveShare
pub struct Processor {
Expand Down Expand Up @@ -121,10 +121,14 @@ impl Processor {

/// Upon receiving a new query request:
/// * processor generates new query id
/// * assigns roles to helpers in the ring. Helper that received new query request becomes `Role::H1` (aka coordinator).
/// The coordinator is in theory free to choose helpers for `Role::H2` and `Role::H3` arbitrarily (aka followers), however, this is not currently exercised.
/// * assigns roles to helpers in the ring.
/// Helper that received new query request becomes `Role::H1` (aka coordinator).
/// The coordinator is in theory free to choose helpers for `Role::H2` and `Role::H3`
/// arbitrarily (aka followers), however, this is not currently exercised.
/// * Requests Infra and Network layer to create resources for this query
/// * sends `prepare` request that describes the query configuration (query id, query type, field type, roles -> endpoints or reverse) to followers and waits for the confirmation
/// * sends `prepare` request that describes the query configuration
/// (query id, query type, field type, roles -> endpoints or reverse)
/// to followers and waits for the confirmation
/// * records newly created query id internally and sets query state to awaiting data
/// * returns query configuration
///
Expand Down

0 comments on commit 75f1650

Please sign in to comment.