Search Unity

Feedback Improve "GLSL link error" error

Discussion in 'General Graphics' started by Peter77, Dec 25, 2021.

  1. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,618
    In Cloud Diagnostics I'm able to see that some of our players have GLSL link errors, such as this one:
    Code (CSharp):
    1. -------- GLSL link error:  The number of vertex shader storage blocks (1) is greater than the maximum number allowed (0).
    Unfortunately, this message doesn't specify what shader is causing the error. Please add the shader name to the error message.
     
    Ruchir likes this.
  2. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    3,023
    It should say something like
    Note: Creation of internal variant of shader '<Shader name>' failed.
    on the line right after that
     
  3. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,618
    Thank you for the reply.

    I just checked in Cloud Diagnostics, there is no additional output, only the
    GLSL link error
    .
    upload_2022-1-11_9-8-10.png

    1. The build is not using the "Development Build" flag, perhaps that's why the 2nd output is missing?
    2. We're using Unity 2019.4.20f1, perhaps the 2nd line has been added in newer versions only?
     
  4. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    3,023
    @Peter77 do you have access to the raw log there? It should only be there.
     
  5. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,618
    Thank you for your answer.

    The "Log" in Cloud Diagnostics (see screenshot from previous post) is what went through Debug.Log/Error/Warning as far as I know. Cloud Diagnostics doesn't provide a "raw" Log as text for download or so, it only contains the view as shown in the screenshot.

    PS: It still would be useful when the shader name is included in the first error message.
     
  6. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    3,023
    OK, just as I thought :)
    We do print the name of the shader in the raw log. I'll change it to be part of the output to the Console then.
     
  7. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,618
    Awesome, thank you! Would be useful if it can be back-ported to LTS too.
     
  8. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    3,023