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

Unity hung after I started 2018.1.0b2 and opened shader example

Discussion in '2018.1 Beta' started by CGinSeattle, Jan 10, 2018.

  1. CGinSeattle

    CGinSeattle

    Joined:
    Jul 20, 2013
    Posts:
    15
    Installed Unity beta with no issues on Windows 8.1 Desktop machine.
    Downloaded the shader node demo and unzipped it.
    Ran Unity and opened the demo.
    Loaded up Nightmare scene.
    Realized that I had to double click on the shader (in Projects) and that would bring up the shader node interface. Brought up the Eyes and looked around. Then brought up the Helioxxx shader and looked at it.
    Right clicked along the way to bring up the Node menu and looked at items. Created and deleted several in the process.
    Went and did something else for awhile (mail, internet, etc.)
    When I came back and tried to get back to the still open shader window. Unity had hung.
    Can not give you crash report because I finally had to shut it down via TaskManager.
     
  2. KevinMaxon

    KevinMaxon

    Unity Technologies

    Joined:
    Oct 11, 2017
    Posts:
    12
    Oh no! Sorry about that! Thanks for the detailed report, I'll look into it.
     
  3. CGinSeattle

    CGinSeattle

    Joined:
    Jul 20, 2013
    Posts:
    15
    Thanks, I should add that it (Unity) was sitting at around 600+ megs according to Taskmanager and overall Desktop Memory was tasked at over 85% (or something like that). Other apps like Outlook, Corel Painter 10, and Expression Design were also running but the latter two were not currently in use (they were minimized and had been overnight). Chrome (with about 50 tabs overall was also up and running. It showed definite slowness when Unity was also began, but up until that point (when I was using Unity) beyond having to wait for things to come up (Chrome and Unity being slower...i.e. definitely heavy memory use), everyone seemed to be playing nicely together.
    Cheers!
     
    KevinMaxon likes this.
  4. RuinsOfFeyrin

    RuinsOfFeyrin

    Joined:
    Feb 22, 2014
    Posts:
    785
    Its because you were using to much of your memory on your system. Based on the applications you listed, you are running a windows PC. I have never seen a windows PC that likes to have 80% of its total memory in use and doesnt start trying to kill stuff.

    In this scenario on MY PC with any version of unity, my unity will complete freeze until i have freed mymemory below 80%. In addition windows usually comes up with a pop up telling me its running low on memory an ALWAYS suggest to close the unity editor, even though most times it is using far less memory then other applications.

    So i would say more then likely this was not an issue with the beta, but a windows memory thing ;)
     
  5. CGinSeattle

    CGinSeattle

    Joined:
    Jul 20, 2013
    Posts:
    15
    Very possibly, which is why I included that information. Though, it wasn't behaving that way before - but only after it had sat for a long time. And the other apps weren't using near that much memory.

    600Meg just at startup of Unity with one sample loaded? It's a bit excessive compared with other apps, including DCC apps I have. My older Unity versions do not grab that much memory at startup or hours later with constant use. Before I would condemn my PC, I would look for memory leaks in my app or ask why it needed so much on load. But that's just me.
    Cheers!
     
  6. RuinsOfFeyrin

    RuinsOfFeyrin

    Joined:
    Feb 22, 2014
    Posts:
    785
    You left it sit, did more stuff and used more memory, which caused the issue when you went back to it. The amount of memory any given app is irrelevant, all that matters is the total system memory used.

    Again, the amount of memory used at startup is irrelevant to the issue you are reporting. Even a memory leak would be irrelevant. The issue you reported as happening will happen anytime you use more then 80% of your systems available memory, on any version of unity, and is not something specific to unity. Windows does not like it when you use more then 80% of the available memory on a system and will exhibit this behavior even if unity is not open. If unity is open however, it likes to target unity first for some reason as an application it wants to mess with.

    The issue was that the editor crashed. The cause was your system memory usage went to high. No ones condemning your pc, I'm simply explaining how widows works in that situation.
     
  7. CGinSeattle

    CGinSeattle

    Joined:
    Jul 20, 2013
    Posts:
    15
    Thank you but I'm quite aware of how Windows works. I used to be a dev there and was quite familiar with the OS. I am still highly suspicious of Unity's memory startup and hogging of that much memory over time.And that I have had earlier versions of Unity behave quite well under similar circumstances. I gave them the facts in as much detail as I could so they could investigate and try to replicate the behavior. You have stated your belief, but you cannot state it as fact, because it is not. It's up to Unity to figure out if there is an issue and it would be premature to assume anything during a beta.
    Best regards,
     
  8. CGinSeattle

    CGinSeattle

    Joined:
    Jul 20, 2013
    Posts:
    15
    Update: Tried it again. Unity loaded at 350+ Meg. Running fine in a system that was already at 79% memory. It took it up to 83%. Then it began to rapidly increase memory usage to 450Mg then 490Meg when I opened the shader graph editor and then again (when I clicked the other shader...note: I did not realize previously that it opens a new graph editor for each shader you double click).

    Released the shader graph editors (closed them) but Unity never gave back the memory. Reopened them and noticed another surge in memory. Left them open, the memory kept rising slowly. Even though Unity was running fine at 88% memory usage on desktop. (as well as other apps) Unity releases the CPU when it's in background, but never the memory and memory continues to climb over time. Until it hung again at 520Mg with 88% memory now, and it's use of the CPU dropped to 0%. Shader graph editors for two shaders were open. All other apps still behaving as normal.

    Closing other apps to bring memory usage down does not work. Tried bringing down practically everything. Unity is hung and unresponsive, period. Brought everything I'd closed back up after a while, and they worked just fine, even with memory impacted so high.

    In my mind, that is either a memory leak or bad memory management on Unity's side, but that's up your troubleshooters. It could be Windows freezing Unity , but somehow, with this behavior, I doubt it - I saw this same behavior with my plugin when it was having a massive memory leak (and I had Visual Studio and Unity ...and MonoDevelop running as well as Chrome and Outlook, which pushed the memory use way up...Even with that, I was able to run them all without issue on my machine, and break into the GP fault that my plugin was causing.)

    Anyway, I hope this report helps.
     
    Last edited: Jan 11, 2018
    KevinMaxon likes this.
  9. KevinMaxon

    KevinMaxon

    Unity Technologies

    Joined:
    Oct 11, 2017
    Posts:
    12
    Thanks so much. I'll look into our memory management today.