Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only.

    Please, do not make any changes to your username or email addresses at during this transition time.

    It's still possible to reply to existing private message conversations during the migration, but any new replies you post will be missing after the main migration is complete. We'll do our best to migrate these messages in a follow-up step.

    On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live.

    Read our full announcement for more information and let us know if you have any questions.

[IL2CPP] My builds crash on any x64 / x86 build target

Discussion in 'Windows' started by patrykk, Sep 6, 2018.

  1. patrykk


    May 20, 2017
    So, whenever I try to build my project with il2cpp as backend, I get crashes when trying to
    run the standalone. The resolution window shows up, then the exe crashes.
    I've tried all the build options I could think of, the final target I settled on is x64 / development build.

    The error doesn't tell me anything reasonable, really:
    Stack Trace of Crashed Thread 3340:
    0x00007FFB728B6E31 (GameAssembly) [k:\bin\2018.2.6\editor\data\il2cpp\libil2cpp\icalls\system\microsoft.win32\nativemethods.cpp:30] il2cpp::icalls::System::Microsoft::Win32::NativeMethods::GetProcessTimes
    0x00007FFB70B6EAC0 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_system_0.cpp:22343] NativeMethods_GetProcessTimes_m1357047

    Could anybody help me track this down? The same project works when build with mono backend - so am I stuck with mono, forever?

    I'm attaching the entire crash log.

    Attached Files:

  2. Tautvydas-Zilys


    Unity Technologies

    Jul 25, 2013
    Looks like you are hitting an unimplemented path in il2cpp. Could we have a bug report?

    The function that is responsible for it is RandomStateGenerator constructor, it's calling into Process.UserProcessorTime. Here's the relevant callstack:

    Code (csharp):
    1. 0x00007FFB728B6E31 (GameAssembly) [k:\bin\2018.2.6\editor\data\il2cpp\libil2cpp\icalls\system\microsoft.win32\nativemethods.cpp:30] il2cpp::icalls::System::Microsoft::Win32::NativeMethods::GetProcessTimes
    2. 0x00007FFB70B6EAC0 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_system_0.cpp:22343] NativeMethods_GetProcessTimes_m1357047
    3. 0x00007FFB70B6EC22 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_system_0.cpp:22372] NativeMethods_GetProcessTimes_m3739936313
    4. 0x00007FFB710A3F4B (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_system_4.cpp:21017] Process_GetProcessTimes_m3993746901
    5. 0x00007FFB710A6001 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_system_4.cpp:21151] Process_get_UserProcessorTime_m3231653866
    6. 0x00007FFB7169C168 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_assembly-csharp-firstpass_1.cpp:29444] RandomStateGenerator__ctor_m2129494024
    7. 0x00007FFB7168ACAD (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_assembly-csharp-firstpass_1.cpp:17003] RandomBase_Seed_m1831886913
    8. 0x00007FFB6FF6DFB3 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_assembly-csharp_13.cpp:140] InterfaceActionInvoker0::Invoke
    9. 0x00007FFB716835FB (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_assembly-csharp-firstpass_1.cpp:16834] MIRandom_CreateStandard_m4226023902
    10. 0x00007FFB71682F72 (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_assembly-csharp-firstpass_1.cpp:16809] MIRandom_CreateShared_m1657751803
    11. 0x00007FFB7168398B (GameAssembly) [k:\checkpointalpha\temp\stagingarea\data\il2cppoutput\bulk_assembly-csharp-firstpass_1.cpp:16707] MIRandom_InitializeStaticFields_m1105216541
    To work around this, remove Process.UserProcessorTime call.
  3. patrykk


    May 20, 2017
    Ah, thank you for the specific response!
    That's coming from the Experilous MakeItRandom asset - I believe it's by now deprecated in the Asset Store,
    so I'll change it or look into a replacement.

    Thanks again.