Skip to content
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

[Wasm][Interp] Assertion at sgen-mono.c:114, condition `m_class_is_valuetype (klass)' not met #52735

Closed
jeromelaban opened this issue May 14, 2021 · 6 comments · Fixed by #52752

Comments

@jeromelaban
Copy link
Contributor

jeromelaban commented May 14, 2021

Description

The runtime fails to execute some code with the following trace:

dotnet.js:1601 * Assertion at /__w/runtime/src/mono/mono/metadata/sgen-mono.c:114, condition `m_class_is_valuetype (klass)' not met
607778    @    dotnet.js:1601
_emscripten_asm_const_int    @    dotnet.js:6347
wasm_trace_logger    @    00d55d3e:0x1e593a
eglib_log_adapter    @    00d55d3e:0xb281b
monoeg_g_logstr    @    00d55d3e:0x107cc8
monoeg_g_logv_nofree    @    00d55d3e:0x107c6c
monoeg_assertion_message    @    00d55d3e:0x107d16
mono_assertion_message    @    00d55d3e:0x107d4d
mono_gc_wbarrier_value_copy_internal    @    00d55d3e:0xacea6
mono_value_copy_internal    @    00d55d3e:0x8d52d
interp_exec_method    @    00d55d3e:0x1328f
interp_runtime_invoke    @    00d55d3e:0xa809
mono_jit_runtime_invoke    @    00d55d3e:0xd8e93
do_runtime_invoke    @    00d55d3e:0x8751d
mono_runtime_try_invoke    @    00d55d3e:0x87bcd
mono_runtime_invoke    @    00d55d3e:0x89ec8
mono_wasm_invoke_method    @    00d55d3e:0x1e5a35

Does not fail with Interp+AOT.
Repro: https://github.com/jeromelaban/Wasm.Samples/tree/master/Bug52735

Configuration

Last working: da580be
Failure since efd3410 (#52130)

Regression?

Yes

Other information

#52130

Trying to add more information, here's the log for this:
image

Right before the assert:

Adding value remset at 0x166e20c, count 1, descr 0 for class ؂�
dotnet.js:1 ؂�
dotnet.js:1 𶕀
dotnet.js:1 � (0xa55fd00)
@dotnet-issue-labeler
Copy link

I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label.

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label May 14, 2021
@ghost
Copy link

ghost commented May 14, 2021

Tagging subscribers to this area: @BrzVlad
See info in area-owners.md if you want to be subscribed.

Issue Details

Description

The runtime fails to execute some code with the following trace:

dotnet.js:1601 * Assertion at /__w/runtime/src/mono/mono/metadata/sgen-mono.c:114, condition `m_class_is_valuetype (klass)' not met
607778    @    dotnet.js:1601
_emscripten_asm_const_int    @    dotnet.js:6347
wasm_trace_logger    @    00d55d3e:0x1e593a
eglib_log_adapter    @    00d55d3e:0xb281b
monoeg_g_logstr    @    00d55d3e:0x107cc8
monoeg_g_logv_nofree    @    00d55d3e:0x107c6c
monoeg_assertion_message    @    00d55d3e:0x107d16
mono_assertion_message    @    00d55d3e:0x107d4d
mono_gc_wbarrier_value_copy_internal    @    00d55d3e:0xacea6
mono_value_copy_internal    @    00d55d3e:0x8d52d
interp_exec_method    @    00d55d3e:0x1328f
interp_runtime_invoke    @    00d55d3e:0xa809
mono_jit_runtime_invoke    @    00d55d3e:0xd8e93
do_runtime_invoke    @    00d55d3e:0x8751d
mono_runtime_try_invoke    @    00d55d3e:0x87bcd
mono_runtime_invoke    @    00d55d3e:0x89ec8
mono_wasm_invoke_method    @    00d55d3e:0x1e5a35

No clear repro outside a standard Uno application startup. Does not fail with Interp+AOT.

Configuration

Last working: da580be
Failure since efd3410 (#52130)

Regression?

Yes

Other information

#52130

Trying to add more information, here's the log for this:
image

Right before the assert:

Adding value remset at 0x166e20c, count 1, descr 0 for class ؂�
dotnet.js:1 ؂�
dotnet.js:1 𶕀
dotnet.js:1 � (0xa55fd00)
Author: jeromelaban
Assignees: -
Labels:

area-Codegen-Interpreter-mono, untriaged

Milestone: -

@marek-safar marek-safar removed the untriaged New issue has not been triaged by the area owner label May 14, 2021
@marek-safar marek-safar added this to the 6.0.0 milestone May 14, 2021
@BrzVlad
Copy link
Member

BrzVlad commented May 14, 2021

@jeromelaban Could I get info on how to reproduce this ? I doesn't matter if it's a specific or bloated app.

@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label May 14, 2021
@jeromelaban
Copy link
Contributor Author

I can provide you that, I'll try the PR as well so we can do this faster :) Thanks for the speed of fixing !

jeromelaban added a commit to jeromelaban/Wasm.Samples that referenced this issue May 14, 2021
jeromelaban added a commit to jeromelaban/Wasm.Samples that referenced this issue May 14, 2021
@jeromelaban
Copy link
Contributor Author

jeromelaban commented May 14, 2021

Here's the repro: https://github.com/jeromelaban/Wasm.Samples/tree/master/Bug52735

Also, the fix in #52752 does not seem to address the issue.

@jeromelaban
Copy link
Contributor Author

Update, the issue is fixed by #52752.

@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label May 17, 2021
@ghost ghost locked as resolved and limited conversation to collaborators Jun 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants