Open mmackh opened 2 years ago
@mmackh, @RodrigoSAlves, could you check if Metal API validation is enabled for the scheme? It can be one cause for the performance drop.
@ZiZasaurus Thanks for taking a look. I disabled the Metal API validation option and did not see a significant decrease in the CPU utilisation. While running the Examples app with same device as my initial tests, it seemed to decrease CPU utilisation by 1% or 2%. While running my app with the same device, it also seemed to decrease at most 3% to 4%. The profiler shows the same pattern.
@RodrigoSAlves, @mmackh are you able to provide a public style url so that we can investigate this further?
I've set mapbox://styles/touchgrove/cl70b4lij000f14pndegvdba9 to public
same here, drawInMTKView consuming between 70-90% of CPU when unchecked Metal API validation I got half percentage
Environment
Observed behavior and steps to reproduce
On the initial load (without caching), flying a camera with a fixed duration will cause frame drops. This is sometimes also apparent when panning. Below is the code I'm using:
Expected behavior
Consistent 60fps performance on up-to date hardware
Notes / preliminary analysis
It seems some drawing code is spending a significant time on the main thread causing frame drops. The style URI we're using: mapbox://styles/touchgrove/cl70b4lij000f14pndegvdba9
Additional links and references