Skip to content

Commit 24ab122

Browse files
committed
update comments
1 parent 32e4f98 commit 24ab122

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

prover/src/tables/cpu.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -485,10 +485,11 @@ impl CpuOperation {
485485
}
486486
}
487487

488-
/// Collects IS_BYTE lookups for CPU byte range checks.
488+
/// Collects CPU range-check lookups for register indices and byte pairs.
489489
///
490-
/// The CPU has 27 byte columns that must be range-checked: RS1, RS2, RD,
491-
/// ARG1[0..7], ARG2[0..7], RES[0..7]. Each generates one IS_BYTE lookup.
490+
/// The CPU sends:
491+
/// - 3 IS_BYTE lookups for RS1, RS2, RD
492+
/// - 12 IS_BYTE_PAIR lookups for adjacent bytes in ARG1, ARG2, and RES
492493
pub fn collect_byte_check_ops(&self) -> Vec<super::bitwise::BitwiseOperation> {
493494
use super::bitwise::{BitwiseOperation, BitwiseOperationType};
494495

prover/src/tests/cpu_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ fn test_bus_interactions_count() {
330330
// - 1 BRANCH (branch/jump target calculation)
331331
// - 1 ECALL (single shared bus for HALT and COMMIT, mult = ECALL)
332332
// - 3 IS_BYTE (register indices: RS1, RS2, RD)
333-
// - 12 IS_HALF (ARG1/ARG2/RES byte pairs: 4 halfwords × 3 arrays)
333+
// - 12 IS_BYTE_PAIR (ARG1/ARG2/RES byte pairs: 4 pairs × 3 arrays)
334334
// Total: 8 + 8 + 8 + 2 + 1 + 1 + 1 + 1 + 5 + 1 + 1 + 1 + 1 + 1 + 1 + 3 + 12 = 56
335335
assert_eq!(interactions.len(), 56);
336336
}

0 commit comments

Comments
 (0)