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

Integrate LogUp-GKR into the VM #1493

Merged
merged 23 commits into from
Sep 19, 2024
Merged

Integrate LogUp-GKR into the VM #1493

merged 23 commits into from
Sep 19, 2024

Conversation

Al-Kindi-0
Copy link
Collaborator

Describe your changes

Once this is merged, the PR will be ready for review.

Checklist before requesting a review

  • Repo forked and branch created from next according to naming convention.
  • Commit messages and codestyle follow conventions.
  • Relevant issues are linked in the PR description.
  • Tests added for new functionality.
  • Documentation/comments updated according to changes.

@Al-Kindi-0
Copy link
Collaborator Author

Al-Kindi-0 commented Sep 12, 2024

Here are the numbers on my machine using MIDEN_LOG=info RAYON_NUM_THREADS=8 ./target/release/miden example blake3 -n 50:

Next branch (serial)

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
2024-09-12T11:08:48.245269Z prove_program:execute_program: close time.busy=163ms time.idle=748ns
2024-09-12T11:08:48.245294Z prove_program: Generated execution trace of 70 columns and 262144 steps (8% padded) in 162 ms
2024-09-12T11:08:48.259371Z prove_program:build_domain: close time.busy=14.0ms time.idle=1.17µs trace_length=262144 lde_domain_size=2097152
2024-09-12T11:09:04.299009Z prove_program:commit_to_main_trace_segment:extend_execution_trace: close time.busy=16.0s time.idle=667ns num_cols=70 blowup=8
2024-09-12T11:09:05.942912Z prove_program:commit_to_main_trace_segment:compute_execution_trace_commitment: close time.busy=1.64s time.idle=19.2µs tree_depth=21
2024-09-12T11:09:05.942954Z prove_program:commit_to_main_trace_segment: close time.busy=17.7s time.idle=957ns
2024-09-12T11:09:09.269289Z prove_program:commit_to_aux_trace_segment:extend_execution_trace: close time.busy=3.20s time.idle=643ns num_cols=7 blowup=8
2024-09-12T11:09:09.882913Z prove_program:commit_to_aux_trace_segment:compute_execution_trace_commitment: close time.busy=614ms time.idle=1.22µs tree_depth=21
2024-09-12T11:09:09.882954Z prove_program:commit_to_aux_trace_segment: close time.busy=3.81s time.idle=1.17µs
2024-09-12T11:09:18.276091Z prove_program:evaluate_constraints: close time.busy=8.39s time.idle=1.49µs ce_domain_size=2097152
2024-09-12T11:09:18.796494Z prove_program:commit_to_constraint_evaluations:build_composition_poly_columns: close time.busy=520ms time.idle=26.3µs num_columns=8
2024-09-12T11:09:22.005166Z prove_program:commit_to_constraint_evaluations:evaluate_composition_poly_columns: close time.busy=3.21s time.idle=1.02µs
2024-09-12T11:09:22.516752Z prove_program:commit_to_constraint_evaluations:compute_constraint_evaluation_commitment: close time.busy=512ms time.idle=1.19µs tree_depth=21
2024-09-12T11:09:22.516794Z prove_program:commit_to_constraint_evaluations: close time.busy=4.24s time.idle=1.05µs
2024-09-12T11:09:23.519249Z prove_program:build_deep_composition_poly: close time.busy=1.00s time.idle=19.3µs
2024-09-12T11:09:23.969089Z prove_program:evaluate_deep_composition_poly: close time.busy=450ms time.idle=1.28µs
2024-09-12T11:09:24.156218Z prove_program:compute_fri_layers: close time.busy=187ms time.idle=1.30µs num_layers=4
2024-09-12T11:09:24.175272Z prove_program:determine_query_positions: close time.busy=19.0ms time.idle=1.03µs grinding_factor=16 num_positions=27
2024-09-12T11:09:24.195195Z prove_program:build_proof_object: close time.busy=19.9ms time.idle=1.01µs
2024-09-12T11:09:24.270684Z prove_program: close time.busy=36.2s time.idle=2.54µs
--------------------------------
Executed program in 36188 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 87 KB
Execution proof security: 96 bits
--------------------------------
2024-09-12T11:09:24.271951Z verify_program: close time.busy=1.09ms time.idle=1.08µs

