Skip to content

Commit dc5a22a

Browse files
hero78119Wu Sung-Ming
andauthored
migrate shift opcode (#1025)
To close #1016 ### stats ```diff +---------------+---------------+---------+-------+-----------+--------+------------+---------------------+ | opcode_name | num_instances | lookups | reads | witnesses | writes | 0_expr_deg | 0_expr_sumcheck_deg | +---------------+---------------+---------+-------+-----------+--------+------------+---------------------+ -| SLL | 0 | 15 | 4 | 29 | 4 | [1: 5] | [2: 1] | +| SLL | 0 | 17 | 4 | 47 | 4 | [1: 6] | [3: 10,2: 27] | -| SLLI | 0 | 9 | 3 | 20 | 3 | [1: 3] | [2: 1] | +| SLLI | 0 | 15 | 3 | 40 | 3 | [1: 5] | [2: 27,3: 10] | -| SRA | 0 | 16 | 4 | 30 | 4 | [1: 5] | [2: 2] | +| SRA | 0 | 18 | 4 | 47 | 4 | [1: 5] | [3: 10,2: 27] | -| SRAI | 0 | 10 | 3 | 21 | 3 | [1: 3] | [2: 2] | +| SRAI | 0 | 16 | 3 | 40 | 3 | [1: 4] | [2: 27,3: 10] | -| SRL | 0 | 15 | 4 | 29 | 4 | [1: 5] | [2: 1] | +| SRL | 0 | 17 | 4 | 47 | 4 | [1: 6] | [2: 27,3: 10] | -| SRLI | 0 | 9 | 3 | 20 | 3 | [1: 3] | [2: 1] | +| SRLI | 0 | 15 | 3 | 40 | 3 | [1: 5] | [3: 10,2: 27] | +---------------+---------------+---------+-------+-----------+--------+------------+---------------------+ ``` --------- Co-authored-by: Wu Sung-Ming <[email protected]>
1 parent ad05ca5 commit dc5a22a

File tree

9 files changed

+1086
-479
lines changed

9 files changed

+1086
-479
lines changed

ceno_zkvm/src/instructions/riscv/insn_base.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -506,7 +506,6 @@ impl<E: ExtensionField> MemAddr<E> {
506506
// Range check the high limb.
507507
for i in 1..UINT_LIMBS {
508508
let high_u16 = (addr >> (i * 16)) & 0xffff;
509-
println!("assignment max bit {}", (self.max_bits - i * 16).min(16));
510509
lkm.assert_ux_v2(high_u16 as u64, (self.max_bits - i * 16).min(16));
511510
}
512511

ceno_zkvm/src/instructions/riscv/rv32im.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ use super::{
66
use crate::instructions::riscv::auipc::AuipcInstruction;
77
#[cfg(feature = "u16limb_circuit")]
88
use crate::instructions::riscv::lui::LuiInstruction;
9-
109
use crate::{
1110
error::ZKVMError,
1211
instructions::{

0 commit comments

Comments
 (0)