-
Notifications
You must be signed in to change notification settings - Fork 9
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
[EraVM] Add support for select instructions in EraVMBytesToCells #536
Merged
Conversation
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
vladimirradosavljevic
force-pushed
the
add_select_bytes_to_cells
branch
from
May 12, 2024 18:15
75a9853
to
364cf05
Compare
Benchmark results:
|
vladimirradosavljevic
force-pushed
the
add_select_bytes_to_cells
branch
3 times, most recently
from
May 13, 2024 11:28
fd2e5d7
to
414bd7f
Compare
akiramenai
requested changes
May 13, 2024
…in EraVMBytesToCells Add tests where we fail to convert address in select instructions to cells. E.g. where r2 is not in cells: ``` add stack[r2], r0, r1 ``` should be ``` shr.s 5, r2, r2 add stack[r2], r0, r1 ``` Signed-off-by: Vladimir Radosavljevic <vr@matterlabs.dev>
vladimirradosavljevic
force-pushed
the
add_select_bytes_to_cells
branch
from
May 13, 2024 13:58
414bd7f
to
42bc17a
Compare
Since select instructions have stack and code operands, we need to convert them into cell addressing. This patch also adds IsEarlyClobber flag to select instructions in which register is converted to cell addressing, to prevent the regalloc from assigning output register to this register. Without IsEarlyClobber flag: ``` shr.s 5, r2, r1 shr.s 5, r3, r2 add stack[r2], r0, r1 add.ne stack[r1], r0, r1 ``` With IsEarlyClobber flag: ``` shr.s 5, r2, r2 shr.s 5, r3, r3 add stack[r3], r0, r1 add.ne stack[r2], r0, r1 ``` Signed-off-by: Vladimir Radosavljevic <vr@matterlabs.dev>
vladimirradosavljevic
force-pushed
the
add_select_bytes_to_cells
branch
from
May 13, 2024 14:05
42bc17a
to
38f6816
Compare
akiramenai
approved these changes
May 13, 2024
hedgar2017
approved these changes
May 13, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
No description provided.