Next branch (concurrent 8 threads)

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
2024-09-12T11:14:48.259930Z prove_program:execute_program: close time.busy=155ms time.idle=740ns
2024-09-12T11:14:48.259977Z prove_program: Generated execution trace of 70 columns and 262144 steps (8% padded) in 155 ms
2024-09-12T11:14:48.263393Z prove_program:build_domain: close time.busy=3.35ms time.idle=1.11µs trace_length=262144 lde_domain_size=2097152
2024-09-12T11:14:51.707196Z prove_program:commit_to_main_trace_segment:extend_execution_trace: close time.busy=3.44s time.idle=951ns num_cols=70 blowup=8
2024-09-12T11:14:52.126032Z prove_program:commit_to_main_trace_segment:compute_execution_trace_commitment: close time.busy=419ms time.idle=1.48µs tree_depth=21
2024-09-12T11:14:52.126069Z prove_program:commit_to_main_trace_segment: close time.busy=3.86s time.idle=1.57µs
2024-09-12T11:14:53.020482Z prove_program:commit_to_aux_trace_segment:extend_execution_trace: close time.busy=762ms time.idle=714ns num_cols=7 blowup=8
2024-09-12T11:14:53.190654Z prove_program:commit_to_aux_trace_segment:compute_execution_trace_commitment: close time.busy=170ms time.idle=1.67µs tree_depth=21
2024-09-12T11:14:53.190703Z prove_program:commit_to_aux_trace_segment: close time.busy=932ms time.idle=1.43µs
2024-09-12T11:14:55.516256Z prove_program:evaluate_constraints: close time.busy=2.31s time.idle=1.49µs ce_domain_size=2097152
2024-09-12T11:14:55.649070Z prove_program:commit_to_constraint_evaluations:build_composition_poly_columns: close time.busy=133ms time.idle=991ns num_columns=8
2024-09-12T11:14:56.395821Z prove_program:commit_to_constraint_evaluations:evaluate_composition_poly_columns: close time.busy=747ms time.idle=1.55µs
2024-09-12T11:14:56.557601Z prove_program:commit_to_constraint_evaluations:compute_constraint_evaluation_commitment: close time.busy=161ms time.idle=2.43µs tree_depth=21
2024-09-12T11:14:56.557639Z prove_program:commit_to_constraint_evaluations: close time.busy=1.04s time.idle=1.07µs
2024-09-12T11:14:56.773301Z prove_program:build_deep_composition_poly: close time.busy=216ms time.idle=1.76µs
2024-09-12T11:14:56.871423Z prove_program:evaluate_deep_composition_poly: close time.busy=98.1ms time.idle=1.26µs
2024-09-12T11:14:56.935988Z prove_program:compute_fri_layers: close time.busy=64.5ms time.idle=1.78µs num_layers=4
2024-09-12T11:14:56.939452Z prove_program:determine_query_positions: close time.busy=3.43ms time.idle=1.35µs grinding_factor=16 num_positions=27
2024-09-12T11:14:56.959647Z prove_program:build_proof_object: close time.busy=20.2ms time.idle=1.07µs
2024-09-12T11:14:57.035787Z prove_program: close time.busy=8.93s time.idle=2.27µs
--------------------------------
Executed program in 8931 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 86 KB
Execution proof security: 96 bits
--------------------------------
2024-09-12T11:14:57.037141Z verify_program: close time.busy=1.20ms time.idle=13.6µs
Execution verified in 1 ms

