Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(all): update toolchain #1932

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 6 additions & 11 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,21 @@ members = [
"backends/tfhe-cuda-backend",
"utils/tfhe-versionable",
"utils/tfhe-versionable-derive",
"tests"
"tests",
]

exclude = [
"tests/backward_compatibility_tests",
"utils/tfhe-lints",
]
exclude = ["tests/backward_compatibility_tests", "utils/tfhe-lints"]
[workspace.dependencies]
aligned-vec = { version = "0.6", default-features = false }
bytemuck = "1.14.3"
dyn-stack = { version = "0.11", default-features = false }
itertools = "0.13"
itertools = "0.14"
num-complex = "0.4"
pulp = { version = "0.20.0", default-features = false }
pulp = { version = "0.21", default-features = false }
rand = "0.8"
rayon = "1"
serde = { version = "1.0", default-features = false }
wasm-bindgen = ">=0.2.86,<0.2.94"
wasm-bindgen = "0.2.100"

[profile.bench]
lto = "fat"
Expand All @@ -48,6 +45,4 @@ lto = "off"
debug-assertions = false

[workspace.metadata.dylint]
libraries = [
{ path = "utils/tfhe-lints" }
]
libraries = [{ path = "utils/tfhe-lints" }]
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ install_wasm_bindgen_cli: install_rs_build_toolchain
.PHONY: install_wasm_pack # Install wasm-pack to build JS packages
install_wasm_pack: install_rs_build_toolchain
@wasm-pack --version | grep "$(WASM_PACK_VERSION)" > /dev/null 2>&1 || \
cargo $(CARGO_RS_BUILD_TOOLCHAIN) install --locked wasm-pack@0.13.1 || \
cargo $(CARGO_RS_BUILD_TOOLCHAIN) install --locked wasm-pack@$(WASM_PACK_VERSION) || \
( echo "Unable to install cargo wasm-pack, unknown error." && exit 1 )

.PHONY: install_node # Install last version of NodeJS via nvm
Expand Down Expand Up @@ -521,11 +521,11 @@ build_web_js_api: install_rs_build_toolchain install_wasm_pack
build_web_js_api_parallel: install_rs_check_toolchain install_wasm_pack
cd tfhe && \
rustup component add rust-src --toolchain $(RS_CHECK_TOOLCHAIN) && \
RUSTFLAGS="$(WASM_RUSTFLAGS) -C target-feature=+atomics,+bulk-memory,+mutable-globals" rustup run $(RS_CHECK_TOOLCHAIN) \
RUSTFLAGS="$(WASM_RUSTFLAGS) -C target-feature=+atomics,+bulk-memory" rustup run $(RS_CHECK_TOOLCHAIN) \
wasm-pack build --release --target=web \
-- --features=boolean-client-js-wasm-api,shortint-client-js-wasm-api,integer-client-js-wasm-api,parallel-wasm-api,zk-pok \
-Z build-std=panic_abort,std && \
find pkg/snippets -type f -iname workerHelpers.worker.js -exec sed -i "s|from '..\/..\/..\/';|from '..\/..\/..\/tfhe.js';|" {} \;
find pkg/snippets -type f -iname workerHelpers.js -exec sed -i "s|const pkg = await import('..\/..\/..');|const pkg = await import('..\/..\/..\/tfhe.js');|" {} \;
jq '.files += ["snippets"]' tfhe/pkg/package.json > tmp_pkg.json && mv -f tmp_pkg.json tfhe/pkg/package.json

.PHONY: build_node_js_api # Build the js API targeting nodejs
Expand Down
2 changes: 1 addition & 1 deletion backends/tfhe-cuda-backend/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ keywords = ["fully", "homomorphic", "encryption", "fhe", "cryptography"]
[build-dependencies]
cmake = { version = "0.1" }
pkg-config = { version = "0.3" }
bindgen = "0.70.1"
bindgen = "0.71"
2 changes: 1 addition & 1 deletion tfhe-fft/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ getrandom = { version = "0.2", features = ["js"] }
rug = "1.19.1"

[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies]
criterion = "0.4"
criterion = "0.5"
fftw-sys = { version = "0.6", default-features = false, features = ["system"] }

[[bench]]
Expand Down
2 changes: 1 addition & 1 deletion tfhe-ntt/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ std = ["pulp/std", "aligned-vec/std"]
nightly = ["pulp/nightly"]

[dev-dependencies]
criterion = "0.4"
criterion = "0.5"
rand = { workspace = true }
serde = "1.0.163"
serde_json = "1.0.96"
Expand Down
18 changes: 13 additions & 5 deletions tfhe/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,20 @@ serde_json = "1.0.94"
clap = { version = "=4.4.4", features = ["derive"] }
# Used in user documentation
fs2 = { version = "0.4.3" }
statrs = "0.16"
statrs = "0.18"
# For erf and normality test
libm = "0.2.6"
# Begin regex-engine deps
test-case = "3.1.0"
combine = "4.6.6"
env_logger = "0.10.0"
env_logger = "0.11"
log = "0.4.19"
hex = "0.4.3"
# End regex-engine deps
strum = { version = "0.26", features = ["derive"] }

[build-dependencies]
cbindgen = { version = "0.26.0", optional = true }
cbindgen = { version = "0.28", optional = true }

[dependencies]
tfhe-csprng = { version = "0.5.0", path = "../tfhe-csprng", features = [
Expand Down Expand Up @@ -76,7 +76,7 @@ tfhe-versionable = { version = "0.4.0", path = "../utils/tfhe-versionable" }
wasm-bindgen = { workspace = true, features = [
"serde-serialize",
], optional = true }
wasm-bindgen-rayon = { version = "=1.2.2", optional = true }
wasm-bindgen-rayon = { version = "1.3.0", optional = true }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mayeul-zama could you rm -rf tfhe/pkg and check the content of the generated pkg for the parallel API ? to know what the packaging will look like

js-sys = { version = "0.3", optional = true }
console_error_panic_hook = { version = "0.1.7", optional = true }
serde-wasm-bindgen = { version = "0.6.0", optional = true }
Expand Down Expand Up @@ -130,7 +130,15 @@ software-prng = ["tfhe-csprng/software-prng"]

[package.metadata.docs.rs]
# TODO: manage builds for docs.rs based on their documentation https://docs.rs/about
features = ["boolean", "shortint", "integer", "gpu", "zk-pok", "software-prng", "strings"]
features = [
"boolean",
"shortint",
"integer",
"gpu",
"zk-pok",
"software-prng",
"strings",
]
rustdoc-args = ["--html-in-header", "katex-header.html"]

###########
Expand Down
2 changes: 1 addition & 1 deletion toolchain.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
nightly-2024-11-29
nightly-2025-01-17
Loading