-
Notifications
You must be signed in to change notification settings - Fork 34
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
Add opcodes for fast interpreter #182
Conversation
@@ -4,3 +4,22 @@ test/regress/ext:gc/array_new_fixed.bin.wast | |||
test/regress/ext:gc/br_on_non2.bin.wast | |||
test/regress/ext:gc/br_on_non.bin.wast | |||
test/regress/ext:gc/ref_eq.bin.wast | |||
test/regress/ext:threads/atomic_load_i32.bin.wast |
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.
Do these tests only fail on the single-pass compiler now? If so, the failures file should be at least platform-specific, since these should all pass on the V3 interpreter.
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.
Oh, it passes on V3 interpreter. I was planning to remove all of these when making a final PR to V3 interpreter.
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.
Ok, sgtm.
bindHandler(Opcode.I64_ATOMIC_RMW16_CMPXCHG_U); | ||
genAtomicCompareAndExchange(asm.cmpxchgw_m_r); | ||
} | ||
def genAtomicOp<T>(op: (X86_64Addr, X86_64Gpr) -> T, |
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 method is getting a little big. In particular, it takes a bool
that switches off a lot of the functionality. I think it makes sense to split it into two methods at least, and factor out some of the commonality to shared functions.
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.
Sure thing! I didn’t like it either tbh. But since it was done in a single function I kept like that to get feedback
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.
Ok, I am going to merge this and we can fix it in a followup.
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.
Hey! Thanks! I am going to make PR s about JIT and Virgil interpreters. I will write separate functions when making a PR about wait and notify o7
Add thread-related opcodes onto fast interpreter.