Let's talk about this. How to find the performance problem of mono memory
Mono is primarily a code problem, and various solutions will be addressed elsewhere, starting with the resolution of each spike, which can lead to Gc,mono heap memory requests.
1. First Use cube to measure
Run a game on the phone, look at the data.
You can see that you have applied for memory here. This time there was a downward spike, and this was a GC. Then Mono discovers that the memory you have applied for in your code has exceeded the current heap memory, so you can only request one more.
So it's time to find out what this moment is about.
2. Use the profiler to measure
This is the time to run the previous game in editor. Probably found the same location.
The diagram corresponding to the cube above can find the corresponding position of the profiler.
You can roughly find out where the memory is being applied.
Or you can use UWA tools to measure it at this time.
Also run the game again, upload the data
Find the function that corresponds to consumption
"Komatsu teaches you to develop" unity practical skills "Unity performance problem Finding method