Search Unity

Bug function-name not avalaible crash

Discussion in 'Editor & General Support' started by cryothink, Dec 21, 2022.

  1. cryothink

    cryothink

    Joined:
    Dec 21, 2022
    Posts:
    2
    on editor and development builds the crash doesn't occur, but only on the release build it crashes after I played it for sometime. I cannot find where the problem occurs but I think it has something to do with unity collections. The crash also occurs on android build. any help would be appreciated.

    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA06E8FF5B)
    0x00007FFA06E8FF5B (UnityPlayer) (function-name not available)
    0x00007FFA07734961 (UnityPlayer) UnityMain
    0x00007FFA0772F132 (UnityPlayer) UnityMain
    0x00007FFA077331A5 (UnityPlayer) UnityMain
    0x00007FFA0771E91D (UnityPlayer) UnityMain
    0x00007FFA0771C913 (UnityPlayer) UnityMain
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA07096C2A)
    0x00007FFA07096C2A (UnityPlayer) (function-name not available)
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA07096CD0)
    0x00007FFA07096CD0 (UnityPlayer) (function-name not available)
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA070995F8)
    0x00007FFA070995F8 (UnityPlayer) (function-name not available)
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA07293E4A)
    0x00007FFA07293E4A (UnityPlayer) (function-name not available)
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA07292B7B)
    0x00007FFA07292B7B (UnityPlayer) (function-name not available)
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA07297357)
    0x00007FFA07297357 (UnityPlayer) (function-name not available)
    0x00007FFA07298EBB (UnityPlayer) UnityMain
    ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FF73D3A11F2)
    0x00007FF73D3A11F2 (Beastria) (function-name not available)
    0x00007FFAB7F36FD4 (KERNEL32) BaseThreadInitThunk
    0x00007FFAB8D5CEC1 (ntdll) RtlUserThreadStart
     

    Attached Files:

  2. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,674
    Here's a resolved callstack from the dump file:

    Code (csharp):
    1. UnityPlayer.dll!GameObject::SendMessageAny(const MessageIdentifier & messageIdentifier, MessageData & messageData) Line 1285
    2. [Inline Frame] UnityPlayer.dll!Unity::Component::SendMessage(const MessageIdentifier &) Line 591
    3. UnityPlayer.dll!PhysicsContacts2D::SendCallbackReports(dynamic_array<Collision2D::TriggerReport,0> & triggerReports, dynamic_array<Collision2D::CollisionReport,0> & collisionReports) Line 537
    4. UnityPlayer.dll!ProcessContactsData::Finalize(PhysicsContacts2D & contacts) Line 854
    5. UnityPlayer.dll!PhysicsContacts2D::ProcessContacts(Collider2D * colliderFilter, const bool performCallbacks) Line 899
    6. UnityPlayer.dll!PhysicsManager2D::Simulate(PhysicsScene2D * physicsScene, float timeDelta) Line 901
    7. UnityPlayer.dll!PhysicsManager2D::FixedUpdate() Line 548
    8. UnityPlayer.dll!ExecutePlayerLoop(NativePlayerLoopSystem * system) Line 384
    9. UnityPlayer.dll!ExecutePlayerLoop(NativePlayerLoopSystem * system) Line 408
    10. UnityPlayer.dll!PlayerLoop() Line 514
    11. UnityPlayer.dll!PerformMainLoop() Line 329
    12. UnityPlayer.dll!MainMessageLoop() Line 1260
    13. UnityPlayer.dll!UnityMainImpl(HINSTANCE__ * hInst, HINSTANCE__ * hPrev, wchar_t * szCmdLine, int nCmdShow) Line 1777
    14. UnityPlayer.dll!UnityMain(HINSTANCE__ * hInst, HINSTANCE__ * hPrev, wchar_t * szCmdLine, int nCmdShow) Line 1817
    I've moved this thread to 2D forum as the crash seems to be related to that.
     
  3. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    914
    Thank you @Tautvydas-Zilys !
    @cryothink could you please file a bug report and let us know the bug id? Then we'll take a closer look at it.
    Thanks!
     
    eveinc likes this.
  4. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    11,428
    It's happening inside the physics callback from the look of it, not inside physics itself from a cursory look. I do see a lot of JobTempAlloc messages beforehand:

    Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
    Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
    Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
    Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
    Internal: JobTempAlloc has allocations that are more than 4 frames old - this is not allowed and likely a leak
    Crash!!!

    You'll need to submit a bug report though. For your investigation, I'd see if removing work in those callbacks still results in the same issue. Of course doing that might indirectly affect it too.
     
  5. cryothink

    cryothink

    Joined:
    Dec 21, 2022
    Posts:
    2
    Thanks for the reply! i already fixed it. the problem is caused by multiple threads trying to access an already disposed native container (not unsafe container), i'm surprised that it doesn't throw any disposed exceptions in the editor or development builds and just end up crashing in builds.
     
    MelvMay likes this.
  6. tzxbbo

    tzxbbo

    Joined:
    Dec 14, 2019
    Posts:
    98
    Hi, Could you please elaborate on how you find out the real cause of it, I'm suffering from the same bug right now, I'm using unitask and zenject in my project, what do you mean by "disposed native container" , is that a zenject container or something?
     
    tural_ likes this.
  7. tural_

    tural_

    Joined:
    Aug 22, 2022
    Posts:
    1
    EDIT: I began to experience this typical crashes on Lenovo and Dell again.

    Furthermore,

    I've included another (3rd) device to the test list. HP 8Gb RAM, i5-10300H, Intel UHD Graphics 630, in which my 3D game crashed also.

    In general, when the game has less CPU, RAM, GPU and Power usage, then game lasts a bit longer, comparing the one dominated with high poly objects etc.


    I am calling this "random", and now, thinking about switching the software sadly.

    OLD:
    I had same crash too. Here is my experience and the solution that worked for me:

    After 50 built test of my 3D side-scroller game project in 2 laptops, results were:
    Development built: no crash 5 out of 5 tests (between 10 - 30 minutes of playing, but game was laggy)
    Built: in 42 out of 45 tests, game crashed in first few minutes, sometimes in the first 10 seconds after starting.
    Only on 2-3 occasions, game lasted around 10 minutes without any crash.

    But, I noticed that around 70% of crashes happened in 2 locations. And these locations were right and left border of Occlusion Culling area of water/river object (180k tris, 130 batches effect based on stats) that rendered fully (unlike terrain) when enters into occlusion area (When Player approaches to that water, game gradually becomes more laggy in development built, and in normal built, most of the time game crashed when Player is about to enter or leave occlusion rendering area of water).
    Deleted that water object and since then, game performs without crashes.

    After seeing sudden spikes in CPU usage in Profiler analysis, (which was Garbage Collector) enabled "use incremental GC" from Project settings/Player under Configuration parameters, have not encountered any lag since. Not sure it has any contribution to this crash solution.

    Laptops are:
    Dell G3 i5-10300, 8GB RAM, GTX1650 OS: Windows 10
    Lenovo Yoga 7 14ITL5, i5-1135G7, 16GB RAM, OS: Windows 10


    Attached one of my crash report for reference.
     

    Attached Files:

    Last edited: Mar 15, 2023