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 }}
Repository navigation
Failure in Regressions/coreclr/GitHub_35000/test35000/test35000.sh #47294
This likely won't be trivial to fix. The whole shuffle thunk generator logic relies on the fact that the entries being shuffled between stack and register slots are of the same size. We've had couple of hard to diagnose bugs there caused by incorrect ordering of the moves. I've ended up rewriting the code completely.
hmm.. interesting. What is the behavior currently, does it fail to invoke the delegate, or crash when h is accessed?
so before the VM changes were merged the test was working correctly because VM was using not-apple ABI and allocation both arguments at 8 offsets. We could write a test where the target is a C++ method so it would fail without VM changes. In this case it would be wrong execution because the target method would read garbage instead of the real argument value.
with the last VM changes merged it fails with an assert, if we build release VM then we will generate a wrong move.
It should be a fail-fast, there is no way to recover from such a situation. And we need to fix it, any user code can hit this depending on arguments to delegates. Please note that even though the file is called comdelegate.cpp, it is used for all delegates.
Activity
sandreenko commentedon Jan 21, 2021
PTAL @janvorli @sdmaclea @mangod9 not sure if it worth our immediate attention but we probably should discuss a long-term solution.
sandreenko commentedon Jan 21, 2021
cc @jkoritzinsky
mangod9 commentedon Jan 21, 2021
hmm.. interesting. What is the behavior currently, does it fail to invoke the delegate, or crash when h is accessed?
janvorli commentedon Jan 21, 2021
This likely won't be trivial to fix. The whole shuffle thunk generator logic relies on the fact that the entries being shuffled between stack and register slots are of the same size. We've had couple of hard to diagnose bugs there caused by incorrect ordering of the moves. I've ended up rewriting the code completely.
sandreenko commentedon Jan 21, 2021
so before the VM changes were merged the test was working correctly because VM was using not-apple ABI and allocation both arguments at 8 offsets. We could write a test where the target is a C++ method so it would fail without VM changes. In this case it would be wrong execution because the target method would read garbage instead of the real argument value.
with the last VM changes merged it fails with an assert, if we build release VM then we will generate a wrong move.
mangod9 commentedon Jan 22, 2021
is there anyway to detect and fail gracefully than possibly corrupting state?
sandreenko commentedon Jan 22, 2021
So it is detected here:
runtime/src/coreclr/vm/comdelegate.cpp
Line 281 in 311de30
and here:
runtime/src/coreclr/vm/comdelegate.cpp
Line 294 in 311de30
do we have a throwing mechanism for VM?
janvorli commentedon Jan 22, 2021
It should be a fail-fast, there is no way to recover from such a situation. And we need to fix it, any user code can hit this depending on arguments to delegates. Please note that even though the file is called comdelegate.cpp, it is used for all delegates.
sdmaclea commentedon Feb 25, 2021
These tests also now failing with the same assert
sdmaclea commentedon Apr 7, 2021
These tests are disabled
runtime/src/tests/issues.targets
Lines 722 to 731 in c320071
sdmaclea commentedon May 5, 2021
@mangod9 This is one other Apple Silicon functional issue.
mangod9 commentedon May 5, 2021
Ok, thanks. Looks like its already included in "ToDo" on the project dashboard.