-
Notifications
You must be signed in to change notification settings - Fork 574
Description
Which section of the Halo 2 book were you reading?
https://zcash.github.io/halo2/background/curves.html
fn create_proof() {
// ... lots of code ...
let commitment = params.commit_lagrange(poly); // ← MSM happens HERE
// ... more code ...
}
// params.commit_lagrange() internally calls:
fn commit_lagrange() {
best_multiexp(scalars, bases) // ← This is the MSM
}
What was unclear?
-
best_multiexp() is a synchronous function call buried deep in Halo2
-
Why cant I intercept it to send data to GPU
-
Why Rayon parallelizes within best_multiexp(), but on CPU only
-
Is there any hook to say "send this to WebGPU instead"
What would help to make it clearer to you?
My goal is to make Halo2 proof genrate totally on client side, currently I archived it trough WASM Single Thread but its slover for bigger constrains like k = 2^18, k = 2^20, Trying to use WebGPU and Rayon multi-thread WASM to make it faster.
Do you have any recommendations or insights on the best strategies to structure or batch these seemingly 'tiny' MSM operations effectively for WebGPU processing from WASM, specifically to minimize the communication overhead you warned about and avoid pipeline bubbles
Just need to know how to compute FFT and MSM using WebGPU for faster calculations, Cause Rayon multithread only spans with shared memory Halo2 internals cant do caluclations with those shared memory for my zero knowledge auth protocol I require WebGPU for fast calculations. (https://github.com/Deadends/legion)