From d7fd7546a045e547a12e7b9ff827f64479e50948 Mon Sep 17 00:00:00 2001 From: Vladislav Volosnikov Date: Tue, 13 Aug 2024 16:30:45 +0200 Subject: [PATCH] Move MemoryQueueStateWitnesses definition to circuit_encodings --- circuit_encodings/src/memory_query.rs | 4 ++++ src/witness/oracle.rs | 8 +++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/circuit_encodings/src/memory_query.rs b/circuit_encodings/src/memory_query.rs index d65d6b30..a9faef5e 100644 --- a/circuit_encodings/src/memory_query.rs +++ b/circuit_encodings/src/memory_query.rs @@ -157,3 +157,7 @@ impl CircuitEquivalentReflection for MemoryQuery { } } } + +use zkevm_circuits::base_structures::memory_query::MemoryQueryWitness; +pub type MemoryQueueStateWitnesses = + Vec<(MemoryQueryWitness, [F; FULL_SPONGE_QUEUE_STATE_WIDTH])>; \ No newline at end of file diff --git a/src/witness/oracle.rs b/src/witness/oracle.rs index 914cdab8..3828f26b 100644 --- a/src/witness/oracle.rs +++ b/src/witness/oracle.rs @@ -824,7 +824,7 @@ use crate::witness::artifacts::DecommitmentArtifactsForMainVM; use crate::witness::artifacts::LogQueueStates; use crate::zkevm_circuits::demux_log_queue::NUM_DEMUX_OUTPUTS; -use circuit_definitions::encodings::memory_query::MemoryQueueState; +use circuit_definitions::encodings::memory_query::{MemoryQueueState, MemoryQueueStateWitnesses}; fn simulate_memory_queue( geometry: GeometryConfig, @@ -1389,8 +1389,6 @@ fn process_memory_related_circuits( ) } -pub type MemoryQueueWitness = - Vec<(MemoryQueryWitness, [F; FULL_SPONGE_QUEUE_STATE_WIDTH])>; pub enum WitnessGenerationArtifact { BaseLayerCircuit(ZkSyncBaseLayerCircuit), RecursionQueue( @@ -1400,8 +1398,8 @@ pub enum WitnessGenerationArtifact { Vec>, ), ), - SortedMemoryQueueWitness(MemoryQueueWitness), - UnsortedMemoryQueueWitness(MemoryQueueWitness), + SortedMemoryQueueWitness(MemoryQueueStateWitnesses), + UnsortedMemoryQueueWitness(MemoryQueueStateWitnesses), } /// Make basic circuits instances and witnesses,