#1.0.8 persistent leaks on unity load

1 messages · Page 1 of 1 (latest)

young loom
#

These pop up just starting the editor

young loom
#

On recompile there seems to be a few from logging package, i have like 20 slightly different stacks but this looks like the general theme

#

and the 1 other variant

0x00007ff88a6d4ad0 (d1064f4fa4243203088c864aa713dc4) Unity.Collections.LowLevel.Unsafe.UnsafeList`1<Unity.Logging.PayloadHandle>::Unity.Collections.LowLevel.Unsafe.UnsafeList`1<Unity.Logging.PayloadHandle>.ResizeExact<Unity.Collections.AllocatorManager.AllocatorHandle> (at I:/Documents/BovineLabs/com.bovinelabs.shattered/Library/PackageCache/com.unity.burst@1.8.4/.Runtime/Library/PackageCache/com.unity.collections@2.1.4/Unity.Collections/UnsafeList.cs:354)
0x00007ff88a6d55bc (d1064f4fa4243203088c864aa713dc4) Unity.Logging.LogMemoryManager::Unity.Logging.LogMemoryManager.Initialize (at I:/Documents/BovineLabs/com.bovinelabs.shattered/Library/PackageCache/com.unity.burst@1.8.4/.Runtime/Library/PackageCache/com.unity.logging@1.0.8/Runtime/LogMemoryManager.cs:415)
0x00007ff88a6d4f9c (d1064f4fa4243203088c864aa713dc4) Unity.Jobs.IJobExtensions.JobStruct`1<Unity.Logging.Internal.AfterUpdateLoggersJob>.Execute(ref Unity.Logging.Internal.AfterUpdateLoggersJob data, System.IntPtr additionalPtr, System.IntPtr bufferRangePatchData, ref Unity.Jobs.LowLevel.Unsafe.JobRanges ranges, int jobIndex) -> void_73c04fea4d034adcf3d7ccb459d2c985 from UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null (at I:/Documents/BovineLabs/com.bovinelabs.shattered/Library/PackageCache/com.unity.burst@1.8.4/.Runtime/unknown/unknown:0)
0x00007ff88a6d4146 (d1064f4fa4243203088c864aa713dc4) bc3a73b0bb38de2a634832fdfd92389c
0x00007ff735d7e96c (Unity) ExecuteJob
0x00007ff735d7fcab (Unity) ForwardJobToManaged
0x00007ff735d7bfd8 (Unity) ujob_execute_job
0x00007ff735d7b664 (Unity) lane_guts
0x00007ff735d7db14 (Unity) worker_thread_routine
0x00007ff735fa3c87 (Unity) Thread::RunThreadWrapper
0x00007ff929fb7604 (KERNEL32) BaseThreadInitThunk
0x00007ff92ac026a1 (ntdll) RtlUserThreadStart```
wild mulch
#

Logging, EntityManager, Collections. Pretty much everywhere

fast crown
#

@lime apex for the OP set of leaks

#

some of these i think are fixed in the hotfix, which was not this release for internal process reasons

prime oxide
#

Logging leaks are known and work is scheduled to fix them

#

The Unity.Entities.Editor.HierarchyPrefabStageChanges leak is new to me, so thanks!

prime oxide
young loom
#

i have a bunch of this one

#

