-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor lt config to gadget and blt #280
Conversation
e2052d9
to
1f7a3f7
Compare
488a0f9
to
d0c8203
Compare
let read_rs1 = UInt::new_unchecked(|| "rs1_limbs", circuit_builder)?; | ||
let read_rs2 = UInt::new_unchecked(|| "rs2_limbs", circuit_builder)?; | ||
let is_lt = | ||
circuit_builder.less_than(|| "rs1<rs2", read_rs1.value(), read_rs2.value(), None)?; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this part actually need to be signed comparison 😃
so I just updated to implemented uint signed lt algebraric version (which should somehow be cheaper than previous u8 limb lookup)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant to bring this up later, but since you started here, I wrote up the generalization of this technique: #285
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait, I’m also working on the signed version (I’m doing all the branches). I planned on using this gadget for the unsigned branches (essentially renaming this BLT to BLTU). Can you put it back (have both unsigned and signed)?
Or let’s merge this PR then I’ll glue it all together afterwards.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay! The singed version I implemented was end up with degree = 3 in my side, which is unfavorable, so I just switch back to unsigned version, and will be good to glue/revamping together with your signed version
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The soundness issue existed before but let’s fix it now.
223041f
to
0249d36
Compare
0249d36
to
bbf1393
Compare
bbf1393
to
f85777a
Compare
haha, I did simliar thing in #278, again. |
No description provided.