Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice
  2. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  3. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Extremely slow editor in 2019.2.0a7

Discussion in '2019.2 Beta' started by DefiantDev_Chris, Mar 7, 2019.

  1. mangax

    mangax

    Joined:
    Jul 17, 2013
    Posts:
    334

    i wasn't able to reproduce the issue on separate new clean project, in fact, even baked shadow maps shows correctly in the android build!! No black maps whatsoever..

    so there is something in old projects "upgraded" from unity 2018 causing issues on new unity 2019 and it's new features maybe..

    i tried deleting "Library" folder in order to rebuild the project, but the baked lightmaps stills shows up as black on all my android devices.. along with the performance issues.

    what i should be delete from my project in order to rebuild the project again??
     
    Last edited: Jul 18, 2019
  2. LeonhardP

    LeonhardP

    Unity Technologies

    Joined:
    Jul 4, 2016
    Posts:
    3,130
    Can you share the original project with us? It doesn't need to be uploaded via the bug reporter. If you're using Github or the likes you can share it through that or ask in your bug report or for an alternative repository to upload it to.
     
  3. mangax

    mangax

    Joined:
    Jul 17, 2013
    Posts:
    334
    i've just sent you a download link of sample project.
    if you can find away to resolve this project issue (deleting/upgrading stuff) let me know.
     
    LeonhardP likes this.
  4. lucasmontec

    lucasmontec

    Joined:
    Apr 7, 2015
    Posts:
    97
    upload_2019-7-21_13-56-17.png

    Editor rendering at less than 15 fps...
     
  5. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,586
    Please enable "Profile Editor" and check if it adds items under the "PlayerUpdates.Tick" entry. If it doesn't, please enable "Deep Profile" and check again. This should hopefully give some insight in what's causing it being so slow.
     
  6. lucasmontec

    lucasmontec

    Joined:
    Apr 7, 2015
    Posts:
    97
    That was with profile editor enabled. I just untoggled it so I could snap a single shot.

    upload_2019-7-21_15-34-3.png
     
  7. lucasmontec

    lucasmontec

    Joined:
    Apr 7, 2015
    Posts:
    97
    Seems fixed after updating nvidia graphics driver.
     
  8. hongmexiton

    hongmexiton

    Joined:
    Aug 10, 2017
    Posts:
    2
    when i tried to load a bunch of assetbundle this happen
    assetbundle consist of
    - "SpriteAtlas"
    - "animation clip"
    - "animation controller"

    it just killed the whole thing.

    upload_2019-7-24_11-45-55.png
     
  9. DeliaF_Manea

    DeliaF_Manea

    Unity Technologies

    Joined:
    Jul 9, 2019
    Posts:
    25
    Could you please submit a bug report with a minimal reproduction project for this issue and reply in here with the issue ID?
     
  10. ReignOfDave

    ReignOfDave

    Joined:
    Oct 22, 2015
    Posts:
    51
    I am also getting poor editor performance (b10).

    Importing packages/assets.
    Starting/Stopping play mode.
    Switching editor windows.
     
  11. scottharber

    scottharber

    Joined:
    May 14, 2014
    Posts:
    42
    What does Semaphore.WaitforSignal actually do? Is it possible to disable it?
     
  12. mangax

    mangax

    Joined:
    Jul 17, 2013
    Posts:
    334
    am not 100% entirely sure.. but this thing only seen it show up in profiler if there is something causing a lot of time spent on GPU .. usually because of heavy shaders.. or an issue in the project it self.
     
  13. xtytyx

    xtytyx

    Joined:
    Dec 29, 2017
    Posts:
    24
    this is the exact issue im having, but because i cannot tell whether it is happening on non development builds (because no profiler) I'm wondering if it would be a problem playing non dev builds. For me its only taking up 15% give or take,but that's still a ton. Is it confirmed that it is just the editor?
    (also im runnning 2019.3.11 and it has been happening since I switched to the 2d LWRP)
     
  14. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    We struggle developing in Unity 2019.2f1 !
    The editor is so slow, constant freezes, lags, spikes etc. etc. Nobody seems to want to talk about it ! May be is not an issue that all users are experiencing !
    I don't know what is happening to the engine but we are about to clean up some HDD space in the HUB folder !

    EDIT : also having the same issues as you !
     
    sand_lantern likes this.
  15. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    Could you please make a profiler capture when you are experiencing freeze or lag.
    You can keep profiler running and stop profiling when spike happens. To minimize profiler window overhead switch to memory view there or dock it in a way that it is not visible.
    We are more than eager to talk about it and want to get rid of all spikes in the Editor, please help us to discover those. Some issues might occur only in specific conditions which makes them hard to be discovered.
     
    Peter77 likes this.
  16. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    Hi i will do my best to do so.

    I did a few times on other threads but i will do as soon as i can catch something in the profile.
    The actual point though is that the editor itself feels heavy. This is one of the biggest concerns currently !
    Honestly the new Incremental Garbage collector seems to be able to help quite a lot in builds. But overall in editor experience is not pleasant at all ( at least for us ). For example, expanding an inspector takes up to a second and the editor loop seems to take quite a lot of CPU time in general ! Also the editor allocates quite a lot of garbage memory which may be one of the main issues with performance !

    However if you can take a look at this initially - that would be super. The report says that it is not reproducible in 2019.2 but i am having this issue in 2019.1 as well and now in f1 of 2019.2 !

    This issue is reported by someone else and i did report the same issue with Case 1171123 as well.
    https://issuetracker.unity3d.com/issues/focusing-the-editor-window-causes-noticeable-slowdowns

    Here is a screenshot from a minute ago and this is happening every time editor gets focused !

    upload_2019-8-7_11-26-54.png
     
    sand_lantern and alexeyzakharov like this.
  17. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    Thanks for more information!

    This look like assets auto refresh - every time editor window gets focus back we scan Assets folder to detect changed assets. On large projects you can mitigate this with disabling Auto Refresh and using a manual refresh when you need it (Ctrl+R). image.png
    The issue (https://issuetracker.unity3d.com/issues/focusing-the-editor-window-causes-noticeable-slowdowns) is currently being investigated.

    Is this happening for a particular asset or gameobject? The profiling capture (especially with deep profiler enabled) should give enough information to find out the offending place.
     
  18. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    The AutoRefresh toggle is enabled in 2018 as well but there is no a delay when gets on focus even a ms. Until this issue is fixed at least the option for auto refreshing can be disabled !

    Here is a screen shot of a component i just collapsed. It does not matter which game object or which component. Just takes different time on different inspectors and also happens mostly after you have done some heavy work in the scene, or may be just after you stopped playing or when you just opened a new scene. It does not happen in empty scenes. It just gets fixed for some time and then happens again. Sometimes it can happen when expand/collapse a few inspectors sequentially ! Also not happening in v2018.x !

    Does the info from the image seem related to dealing with inspector

    upload_2019-8-7_12-35-6.png
     
    alexeyzakharov likes this.
  19. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    I think this image shows better. Simply collapsing a Canvas inspector in a scene which is the game entry and only has some managers inside...

    upload_2019-8-7_12-50-59.png
     
  20. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    And another one this time Canvas Scalar

    upload_2019-8-7_12-54-14.png
     
  21. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    @Vagabond_ Do you mind filing a bug for those issues. If this didn't happen in 2018 this is a regression and we should fix and add more performance tests for the inspector area.
     
  22. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    Yes i will try do that !

    One more thing! There seems to be some known performance issues with scene view gizmos as well. We are using a few tools that rely on gizmos and as soon as the gizmos get visible performance brakes down to a point where the scene view gets unresponsive and running at a few FPS only. I talked to one of the devs of one of the tools and he said that they did contacted you and you are aware ! I think one of the issues is regarding the "Gizmos.DrawSphere" method, also i think drawing lines also can make the editor super super slow !

    So is there anything known regarding gizmos performance or i will have to dig into that as well !?

    Thanks !
     
    alexeyzakharov likes this.
  23. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,586
    A good reproduce for this is also the LightProbeGroup. In a scene where many light probes are placed, selecting a gameobject with a LightProbeGroup, causes the editor to turn dead slow here.

    While a LightProbeGroup is selected:
    upload_2019-8-7_13-21-55.png
     
    alexeyzakharov likes this.
  24. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    Gizmos performance seems to depend on gizmo type, I didn't find any general issues there. Gizmos.DrawSphere only work seems to be create sphere vertices and push them to a batch buffer.

    I think this might deserve a separate issue to be filed. Let me ask if it is intended behavior or not.
     
    Peter77 likes this.
  25. kaarrrllll

    kaarrrllll

    Unity Technologies

    Joined:
    Aug 24, 2017
    Posts:
    552
    Yes, I am working on improving gizmo performance at the moment. There are some significant improvements on the way for scenes with many gizmos.

    Edit: However, like @alexeyzakharov mentioned, the sphere (and primitive drawing in general) gizmos are actually not too bad in terms of performance. Most of my work is related to icons and text.
     
  26. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    Thanks! Please post issue # here, so I can follow up later.

    Peter, could you please file a separate issue for it - it is unexpected behavior to Lightning Team.
     
    Peter77 likes this.
  27. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,586
    Thanks for raising this issue at the Lighting Team. I've submitted the following bug-report:
    (Case 1176891) Selecting LightProbeGroup causes Editor to become very slow
     
    FlightOfOne and alexeyzakharov like this.
  28. Nikolay-Smorgun

    Nikolay-Smorgun

    Joined:
    Jan 12, 2016
    Posts:
    6
    Удалось решить переключив в GameView с соотношением сторон с фиксированным разрешением на Aspect Ratio. Но это только в эдиторе.
     
  29. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,292
    In my experience, the sphere gizmos are essentially useless at scale, we must use cube gizmos in order to have the scene view still be usable when visualizing things like navigation data.

    I'm pretty sure Gizmos has a lot worse perf than DrawMeshInstanced for the exact same primitives.
     
  30. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    Found this today as well. No issue on one computer, almost unusable on the other. Both are on windows with similar but not identical hardware. Exactly the same project, don't have pro builder open.

    This is whilst the game is running. I don't have time tonight but will try and upload a ticket tomorrow (our project is big so it takes time and I don't have time to find a simple repro)

    Untitled-1.jpg Screenshot_3.png
     
  31. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    The first screenshot says that Canvas batch rebuild is taking about 100ms (potentially waiting for jobs) and is the only contributor to the PlayerLoop.
    The second screenshot is unclear - particle system bounding volumes update is waiting for jobs, but that is only 0.02ms of 800ms of the frame.
    (Semaphore.WaitForSignal marks the semaphore synchronization point where one thread waits for a work finished on another thread (e.g. waiting for jobs or async read command))
     
  32. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    Ah ok so what I was trying to emphasize here is the extreme difference rather than a specific example. I was seeing the semaphore coming up in lots of situations in the first profile so I just grabbed one of the biggest ones.

    In the second, there was no hit so I just grabbed a random one.

    However, by highlighting them you can see in the first image that the highlighted areas are taking significant time but in the second image, you can't even spot the highlighting. Was using this to show it had no effect on the second PC and wasn't the cause of the two big spikes you can see there.

    I'll try and upload the project over lunch

    Edit: I have no jobs running in this project but I do have my own multithreaded system. I wrote it before jobs existed and not updated to jobs since its a huge rework job.
     
    Last edited: Aug 20, 2019
    alexeyzakharov likes this.
  33. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    Yes, I can see that. Thanks for highlighting that - I missed the point :)
    That actually means that on the first screen there is a high chance of contention happening on the machine - looks like main thread is mainly waiting for other threads to complete jobs, tasks. I wonder if that could be a result of improper JobSystem setup. Could you please expand Jobs group in the Timeline View of Profiler Window or attach the capture from the first machine. It would be great to check out the source of stalls on other threads
     
  34. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    Hmm so yeah that would make sense since the difference between the machines is the CPU, the one with no issues is an Intel I7 and the other, with the issues, an Intel I5 (I think the same generation but forget which one).

    Took some new shots but you will have to excuse my ignorance since I don't typically use the hierarchy view of the profiler so I just grabbed what I thought was important.

    So this is the frame I am inspecting:
    Untitled-4.png

    The hierarchy view:
    Untitled-1 (1).png

    These are threads I have made doing their job, seems a bit strange that this Expand World thread is the only one with some info and not sure what it means about it having so many instances (gonna go read up on what all this means). Its a continually running thread that sleeps at given intervals.
    Untitled-2.png

    Rest of my threads and the background jobs:
    Untitled-3.png

    Let me know if you need anything else. Stuff like this I am fine to grab, uploading the project locks up that machine for 30+ mins and thus waiting for my lunch to do that
     
  35. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,292
    I'd recommend doing a deep profile, so you can actually see what's going on in the hierarchy view.
     
  36. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    I can give it a go but deep profile is a bit of an anomaly for this project! Turning it on stops my world from generating so it never feels like a realistic situation its checking. Its great for my other systems like animals walking around but since they are not threaded they tend to be the simpler systems that don't cause problems :D

    However I have used to it get samples as I run stuff through the main thread. So I load a world, turn on deep profile and then as a player break a block (this is a minecraft-esq game) which then updates the chunk on the main thread.

    Once Alexy sees this I will try a deep profile and whatever else he requires at the same time
     
  37. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    @LaireonGames Thank you for more information!
    Looking at the profiler data I'm starting to suspect that GC.Collect might impacts the Editor usability.
    The second screenshot is not related to the first one, but I can see that "Job Worker2" doesn't have "Idle" marker under "Updating Chunks" on the main thread.
    It could be that allocations on "Expand World" cause GC.Collect happen more often. And when it happens Mono pauses all attached threads (which could be main thread and job threads) and you can see that some particular sample takes long time. If e.g. main thread is waiting for a job completion and job thread is paused you'll see most likely Semaphore.WaitForSignal.
    I think we should just add GC.Collect to the top of the timeline view to clearly see when GC.Collect happens.
     
    LaireonGames likes this.
  38. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    Huh interesting. What your saying makes sense but I don't follow how this chain of thought would impact one PC and not the other.

    Regardless of that though, still want me to upload the project or do you now have enough info to try and repo on your end?
     
  39. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    507
    Yes, it doesn't really explain that. I would try to correlate what happens on threads (especially on "Expand World" thread) for i7 and i5 machines - could be that i7 machine does the work faster due to more cores available. How many cores do they have? Do you see the same GC.Alloc pattern on i7?

    I think it would be still useful to upload the project - this issue might be impossible to reproduce without a project and the same hardware setup. It would be useful to add profiler saves alongside the bug.
    There might be multiple factors in play - machine hardware config, machine software setup, unity issues, project issues, etc. - which might be tricky to analyze. If this is a GC.Collect issue, then only changes in the project can fix it. If it is some kind of contention happening due to bad threads setup, then we should fix it.
     
  40. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    Seems so yeah, I also noticed the worker threads are doing a bit more on the I7
    Screenshot_5.png

    Screenshot_1.png

    So the I7 I am using is https://ark.intel.com/content/www/u...-6700k-processor-8m-cache-up-to-4-20-ghz.html

    And the I5: https://ark.intel.com/content/www/u...-7600k-processor-6m-cache-up-to-4-20-ghz.html

    Looks like this means the I7 has 8 threads and the I5 has 4, both on 4 cores.

    Cool, project is uploading now alongside a profiler sample which is 0.5gb for the sample alone! Will let you know the ticket number once its done

    Edit: as a note since you mentioned the GC I checked and both PCs are using the incremental GC, had a nagging worry one was and the other wasn't but it was an unfounded worry!

    Edit 2: upload failed :( trying again
     
    Last edited: Aug 20, 2019
    alexeyzakharov likes this.
  41. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    I keep seeing this as I try to upload the project. Will manually upload it to google drive or something later and try an empty ticket instead that links to it.

    failed upload.png
     
  42. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,292
    How large is the project?

    If it's several gigs, the bug reporter won't handle it. Instead, report a bug without adding the repro and ask for an upload link for a larger project.
     
    LaireonGames likes this.
  43. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    ah duh I had to do this in the past!! It is indeed several gigs, I should have thought about this
     
  44. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    698
    Alright got a ticket made, not uploaded the project yet since QA has not had a chance to reply with an upload link but I did send a profiling dump with it that you should be able to check out right away.

    (Case 1178300) Semaphore.WaitForSignal: Slow Editor
     
    buc and alexeyzakharov like this.
  45. buc

    buc

    Joined:
    Apr 22, 2015
    Posts:
    123
    Having the problem from time to time, but working on the same project and on the same machine. Often a reboot of the OS helped (yes, maybe a useless info, but this was the only thing that helped, restarting unity didn't and the scene wasn't changed/saved, so it was always the same scene).

    It always happened only in the scenes which had Vegetation Studio Pro (my only asset that uses jobs).
    And now I've found something strange: when turning VS pro into instanced- or even normal-rendering mode the FPS go up to 60. When selecting instanced indirect the FPS drop down to 15. Test was in a simple scene with 1 terrain and only 1 tree (this tree was used before in scenes which had no problems and the tree wasn't changed). The jobs debugger is disabled which also drops the FPS to 15.

    With 50GB sending the project doesn't make sense, and it happens only from time to time. So, catching this problem will be tough.
     
  46. Tracecat

    Tracecat

    Joined:
    Mar 20, 2014
    Posts:
    23
    I am having a similar Problem (in Unity 2019.2.2f1) when I select a MeshRenderer (default node in Screenshot) in Prefab mode.
    upload_2019-8-28_13-57-54.png
    This takes over 14 s(!!) until the operation is completed. The Deep profiling showed that there is Semaphore.WaitForSignal involved...

    upload_2019-8-28_13-53-47.png

    This makes prefab mode quite unusable at the moment.
     
  47. eco_bach

    eco_bach

    Joined:
    Jul 8, 2013
    Posts:
    1,601
    Definitely something funky happening in the editor on the mac with 2019.2 and latest HDRP. Perhaps driver related? Notice in the attached in a bare bones scene even though I'm forcing 60 fps I only get 15.
    Same project in Windows not experiencing this slowdown.

    At first I thought simply toggling Vsync from Don't Sync to Every VBlank corrected the issue but on further testing it seems this slowdown is random.

    ie 9/10 times when i playback in the editor I experience the slow down, sometimes only a few frames a second. Every nth time it plays back normally.

    The only fix is to disable HDRP.

    This makes the HDRP totally unusable on the Mac. Can't work like this.

    Unity 2019.2.0f1 Screen Shot 2019-08-30 at 12.28.04 PM.png
     
    Last edited: Aug 30, 2019
  48. CoCoNutti

    CoCoNutti

    Joined:
    Nov 30, 2009
    Posts:
    513
    Same here. I regularly have to force quit (unless it hangs) unity and VS and then reboot my laptop. It's so slow that it's taking me 4 x longer to do any work. Nothing like staring at the rotating rainbow circle.
     
  49. MaxXR

    MaxXR

    Joined:
    Jun 18, 2017
    Posts:
    67
    Getting <1 FPS here in editor - just idle, not play mode - trying to run this project https://github.com/keijiro/Evp3
    2019.1 and 2019.2 otherwise working fine with other projects but for some reason, this Evp3 project screws the system.

    Any idea how to fix?
    Have lodged a bug report.
    2019.1 and exported package and imported to 2019.2 - same problem.
    upload_2019-9-6_18-58-28.png
    Can anyone replicate with this project:
     
  50. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    1,148
    I got a lot of the same issues but i gave up trying to deal with whatever issue i got !