Introduction to the Profiler - Unity Official Tutorials
Why Stack Overflow recommends it
Stack Overflow users link it when answering Unity performance questions such as low FPS or choppy motion, to show people how to start profiling their game.
Recommended by 3 people across 2 different months, 2014 to 2020.
What it is
A short official Unity tutorial that introduces the built-in Profiler and walks through its basic sections. It shows how to capture real-time data about a scene and analyze its performance in the editor.
What people said
Recommends Anas iqbal · 2015-07 · Stack Overflow · on “Terrible FPS in simple game”
Use profiler to test your game and look for the spikes inside your game. This will help you identify easily that which part of your code is creating problems as it is not necessary that your object spawn script is causing problems. In one of my projects I faced a problem where my font was causing FPS drop. As you mentioned your "points counter" then I would ask if you are using custom font? If yes then is it set to dynamic? If yes then this might be the issue as Unity renders the dynamic font at runtime and every time you update the text and so it is suggested to use dynamic font for static menus but not for constantly changing text. For more detail on profilers Look at the following links:
Recommends JohannesAndersson · 2015-07 · Stack Overflow · on “Terrible FPS in simple game”
Well first of all, all games will be laggy cause of the instantiate method. If you need to use it then use it in void Start() {...} or void Awake() {...} and cache all created objects. With these cached objects create a object pooling and save performance. Dont use transform from Unitys created instance, make sure you create a cached object private Transform _transform; void Start() { _transform = transform; } Instead of doing your own calculating counter > timebetweenSpawn make sure you use InvokeRepeating [LINK] to save performance. Make sure created objects in editor (if not moving objects) are static . You do not have to redraw them if the are not to be moved. Unity Profiler [this video] will
Recommends Akin Erkan · 2020-05 · Stack Overflow · on “Trouble finding the performance issue in my unity game”
You can also open overview panel of profiler where you can get a detailed breakdown. Here is unity tutorial. [this video]
Cites theodox · 2014-10 · Stack Overflow · on “Unity3D Choppy Camera Motion”
You should look at it under the profiler and see if there any clues. Maybe network code? Or is you computer itelf having hiccups? [this video]