Search Unity

Bug Unable to find internal function `Unity.Collections.LowLevel.Unsafe.UnsafeUtility::MemCpyReplicate`

Discussion in 'Editor & General Support' started by egutentag, May 28, 2023.

  1. egutentag

    egutentag

    Joined:
    Nov 27, 2020
    Posts:
    14
    Hi,
    I get this error on a Quest 2 build (android) but not in the editor:

    Code (Boo):
    1. 2023/05/28 15:34:30.774 5581 5603 Error Unity Unable to find internal function `Unity.Collections.LowLevel.Unsafe.UnsafeUtility::MemCpyReplicate`
    2. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #0 0x714a810b14 (libunity.so) ? 0x0
    3. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #1 0x714a6178ac (libunity.so) ? 0x0
    4. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #2 0x714a8407d8 (libunity.so) ? 0x0
    5. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #3 0x70422883cc (lib_burst_generated.so) burst.initialize.externals3 0x70
    6. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #4 0x704229b2dc (lib_burst_generated.so) burst.initialize 0x20
    7. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #5 0x714a841488 (libunity.so) ? 0x0
    8. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #6 0x714a841aa4 (libunity.so) ? 0x0
    9. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #7 0x714a8418b0 (libunity.so) ? 0x0
    10. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #8 0x714a840e70 (libunity.so) ? 0x0
    11. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #9 0x714a841ccc (libunity.so) ? 0x0
    12. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #10 0x714a28d0fc (libunity.so) ? 0x0
    13. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #11 0x714564d1a8 (libil2cpp.so) ? 0x0
    14. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #12 0x714564d260 (libil2cpp.so) ? 0x0
    15. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #13 0x7143d713e8 (libil2cpp.so) ? 0x0
    16. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #14 0x7143bf2efc (libil2cpp.so) ? 0x0
    17. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #15 0x7143be8794 (libil2cpp.so) ? 0x0
    18. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #16 0x7144bb2780 (libil2cpp.so) ? 0x0
    19. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #17 0x7144bb23b8 (libil2cpp.so) ? 0x0
    20. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #18 0x714585590c (libil2cpp.so) ? 0x0
    21. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #19 0x7143d713e8 (libil2cpp.so) ? 0x0
    22. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #20 0x7143bf2efc (libil2cpp.so) ? 0x0
    23. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #21 0x7143be8794 (libil2cpp.so) ? 0x0
    24. 2023/05/28 15:34:30.774 5581 5603 Error Unity  #22 0x714563f868 (li
    25.  
    I even have a link.xml file:
    Code (CSharp):
    1. <linker>
    2.   <assembly fullname="Unity.Collections" preserve="all" />
    3.   <!-- <assembly fullname="Unity.Collections.Tests" preserve="all" /> -->
    4.   <!-- <assembly fullname="Unity.Burst.Tests" preserve="all" /> -->
    5.   <assembly fullname="Unity.Transforms" preserve="all" />
    6.   <assembly fullname="Unity.Transforms.Hybrid" preserve="all" />
    7.   <!-- <assembly fullname="Unity.Transforms.Tests" preserve="all" /> -->
    8.   <assembly fullname="Unity.Jobs" preserve="all" />
    9.   <!-- <assembly fullname="Unity.Jobs.Tests" preserve="all" /> -->
    10.   <assembly fullname="Unity.Burst" preserve="all" />
    11. </linker>
    Jobs 0.70
    Collections: 1.4.00
    Burst: 1.6.6

    This happens also when i try the latest versions.
     
  2. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,745
    Does that identifier exist anymore? As in, can you find the docs that say it does?

    If not then perhaps some other library you are using must be updated.
     
  3. egutentag

    egutentag

    Joined:
    Nov 27, 2020
    Posts:
    14
    From dev build i can see more details and it look's like unity internal problem with bursts:

    "
    Code (CSharp):
    1. <i>Autoconnected Player</i> Unable to find internal function `Unity.Collections.LowLevel.Unsafe.UnsafeUtility::MemCpyReplicate`
    2. #0 0x7e0ff16d58 (libunity.so) GetStacktrace(int) 0x3c
    3. #1 0x7e0fcea720 (libunity.so) DebugStringToFile(DebugStringToFileData const&) 0x238
    4. #2 0x7e0ff6ce18 (libunity.so) BurstCompilerService::NativeGetExternalFunctionPointerCallback(char const*) 0x1a4
    5. #3 0x7cfca99370 (lib_burst_generated.so) burst.initialize.externals3 0x70
    6. #4 0x7cfcaac2a4 (lib_burst_generated.so) burst.initialize 0x20
    7. #5 0x7e0ff6dbc0 (libunity.so) BurstCompilerService::LoadBurstLibrary(char const*) 0x1e4
    8. #6 0x7e0ff6e168 (libunity.so) BurstCompilerService::AttemptLoadAdditionalBurstLibrary(core::basic_string<char, core::StringStorageDefault<char> >) 0x74
    9. #7 0x7e0ff6df50 (libunity.so) BurstCompilerService::DynamicResolve(ScriptingMethodPtr, void*, int, void (*)(void*, int, void*), void (*)(void*, BurstLogType, char const*, char const*, int), char const*) 0xd0
    10. #8 0x7e0ff6d524 (libunity.so) BurstCompilerService::CompileAsync(ScriptingObjectPtr, void*, int, void (*)(void*, int, void*), void (*)(void*, BurstLogType, char const*, char const*, int), char const*) 0x108
    11. #9 0x7e0ff6e30c (libunity.so) CompileAsyncDelegateMethod(ScriptingObjectPtr, char const*) 0x84
    12. #10 0x7e0f85379c (libunity.so) BurstCompilerService_CUSTOM_CompileAsyncDelegateMethod(ScriptingBackendNativeObjectPtrOpaque*, ScriptingBackendNativeStringPtrOpaque*) 0xe8
    13. #11 0x7e06615d2c (libil2cpp.so) ? 0x0
    14. #12 0x7e0990c5ec (libil2cpp.so) ? 0x0
    15. #13 0x7e0990c7a4 (libil2cpp.so) ? 0x0
    16. #14 0x7e05412b1c (libil2cpp.so) ? 0x0
    17. #15 0x7e09b39f00 (libil2cpp.so) ? 0x0
    18. #16 0x7e09b2f544 (libil2cpp.so) ? 0x0
    19. #17 0x7e09903f54 (libil2cpp.so) ? 0x0
    20. #18 0x7e0990379c (libil2cpp.so) ? 0x0
    21. #19 0x7e0975f13c (libil2cpp.so) ? 0x0
    22. #20 0x7e0975f2a0 (libil2cpp.so) ? 0x0
    23. #21 0x7e05412b1c (libil2cpp.so) ? 0x0
    24. #22 0x7e09b39f00 (libil2cpp.so) ? 0x0
    25. #23 0x7e09b2f544 (libil2cpp.so) ? 0x0
    26. #24 0x7e0974c828 (libil2cpp.so) ? 0x0
    27. #25 0x7e05412b1c (libil2cpp.so) ? 0x0
    28. #26 0x7e09b39f00 (libil2cpp.so) ? 0x0
    And here's the ref: https://docs.unity3d.com/2020.3/Doc...vel.Unsafe.UnsafeUtility.MemCpyReplicate.html
     
  4. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,745
    Interesting!

    Here's some options to consider:

    - something is wrong with packages (see below). Try that same set of packages in a fresh empty project (just copy the
    Packages/manifest.json
    over and see if you get the same errors)

    If that doesn't fix it.

    - that burst compiler version has a bug
    - that version of unity collections (I'm not even sure what delivers that) has a bug
    - there's just a simple version requirement that the Package Mangler is failing to catch
    - there is something unaccounted for in your code that makes burst choke

    To fix package-y stuff:

    Extra unwanted packages in new projects (collab, testing, rider and other junk):

    https://forum.unity.com/threads/temp-unityengine-testrunner-dll-error.1133938/#post-7287748

    About the fastest way I have found to make a project and avoid all this noise is to create the project, then as soon as you see the files appear, FORCE-STOP (hard-kill) Unity (with the Activity Manager or Task Manager), then go hand-edit the Packages/manifest.json file as outlined in the above post, then reopen Unity.

    Sometimes the package system gets borked from all this unnecessary churn and requires the package cache to be cleared:

    https://stackoverflow.com/questions/53145919/unity3d-package-cache-errors/69779122