Performance: HkShape comparison with boxing allocation

Guest shared this bug 2 years ago
Reported

Game version: 1.200.032

Method: Havok.HkShape.HandleEqualityComparer.Equals

There is boxing allocation and a useless null check inside the above method, so it could be optimized.

Optimize to: x.m_handle.ToInt64() == y.m_handle.ToInt64()

Also request aggressive inlining:

[MethodImpl(MethodImplOptions.AggressiveInlining)]

Replies (2)

photo
1

Hello, Viktor!

Thank you for letting us know about this. I have reported this internally.

Kind Regards

Laura, QA Department

photo
1

Fix is already in the 1.202.048 beta.

Thanks for implementing it.

Leave a Comment
 
Attach a file