Search Issue Tracker

Won't Fix



Found in


Issue ID




Object.FindObjectOfType finds all objects of type and returns the first one, which allocates GC



How to reproduce:

1. Open attached project
2. Attach script Test.cs to any gameobject
- The script simply attempts to find an object of its own type in the Update() message
3. Play the scene
4. Open the Profiler
- Note how BehaviourUpdate -> Test.Update() is allocating GC

  1. Resolution Note:

    We really appreciate your contribution to the Unity product. Thank you for reporting this issue. We take every case submitted to us seriously by investigating the impact on you, our customer, as well as the impact it may have on the engineering and experience of our product.

    This particular case has been investigated thoroughly and we have decided, in the interests of protecting the stability and features of Unity for users that rely upon the affected versions, to not address this issue.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.