This branch (serial)

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
2024-09-12T12:48:29.031962Z prove_program:execute_program: close time.busy=163ms time.idle=601ns
2024-09-12T12:48:29.032007Z prove_program: Generated execution trace of 70 columns and 262144 steps (8% padded) in 162 ms
2024-09-12T12:48:29.047618Z prove_program:build_domain: close time.busy=15.6ms time.idle=1.53µs trace_length=262144 lde_domain_size=2097152
2024-09-12T12:48:44.488778Z prove_program:commit_to_main_trace_segment:extend_execution_trace: close time.busy=15.4s time.idle=747ns num_cols=70 blowup=8
2024-09-12T12:48:46.298053Z prove_program:commit_to_main_trace_segment:compute_execution_trace_commitment: close time.busy=1.81s time.idle=1.17µs commitment_domain_size=2097152
2024-09-12T12:48:46.298093Z prove_program:commit_to_main_trace_segment: close time.busy=17.3s time.idle=1.60µs
2024-09-12T12:48:51.934784Z prove_program:commit_to_aux_trace_segment:extend_execution_trace: close time.busy=3.52s time.idle=599ns num_cols=8 blowup=8
2024-09-12T12:48:52.479505Z prove_program:commit_to_aux_trace_segment:compute_execution_trace_commitment: close time.busy=545ms time.idle=1.29µs commitment_domain_size=2097152
2024-09-12T12:48:52.479547Z prove_program:commit_to_aux_trace_segment: close time.busy=4.07s time.idle=1.15µs
2024-09-12T12:49:04.158982Z prove_program:evaluate_constraints: close time.busy=11.7s time.idle=1.46µs ce_domain_size=2097152
2024-09-12T12:49:04.696805Z prove_program:commit_to_constraint_evaluations:build_composition_poly_columns: close time.busy=538ms time.idle=1.01µs num_columns=8
2024-09-12T12:49:08.009521Z prove_program:commit_to_constraint_evaluations:evaluate_composition_poly_columns: close time.busy=3.31s time.idle=1.20µs
2024-09-12T12:49:08.527049Z prove_program:commit_to_constraint_evaluations:compute_constraint_evaluation_commitment: close time.busy=517ms time.idle=2.22µs log_domain_size=21
2024-09-12T12:49:08.527072Z prove_program:commit_to_constraint_evaluations: close time.busy=4.37s time.idle=789ns
2024-09-12T12:49:09.607570Z prove_program:build_deep_composition_poly: close time.busy=1.08s time.idle=1.06µs
2024-09-12T12:49:10.070383Z prove_program:evaluate_deep_composition_poly: close time.busy=463ms time.idle=1.24µs
2024-09-12T12:49:10.264993Z prove_program:compute_fri_layers: close time.busy=195ms time.idle=1.57µs num_layers=4
2024-09-12T12:49:10.265693Z prove_program:determine_query_positions: close time.busy=656µs time.idle=985ns grinding_factor=16 num_positions=27
2024-09-12T12:49:10.287648Z prove_program:build_proof_object: close time.busy=21.9ms time.idle=952ns
2024-09-12T12:49:10.363808Z prove_program: close time.busy=41.5s time.idle=2.19µs
--------------------------------
Executed program in 41494 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 104 KB
Execution proof security: 96 bits
--------------------------------
2024-09-12T12:49:10.365724Z verify_program: close time.busy=1.57ms time.idle=1.09µs
Execution verified in 1 ms

This branch (concurrent 8 threads)

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
2024-09-12T12:42:05.983555Z prove_program:execute_program: close time.busy=162ms time.idle=825ns
2024-09-12T12:42:05.983609Z prove_program: Generated execution trace of 70 columns and 262144 steps (8% padded) in 162 ms
2024-09-12T12:42:05.988278Z prove_program:build_domain: close time.busy=4.60ms time.idle=1.47µs trace_length=262144 lde_domain_size=2097152
2024-09-12T12:42:09.310476Z prove_program:commit_to_main_trace_segment:extend_execution_trace: close time.busy=3.32s time.idle=1.01µs num_cols=70 blowup=8
2024-09-12T12:42:09.742137Z prove_program:commit_to_main_trace_segment:compute_execution_trace_commitment: close time.busy=432ms time.idle=1.30µs commitment_domain_size=2097152
2024-09-12T12:42:09.742172Z prove_program:commit_to_main_trace_segment: close time.busy=3.75s time.idle=2.12µs
2024-09-12T12:42:12.517252Z prove_program:commit_to_aux_trace_segment:extend_execution_trace: close time.busy=747ms time.idle=819ns num_cols=8 blowup=8
2024-09-12T12:42:12.654288Z prove_program:commit_to_aux_trace_segment:compute_execution_trace_commitment: close time.busy=137ms time.idle=1.63µs commitment_domain_size=2097152
2024-09-12T12:42:12.654325Z prove_program:commit_to_aux_trace_segment: close time.busy=884ms time.idle=1.23µs
2024-09-12T12:42:17.975884Z prove_program:evaluate_constraints: close time.busy=5.31s time.idle=1.44µs ce_domain_size=2097152
2024-09-12T12:42:18.109640Z prove_program:commit_to_constraint_evaluations:build_composition_poly_columns: close time.busy=134ms time.idle=852ns num_columns=8
2024-09-12T12:42:18.791498Z prove_program:commit_to_constraint_evaluations:evaluate_composition_poly_columns: close time.busy=682ms time.idle=1.09µs
2024-09-12T12:42:18.925580Z prove_program:commit_to_constraint_evaluations:compute_constraint_evaluation_commitment: close time.busy=134ms time.idle=1.17µs log_domain_size=21
2024-09-12T12:42:18.925607Z prove_program:commit_to_constraint_evaluations: close time.busy=950ms time.idle=870ns
2024-09-12T12:42:19.230222Z prove_program:build_deep_composition_poly: close time.busy=305ms time.idle=1.69µs
2024-09-12T12:42:19.335899Z prove_program:evaluate_deep_composition_poly: close time.busy=106ms time.idle=1.47µs
2024-09-12T12:42:19.402499Z prove_program:compute_fri_layers: close time.busy=66.6ms time.idle=1.67µs num_layers=4
2024-09-12T12:42:19.404957Z prove_program:determine_query_positions: close time.busy=2.43ms time.idle=1.56µs grinding_factor=16 num_positions=27
2024-09-12T12:42:19.426505Z prove_program:build_proof_object: close time.busy=21.5ms time.idle=1.41µs
2024-09-12T12:42:19.504803Z prove_program: close time.busy=13.7s time.idle=2.26µs
--------------------------------
Executed program in 13683 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 104 KB
Execution proof security: 96 bits
--------------------------------
2024-09-12T12:42:19.506585Z verify_program: close time.busy=1.34ms time.idle=904ns
Execution verified in 1 ms

