fixes Bil.eval memory operations for different sizes of values #1102
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.
Bil.Eval
still relies on the assumption that memory can address only values of 1-byte length. And once the stored/loaded value size differs from memory value size, we try to simplify an expression. But the simplification in its turn can leave an expression unchanged since it takes into account both memory value size and size of a stored/loaded value. And that's how we get an infinite loop: since an expression is unchanged, we try to eval it again, simplify, and so on.This PR fixes this problem and checks both the size of the stored/loaded value and memory value size.
fixes #848