@@ -34,18 +34,6 @@ pub struct ProcessorTableRow {
34
34
mvi : BaseField ,
35
35
}
36
36
37
- impl ProcessorTableRow {
38
- /// Creates a row for the [`ProcessorTable`] which is considered 'dummy'.
39
- ///
40
- /// A 'dummy' row, is a row that is not part of the execution trace from the Brainfuck program
41
- /// execution.
42
- /// They are used for padding and filling the gaps after sorting by `clk`, to enforce the
43
- /// correct sorting.
44
- pub fn new_dummy ( clk : BaseField , ip : BaseField ) -> Self {
45
- Self { clk, ip, ..Default :: default ( ) }
46
- }
47
- }
48
-
49
37
impl From < & Registers > for ProcessorTableRow {
50
38
fn from ( registers : & Registers ) -> Self {
51
39
Self {
@@ -111,10 +99,11 @@ impl ProcessorTable {
111
99
let trace_len = self . table . len ( ) ;
112
100
let padding_offset = ( trace_len. next_power_of_two ( ) - trace_len) as u32 ;
113
101
for i in 1 ..=padding_offset {
114
- self . add_row ( ProcessorTableRow :: new_dummy (
115
- last_row. clk + BaseField :: from ( i) ,
116
- last_row. ip ,
117
- ) ) ;
102
+ self . add_row ( ProcessorTableRow {
103
+ clk : last_row. clk + BaseField :: from ( i) ,
104
+ ip : last_row. ip ,
105
+ ..Default :: default ( )
106
+ } ) ;
118
107
}
119
108
}
120
109
}
@@ -124,7 +113,7 @@ impl From<Vec<Registers>> for ProcessorTable {
124
113
fn from ( registers : Vec < Registers > ) -> Self {
125
114
let mut processor_table = Self :: new ( ) ;
126
115
127
- let rows = registers. iter ( ) . map ( |x| x . into ( ) ) . collect ( ) ;
116
+ let rows = registers. iter ( ) . map ( Into :: into) . collect ( ) ;
128
117
processor_table. add_rows ( rows) ;
129
118
processor_table. pad ( ) ;
130
119
0 commit comments