<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><span class="vcard"><a class="email" href="mailto:jason@jlekstrand.net" title="Jason Ekstrand <jason@jlekstrand.net>"> <span class="fn">Jason Ekstrand</span></a>
</span> changed
<a class="bz_bug_link
bz_status_NEW "
title="NEW - [SNB,HSW,BYT] dEQP regressions associated with using NIR for vertex shaders"
href="https://bugs.freedesktop.org/show_bug.cgi?id=91719">bug 91719</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;">CC</td>
<td>
</td>
<td>mattst88@gmail.com
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - [SNB,HSW,BYT] dEQP regressions associated with using NIR for vertex shaders"
href="https://bugs.freedesktop.org/show_bug.cgi?id=91719#c1">Comment # 1</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - [SNB,HSW,BYT] dEQP regressions associated with using NIR for vertex shaders"
href="https://bugs.freedesktop.org/show_bug.cgi?id=91719">bug 91719</a>
from <span class="vcard"><a class="email" href="mailto:jason@jlekstrand.net" title="Jason Ekstrand <jason@jlekstrand.net>"> <span class="fn">Jason Ekstrand</span></a>
</span></b>
<pre>After a bit more analysis, this bug appears to be a coalescing bug. Thanks to
Kristian for spotting the broken swizzle! What happens is that NIR gives us
vec1 ssa_9 = imul ssa_7, ssa_8
vec4 ssa_10 = vec4 ssa_2, ssa_2.y, ssa_9, ssa_2.z
in SSA which then becomes
r7 = imul r5, r6
r8.xyw = imov ssa_2.xyz
r8.z = imov r7.x
When we go out of SSA. This then turns into
9: mul acc0:D, vgrf5.xyzw:D, u0.xyzw:D
10: mach null:D, vgrf5.xyzw:D, u0.xyzw:D
11: mov vgrf7.0.x:D, acc0.xxxx:D
12: mov vgrf8.0.xyw:D, vgrf13.xyxz:D
13: mov vgrf8.0.z:D, vgrf7.xyxw:D
which register coalesce happily turns into
9: mul acc0:D, vgrf5.xyzw:D, u0.xyzw:D
10: mach null:D, vgrf5.xyzw:D, u0.xyzw:D
11: mov vgrf8.0.z:D, acc0.xxxx:D
Note that we completely miss the fact that line 13 above moves the x channel to
the z channel and we just coalesce to mask out all but z. The result is that
mul/mach write to .x but we read from .z. If I run the test with register
coalescing turned off, it passes.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the QA Contact for the bug.</li>
</ul>
</body>
</html>