<html>
    <head>
      <base href="https://bugs.freedesktop.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - [r600 llvm backend] Assert with 32-bit lightsmark, TF2 when shader dump is enabled"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=66883">66883</a>
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>dri-devel@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[r600 llvm backend] Assert with 32-bit lightsmark, TF2 when shader dump is enabled
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>ptpzz@yandex.ru
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>git
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Drivers/Gallium/r600
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>Mesa
          </td>
        </tr></table>
      <p>
        <div>
        <pre>I have asserts in the middle of shader dump in llvm backend with 32-bit Team
Fortress 2 and Lightsmark, R600_DEBUG=ps,vs. Here is message with Lightsmark:

...
ALU_CLAUSE 8; dbg:backend: DebugLoc.cpp:27: llvm::MDNode*
llvm::DebugLoc::getScope(const llvm::LLVMContext&) const: Assertion
`unsigned(ScopeIdx) <= Ctx.pImpl->ScopeRecords.size() && "Invalid ScopeIdx!"'
failed.

TF2 message:

...
ALU_CLAUSE 32; dbg:hl2_linux: DebugLoc.cpp:33: llvm::MDNode*
llvm::DebugLoc::getScope(const llvm::LLVMContext&) const: Assertion
`unsigned(-ScopeIdx) <= Ctx.pImpl->ScopeInlinedAtRecords.size() && "Invalid
ScopeIdx"' failed.

It seems in both cases it happens on ALU clause start in the dump.
So far I can't reproduce this issue with 64-bit Lightsmark/mesa/llvm.</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>