Skip to content

Commit

Permalink
fix(wasm): fix size used for serialization in benches
Browse files Browse the repository at this point in the history
  • Loading branch information
nsarlin-zama committed Oct 22, 2024
1 parent 3b4f0d2 commit 7c29594
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tfhe/web_wasm_parallel_tests/worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -603,13 +603,13 @@ async function compressedServerKeyBenchConfig(config) {
bench_results["compressed_server_key_gen_mean"] = timing_1;

let serverKey = TfheCompressedServerKey.new(clientKey);
let serialized_key = serverKey.safe_serialize(BigInt(10000000));
let serialized_key = serverKey.safe_serialize(BigInt(1000000000));
console.log("Serialized ServerKey size: ", serialized_key.length);

// Bench the serialization for bench_loops iterations
start = performance.now();
for (let i = 0; i < bench_loops; i++) {
let _ = serverKey.safe_serialize(BigInt(10000000));
let _ = serverKey.safe_serialize(BigInt(1000000000));
}
end = performance.now();
const timing_2 = (end - start) / bench_loops;
Expand Down

0 comments on commit 7c29594

Please sign in to comment.