I’m trying to optimize some prefabs for render speed. Naturally, the first stop is to run the frame debugger to see what is generating the draw calls. After running the scene and running the frame debugger a few times, the game view stops updating. It will render what appears to be a single frame, and then it no longer updates. The scene view is fine. If I resize the game view, it goes completely black. The stats show zero batches, and it shoots up to around 4k FPS. (My video card is fast, but it’s not that fast.) The frame debugger no longer functions at this point.
The only way to fix it that I can find is to restart Unity. After running the frame debugger a few times, the problem comes back. I’m using Unity 2020.1.17f1 with SRP on Windows. The project has VR enabled, so Oculus is running in the background. Graphics API is set to D3D11. Latest video drivers as far as I can tell. Have I run into a bug, or am I doing something wrong?
System stats, for reference: i9 10-core @3.7G, 128G memory, 4TB SSD, RTX 2080Ti
Thanks for the reply. Yes. I’ve tried various different procedures for troubleshooting, but that’s how I have always used the frame debugger - turn it on, get the info I need, and turn it off.
I think I have narrowed it down, so I can now reproduce the problem more reliably on my own computer. One thing I neglected to mention is that once I enable the frame debugger, I can only click on one event, after which the editor freezes for a little over thirty seconds before I can browse other events. I had assumed that it was just gathering frame data and analyzing it, but the problem does not appear unless I click an event and I experience that pause. I’m going to try a fresh project and a fresh scene to see if it still happens.
I created a fresh project to reproduce, and I discovered some things. First, everything works perfectly fine, with no freezes or problems of any kind until I add Oculus support - and then I get the pause. BUT, the frame debugger functions normally after the freeze. So I decided to go back to my project to see what the differences are. I started it up, clicked an event, got the freeze, but surprisingly, the frame debugger continued to function. It worked for a couple more runs, so I decided, okay, maybe it fixed itself. Then, after another run, it stopped working again. Memory issue? Caching?
Edit: Oops, I just reproduced it on my fresh project. It may be a cache filling up or something - the repro project has nothing in it except one test mesh, and it has Oculus support enabled with all the defaults, so there isn’t much to fill up memory or caches.
… this no-update (and stack in a single frame) editor window is a bug that needs to be ironed out by Unity, and is present from some few months ago, on all versions of Unity, and seems to be more present with more Windows updates performed each time … it seems that also: the same bug now also causes complete project reimports on every build, and on every asset change, by now, and is also getting worse, day by day, and more aggressive. So that’s for our side of report, using 2017, and all to-day versions as well, at our tests: it does the same. Bad, where also all current advised ‘solutions’ that we could find on the forums are not really tackling the issue yet … It would happen on all versions of unity from versions 2017, to-day, if you have anything more than 8+ different assets used, which is the normal average, per every project … Please, keep reporting, everyone, as we all do, each individual cases of this ‘stacked editor-frame’ sort, so we can all hopefully, with enough community input find the main issue one day much quicker, and get quicker to the bottom of the mistery :).