-
Notifications
You must be signed in to change notification settings - Fork 102
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
Solve bit decomposition with negative coefficients. #2554
Merged
chriseth
merged 37 commits into
main
from
solve_bit_decomposition_with_negative_numbers
Mar 26, 2025
Merged
Changes from 1 commit
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
5f9c452
Solve bit decomposition with negative coefficients.
chriseth bf43c73
Make bit decomposition its own effect.
chriseth 99558c2
fixes
chriseth f4f8a28
Remove negative case since this is now also covered.
chriseth f5fe3f5
Update test expectations.
chriseth 1a378c3
Implement missing functions.
chriseth fcc5190
Codegen for bit decomposition.
chriseth 7b4780e
clippy
chriseth 94a8cc4
Test with negative value.
chriseth 44bdd08
Use shift instead of division.
chriseth d2980dd
Fix typo.
chriseth a3b210c
Bit decomposition interpreter.
chriseth 2e7d3a7
Jump through some hoops.
chriseth 4ddae64
Tests and fixes.
chriseth 721cd36
Merge remote-tracking branch 'origin/main' into bit_decomp_interpreter
chriseth 589963b
Cover check.
chriseth 977f106
Update executor/src/witgen/jit/compiler.rs
chriseth 14647d1
Review.
chriseth 2e87944
Remove bitand_signed_negated.
chriseth 0906258
debugging
chriseth 1059fa6
Add comment.
chriseth 5cf50ee
Make all variables to be assigned in the branch mutable.
chriseth 00750c8
Revert "debugging"
chriseth f71190c
remove debug
chriseth d398c25
Fix expectation.
chriseth 85a3a4d
Merge remote-tracking branch 'origin/main' into solve_bit_decompositi…
chriseth 1c1eaa2
Merge remote-tracking branch 'origin/main' into solve_bit_decompositi…
chriseth ea0a974
Merge remote-tracking branch 'origin/main' into solve_bit_decompositi…
chriseth cbf290f
Merge remote-tracking branch 'origin/main' into solve_bit_decompositi…
chriseth 73f11ce
fix merge.
chriseth 84d05ce
Merge remote-tracking branch 'origin/main' into solve_bit_decompositi…
chriseth 392a6d1
Merge remote-tracking branch 'origin/main' into bit_decomp_interpreter
chriseth 8275be7
Merge branch 'bit_decomp_interpreter' into solve_bit_decomposition_wi…
chriseth 4e70926
Remove "needs_mut"
chriseth f3d6b63
Review comments.
chriseth 06cf432
Merge remote-tracking branch 'origin/main' into solve_bit_decompositi…
chriseth f7630b9
Comment about conversion to two's complement.
chriseth File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Tests and fixes.
- Loading branch information
commit 4ddae64e8cfbdff8f60585a1dca56fdcb8fec750
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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 would be slightly clearer to me, but still pretty confusing.
Maybe this would also give the right result?
Then we also don't need
MAX
. We could also requireT::Integer
to implementNeg
.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.
No, the problem is that
T::Integer::from(0) - abs_component
underflows and thus might panic.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.
Added a comment.