from different jobs, all ending on
Unity.Collections.LowLevel.Unsafe.UnsafeList`1<Unity.Logging.PayloadHandle>::Unity.Collections.LowLevel.Unsafe.UnsafeList`1<Unity.Logging.PayloadHandle>.ResizeExact<Unity.Collections.AllocatorManager.AllocatorHandle> (at

#

seems to be anywhere i use logger in a job

prime oxide
#

Oh, yeah, this one's logging too

Unity.Jobs.IJobExtensions.JobStruct`1<Unity.Logging.Internal.AfterUpdateLoggersJob>
#

Ah, yeah, that'd be a known issue leaking BurstSpinLockReadWrite. Work-in-progress

prime oxide
# wild mulch Logging, EntityManager, Collections. Pretty much everywhere

Any of these in Memory/Unmanaged/Array:Resize, you'll have to look at the full callstack. This is the method that all Unity.Collections allocations funnel into, so it's where we call MallocTracked. You'll have to look up the callstack a bit to find out what is allocating and not disposing the container in question.

wild mulch
#

Unity.Logging.LogMemoryManager::Unity.Logging.LogMemoryManager.Initialize (at C:/Users/CornFlakes/Documents/DotsSum/Library/PackageCache/com.unity.burst@1.8.4/.Runtime/Library/PackageCache/com.unity.logging@1.0.8/Runtime/LogMemoryManager.cs:434)

prime oxide
#

ah, yup, that'll do it

#

thanks!

young loom
#

this one's from netcode - MultiplayerPlaymodeLoggingSystem:OnCreate

0x000002a85fc267a3 (Mono JIT Code) Unity.Collections.Memory/Unmanaged/Array:Resize (void*,long,long,Unity.Collections.AllocatorManager/AllocatorHandle,long,int) (at ./Library/PackageCache/com.unity.collections@2.1.4/Unity.Collections/Memory.cs:79)
0x000002a85fc263b3 (Mono JIT Code) Unity.Collections.Memory/Unmanaged:Allocate (long,int,Unity.Collections.AllocatorManager/AllocatorHandle) (at ./Library/PackageCache/com.unity.collections@2.1.4/Unity.Collections/Memory.cs:20)
0x000002a8a4437efb (Mono JIT Code) Unity.Entities.EntityQueryImpl:Allocate () (at ./Packages/com.unity.entities@1.0.8/Unity.Entities/Iterators/EntityQuery.cs:1951)
0x000002a8a4437b2b (Mono JIT Code) Unity.Entities.EntityQuery:Construct (Unity.Entities.EntityQueryData*,Unity.Entities.EntityDataAccess*) (at ./Packages/com.unity.entities@1.0.8/Unity.Entities/Iterators/EntityQuery.cs:2130)
0x000002a8a442e223 (Mono JIT Code) Unity.Entities.EntityQueryManager:CreateEntityQuery (Unity.Entities.EntityDataAccess*,Unity.Entities.ArchetypeQuery*,int,Unity.Entities.ComponentType*,int) (at ./Packages/com.unity.entities@1.0.8/Unity.Entities/Iterators/EntityQueryManager.cs:720)
0x000002a8a4440473 (Mono JIT Code) Unity.Entities.EntityQueryManager:CreateEntityQuery (Unity.Entities.EntityDataAccess*,Unity.Entities.ComponentType*,int) (at ./Packages/com.unity.entities@1.0.8/Unity.Entities/Iterators/EntityQueryManager.cs:549)
0x000002a8a443f5b3 (Mono JIT Code) Unity.Entities.EntityManager:CreateEntityQuery (Unity.Entities.ComponentType[]) (at ./Packages/com.unity.entities@1.0.8/Unity.Entities/EntityManager.cs:4446)
0x000002aa17d9b743 (Mono JIT Code) Unity.NetCode.Editor.MultiplayerPlaymodeLoggingSystem:OnCreate () (at ./Library/PackageCache/com.unity.netcode@1.0.8/Editor/MultiplayerPlayModeWindow.cs:1290)```
#

also in NetcodeClientPredictionRateManager

#

i think I'll stop posting these though, I suspect you'll find them all yourselves if they aren't already fixed ^_^

slender iris
#

@prime oxide will ping you with another stable leaks from baking. Context:
Simple subscene (opened(!)), just two entities, without any custom bakers, just renderers. Domain reload enabled for testing purposes. Enter play mode, exit playmode, enter playmode again. (No custom Forgive\CheckLeaks)

lime apex
#

Hey @young loom, I'm looking into the original leaks and can't repro them locally. Is there any chance you can either give more info in this thread or use the bug reporter and attach a project? If you do file a bug, please report the ID (IN-####) here so I can get to it quicker. Thanks!

young loom
#

Hmm the original one literally just happens opening editor for me

#

A made a script to turn leak detection early enough to see

#

I'll see about a bug report once I get up

young loom
#

oh yeah i tried to repo this, this morning in an empty project

#

i could not repo it with just entities installed

#

installing graphics and i had my usual 4 leaks after the reload

#

but then again could not repo it

#

will try again to find a small repo

lime apex
#

That would be super helpful, thank you!

ocean phoenix
#

Hey guys, in case 1.0.8/Unity.Entities/Iterators/EntityQuery.cs:1951 leak is still actual, I've sent the repo just in case IN-41348