You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 23, 2024. It is now read-only.
There are a number of places where the address is added to an offset (symbolic address mode, jxx instructions, etc.) There's already been one issue discovered and fixed caused by bad casting + arithmetic that caused an i16 MAX_I16 overflow during computation. Checked add is probably the correct way to make sure at runtime that nothing bad happens but since we're casting up to i64 to do math and both values are at most MAX_I16 or MAX_U16 there should be plenty of space to work with. If it's found to not be true the following is probably the correct way to handle it:
let val = ((addr asi64).checked_add(*i asi64)).unwrap_or(0)asu64;
The text was updated successfully, but these errors were encountered:
There are a number of places where the address is added to an offset (symbolic address mode, jxx instructions, etc.) There's already been one issue discovered and fixed caused by bad casting + arithmetic that caused an i16 MAX_I16 overflow during computation. Checked add is probably the correct way to make sure at runtime that nothing bad happens but since we're casting up to i64 to do math and both values are at most MAX_I16 or MAX_U16 there should be plenty of space to work with. If it's found to not be true the following is probably the correct way to handle it:
The text was updated successfully, but these errors were encountered: