Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Crash on startup (iOS, 5.2.3p3)

Discussion in 'iOS and tvOS' started by Guillaume-Portes, Dec 18, 2015.

  1. Guillaume-Portes

    Guillaume-Portes

    Joined:
    Oct 10, 2012
    Posts:
    13
    Hi,

    We're very close to submitting our game, and unfortunately are being hit by a very weird crash on start up.
    We've had instances of it for a couple of weeks but more recently it has started to happen very regularly, on quite a few devices and OS versions (8+).
    After trying many, many things I ended up loading into an empty scene, and it still occurs, at which point I'm not sure what to try next.

    Here is the callstack, it's crashing in the UnityPreloadThread:
    #0 0x0000000102e3e14c in il2cpp::vm::Class::HasParent(TypeInfo*, TypeInfo*) [inlined] at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/vm/Class.h:110
    #1 0x0000000102e3e134 in il2cpp::vm::Class::IsSubclassOf(TypeInfo*, TypeInfo*, bool) at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/vm/Class.cpp:690
    #2 0x000000010274736c in CreateMonoScriptCache [inlined] at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScriptCache.cpp:631
    #3 0x000000010274652c in ::FindOrCreateMonoScriptCache() at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScriptCache.cpp:648
    #4 0x0000000102743ef8 in Renew [inlined] at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScript.cpp:159
    #5 0x0000000102743ee8 in ::Rebuild() at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScript.cpp:166
    #6 0x000000010277a124 in ::postReadActivationQueue() at /Users/builduser/buildslave/unity/build/Runtime/Serialize/PersistentManager.cpp:1143
    #7 0x000000010277aeac in ::LoadFileCompletelyThreaded() at /Users/builduser/buildslave/unity/build/Runtime/Serialize/PersistentManager.cpp:1602
    #8 0x00000001026f67ac in ::perform() at /Users/builduser/buildslave/unity/build/Runtime/Misc/LoadSceneOperation.cpp:131
    #9 0x00000001026f53ac in ::processSingleOperation() at /Users/builduser/buildslave/unity/build/Runtime/Misc/PreloadManager.cpp:273
    #10 0x00000001026f5194 in ::Run() at /Users/builduser/buildslave/unity/build/Runtime/Misc/PreloadManager.cpp:331
    #11 0x00000001026f5148 in ::Run() at /Users/builduser/buildslave/unity/build/Runtime/Misc/PreloadManager.cpp:180
    #12 0x00000001027a78f4 in ::RunThreadWrapper() at /Users/builduser/buildslave/unity/build/Runtime/Threads/Thread.cpp:40

    The output is pretty much empty (apart from some Metal related shader compiling warnings).

    Anyone has encountered this one before?

    Thanks,

    G.
     
  2. Guillaume-Portes

    Guillaume-Portes

    Joined:
    Oct 10, 2012
    Posts:
    13
    Ha! It looks like Unity is not coping with an initial scene that loads too fast.
    As soon as I put an object in there with a fair amount of references (therefore taking longer to load) the problem goes away!
     
  3. povilas

    povilas

    Unity Technologies

    Joined:
    Jan 28, 2014
    Posts:
    427
    Hi, could you check if the original problem is reproducible on Unity 5.3.0? If yes, it would be great if you submitted a bug report with a reproduction project.
     
  4. Guillaume-Portes

    Guillaume-Portes

    Joined:
    Oct 10, 2012
    Posts:
    13
    Hello!

    Unfortunately I can't really at the moment as we're really up against it!
    I'll loop back when I get to it though!
     
  5. sdpgames

    sdpgames

    Joined:
    Sep 2, 2014
    Posts:
    17
  6. Lamosca_2014

    Lamosca_2014

    Joined:
    Jan 26, 2015
    Posts:
    10
    Any progress on this one?

    We're having the same problem on Unity 5.3.0f4 and are now unable to run on game on iOS. (It's the same on all our test devices)

    Details:

    Thread 1Queue : com.apple.main-thread (serial)
    #0 0x0140db78 in il2cpp::vm::Class::HasParent(TypeInfo*, TypeInfo*) [inlined] at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/vm/Class.h:110
    #1 0x0140db66 in il2cpp::vm::Class::IsSubclassOf(TypeInfo*, TypeInfo*, bool) at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/vm/Class.cpp:690
    #2 0x00dcb84e in CreateMonoScriptCache at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScriptCache.cpp:619
    #3 0x00dcbb2c in FindOrCreateMonoScriptCache at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScriptCache.cpp:636
    #4 0x00dc86b8 in Renew [inlined] at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScript.cpp:151
    #5 0x00dc86ac in Rebuild at /Users/builduser/buildslave/unity/build/Runtime/Mono/MonoScript.cpp:158
    #6 0x00deadd6 in PostReadActivationQueue at /Users/builduser/buildslave/unity/build/Runtime/Serialize/PersistentManager.cpp:1158
    #7 0x00debc16 in LoadFileCompletelyThreaded at /Users/builduser/buildslave/unity/build/Runtime/Serialize/PersistentManager.cpp:1624
    #8 0x00debd94 in LoadFileCompletely at /Users/builduser/buildslave/unity/build/Runtime/Serialize/PersistentManager.cpp:1653
    #9 0x00c7c234 in PlayerLoadGlobalManagers at /Users/builduser/buildslave/unity/build/Runtime/BaseClasses/ManagerContextLoading.cpp:112
    #10 0x00d8a292 in PlayerInitEngineGraphics at /Users/builduser/buildslave/unity/build/Runtime/Misc/Player.cpp:720
    #11 0x00f51eb4 in UnityInitApplicationGraphics at /Users/builduser/buildslave/unity/build/PlatformDependent/iPhonePlayer/LibEntryPoint.mm:207
    #12 0x0007c0a0 in -[UnityAppController startUnity:] at .../UnityAppController.mm:109
    #13 0x2baee7c8 in __NSFireDelayedPerform ()
    #14 0x2adb04be in __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ ()
    #15 0x2adb003a in __CFRunLoopDoTimer ()
    #16 0x2adae28a in __CFRunLoopRun ()
    #17 0x2acfc620 in CFRunLoopRunSpecific ()
    #18 0x2acfc432 in CFRunLoopRunInMode ()
    #19 0x320510a8 in GSEventRunModal ()
    #20 0x2e2e7358 in UIApplicationMain ()
    #21 0x0006567a in main at ...Classes/main.mm:32

    Output:

    -> registered mono modules 0x14d1290
    -> applicationDidFinishLaunching()
    -> applicationDidBecomeActive()
    Init: screen size 2048x1536
    Initializing Metal device caps
    Initialize engine version: 5.3.0f4 (2524e04062b4)
    (lldb)
     
  7. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,775
    @Lamosca_2014

    This looks like a known bug that was corrected in 5.3.1p1. You should be able to try that release here: http://unity3d.com/unity/qa/patch-releases
     
  8. Lamosca_2014

    Lamosca_2014

    Joined:
    Jan 26, 2015
    Posts:
    10
    Hi Josh

    Thanks for the fast reply. Installing the patch release did solve this problem. Thanks!

    Kind regards
    Sam
     
  9. NeilW

    NeilW

    Joined:
    May 29, 2014
    Posts:
    40
    Is there any chance that this fix will be added as a 5.2 patch release? We have had so many issues since moving to 5.x that we really don't want to move to 5.3 to fix this issue and potentially cause us a bunch of new ones.
     
  10. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,775
    @NeilW

    Unfortunately we're not planning to ship any more 5.2 patch releases. It is possible to build and ship special versions if necessary. I'm not entirely sure about that process, can you ping someone from our support team? If not, I'll see what I can find.
     
  11. Mint-Mobile

    Mint-Mobile

    Joined:
    Apr 9, 2015
    Posts:
    7
    Unity 5.3.2 ios crash on startup. On iPad 3 (9.2.1) all work ok, but on iPad Air, iphone 5, 5s, 6, 6s didn't work
     
  12. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,775
    @Mint Mobile

    Are you seeing the same crash described here? We did have one known bug in 5.3.2 that was corrected in 5.3.2p2. If you can provide the call stack for the crash you see I should be able to determine if it is the bug we corrected.