@Al-Kindi-0
Copy link
Collaborator Author

As one can see, constraint evaluation for the Lagrange kernel and s-columns incurs an addition 3s in the multi-threaded benchmarks. This is more than 60% of the overhead of LogUp-GKR. This should go down once we parallelize constraint evaluation for the LogUp-GKR columns.
The remaining 40% should be attributed to GKR, including circuit evaluation (serial), input layer computation (serial) and the sum-checks (parallel).

@Al-Kindi-0 Al-Kindi-0 marked this pull request as ready for review September 13, 2024 08:27
@Al-Kindi-0
Copy link
Collaborator Author

Set up
cargo build --profile release --features concurrent,executable,tracing-forest
MIDEN_LOG=info RAYON_NUM_THREADS=8 ./target/release/miden example blake3 -n 50

Next

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
INFO     prove_program [ 8.32s | 2.25% / 100.00% ]
INFO     ┝━ execute_program [ 155ms | 1.87% ]
INFO     ┝━ i [info]: Generated execution trace of 70 columns and 262144 steps (8% padded) in 155 ms
INFO     ┝━ build_domain [ 2.86ms | 0.03% ] trace_length: 262144 | lde_domain_size: 2097152
INFO     ┝━ commit_to_main_trace_segment [ 3.72s | 0.00% / 44.72% ]
INFO     │  ┝━ extend_execution_trace [ 3.35s | 40.29% ] num_cols: 70 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 369ms | 4.44% ] tree_depth: 21
INFO     ┝━ commit_to_aux_trace_segment [ 883ms | 0.00% / 10.60% ]
INFO     │  ┝━ extend_execution_trace [ 740ms | 8.89% ] num_cols: 7 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 143ms | 1.71% ] tree_depth: 21
INFO     ┝━ evaluate_constraints [ 2.18s | 26.23% ] ce_domain_size: 2097152
INFO     ┝━ commit_to_constraint_evaluations [ 892ms | 0.00% / 10.72% ]
INFO     │  ┝━ build_composition_poly_columns [ 125ms | 1.51% ] num_columns: 8
INFO     │  ┝━ evaluate_composition_poly_columns [ 655ms | 7.86% ]
INFO     │  ┕━ compute_constraint_evaluation_commitment [ 112ms | 1.35% ] tree_depth: 21
INFO     ┝━ build_deep_composition_poly [ 136ms | 1.63% ]
INFO     ┝━ evaluate_deep_composition_poly [ 91.4ms | 1.10% ]
INFO     ┝━ compute_fri_layers [ 49.5ms | 0.59% ] num_layers: 4
INFO     ┝━ determine_query_positions [ 2.86ms | 0.03% ] grinding_factor: 16 | num_positions: 27
INFO     ┕━ build_proof_object [ 17.9ms | 0.22% ]
--------------------------------
Executed program in 8324 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 86 KB
Execution proof security: 96 bits
--------------------------------
INFO     verify_program [ 1.09ms | 100.00% ]
Execution verified in 1 ms

This

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
INFO     prove_program [ 10.4s | 19.21% / 100.00% ]
INFO     ┝━ execute_program [ 153ms | 1.47% ]
INFO     ┝━ i [info]: Generated execution trace of 70 columns and 262144 steps (8% padded) in 153 ms
INFO     ┝━ build_domain [ 4.10ms | 0.04% ] trace_length: 262144 | lde_domain_size: 2097152
INFO     ┝━ commit_to_main_trace_segment [ 3.53s | 0.00% / 34.03% ]
INFO     │  ┝━ extend_execution_trace [ 3.17s | 30.54% ] num_cols: 70 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 362ms | 3.49% ] commitment_domain_size: 2097152
INFO     ┝━ commit_to_aux_trace_segment [ 808ms | 0.00% / 7.78% ]
INFO     │  ┝━ extend_execution_trace [ 689ms | 6.63% ] num_cols: 8 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 119ms | 1.15% ] commitment_domain_size: 2097152
INFO     ┝━ evaluate_constraints [ 2.59s | 24.99% ] ce_domain_size: 2097152
INFO     ┝━ commit_to_constraint_evaluations [ 886ms | 0.00% / 8.53% ]
INFO     │  ┝━ build_composition_poly_columns [ 127ms | 1.22% ] num_columns: 8
INFO     │  ┝━ evaluate_composition_poly_columns [ 649ms | 6.25% ]
INFO     │  ┕━ compute_constraint_evaluation_commitment [ 110ms | 1.06% ] log_domain_size: 21
INFO     ┝━ build_deep_composition_poly [ 257ms | 2.47% ]
INFO     ┝━ evaluate_deep_composition_poly [ 87.6ms | 0.84% ]
INFO     ┝━ compute_fri_layers [ 42.7ms | 0.41% ] num_layers: 4
INFO     ┝━ determine_query_positions [ 2.68ms | 0.03% ] grinding_factor: 16 | num_positions: 27
INFO     ┕━ build_proof_object [ 19.9ms | 0.19% ]
--------------------------------
Executed program in 10383 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 105 KB
Execution proof security: 96 bits
--------------------------------
INFO     verify_program [ 1.35ms | 100.00% ]
Execution verified in 1 ms

The above numbers suggest that there is about half a second of overhead between constraint evaluation and building the DEEP poly. This means that GKR is taking about 1.5 seconds in the above.
Note that we still have to optimize building the DEEP poly associated with the Lagrange kernel.

Copy link
Contributor

@plafer plafer left a comment

Choose a reason for hiding this comment

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

LGTM! I love PRs that remove more code than they add :)

Should we merge this into some (new) logup-gkr branch so that we can start working on integrating more bus/tables into LogUp-GKR? Ideally we wouldn't cram all of those into this PR.

@Al-Kindi-0
Copy link
Collaborator Author

LGTM! I love PRs that remove more code than they add :)

😄

Should we merge this into some (new) logup-gkr branch so that we can start working on integrating more bus/tables into LogUp-GKR? Ideally we wouldn't cram all of those into this PR.

Agreed!

@Al-Kindi-0
Copy link
Collaborator Author

Al-Kindi-0 commented Sep 18, 2024

Next

