Consider replacing ReaderWriterLock with ReaderWriterLockSlim


Has the Unity SDK team experimented with ReaderWriterLockSlim? The reason I bring it up is because when profiling, SendBird sticks out because ReaderWriterLock allocates 100 bytes every frame because of the calls to AcquireReaderLock and ReleaseReaderLock. It must be something to do with Mono because I used MemoryDiagnoser in a BenchmarkDotNet project for net6.0 and netcoreapp3.1, and those calls don’t generate any garbage.