<html>
    <head>
      <base href="https://bugs.freedesktop.org/">
    </head>
    <body><span class="vcard"><a class="email" href="mailto:samuel.pitoiset@gmail.com" title="Samuel Pitoiset <samuel.pitoiset@gmail.com>"> <span class="fn">Samuel Pitoiset</span></a>
</span> changed
          <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED NOTOURBUG - Running ConeStepMap in wine freezes the system"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=102633">bug 102633</a>
          <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">Resolution</td>
           <td>---
           </td>
           <td>NOTOURBUG
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Status</td>
           <td>NEW
           </td>
           <td>RESOLVED
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED NOTOURBUG - Running ConeStepMap in wine freezes the system"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=102633#c2">Comment # 2</a>
              on <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED NOTOURBUG - Running ConeStepMap in wine freezes the system"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=102633">bug 102633</a>
              from <span class="vcard"><a class="email" href="mailto:samuel.pitoiset@gmail.com" title="Samuel Pitoiset <samuel.pitoiset@gmail.com>"> <span class="fn">Samuel Pitoiset</span></a>
</span></b>
        <pre>Thanks for reporting this.

I'm able to reproduce the hang with the following environment:

OpenGL renderer string: AMD Radeon (TM) RX 480 Graphics (POLARIS10 / DRM 3.19.0
/ 4.13.0-rc5-ARCH+, LLVM 6.0.0)
OpenGL core profile version string: 4.5 (Core Profile) Mesa 17.3.0-devel
(git-8e8c7c6703)

No VM faults are reported, but it appears that one shader is stucked because
some uniform variables are undefined and it loops indefinitely.

When replaying the trace, I get a bunch of errors like:

Mesa: User error: GL_INVALID_OPERATION in glUniform(location=18)
4867496: message: major api error 3: GL_INVALID_OPERATION in
glUniform(location=18)
4867496 @0 glUniform1ivARB(location = 18, count = 1, value = &0)
4867496: warning: glGetError(glUniform1ivARB) = GL_INVALID_OPERATION

Basically, the app is trying to update a uniform variable with an invalid
location.

After looking at the trace, the app assumes that uniform locations are fixed,
which is wrong (except if they are explicitly set inside the shader). Instead,
new locations are generated after each successful re-link, which is why
GetUniformLocation exists (and the app never calls it).

The GLSL compiler doesn't allocate locations for built-in uniform variables
like gl_ModelViewMatrix which explains the above errors. The attached (hacky)
patch fixes the hang but don't except this to be upstream, the application is
buggy.

Though, it would be doable to add new drirc option like
glsl_force_fixed_locations but I personally don't want to introduce new hacks
in Mesa.

Closing.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>