Skip to content
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

Verifier doesn't correctly perform unsigned 32-bit division and modulo #730

Closed
Alan-Jowett opened this issue Oct 15, 2024 · 0 comments · Fixed by #731
Closed

Verifier doesn't correctly perform unsigned 32-bit division and modulo #730

Alan-Jowett opened this issue Oct 15, 2024 · 0 comments · Fixed by #731

Comments

@Alan-Jowett
Copy link
Contributor

Failing test cases:

---
test-case: 32bit division - negative divisor

pre: ["r0.type=number", "r0.svalue=0", "r0.uvalue=0"]

code:
  <start>: |
    w0 = 4194435072
    w0 /= 4096655360

post:
  - r0.type=number
  - r0.svalue=1
  - r0.uvalue=1
 
---
test-case: 32bit modulo - negative divisor
pre: ["r0.type=number", "r0.svalue=0", "r0.uvalue=0"]

code:
  <start>: |
    w0 = 4194435072
    w0 %= 4096655360

post:
  - r0.type=number
  - r0.svalue=97779712
  - r0.uvalue=97779712

Note:
This was found using a version of the fix for #728

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant