File tree 1 file changed +3
-2
lines changed
extensions/rv32im/circuit/src/auipc
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -129,8 +129,9 @@ where
129
129
need_range_check. push ( limb. into ( ) ) ;
130
130
}
131
131
132
+ assert_eq ! ( pc_limbs. len( ) , RV32_REGISTER_NUM_LIMBS ) ;
132
133
// pc_limbs[0] is already range checked through rd_data[0]
133
- for ( i, limb) in pc_limbs. iter ( ) . skip ( 1 ) . enumerate ( ) {
134
+ for ( i, limb) in pc_limbs. iter ( ) . enumerate ( ) . skip ( 1 ) {
134
135
if i == pc_limbs. len ( ) - 1 {
135
136
// Range check the most significant limb of pc to be in [0, 2^{PC_BITS-(RV32_REGISTER_NUM_LIMBS-1)*RV32_CELL_BITS})
136
137
need_range_check. push (
@@ -242,7 +243,7 @@ where
242
243
need_range_check. push ( limb) ;
243
244
}
244
245
245
- for ( i, limb) in pc_limbs. iter ( ) . skip ( 1 ) . enumerate ( ) {
246
+ for ( i, limb) in pc_limbs. iter ( ) . enumerate ( ) . skip ( 1 ) {
246
247
if i == pc_limbs. len ( ) - 1 {
247
248
need_range_check. push ( ( * limb) << ( pc_limbs. len ( ) * RV32_CELL_BITS - PC_BITS ) ) ;
248
249
} else {
You can’t perform that action at this time.
0 commit comments