BLAKE3 50 iterations

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
INFO     prove_program [ 8.41s | 2.36% / 100.00% ]
INFO     ┝━ execute_program [ 154ms | 1.83% ]
INFO     ┝━ i [info]: Generated execution trace of 70 columns and 262144 steps (8% padded) in 153 ms
INFO     ┝━ build_domain [ 2.88ms | 0.03% ] trace_length: 262144 | lde_domain_size: 2097152
INFO     ┝━ commit_to_main_trace_segment [ 3.76s | 0.00% / 44.67% ]
INFO     │  ┝━ extend_execution_trace [ 3.34s | 39.74% ] num_cols: 70 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 414ms | 4.93% ] tree_depth: 21
INFO     ┝━ commit_to_aux_trace_segment [ 878ms | 0.00% / 10.45% ]
INFO     │  ┝━ extend_execution_trace [ 730ms | 8.69% ] num_cols: 7 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 148ms | 1.76% ] tree_depth: 21
INFO     ┝━ evaluate_constraints [ 2.20s | 26.15% ] ce_domain_size: 2097152
INFO     ┝━ commit_to_constraint_evaluations [ 914ms | 0.00% / 10.88% ]
INFO     │  ┝━ build_composition_poly_columns [ 127ms | 1.51% ] num_columns: 8
INFO     │  ┝━ evaluate_composition_poly_columns [ 651ms | 7.74% ]
INFO     │  ┕━ compute_constraint_evaluation_commitment [ 137ms | 1.62% ] tree_depth: 21
INFO     ┝━ build_deep_composition_poly [ 148ms | 1.76% ]
INFO     ┝━ evaluate_deep_composition_poly [ 90.1ms | 1.07% ]
INFO     ┝━ compute_fri_layers [ 46.5ms | 0.55% ] num_layers: 4
INFO     ┝━ determine_query_positions [ 2.93ms | 0.03% ] grinding_factor: 16 | num_positions: 27
INFO     ┕━ build_proof_object [ 18.2ms | 0.22% ]
--------------------------------
Executed program in 8407 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 86 KB
Execution proof security: 96 bits
--------------------------------
INFO     verify_program [ 1.11ms | 100.00% ]
Execution verified in 1 ms

BLAKE3 100 iterations

============================================================
Generated a program to compute 100-th iteration of BLAKE3 1-to-1 hash; expected result: [4210649924, 4239425932, 2583891669, 2278324621, 1697424527, 1323302812, 3062448259, 2695025053]
--------------------------------
INFO     prove_program [ 17.9s | 2.19% / 100.00% ]
INFO     ┝━ execute_program [ 328ms | 1.83% ]
INFO     ┝━ i [info]: Generated execution trace of 70 columns and 524288 steps (8% padded) in 328 ms
INFO     ┝━ build_domain [ 5.28ms | 0.03% ] trace_length: 524288 | lde_domain_size: 4194304
INFO     ┝━ commit_to_main_trace_segment [ 8.07s | 0.00% / 45.11% ]
INFO     │  ┝━ extend_execution_trace [ 7.27s | 40.65% ] num_cols: 70 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 798ms | 4.46% ] tree_depth: 22
INFO     ┝━ commit_to_aux_trace_segment [ 1.88s | 0.00% / 10.50% ]
INFO     │  ┝━ extend_execution_trace [ 1.56s | 8.73% ] num_cols: 7 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 317ms | 1.77% ] tree_depth: 22
INFO     ┝━ evaluate_constraints [ 4.63s | 25.89% ] ce_domain_size: 4194304
INFO     ┝━ commit_to_constraint_evaluations [ 1.96s | 0.00% / 10.93% ]
INFO     │  ┝━ build_composition_poly_columns [ 264ms | 1.48% ] num_columns: 8
INFO     │  ┝━ evaluate_composition_poly_columns [ 1.44s | 8.04% ]
INFO     │  ┕━ compute_constraint_evaluation_commitment [ 252ms | 1.41% ] tree_depth: 22
INFO     ┝━ build_deep_composition_poly [ 288ms | 1.61% ]
INFO     ┝━ evaluate_deep_composition_poly [ 198ms | 1.11% ]
INFO     ┝━ compute_fri_layers [ 101ms | 0.57% ] num_layers: 4
INFO     ┝━ determine_query_positions [ 4.09ms | 0.02% ] grinding_factor: 16 | num_positions: 27
INFO     ┕━ build_proof_object [ 36.4ms | 0.20% ]
--------------------------------
Executed program in 17887 ms
Stack outputs: [4210649924, 4239425932, 2583891669, 2278324621, 1697424527, 1323302812, 3062448259, 2695025053]
Execution proof size: 93 KB
Execution proof security: 96 bits
--------------------------------
INFO     verify_program [ 1.13ms | 100.00% ]

Current

BLAKE3 50 iterations

============================================================
Generated a program to compute 50-th iteration of BLAKE3 1-to-1 hash; expected result: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
--------------------------------
INFO     prove_program [ 10.6s | 0.74% / 100.00% ]
INFO     ┝━ execute_program [ 154ms | 1.45% ]
INFO     ┝━ i [info]: Generated execution trace of 70 columns and 262144 steps (8% padded) in 154 ms
INFO     ┝━ build_domain [ 3.85ms | 0.04% ] trace_length: 262144 | lde_domain_size: 2097152
INFO     ┝━ commit_to_main_trace_segment [ 3.58s | 0.00% / 33.66% ]
INFO     │  ┝━ extend_execution_trace [ 3.19s | 29.94% ] num_cols: 70 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 396ms | 3.72% ] commitment_domain_size: 2097152
INFO     ┝━ build_aux_trace [ 101ms | 0.95% ]
INFO     ┝━ prove_gkr [ 1.74s | 0.00% / 16.39% ]
INFO     │  ┝━ evaluate_logup_gkr_circuit [ 236ms | 2.21% ]
INFO     │  ┝━ prove_intermediate_layers [ 580ms | 5.45% ]
INFO     │  ┝━ build_mls_from_main_trace_segment [ 112ms | 1.05% ]
INFO     │  ┕━ prove_input_layer [ 816ms | 7.67% ]
INFO     ┝━ build_logup_gkr_columns [ 130ms | 1.22% ]
INFO     ┝━ commit_to_aux_trace_segment [ 835ms | 0.00% / 7.85% ]
INFO     │  ┝━ extend_execution_trace [ 716ms | 6.73% ] num_cols: 8 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 119ms | 1.12% ] commitment_domain_size: 2097152
INFO     ┝━ evaluate_constraints [ 2.71s | 25.52% ] ce_domain_size: 2097152
INFO     ┝━ commit_to_constraint_evaluations [ 886ms | 0.00% / 8.33% ]
INFO     │  ┝━ build_composition_poly_columns [ 123ms | 1.16% ] num_columns: 8
INFO     │  ┝━ evaluate_composition_poly_columns [ 649ms | 6.10% ]
INFO     │  ┕━ compute_constraint_evaluation_commitment [ 114ms | 1.07% ] log_domain_size: 21
INFO     ┝━ build_deep_composition_poly [ 257ms | 2.42% ]
INFO     ┝━ evaluate_deep_composition_poly [ 88.3ms | 0.83% ]
INFO     ┝━ compute_fri_layers [ 45.9ms | 0.43% ] num_layers: 4
INFO     ┝━ determine_query_positions [ 328µs | 0.00% ] grinding_factor: 16 | num_positions: 27
INFO     ┕━ build_proof_object [ 19.9ms | 0.19% ]
--------------------------------
Executed program in 10639 ms
Stack outputs: [664088198, 4259451035, 218783966, 2579530912, 3535070201, 4210849069, 2460906358, 3194996903]
Execution proof size: 104 KB
Execution proof security: 96 bits
--------------------------------
INFO     verify_program [ 1.38ms | 100.00% ]
Execution verified in 1 ms

BLAKE3 100 iterations

============================================================
Generated a program to compute 100-th iteration of BLAKE3 1-to-1 hash; expected result: [4210649924, 4239425932, 2583891669, 2278324621, 1697424527, 1323302812, 3062448259, 2695025053]
--------------------------------
INFO     prove_program [ 21.8s | 0.65% / 100.00% ]
INFO     ┝━ execute_program [ 328ms | 1.50% ]
INFO     ┝━ i [info]: Generated execution trace of 70 columns and 524288 steps (8% padded) in 327 ms
INFO     ┝━ build_domain [ 5.14ms | 0.02% ] trace_length: 524288 | lde_domain_size: 4194304
INFO     ┝━ commit_to_main_trace_segment [ 7.48s | 0.00% / 34.26% ]
INFO     │  ┝━ extend_execution_trace [ 6.67s | 30.56% ] num_cols: 70 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 808ms | 3.70% ] commitment_domain_size: 4194304
INFO     ┝━ build_aux_trace [ 210ms | 0.96% ]
INFO     ┝━ prove_gkr [ 3.42s | 0.00% / 15.67% ]
INFO     │  ┝━ evaluate_logup_gkr_circuit [ 481ms | 2.21% ]
INFO     │  ┝━ prove_intermediate_layers [ 1.13s | 5.18% ]
INFO     │  ┝━ build_mls_from_main_trace_segment [ 230ms | 1.05% ]
INFO     │  ┕━ prove_input_layer [ 1.58s | 7.23% ]
INFO     ┝━ build_logup_gkr_columns [ 269ms | 1.23% ]
INFO     ┝━ commit_to_aux_trace_segment [ 1.66s | 0.00% / 7.63% ]
INFO     │  ┝━ extend_execution_trace [ 1.44s | 6.58% ] num_cols: 8 | blowup: 8
INFO     │  ┕━ compute_execution_trace_commitment [ 229ms | 1.05% ] commitment_domain_size: 4194304
INFO     ┝━ evaluate_constraints [ 5.60s | 25.66% ] ce_domain_size: 4194304
INFO     ┝━ commit_to_constraint_evaluations [ 1.86s | 0.00% / 8.51% ]
INFO     │  ┝━ build_composition_poly_columns [ 275ms | 1.26% ] num_columns: 8
INFO     │  ┝━ evaluate_composition_poly_columns [ 1.35s | 6.18% ]
INFO     │  ┕━ compute_constraint_evaluation_commitment [ 234ms | 1.07% ] log_domain_size: 22
INFO     ┝━ build_deep_composition_poly [ 532ms | 2.44% ]
INFO     ┝━ evaluate_deep_composition_poly [ 187ms | 0.86% ]
INFO     ┝━ compute_fri_layers [ 90.3ms | 0.41% ] num_layers: 4
INFO     ┝━ determine_query_positions [ 1.97ms | 0.01% ] grinding_factor: 16 | num_positions: 27
INFO     ┕━ build_proof_object [ 37.3ms | 0.17% ]
--------------------------------
Executed program in 21819 ms
Stack outputs: [4210649924, 4239425932, 2583891669, 2278324621, 1697424527, 1323302812, 3062448259, 2695025053]
Execution proof size: 112 KB
Execution proof security: 96 bits
--------------------------------
INFO     verify_program [ 1.41ms | 100.00% ]
Execution verified in 1 ms

@plafer plafer changed the base branch from next to logup-gkr September 19, 2024 17:21
@plafer plafer merged commit 3d2294e into logup-gkr Sep 19, 2024
9 checks passed
@plafer plafer deleted the al-logup-gkr-integration branch September 19, 2024 17:22
plafer added a commit that referenced this pull request Sep 23, 2024
* chore: fix no-std errors

* wip

* wip: migrate to new winterfell

* wip: migrate to logup-gkr branch of winterfell

* chore: fix issues after next rebase

* wip: migrate range checker to use logup-gkr

* wip: remove random row values

* wip: remove range checker b-column from aux segment

* chore: remove random trace rows at the end

* chore: remove random trace rows at the end (continue)

* chore: remove range checker from aux trace (continue)

* chore: adapt to  updated AirContext

* fix: clippy

* chore: update to changes in Winterfell

* fix: clippy

* changelog

---------

Co-authored-by: Philippe Laferriere <[email protected]>
plafer added a commit that referenced this pull request Sep 25, 2024
* chore: fix no-std errors

* wip

* wip: migrate to new winterfell

* wip: migrate to logup-gkr branch of winterfell

* chore: fix issues after next rebase

* wip: migrate range checker to use logup-gkr

* wip: remove random row values

* wip: remove range checker b-column from aux segment

* chore: remove random trace rows at the end

* chore: remove random trace rows at the end (continue)

* chore: remove range checker from aux trace (continue)

* chore: adapt to  updated AirContext

* fix: clippy

* chore: update to changes in Winterfell

* fix: clippy

* changelog

---------

Co-authored-by: Philippe Laferriere <[email protected]>
plafer added a commit that referenced this pull request Oct 4, 2024
* chore: fix no-std errors

* wip

* wip: migrate to new winterfell

* wip: migrate to logup-gkr branch of winterfell

* chore: fix issues after next rebase

* wip: migrate range checker to use logup-gkr

* wip: remove random row values

* wip: remove range checker b-column from aux segment

* chore: remove random trace rows at the end

* chore: remove random trace rows at the end (continue)

* chore: remove range checker from aux trace (continue)

* chore: adapt to  updated AirContext

* fix: clippy

* chore: update to changes in Winterfell

* fix: clippy

* changelog

---------

Co-authored-by: Philippe Laferriere <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants