VContainer icon indicating copy to clipboard operation
VContainer copied to clipboard

More performance improvement

Open hadashiA opened this issue 4 years ago • 0 comments

gustavopsantos/reflex seems to have an amazing performance.

  • Using Expression Tree.
    • https://github.com/gustavopsantos/reflex/blob/main/Reflex/Assets/Reflex/Scripts/TypeInfoCache.cs#L81-L105
    • I thought this wouldn't work in Unity.. I want to test it.
    • However, VContaienr has IL generation, so this will be fast enough
  • Caching GetHashCode by static type caching
    • ↑In addition, they are building their own Stacks and Collections.
  • Heavy use of [MethodImpl(MethodImplOptions.AggressiveInlining)] and [IL2CppSetOption(...)] (Skipping null checks, array bounds checks, divide by zero checks)
    • My previous validation didn't show much of an effect, but things may have changed.

hadashiA avatar Aug 25 '21 11:08 hadashiA