Skip to content

Commit

Permalink
update cryptography_cuda version and fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
dloghin committed Aug 30, 2024
1 parent f757d1e commit b74c2ac
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 18 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ members = ["field", "maybe_rayon", "plonky2", "starky", "util", "gen", "u32", "e
resolver = "2"

[workspace.dependencies]
cryptography_cuda = { git = "ssh://[email protected]/okx/cryptography_cuda.git", rev = "173510160183f3299f4765b30bd4f2c1685353f9" }
cryptography_cuda = { git = "ssh://[email protected]/okx/cryptography_cuda.git", rev = "73261c1420670cb371b359929df578edbb3b6a62" }
ahash = { version = "0.8.7", default-features = false, features = [
"compile-time-rng",
] } # NOTE: Be sure to keep this version the same as the dependency in `hashbrown`.
Expand Down
2 changes: 1 addition & 1 deletion plonky2/src/hash/merkle_tree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use cryptography_cuda::device::memory::HostOrDeviceSlice;
#[cfg(feature = "cuda")]
use cryptography_cuda::device::stream::CudaStream;
#[cfg(feature = "cuda")]
use cryptography_cuda::merkle::bindings::{
use cryptography_cuda::{
fill_digests_buf_linear_gpu_with_gpu_ptr, fill_digests_buf_linear_multigpu_with_gpu_ptr,
};
use num::range;
Expand Down
15 changes: 0 additions & 15 deletions plonky2/src/hash/poseidon2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -389,9 +389,6 @@ where
}
}

#[derive(Debug, Clone, Default)]
struct DiffusionMatrixGoldilocks;

pub fn matmul_internal<F: RichField>(
state: &mut [F; SPONGE_WIDTH],
mat_internal_diag_m_1: [u64; SPONGE_WIDTH],
Expand All @@ -403,18 +400,6 @@ pub fn matmul_internal<F: RichField>(
}
}

impl<F: RichField> P2Permutation<[F; 12]> for DiffusionMatrixGoldilocks {
#[cfg(not(target_feature = "avx2"))]
fn permute_mut(&self, state: &mut [F; 12]) {
matmul_internal::<F>(state, MATRIX_DIAG_12_GOLDILOCKS);
}

#[cfg(target_feature = "avx2")]
fn permute_mut(&self, state: &mut [F; 12]) {
matmul_internal_avx::<F>(state, MATRIX_DIAG_12_GOLDILOCKS);
}
}

pub trait Poseidon2: RichField {
// const WIDTH: usize = 12;
// const D: u64 = 7;
Expand Down
1 change: 1 addition & 0 deletions plonky2/src/plonk/copy_constraint.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use crate::iop::target::Target;
#[derive(Debug, Clone)]
pub struct CopyConstraint {
pub pair: (Target, Target),
#[allow(dead_code)]
pub name: String,
}

Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[toolchain]
channel = "nightly-2024-01-16"
channel = "nightly"
components = []
targets = []
profile = "default"

0 comments on commit b74c2ac

Please sign in to comment.