Search Issue Tracker
Won't Fix
Votes
0
Found in
2018.3.0b5
Issue ID
1098024
Regression
No
[IL2CPP] Build process fails with StackOverflowException when building for Standalone
To reproduce:
1. Download the attached project "TestUnity.zip" and open in Unity
2. Open "SampleScene" scene
3. Set Scripting Backend to IL2CPP
4. Build & Run project for PC, Mac & Standalone platform
5. Observe Build failing after some time with the Exception:
Either:
Process is terminated due to StackOverflowException when trying to build
Or:
fatal error C1060: compiler is out of heap space
Notes:
- This issue appears on both Windows and macOS
- Build only seems to fail when IL2CPP Scripting Backend enabled
- File it fails on is called PlayerSnapshotGenerated.cs. It has got 23k lines of code,
seems to be a size problem (as one of the exceptions complains about heap space issues)
- Could not check on newest Unity 2018.2 because my both Windows and macOS machines freeze up, but
Reproduced on Unity 2018.1.0f1, 2018.2.0f2, 2018.3.0b5, 2018.3.0b9 and 2019.1.0a8
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
- Light is not applied properly to Terrain Details when using Light Layers
- Opening reference for XR component redirects to a missing page
- [Android]Crash on PersistentManager::GlobalToLocalSerializedFileIndex(SerializedObjectIdentifier const&) when building the Android Player
- [Android] The Video Player stops playing at different points when Skip On Drop is enabled
- Rigidbody2D.Slide API does not have the needed configuration when creating a 2D Top-Down character controller
Resolution Note:
We are going to fix the IL2CPP stack overflow exception in this case, but the C++ compiler will still crash because the generated method is too large. The user should change their code to use arrays instead of generating so many statements.