Make reports serializable

This commit is contained in:
Kevaundray Wedderburn
2025-05-18 00:27:48 +01:00
parent 86d476b9dd
commit 9123ce193a
2 changed files with 4 additions and 3 deletions

View File

@@ -9,7 +9,7 @@ license.workspace = true
anyhow = "1.0"
serde = { version = "1.0", features = ["derive"] }
bincode = "1.3"
indexmap = "2.9.0"
indexmap = { version = "2.9.0", features = ["serde"] }
thiserror = "2"
[lints]

View File

@@ -1,4 +1,5 @@
use indexmap::IndexMap;
use serde::{Deserialize, Serialize};
use std::{path::Path, time::Duration};
mod input;
@@ -38,7 +39,7 @@ pub trait zkVM<C: Compiler> {
/// ProgramExecutionReport produces information about a particular program
/// execution.
#[derive(Debug, Clone, Default)]
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
pub struct ProgramExecutionReport {
/// Total number of cycles for the entire workload execution.
pub total_num_cycles: u64,
@@ -60,7 +61,7 @@ impl ProgramExecutionReport {
/// ProgramProvingReport produces information about proving a particular
/// program's instance.
#[derive(Debug, Clone, Default)]
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
pub struct ProgramProvingReport {
pub proving_time: Duration,
}