Search Issue Tracker
Fixed
Votes
7
Found in
2020.3.44f1
2021.3.17f1
2022.2.5f1
2023.1.0b2
2023.2.0a2
Issue ID
UUM-26432
Regression
No
[IL2CPP] Crash in "il2cpp::vm::Class::SetupMethods" when EqualityComparer is created from multiple threads
How to reproduce:
1. Open the attached “TestIL2CPPEnumCrash.zip“ project
2. Build for a Standalone Player
3. Run a Build Player
Expected result: The Player opens and closes
Actual result: The Player opens and crashes
Reproducible with: 2020.3.44f1, 2021.3.17f1, 2022.2.5f1, 2023.1.0b2
Reproducible with: Windows, MacOS, Android
Notes:
- The Player crashes after the 1st-2nd attempt
- The crash is not reproducible after the 1st-10th crash (The Player starts acting as expected or freezes)
Forum thread: [https://forum.unity.com/threads/il2cpp-crash-calling-array-indexof-on-array-of-enums-running-on-the-thread-pool.1341764/#post-8735814]
First few lines of the stack trace:
(GameAssembly) [[EditorLocation]\Data\il2cpp\libil2cpp\vm\Class.cpp:1140] il2cpp::vm::Class::SetupMethods
(GameAssembly) [[EditorLocation]\2020.3.44f1\Editor\Data\il2cpp\libil2cpp\vm\Class.cpp:367] il2cpp::vm::Class::GetMethods
(GameAssembly) [[EditorLocation]\2020.3.44f1\Editor\Data\il2cpp\libil2cpp\icalls\mscorlib\System\MonoType.cpp:322] il2cpp::icalls::mscorlib::System::MonoType::GetConstructors_internal
(GameAssembly) [[EditorLocation]\Data\il2cpp\libil2cpp\icalls\mscorlib\System\RuntimeType.cpp:186] il2cpp::icalls::mscorlib::System::RuntimeType::GetConstructors_native
(GameAssembly) [ProjectLocation\Library\Il2cppBuildCache\Windows\x64\il2cppOutput\mscorlib11.cpp:32075] RuntimeType_GetConstructors_internal_m76E62D68C52B212895C44CE5E213BBA00F5E397F
(GameAssembly) [ProjectLocation\Library\Il2cppBuildCache\Windows\x64\il2cppOutput\mscorlib11.cpp:24620] RuntimeType_GetConstructorCandidates_m1AF80B6730AF93BA20B47C13DDBBF4EC3E79793F
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- [Android][iOS] The keyboard closes and re-opens when consecutive input fields are selected
- Complex Sub Graph connected to a Voronoi node is ignored when the shader gets applied as a Material
- Compute Shader property not set error when entering play mode with path tracing and PBR sky
- "WebGL Publish" detects WebGL module and allows building when it is installed without restarting the project
- Editor is non-responsive and flickers when multiple Water System instances are enabled
Resolution Note:
Fixed by another internal issue: UUM-26516: [Android][iOS] IL2CPP generics can cause crashes when used from multiple threads