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

Parallelize test_only segment simulation #498

Merged
merged 2 commits into from
Aug 15, 2024

Conversation

hratoanina
Copy link
Contributor

Closes #390.

@github-actions github-actions bot added the crate: zero_bin Anything related to the zero-bin subcrates. label Aug 14, 2024
Comment on lines 41 to 43
let _ = SegmentDataIterator::<Field>::new(&inputs.0, Some(inputs.1)).collect::<Vec<_>>();

Ok(())
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
let _ = SegmentDataIterator::<Field>::new(&inputs.0, Some(inputs.1)).collect::<Vec<_>>();
Ok(())
simulate_execution_all_segments::<Field>(&inputs.0, inputs.1)

@@ -25,6 +28,22 @@ use zero_bin_common::{debug_utils::save_inputs_to_disk, prover_state::p_state};

registry!();

#[cfg(feature = "test_only")]
#[derive(Deserialize, Serialize, RemoteExecute)]
pub struct BatchTestOnly {}
Copy link
Collaborator

Choose a reason for hiding this comment

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

is there any reason why you're not using save_inputs_on_error field in this? Even though we technically can't log yet the inputs upon error because the iterator is panicking, we are aiming at changing this logic before the release, which would allow to save inputs even in testing mode.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, I assumed we would add it when logging is available but we can have it there already. I also mimicked the error handling of the other operations for the future.

Copy link
Collaborator

@Nashtare Nashtare left a comment

Choose a reason for hiding this comment

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

Thanks! LGTM!

@Nashtare Nashtare merged commit 9923297 into feat/continuations Aug 15, 2024
14 checks passed
@Nashtare Nashtare deleted the test_only_stream branch August 15, 2024 17:14
Nashtare pushed a commit that referenced this pull request Aug 15, 2024
* Parallelize test_only segment simulation

* Address comments
@Nashtare Nashtare added this to the Performance Tuning milestone Sep 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
crate: zero_bin Anything related to the zero-bin subcrates.
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants