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 are updating our Terms of Service for all Unity subscription plans, effective October 13, 2022, to create a more streamlined, user-friendly set of terms. Please review them here: unity.com/legal/terms-of-service.
    Dismiss Notice
  3. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice

Question Understanding native crashes and symbols with StackTrace Utility

Discussion in 'Android' started by Suduckgames, Sep 16, 2020.

  1. Suduckgames

    Suduckgames

    Joined:
    Nov 28, 2016
    Posts:
    210
    Hi there. I have a game in production with firebase crashlytics and I am trying to understand what happened in order to report the bug to Unity. I have the symbols and I have used the StackTrace Utility to resolve the crash.

    The problem is that I only have the symbols of libUnity.so and I am unable to recover the full stack trace.


    Is any way that I can get the full crash?
    Also, I am getting some non-fatal errors from my game but the line of the crash is not indicated. Is any way that I can see the line of the error?

    I am using IL2CPP scripting backend

    For example this crash:


    Code (CSharp):
    1. Caused by java.lang.Error: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
    2. Version '2019.4.9f1 (50fe8a171dd9)', Build type 'Release', Scripting Backend 'il2cpp', CPU 'armeabi-v7a'
    3. Build fingerprint: 'motorola/falcon_amxbr_ds/falcon_umtsds:4.4.4/KXB21.14-L1.40/37:user/release-keys'
    4. Revision: 'p3c0'
    5. ABI: 'arm'
    6. Timestamp: 2020-09-05 12:13:25-0300
    7. pid: 19491, tid: 19595, name: UnityGfxDeviceW  >>> com.suduck.upgradethegame4 <<<
    8. uid: 10110
    9. signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x3b
    10. Cause: null pointer dereference
    11.     r0  ffffffff  r1  6766a6bc  r2  00000003  r3  00000000
    12.     r4  6766a6e0  r5  7b8a08a8  r6  00000001  r7  0000005b
    13.     r8  00000002  r9  00000001  r10 00000000  r11 00000000
    14.     ip  00000000  sp  6766a5f0  lr  66419f41  pc  66416d64
    15.  
    16. backtrace:
    17.       #00 pc 000b5d64  /system/vendor/lib/libsc-a3xx.so
    18.       #01 pc 000b8f3d  /system/vendor/lib/libsc-a3xx.so
    19.       #02 pc 000ba073  /system/vendor/lib/libsc-a3xx.so
    20.       #03 pc 000bb1c1  /system/vendor/lib/libsc-a3xx.so
    21.       #04 pc 000fb9cf  /system/vendor/lib/libsc-a3xx.so
    22.       #05 pc 000b5635  /system/vendor/lib/libsc-a3xx.so
    23.       #06 pc 000f8237  /system/vendor/lib/libsc-a3xx.so
    24.       #07 pc 000b5635  /system/vendor/lib/libsc-a3xx.so
    25.       #08 pc 000ed405  /system/vendor/lib/libsc-a3xx.so
    26.       #09 pc 000fdda1  /system/vendor/lib/libsc-a3xx.so
    27.       #10 pc 000b5635  /system/vendor/lib/libsc-a3xx.so
    28.       #11 pc 000ed405  /system/vendor/lib/libsc-a3xx.so
    29.       #12 pc 000fdda1  /system/vendor/lib/libsc-a3xx.so
    30.       #13 pc 000b5635  /system/vendor/lib/libsc-a3xx.so
    31.       #14 pc 000fa70f  /system/vendor/lib/libsc-a3xx.so
    32.       #15 pc 000fdf2d  /system/vendor/lib/libsc-a3xx.so
    33.       #16 pc 000b5635  /system/vendor/lib/libsc-a3xx.so
    34.       #17 pc 000ed405  /system/vendor/lib/libsc-a3xx.so
    35.       #18 pc 000fdda1  /system/vendor/lib/libsc-a3xx.so
    36.       #19 pc 000b5635  /system/vendor/lib/libsc-a3xx.so
    37.       #20 pc 000bda69  /system/vendor/lib/libsc-a3xx.so
    38.       #21 pc 000d8cd5  /system/vendor/lib/libsc-a3xx.so
    39.       #22 pc 000e8c55  /system/vendor/lib/libsc-a3xx.so
    40.       #23 pc 000ebae1  /system/vendor/lib/libsc-a3xx.so
    41.       #24 pc 00060909  /system/vendor/lib/egl/libGLESv2_adreno.so (core_glCompileShader+348)
    42.       #25 pc 00041b73  /system/vendor/lib/egl/libGLESv2_adreno.so (glCompileShader+16)
    43.       #26 pc 002b5368  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    44.       #27 pc 002b3a84  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    45.       #28 pc 002b2c50  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    46.       #29 pc 00423cfc  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    47.       #30 pc 0069025b  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    48.       #31 pc 006a2855  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    49.       #32 pc 006a55cb  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    50.       #33 pc 0069e457  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    51.       #34 pc 001f94f7  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    52.       #35 pc 0000d298  /system/lib/libc.so (__thread_entry+72)
    53.       #36 pc 0000d430  /system/lib/libc.so (pthread_create+240)
    54.  
    55.        at libsc-a3xx.0xb5d64()
    56.        at libsc-a3xx.0xb8f3d()
    57.        at libsc-a3xx.0xba073()
    58.        at libsc-a3xx.0xbb1c1()
    59.        at libsc-a3xx.0xfb9cf()
    60.        at libsc-a3xx.0xb5635()
    61.        at libsc-a3xx.0xf8237()
    62.        at libsc-a3xx.0xb5635()
    63.        at libsc-a3xx.0xed405()
    64.        at libsc-a3xx.0xfdda1()
    65.        at libsc-a3xx.0xb5635()
    66.        at libsc-a3xx.0xed405()
    67.        at libsc-a3xx.0xfdda1()
    68.        at libsc-a3xx.0xb5635()
    69.        at libsc-a3xx.0xfa70f()
    70.        at libsc-a3xx.0xfdf2d()
    71.        at libsc-a3xx.0xb5635()
    72.        at libsc-a3xx.0xed405()
    73.        at libsc-a3xx.0xfdda1()
    74.        at libsc-a3xx.0xb5635()
    75.        at libsc-a3xx.0xbda69()
    76.        at libsc-a3xx.0xd8cd5()
    77.        at libsc-a3xx.0xe8c55()
    78.        at libsc-a3xx.0xebae1()
    79.        at libGLESv2_adreno.core_glCompileShader(core_glCompileShader:348)
    80.        at libGLESv2_adreno.glCompileShader(glCompileShader:16)
    81.        at libunity.0x2b5368()
    82.        at libunity.0x2b3a84()
    83.        at libunity.0x2b2c50()
    84.        at libunity.0x423cfc()
    85.        at libunity.0x69025b()
    86.        at libunity.0x6a2855()
    Is converted into this


    Code (CSharp):
    1. Caused by java.lang.Error: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
    2. Version '2019.4.9f1 (50fe8a171dd9)', Build type 'Release', Scripting Backend 'il2cpp', CPU 'armeabi-v7a'
    3. Build fingerprint: 'motorola/falcon_amxbr_ds/falcon_umtsds:4.4.4/KXB21.14-L1.40/37:user/release-keys'
    4. Revision: 'p3c0'
    5. ABI: 'arm'
    6. Timestamp: 2020-09-05 12:13:25-0300
    7. pid: 19491, tid: 19595, name: UnityGfxDeviceW  >>> com.suduck.upgradethegame4 <<<
    8. uid: 10110
    9. signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x3b
    10. Cause: null pointer dereference
    11.     r0  ffffffff  r1  6766a6bc  r2  00000003  r3  00000000
    12.     r4  6766a6e0  r5  7b8a08a8  r6  00000001  r7  0000005b
    13.     r8  00000002  r9  00000001  r10 00000000  r11 00000000
    14.     ip  00000000  sp  6766a5f0  lr  66419f41  pc  66416d64
    15. backtrace:
    16.       #00 pc 000b5d64 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    17.       #01 pc 000b8f3d (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    18.       #02 pc 000ba073 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    19.       #03 pc 000bb1c1 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    20.       #04 pc 000fb9cf (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    21.       #05 pc 000b5635 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    22.       #06 pc 000f8237 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    23.       #07 pc 000b5635 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    24.       #08 pc 000ed405 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    25.       #09 pc 000fdda1 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    26.       #10 pc 000b5635 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    27.       #11 pc 000ed405 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    28.       #12 pc 000fdda1 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    29.       #13 pc 000b5635 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    30.       #14 pc 000fa70f (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    31.       #15 pc 000fdf2d (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    32.       #16 pc 000b5635 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    33.       #17 pc 000ed405 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    34.       #18 pc 000fdda1 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    35.       #19 pc 000b5635 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    36.       #20 pc 000bda69 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    37.       #21 pc 000d8cd5 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    38.       #22 pc 000e8c55 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    39.       #23 pc 000ebae1 (libsc-a3xx.so not found)  /system/vendor/lib/libsc-a3xx.so
    40.       #24 pc 00060909 (libGLESv2_adreno.so not found)  /system/vendor/lib/egl/libGLESv2_adreno.so (core_glCompileShader+348)
    41.       #25 pc 00041b73 (libGLESv2_adreno.so not found)  /system/vendor/lib/egl/libGLESv2_adreno.so (glCompileShader+16)
    42.       #26 pc 002b5368 (ComputeShader::SetBufferParam(unsigned int, ShaderLab::FastPropertyName const&, ComputeBufferID, bool) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    43.       #27 pc 002b3a84 (CachedWriter::SetPosition(unsigned long) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    44.       #28 pc 002b2c50 (FileCacherRead::Request(int, int, FileCacherRead::CacheBlock&, bool) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    45.       #29 pc 00423cfc (vk::Texture::UseTexture(vk::CommandBuffer*, unsigned int, VkSampler_T*) const at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    46.       #30 pc 0069025b (void mecanim::animation::BlendTreeNodeConstant::Transfer<SafeBinaryRead>(SafeBinaryRead&) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    47.       #31 pc 006a2855 (mecanim::animation::InitializeMuscleClipTables() at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    48.       #32 pc 006a55cb (mecanim::animation::EvaluateRootMotion(mecanim::animation::ClipMuscleConstant const&, mecanim::animation::ClipMuscleInput const&, float const*, float const*, mecanim::animation::GenericRootXReference const*, mecanim::animation::MotionOutput&, mecanim::animation::MotionXReference&, bool, bool, bool) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    49.       #33 pc 0069e457 (std::__ndk1::vector<SkeletonBone, std::__ndk1::allocator<SkeletonBone> >::__append(unsigned long) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    50.       #34 pc 001f94f7 (GUITexture::SetVPTransformAndInverse(Matrix4x4f const&, Matrix4x4f) at ??:?)  /data/app-lib/com.suduck.upgradethegame4-1/libunity.so (BuildId: 034c1c887095044b760fc512f48aa609f781b91a)
    51.       #35 pc 0000d298 (libc.so not found)  /system/lib/libc.so (__thread_entry+72)
    52.       #36 pc 0000d430 (libc.so not found)  /system/lib/libc.so (pthread_create+240)
    53.        at libsc-a3xx.0xb5d64()
    54.        at libsc-a3xx.0xb8f3d()
    55.        at libsc-a3xx.0xba073()
    56.        at libsc-a3xx.0xbb1c1()
    57.        at libsc-a3xx.0xfb9cf()
    58.        at libsc-a3xx.0xb5635()
    59.        at libsc-a3xx.0xf8237()
    60.        at libsc-a3xx.0xb5635()
    61.        at libsc-a3xx.0xed405()
    62.        at libsc-a3xx.0xfdda1()
    63.        at libsc-a3xx.0xb5635()
    64.        at libsc-a3xx.0xed405()
    65.        at libsc-a3xx.0xfdda1()
    66.        at libsc-a3xx.0xb5635()
    67.        at libsc-a3xx.0xfa70f()
    68.        at libsc-a3xx.0xfdf2d()
    69.        at libsc-a3xx.0xb5635()
    70.        at libsc-a3xx.0xed405()
    71.        at libsc-a3xx.0xfdda1()
    72.        at libsc-a3xx.0xb5635()
    73.        at libsc-a3xx.0xbda69()
    74.        at libsc-a3xx.0xd8cd5()
    75.        at libsc-a3xx.0xe8c55()
    76.        at libsc-a3xx.0xebae1()
    77.        at libGLESv2_adreno.core_glCompileShader(core_glCompileShader:348)
    78.        at libGLESv2_adreno.glCompileShader(glCompileShader:16)
    79.        at libunity.0x2b5368()
    80.        at libunity.0x2b3a84()
    81.        at libunity.0x2b2c50()
    82.        at libunity.0x423cfc()
    83.        at libunity.0x69025b()
    84.        at libunity.0x6a2855()
    85.  
     
  2. Seraphim-Whiteless

    Seraphim-Whiteless

    Joined:
    Jun 23, 2014
    Posts:
    197
    yep. Hi dear friend.
    You need to upload sym-file to firebase console. And get alredy translated report

    or locally ...

    you can decode address to line with this or this

    tryed it on ios. Works good

    PS
    good games ;)
     
    Last edited: Sep 17, 2020
  3. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,182
    Judging from stacktrace, I am not sure if you used correct libunity symbol file. Here's a small doc explaining where is correct libunity symbol file is placed. https://docs.unity3d.com/Packages/com.unity.mobile.android-logcat@1.2/manual/StacktraceUtility.html

    I am guessing you had Strip Engine Code set to true, thus libunity.so symbols should have end up in symbols.zip file which is placed next to your apk.

    as for symbols for libsc-a3xx.so, I am not sure if you can decode functions there, since those are system libraries.
     
  4. Suduckgames

    Suduckgames

    Joined:
    Nov 28, 2016
    Posts:
    210
    Thanks for the answer, I have Strip Engine Code set to true.

    As far as I know, I am using the correct libunity symbol file. I have two targets (ARMv7 and ARM64) so the symbols are in a zip and separated for each architectures.

    Since the stack trace that I have shown is ARMv7 I am using those symbols (libunity.sym.so, libil2cpp.sym.so, libil2cpp.dbg.so for ARMv7).

    Maybe I am not explaining myself correctly.

    This kind of crash seems to happen in the Unity part ( since there is not pointer to my code but rather to c++ animator code). Is this a bug to report to Unity? Or this can be cause by my code?
     
  5. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,182
    Since it crashes in GPU driver library, it's probably a driver bug. If you have repro project showing this issue, yes the bug report would be very welcomed, at the very least it might help us to make a fix or workaround
     
unityunity