Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Bug Synchronous Shader Compilation slow / bugged in 2022?

Discussion in 'Shaders' started by AcidArrow, Aug 17, 2023.

  1. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    10,977
    Why is synchronous shader compilation so slow and distracting in 2022? There didn't use to be a pop up and the editor would maybe miss a frame or two and then it'd be done. Now there are a bunch of pop ups and the whole process takes like 10x more time and is super distracting.



    The video is with the first LTS but the issue hasn't changed as of .7.
     
  2. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,835
    Hi!
    Which render pipeline are you using?
     
  3. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    10,977
    Built in.
     
  4. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,835
    Would it be possible for you to create a bug report? I'd like to check what's going on there.
     
  5. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    10,977
    I did, a couple of months ago, but I didn't want to upload the whole project, so I submitted without a repro and apparently the video and the logs weren't enough and the bug was closed.

    I'm using all custom vert frag shaders, haven't had this issue with 2021. When 2021 loads the shaders, it maybe hitches for 1 frame, if that (and there's no pop up) so the experience is much smoother.

    I'll see if I can find the time on the weekend to do a minimal repro.
     
    aleksandrk likes this.
  6. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    10,977
    I just submitted a bug report, it's IN-53978

    Here is a comparison video 2021 vs 2022 in a minimal repro scene:


    I guess we can work around this one by enabling async shader compilation, but I find the cyan color the objects have while loading far more distracting than the minimal hitch 2021 has (and also the hitch behaviour is closer to what happens when built on a device, so I don't know what I'm gaining by async shader compilation in the editor).

    In any case, I fully expect QA will not be able to reproduce, which is fine, we are probably going to skip 2022, it would be nice if some of these issues were fixed for 2023 though.
     
    Last edited: Sep 6, 2023
    aleksandrk likes this.
  7. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,835
    Please report back when you get a reply from them.
    Thank you!
     
  8. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    10,977
    I'm starting to think this is an "if" and not a "when"...
     
  9. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,835
    Let me try and poke Customer QA :)
     
    AcidArrow likes this.