Search Unity

  1. Unity 2020.2 has been released.
    Dismiss Notice
  2. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Android 11 Il2Cpp Arm64 Crash in Unity LTS 2019.4.12f1

Discussion in 'Android' started by teatime_johann, Oct 12, 2020.

  1. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    Summary:
    • There seem to be frequent memory crashes on Android phones running Android 11, effectively bricking our app on these phones.
    • The crash seems to be reproducible in Unity LTS Release 2019.4.12f1 in an empty project if using il2cpp and arm64 and run on HWAsan enabled Android 11 on Pixel 3A XL. See the attached project and APK.
    For the last weeks, we’ve been exploring a memory crash on Android 11 that happens soon as Unity renders its first frame. The crash log (attached crash: Android11pixel2xl-OurApp-crash.log) points towards the new Scudo Hardened Memory Allocator released in Android 11. We've seen multiple stack traces so the app doesn't crash at exactly the same time every time, but roughly as soon as we load the first scene.

    The documentation from Google suggests that running a Hardware Address Sanitizer (HWASan) version of Android will help with debugging these types of memory issues. When we run our APK on an HWASan Android 11 on Pixel 3A XL it crashes as soon as it boots. (attached crash: HWASANAndroid11_Pixel3aXL_OurAppCrash-crash.log)

    After a lot of investigation, we managed to reproduce the issue using the following steps using Unity LTS Release 2019.4.12f1:
    • Create an empty 3D project
    • Change the Android player settings to use il2cpp and arm64
    • Build and Run on an Android phone flashed with HWASan Android 11.
    • Notice that the app crashes on start with the attached crash log (attached crash: HWASANAndroid11_Pixel3aXL_LTSEmptyIL2CPPArm64-crash.log) (E/Unity: Using memoryadresses from more than 16GB of memory)

    This makes us believe that this is an issue with il2cpp and arm64 and not specific to our setup.

    Additional info:
    • The issue is not specific to Android 11 but is much easier to reproduce on that OS because of Scudo. We’ve seen crash logs on Android 9 and Android 10 but have always been unable to reproduce until now.
    • We were unable to flash HWAsan Android 11 to Pixel 2 XL but have been able to reproduce the crash on factory Android 11 on Pixel 2 XL, Pixel 3A XL, and Pixel 4 XL
    • An empty project does NOT crash if using Mono or IL2CPP and only armv7

    This is of high urgency for us (and we believe for Unity as well) as Google has started rolling out Android 11 and Google Play started enforcing arm64 in August 2019 so reverting to mono or armv7 is not an option for us.

    Can someone confirm this issue? Is it being worked on or are we making some wrong assumptions?
     

    Attached Files:

  2. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    I don't think I saw such this issue reported anywhere, please report a bug via Unity Editor, Help->Report Bug with detailed repro steps + repro project.

    Thank you
     
  3. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    Thank you @Thomas1856. I've submitted a bug report.
    Thank you Tomas. I've submitted a bug report.
     
  4. mvaz_p

    mvaz_p

    Joined:
    Aug 22, 2018
    Posts:
    39
    Something like this seems to be happening with our Pixel 4 too, but it goes away when the phone is restarted.
    The same message "Using memoryadresses from more than 16GB of memory" appears, but we haven't been able to reproduce it.
     
    teatime_johann likes this.
  5. tapan_unity

    tapan_unity

    Joined:
    Aug 8, 2019
    Posts:
    1
    Hi,

    We have been looking into this issue for the past week. We have been able to consistently reproduce this crash on a specific project with different stack traces every time.

    We have tried multiple Unity Installs: 2019.4.1f1, 2019.4.11f1, 2020.1.8f1, 2018.4.15f1 (We were only able to repro on 2018 once).

    Generally it crashes at startup, <10% of sessions on Android 11 Pixel-2XL have managed to get past the startup stage.
    Can confirm it’s an issue with only il2cpp and arm64 player settings, rest seem to be working fine for us.
    The stack trace isn’t consistent enough, cannot confirm if it is easier to repro on Scudo. (Attached crash log for factory Android11 Pixel 2XL).

    According to crashlytics it mostly on Android11, we have only seen one similar crash; which is on Android10.
    Thanks
     

    Attached Files:

  6. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    Could you copy paste or send me a case number ? Thank you!
     
  7. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    I've sent you it in a private message
     
  8. act10n

    act10n

    Joined:
    Mar 15, 2013
    Posts:
    6
    same here, up
     
  9. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    If you have a stable repro, please submit a bug with steps + project attached. We're still having trouble reproducing this on our side.
     
  10. act10n

    act10n

    Joined:
    Mar 15, 2013
    Posts:
    6
    We are testing it in amazon device farm, the most crash rate was on Google Pixel 4
    If it is possible, you can check our project unity crash and exceptions (crashes from real users from production UPID: 771605e7-3831-410d-b0fd-4256a326c653) upload_2020-10-14_15-12-29.png upload_2020-10-14_15-11-20.png upload_2020-10-14_15-14-13.png
     
    Last edited: Oct 14, 2020
    teatime_johann likes this.
  11. cryptoad

    cryptoad

    Joined:
    Oct 14, 2020
    Posts:
    1
  12. pro_psg

    pro_psg

    Joined:
    May 18, 2017
    Posts:
    4
    Yes, but this issue seems to have surfaced back with the release of Android 11. Our application is registering the majority of these crashes on Pixel devices, but that is also due to the fact that Android 11 has just started rolling out and is currently available for all Pixel devices. This error usually comes post starting the application, post which the application freezes, and finally crashes. This started happening for me on 2019.4.1f1, and updating to 2019.4.12f1 did not resolve anything for me either.
     
  13. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    @cryptoad The NativeParticleSystem repo that you are linking to - is that code that is now part of Unity? The lead looks promising as we're using the Particle System in Unity but not this repository.
     
  14. act10n

    act10n

    Joined:
    Mar 15, 2013
    Posts:
    6
    with targetsdkversion 29 - no crashes, probably this issue only happens with target sdk 30
     
  15. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    We're currently on sdk 28 with our app but have also tried with sdk 30 and did not see any difference - crashes in both situations.
     
  16. mvaz_p

    mvaz_p

    Joined:
    Aug 22, 2018
    Posts:
    39
    Our crashes are happening with target sdk 29.
     
    unity_BUIockkbCwDQ9w likes this.
  17. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
  18. mvaz_p

    mvaz_p

    Joined:
    Aug 22, 2018
    Posts:
    39
    Any updates or workarounds for this?
     
  19. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    eladleb4, RLin and mvaz_p like this.
  20. RLin

    RLin

    Joined:
    May 10, 2015
    Posts:
    117
    Getting lots of negative reviews from Android 11 users who are experiencing the crash. For many players, the game is entirely unplayable; the game crashes before the first loading screen even shows up. I really hope that Unity provides a fix for this soon.

    I'm pretty frustrated with this since I thought there was a problem in my own code that caused a sudden massive spike in crash reports over the past month, but it turns out Unity Engine is just broken right now.
     
    StudioZooka and eladleb4 like this.
  21. ol1ph4nt

    ol1ph4nt

    Joined:
    Jun 29, 2016
    Posts:
    2
    I seem to be running into the same issue.
    Our game crashes regularly on startup.
    We are on 2019.4.12f1 and running the game on a Pixel 2 / Android 11.

    In our case, the game crashes consistently on startup if interacting with the phone.
    If we let the game run for about 10 sec before starting to interact with it, the game runs fine and won't crash anymore.
     
  22. Yury-Habets

    Yury-Habets

    Unity Technologies

    Joined:
    Nov 18, 2013
    Posts:
    1,107
    Using HWAsan on a public Unity version won't bring you anywhere; it will crash on startup but that's not an indication of an issue.
    It requires NDK r21+ (which will be used in 2021.1) and compiling the engine with few additional flags, plus hacks to the Unity's MemoryManager, so not really usable without source code modification.

    However, Android 11 memory issue is not related to HWAsan and will be looked into ASAP.
     
    teatime_johann likes this.
  23. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    Thanks for the update @Yury-Habets. Is there anything that we can do to help? I.e. submit a bug report from our actual app for a constantly reproducable app? Or do you have a reproducible case on Android 11 that you are investigating?
    Any possible mitigations that you've uncovered in your investigation?
     
  24. ol1ph4nt

    ol1ph4nt

    Joined:
    Jun 29, 2016
    Posts:
    2
    A follow up in our case.

    We have a temporary workaround that allow us to run our game with no crash if we disable the ARMv64 version for Android.

    Hope to see the ARMv64 version fixed soon.
     
  25. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    Hi,

    A bug report with Unity project attached which shows this issue on normal Android 11 build (not Aosp build) would be very welcomed.
     
  26. Yury-Habets

    Yury-Habets

    Unity Technologies

    Joined:
    Nov 18, 2013
    Posts:
    1,107
    @teatime_johann as @Tomas1856 said, we'd appreciate a bug report with an actual project. I just tested an empty app (arm64+il2cpp) on a Pixel3XL with a stock Android 11, with no crash.
     
  27. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    @Tomas1856 and @Yury-Habets I'll try to send over a bug report with an actual project later today.

    I'm however also curious if you've stopped exploring the HWAsan on Android 11 crash. I understand that it won't be supported to create an HWAsan build of Unity until NDK 21+ hits Unity main (2021.1) but it still feels suspicious that an empty project would crash only on Arm64 + IL2CPP on HWAsan but not on Armv7 + IL2CPP or mono. Did that investigation uncover any hints on where the root cause might lie?
     
  28. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    There is a reason, HWAsan uses higher pointer bits for its purposes, and that confused internal memory allocator in Unity, since it also uses some of the high bits for book keeping purposes. Long story short, Unity's internal memory allocator mistakenly started to assume that more than 16 GB of memory is being used while in reality those were simply tags used by HWAsan.

    Nevertheless, it seems due allocator changes in Android 11 to Scudo, even without using HWAsan, the 16GB error occurs. Our QA currently trying to reproduce this on factory Android builds, once this done, we'll be sure that our fix will apply both for factory and aosp builds.

    Our preliminary fix most likely be to switch to a different internal Unity allocator which doesn't use high bits, but it also uses a different way of allocating memory, by using blocks. That also means that HWAsan might not be able to correctly show the origin of allocation at least for internal Unity allocations, it will still continue to work fine for external allocations though.
     
    tonialatalo likes this.
  29. teatime_johann

    teatime_johann

    Joined:
    Aug 14, 2018
    Posts:
    11
    Thank you @Thomas1856 for a very thorough and helpful answer. What you are saying aligns with all of the stack traces we've seen.

    I, however, have a hard time creating a minimal project that crashes on factory Android 11. Does someone else in this thread have such a project that they could report to Unity?
     
  30. a-to-z-27

    a-to-z-27

    Joined:
    Oct 11, 2017
    Posts:
    2
    The annoying part of this issue is that rebooting the device usually eliminates the problem. Also, the timing of the occurrence seems to be focused on loading scenes and resources. Could there be a fundamental incompatibility with Android 11's memory management?
     
    akshayPlaySimple likes this.
  31. Aleksey1919

    Aleksey1919

    Joined:
    Oct 24, 2020
    Posts:
    2
    Hi. In our project this crash exist too. It happens when we call "UnityEngine.AssetBundle:LoadAllAssets()" or "UnityEngine.AssetBundle:LoadAsset()" or "UnityEngine.AssetBundle.LoadFromFile()". The crash is reproduced with a probability of 75%-90%, but only if IronSource with Admob mediation in the project and inited. In an empty project with IS, we were unable to reproduce crash.

    I have selected the important from the tracelog:
    10-20 17:13:19.492: E/Unity(21618): Using memoryadresses from more that 16GB of memory
    10-20 17:13:19.492: E/Unity(21618): UnityEngine.AssetBundle:LoadAsset(String)
    ...
    10-20 17:13:19.492: D/Unity(21618): Allocator(ALLOC_DEFAULT).Allocate (0x0x7afe448050): 337672 Total: 67.24MB (70505608) in ./Runtime/Utilities/dynamic_array.h:75
    10-20 17:13:19.492: D/Unity(21618): Allocator(ALLOC_DEFAULT).Allocate (0x0x7cfda7aca0): 4 Total: 67.24MB (70505612) in Overloaded New:0
    10-20 17:13:19.492: D/Unity(21618): Allocator(ALLOC_DEFAULT).Deallocate (0x0x7e0d6de940): - 3072 Total: 67.24MB (70505612)
    10-20 17:13:19.492: D/Unity(21618): Allocator(ALLOC_DEFAULT).Allocate (0x0x7d0d804f50): 23 Total: 67.24MB (70502563) in ./Runtime/Core/Containers/StringStorageDefault.h:289
    ...
    //Further similar lines.
    ...
    10-20 17:13:19.526: I/scudo(21618): Scudo ERROR: corrupted chunk header at address 0x007afe448050
    ...
    10-20 17:13:19.714: E/CRASH(21618): signal 6 (SIGABRT), code -6 (?), fault addr --------
    10-20 17:13:19.714: E/CRASH(21618): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
    10-20 17:13:19.714: E/CRASH(21618): Build type 'Development', Scripting Backend 'il2cpp', CPU 'arm64-v8a'
    10-20 17:13:19.714: E/CRASH(21618): Build fingerprint: 'google/coral/coral:11/RP1A.200720.009/6720564:user/release-keys'
    10-20 17:13:19.714: E/CRASH(21618): Revision: 'MP1.0'
    10-20 17:13:19.714: E/CRASH(21618): pid: 21618, tid: 21651, name: MAIN_THREAD >>> com.company.test <<<
    10-20 17:13:19.714: E/CRASH(21618): x0 0000000000000000 x1 0000000000005493 x2 0000000000000006 x3 0000007c5f8c8d20
    10-20 17:13:19.714: E/CRASH(21618): x4 0000000000008080 x5 0000000000008080 x6 0000000000008080 x7 0000000000000038
    10-20 17:13:19.714: E/CRASH(21618): x8 00000000000000f0 x9 ba00eb98fc51030e x10 0000000000000000 x11 ffffffc0fffffbdf
    10-20 17:13:19.714: E/CRASH(21618): x12 0000000000000001 x13 0000278405ea5256 x14 001f11519cb66af2 x15 0000000009da3c6c
    10-20 17:13:19.714: E/CRASH(21618): x16 0000007f61500c80 x17 0000007f614e23b0 x18 0000000068833ac5 x19 0000000000005472
    10-20 17:13:19.714: E/CRASH(21618): x20 0000000000005493 x21 00000000ffffffff x22 0000007afe448050 x23 0000007c5e096000
    10-20 17:13:19.714: E/CRASH(21618): x24 0000007c5df8b628 x25 00000000000000ff x26 0000000000000000 x27 0000000000000000
    10-20 17:13:19.714: E/CRASH(21618): x28 0000000000000000 x29 0000007c5f8c8da0 x30 0000007f61495e20
    10-20 17:13:19.714: E/CRASH(21618): sp 0000007c5f8c8d00 pc 0000007f61495e4c pstate 0000000000000000
    10-20 17:13:19.714: E/CRASH(21618): backtrace:
    10-20 17:13:19.764: E/CRASH(21618): #00 pc 00000000000007c4 [vdso] ()
    10-20 17:13:19.764: E/CRASH(21618): #01 pc 0000000000012e48 /apex/com.android.runtime/lib64/bionic/libc.so (abort+160)
    10-20 17:13:19.764: E/CRASH(21618): #02 pc 0000000000007910 /apex/com.android.runtime/lib64/bionic/libc.so (_ZN5scudo3dieEv+8)
    10-20 17:13:19.764: E/CRASH(21618): #03 pc 0000000000007f88 /apex/com.android.runtime/lib64/bionic/libc.so (_ZN5scudo17ScopedErrorReportD2Ev+32)
    10-20 17:13:19.764: E/CRASH(21618): #04 pc 0000000000008050 /apex/com.android.runtime/lib64/bionic/libc.so (_ZN5scudo22reportHeaderCorruptionEPv+60)
    10-20 17:13:19.764: E/CRASH(21618): #05 pc 00000000000095c0 /apex/com.android.runtime/lib64/bionic/libc.so (_ZN5scudo9AllocatorINS_13AndroidConfigEXadL_Z21scudo_malloc_postinitEEE10deallocateEPvNS_5Chunk6OriginEmm+328)
    10-20 17:13:19.764: E/CRASH(21618): #06 pc 00000000007391a8 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN13MemoryManager10DeallocateEPv+392)
    10-20 17:13:19.764: E/CRASH(21618): #07 pc 00000000007389c8 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN13MemoryManager10DeallocateEPvRK10MemLabelId+344)
    10-20 17:13:19.764: E/CRASH(21618): #08 pc 0000000000b17b6c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN13dynamic_arrayIhLm4EE13clear_deallocEv+28)
    10-20 17:13:19.764: E/CRASH(21618): #09 pc 000000000123495c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN6Shader20CreateFromParsedFormEv+248)
    10-20 17:13:19.764: E/CRASH(21618): #10 pc 0000000001234ae4 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN6Shader17CreateAndPostLoadEv+20)
    10-20 17:13:19.764: E/CRASH(21618): #11 pc 0000000001234ab0 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN6Shader13AwakeFromLoadE17AwakeFromLoadMode+36)
    10-20 17:13:19.764: E/CRASH(21618): #12 pc 0000000000ce48cc /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode+184)
    10-20 17:13:19.764: E/CRASH(21618): #13 pc 0000000000ce6d1c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager27IntegrateAllThreadedObjectsEv+92)
    10-20 17:13:19.764: E/CRASH(21618): #14 pc 0000000000ce7684 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager38LoadAndIntegrateAllPreallocatedObjectsENS_9LockFlagsE+80)
    10-20 17:13:19.764: E/CRASH(21618): #15 pc 0000000000ce7afc /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager10ReadObjectEi17AwakeFromLoadMode+252)
    10-20 17:13:19.764: E/CRASH(21618): #16 pc 0000000000559a20 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZNK4PPtrI6ShaderEcvPS0_Ev+92)
    10-20 17:13:19.764: E/CRASH(21618): #17 pc 0000000000b17330 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_Z19FindShaderLabShaderRKN4core12basic_stringIcNS_20StringStorageDefaultIcEEEERSt6vectorI4PPtrI6ShaderESaIS9_EEb+144)
    10-20 17:13:19.764: E/CRASH(21618): #18 pc 0000000000b3b41c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN9ShaderLab9IntShader15ResolveFallbackERKNS_16SerializedShaderEP6ShaderRSt6vectorI4PPtrIS4_ESaIS8_EEb+48)
    10-20 17:13:19.764: E/CRASH(21618): #19 pc 0000000000b1490c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN9ShaderLab9IntShader26CreateFromSerializedShaderERKNS_16SerializedShaderERSt6vectorI4PPtrI6ShaderESaIS7_EEbPS6_+932)
    10-20 17:13:19.764: E/CRASH(21618): #20 pc 0000000000b16dc0 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_Z26ShaderFromSerializedShaderPKN9ShaderLab16SerializedShaderERSt6vectorI4PPtrI6ShaderESaIS6_EEbPS5_+36)
    10-20 17:13:19.764: E/CRASH(21618): #21 pc 0000000001234934 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN6Shader20CreateFromParsedFormEv+208)
    10-20 17:13:19.764: E/CRASH(21618): #22 pc 0000000001234ae4 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN6Shader17CreateAndPostLoadEv+20)
    10-20 17:13:19.764: E/CRASH(21618): #23 pc 0000000001234ab0 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN6Shader13AwakeFromLoadE17AwakeFromLoadMode+36)
    10-20 17:13:19.764: E/CRASH(21618): #24 pc 0000000000ce48cc /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode+184)
    10-20 17:13:19.764: E/CRASH(21618): #25 pc 0000000000ce6d1c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager27IntegrateAllThreadedObjectsEv+92)
    10-20 17:13:19.764: E/CRASH(21618): #26 pc 0000000000ce7684 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager38LoadAndIntegrateAllPreallocatedObjectsENS_9LockFlagsE+80)
    10-20 17:13:19.764: E/CRASH(21618): #27 pc 0000000000ce7afc /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager10ReadObjectEi17AwakeFromLoadMode+252)
    10-20 17:13:19.764: E/CRASH(21618): #28 pc 0000000000559a20 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZNK4PPtrI6ShaderEcvPS0_Ev+92)
    10-20 17:13:19.764: E/CRASH(21618): #29 pc 0000000000b22974 /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN8Material15BuildPropertiesEv+56)
    10-20 17:13:19.764: E/CRASH(21618): #30 pc 0000000000ce48cc /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode+184)
    10-20 17:13:19.764: E/CRASH(21618): #31 pc 0000000000ce6d1c /data/app/~~O9Ts74mTt4nx0i2Hp0OCqQ==/com.company.test-ETR3SPl5m8XhhvxUxcYIlA==/lib/arm64/libunity.so (_ZN17PersistentManager27IntegrateAllThreadedObjectsEv+92)
    10-20 17:13:19.765: E/MessageQueue(21618): IdleHandler threw exception
    10-20 17:13:19.765: E/MessageQueue(21618): java.lang.Error: signal 6 (SIGABRT), code -6 (?), fault addr --------
    10-20 17:13:19.765: E/MessageQueue(21618): Build fingerprint: 'google/coral/coral:11/RP1A.200720.009/6720564:user/release-keys'
    10-20 17:13:19.765: E/MessageQueue(21618): Revision: 'MP1.0'
    10-20 17:13:19.765: E/MessageQueue(21618): pid: 21618, tid: 21651, name: MAIN_THREAD >>> com.company.test <<<
    10-20 17:13:19.765: E/MessageQueue(21618): x0 0000000000000000 x1 0000000000005493 x2 0000000000000006 x3 0000007c5f8c8d20
    10-20 17:13:19.765: E/MessageQueue(21618): x4 0000000000008080 x5 0000000000008080 x6 0000000000008080 x7 0000000000000038
    10-20 17:13:19.765: E/MessageQueue(21618): x8 00000000000000f0 x9 ba00eb98fc51030e x10 0000000000000000 x11 ffffffc0fffffbdf
    10-20 17:13:19.765: E/MessageQueue(21618): x12 0000000000000001 x13 0000278405ea5256 x14 001f11519cb66af2 x15 0000000009da3c6c
    10-20 17:13:19.765: E/MessageQueue(21618): x16 0000007f61500c80 x17 0000007f614e23b0 x18 0000000068833ac5 x19 0000000000005472
    10-20 17:13:19.765: E/MessageQueue(21618): x20 0000000000005493 x21 00000000ffffffff x22 0000007afe448050 x23 0000007c5e096000
    10-20 17:13:19.765: E/MessageQueue(21618): x24 0000007c5df8b628 x25 00000000000000ff x26 0000000000000000 x27 0000000000000000
    10-20 17:13:19.765: E/MessageQueue(21618): x28 0000000000000000 x29 0000007c5f8c8da0 x30 0000007f61495e20
    10-20 17:13:19.765: E/MessageQueue(21618): sp 0000007c5f8c8d00 pc 0000007f61495e4c pstate 0000000000000000
    10-20 17:13:19.765: E/MessageQueue(21618): at [vdso].:)0)
    10-20 17:13:19.765: E/MessageQueue(21618): at libc.abort(abort:160)
    10-20 17:13:19.765: E/MessageQueue(21618): at libc._ZN5scudo3dieEv(_ZN5scudo3dieEv:8)
    10-20 17:13:19.765: E/MessageQueue(21618): at libc._ZN5scudo17ScopedErrorReportD2Ev(_ZN5scudo17ScopedErrorReportD2Ev:32)
    10-20 17:13:19.765: E/MessageQueue(21618): at libc._ZN5scudo22reportHeaderCorruptionEPv(_ZN5scudo22reportHeaderCorruptionEPv:60)
    10-20 17:13:19.765: E/MessageQueue(21618): at libc._ZN5scudo9AllocatorINS_13AndroidConfigEXadL_Z21scudo_malloc_postinitEEE10deallocateEPvNS_5Chunk6OriginEmm(_ZN5scudo9AllocatorINS_13AndroidConfigEXadL_Z21scudo_malloc_postinitEEE10deallocateEPvNS_5Chunk6OriginEmm:328)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN13MemoryManager10DeallocateEPv(_ZN13MemoryManager10DeallocateEPv:392)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN13MemoryManager10DeallocateEPvRK10MemLabelId(_ZN13MemoryManager10DeallocateEPvRK10MemLabelId:344)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN13dynamic_arrayIhLm4EE13clear_deallocEv(_ZN13dynamic_arrayIhLm4EE13clear_deallocEv:28)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN6Shader20CreateFromParsedFormEv(_ZN6Shader20CreateFromParsedFormEv:248)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN6Shader17CreateAndPostLoadEv(_ZN6Shader17CreateAndPostLoadEv:20)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN6Shader13AwakeFromLoadE17AwakeFromLoadMode(_ZN6Shader13AwakeFromLoadE17AwakeFromLoadMode:36)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode(_ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode:184)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager27IntegrateAllThreadedObjectsEv(_ZN17PersistentManager27IntegrateAllThreadedObjectsEv:92)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager38LoadAndIntegrateAllPreallocatedObjectsENS_9LockFlagsE(_ZN17PersistentManager38LoadAndIntegrateAllPreallocatedObjectsENS_9LockFlagsE:80)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager10ReadObjectEi17AwakeFromLoadMode(_ZN17PersistentManager10ReadObjectEi17AwakeFromLoadMode:252)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZNK4PPtrI6ShaderEcvPS0_Ev(_ZNK4PPtrI6ShaderEcvPS0_Ev:92)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._Z19FindShaderLabShaderRKN4core12basic_stringIcNS_20StringStorageDefaultIcEEEERSt6vectorI4PPtrI6ShaderESaIS9_EEb(_Z19FindShaderLabShaderRKN4core12basic_stringIcNS_20StringStorageDefaultIcEEEERSt6vectorI4PPtrI6ShaderESaIS9_EEb:144)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN9ShaderLab9IntShader15ResolveFallbackERKNS_16SerializedShaderEP6ShaderRSt6vectorI4PPtrIS4_ESaIS8_EEb(_ZN9ShaderLab9IntShader15ResolveFallbackERKNS_16SerializedShaderEP6ShaderRSt6vectorI4PPtrIS4_ESaIS8_EEb:48)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN9ShaderLab9IntShader26CreateFromSerializedShaderERKNS_16SerializedShaderERSt6vectorI4PPtrI6ShaderESaIS7_EEbPS6_(_ZN9ShaderLab9IntShader26CreateFromSerializedShaderERKNS_16SerializedShaderERSt6vectorI4PPtrI6ShaderESaIS7_EEbPS6_:932)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._Z26ShaderFromSerializedShaderPKN9ShaderLab16SerializedShaderERSt6vectorI4PPtrI6ShaderESaIS6_EEbPS5_(_Z26ShaderFromSerializedShaderPKN9ShaderLab16SerializedShaderERSt6vectorI4PPtrI6ShaderESaIS6_EEbPS5_:36)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN6Shader20CreateFromParsedFormEv(_ZN6Shader20CreateFromParsedFormEv:208)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN6Shader17CreateAndPostLoadEv(_ZN6Shader17CreateAndPostLoadEv:20)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN6Shader13AwakeFromLoadE17AwakeFromLoadMode(_ZN6Shader13AwakeFromLoadE17AwakeFromLoadMode:36)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode(_ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode:184)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager27IntegrateAllThreadedObjectsEv(_ZN17PersistentManager27IntegrateAllThreadedObjectsEv:92)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager38LoadAndIntegrateAllPreallocatedObjectsENS_9LockFlagsE(_ZN17PersistentManager38LoadAndIntegrateAllPreallocatedObjectsENS_9LockFlagsE:80)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager10ReadObjectEi17AwakeFromLoadMode(_ZN17PersistentManager10ReadObjectEi17AwakeFromLoadMode:252)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZNK4PPtrI6ShaderEcvPS0_Ev(_ZNK4PPtrI6ShaderEcvPS0_Ev:92)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN8Material15BuildPropertiesEv(_ZN8Material15BuildPropertiesEv:56)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode(_ZN18AwakeFromLoadQueue28InvokePersistentManagerAwakeEPNS_4ItemEj17AwakeFromLoadMode:184)
    10-20 17:13:19.765: E/MessageQueue(21618): at libunity._ZN17PersistentManager27IntegrateAllThreadedObjectsEv(_ZN17PersistentManager27IntegrateAllThreadedObjectsEv:92)

    Full tracelog in file
     

    Attached Files:

  32. a-to-z-27

    a-to-z-27

    Joined:
    Oct 11, 2017
    Posts:
    2
    Test device: pixel 3a

    1. install Android 10
    2. install the old version of the app
    3. update to Android 11
    4. launch the previous version of the app.
    5. update to the new version of the app
    6. launch the new version of the app.

    I was able to reproduce this procedure.
    We also confirmed that the symptoms did not recur after the reboot.
     
  33. Yury-Habets

    Yury-Habets

    Unity Technologies

    Joined:
    Nov 18, 2013
    Posts:
    1,107
    I assume there has to be some memory pressure for the bug to occur, so an empty project works well.
     
  34. pro_psg

    pro_psg

    Joined:
    May 18, 2017
    Posts:
    4
  35. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    Didn't know that option, thanks for highlighting, just to be clear you're still getting "E/Unity: Using memoryadresses from more than 16GB of memory" ? Also can you drag & drop the apk in Android Studio, and check the final android manifest if it contains android:allowNativeHeapPointerTagging= false? Could you share the manifest excluding any NDA specific items?
     
  36. pro_psg

    pro_psg

    Joined:
    May 18, 2017
    Posts:
    4
    Yes, I am getting the same error. I get this error and the app stops responding and ultimately crashes after getting this error.
    Since our older releases which were targeting Android 10 are also crashing on Android 11, I checked the manifest and it does not contain any entry for allowNativeHeapPointerTagging. It seems like this is a new flag which is not supported when trying to build with Android SDKs prior to 30, i.e. Android 11.
    I also took our latest build which targets Android 11, where we had added the entry for allowNativeHeapPointerTagging = false. This is also present in the final android manifest. The build crashes for this as well. Please find attached the final Android Manifest for reference.
     

    Attached Files:

  37. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    That's a very useful information, thank you. Also a bit sad, that it can't work as a fast workaround to this problem.

    Small update - we have a fix internally, which is currently being tested by our QA. Stay tuned
     
  38. unity_dlDeCc3cmrc0KQ

    unity_dlDeCc3cmrc0KQ

    Joined:
    May 15, 2019
    Posts:
    4
    I'm facing with the same crash on google pixel 2 | 2XL | 3 | 3A | 3XL, any update or workaround on this issue?
     
  39. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
  40. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    The fix should be available in 2019.4.15f1
     
    tonialatalo and SlimeProphet like this.
  41. unity_dlDeCc3cmrc0KQ

    unity_dlDeCc3cmrc0KQ

    Joined:
    May 15, 2019
    Posts:
    4
  42. adbourdages

    adbourdages

    Joined:
    Jul 8, 2012
    Posts:
    55
    I'm getting the same error (Using memoryadresses from more than 16GB of memory) as a result of a Resource.Load after the game has finished loading but only under specific conditions (repeated taps while opening a new UI screen - still needs to investigate why those conditions) with Unity 2019.3.15f1, Android 11, Pixel 4a.

    Does it sounds like it would that be covered by that fix?
     
  43. jasilkm

    jasilkm

    Joined:
    Apr 26, 2017
    Posts:
    6
  44. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    tonialatalo and jasilkm like this.
  45. prinoldmj

    prinoldmj

    Joined:
    Feb 10, 2017
    Posts:
    9
    I have been encountering the same problem the last couple of days, i tried the suggestion of restarting the device but this had no effect. Today i downloaded a software update for android 11 and my game now works again. i will continue to monitor the situation to see if this is permanent or only temporary.
     
  46. Aleksey1919

    Aleksey1919

    Joined:
    Oct 24, 2020
    Posts:
    2
    Will you add a fix to Unity 2018 LTS or it will only be in Unity 2019 LTS?
     
    Dmitry-Fofanov likes this.
  47. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    Yes, the fix will be present in 2018 LTS as well, I see it's still not merged to main 2018 branch, so can't say which exact release it will be in too.
     
  48. Maisey

    Maisey

    Joined:
    Feb 17, 2014
    Posts:
    270
    @Tomas1856 I'm guessing this issue is affecting builds made with Unity 2017.4.40f1 as well(?), if it is, will there be a fix for it as well (even though support has ended)?

    Worth mentioning, as someone else here said, Google seems to have released an update which seems to fix this issue (at least temporarily) unless I'm really lucky with (no-)crashes at the moment.

    EDIT:
    Still happens on latest Android 11 OS version, might have just reduced the frequency of it (or not at all).
     
    Last edited: Nov 17, 2020
    tonialatalo likes this.
  49. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    2,392
    Sadly I can't answer that.
    Besides the official stance of Unity about no longer supporting Unity 2017 or lower, there's also the problem the toolchains which we're used to build 2017 and lower - are no longer maintained, and those toolchains are different from the ones which we are used to build Unity 2018 or higher. It might be technically challenging to produce a Unity 2017 build, that would be the risk

    Until now, we haven't heard anyone who's using Unity 2017 or lower complaining about this problem.

    If someone would report such a problem, it would be a pretext to at least start a discussion on how to proceed.
     
  50. Maisey

    Maisey

    Joined:
    Feb 17, 2014
    Posts:
    270
    Thanks for the answer Tomas, I, personally, haven't experienced the crash on our game built with Unity 2017 (can't upgrade it because of lots of dependencies), so hopefully it's a non-issue. I also believe Genshin Impact is built with 2017.4.30f1 so if anything, they should have reported the issue to you guys. :p
     
    Tomas1856 likes this.
unityunity