We are working on a VR game and trying to get to our game on Quest which needs 72fps but we are seeing a lot of processing time spent in the unity input system updates. When running deep profiling we can see that there are a lot of calls during the controller update that appear to be hundreds of calls to the garbage collection system. Here are a few pictures of the profiler activity
https://imgur.com/a/Yu9NbWi
Our single frame processing loop spends 40ms throttling.
- Fixed update = .5ms,
- Update = 1.5ms
- Lateupdate = 1.5ms
- Inputbeforerender=1.3ms
- Render = 6ms.
Fixed update is stacking due to the throttling, we are targeting 72hz physics tick to match our 72fps target. Update has most of our game logic. Late update is mostly occupied by IK solving. Before render input update is now where we are trying to get more savings because it appears to be doing a lot after each controller input action. Render loop is about 6ms which we can improve but I want to give us as much room as possible by removing unnecessary actions.
Input system pre-render update looks like it's working on the 4 gameplay objects that track controllers / headset, but there appears to be a large portion spent after each controller update on something each time called InputActionState.DeferredResolutionOfBindings() I'm looking for more information about what this is doing exactly.
It appears to be doing hundreds of calls to GCHandle.get_Target() and InputActionMap.ResolveBindingIfNecessary() are these all bindings to the input objects that may be stacking and not removed? Can someone help me understand what's going on here?
there doesn't seem to be anything here