<html>
<head>
<base href="https://bugs.freedesktop.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - [swrast] piglit glsl-array-bounds-01 regression"
href="https://bugs.freedesktop.org/show_bug.cgi?id=96684#c3">Comment # 3</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - [swrast] piglit glsl-array-bounds-01 regression"
href="https://bugs.freedesktop.org/show_bug.cgi?id=96684">bug 96684</a>
from <span class="vcard"><a class="email" href="mailto:t_arceri@yahoo.com.au" title="Timothy Arceri <t_arceri@yahoo.com.au>"> <span class="fn">Timothy Arceri</span></a>
</span></b>
<pre>I think the test is wrong, it should not be expecting a specific outcome.
The spec says:
"Behavior is undefined if a shader subscripts an array with an index less than
0 or greater than or equal to the size the array was declared with."
And the test is doing:
float array[] = float [] (1.0, 2.0, 3.0, 4.0);
void main()
{
int idx = 20;
if (array[idx] == 5.0)
gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0);
else
gl_FragColor = vec4(0.0, 1.0, 0.0, 1.0);
}
So the result is undefined.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the QA Contact for the bug.</li>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>