<div dir="ltr">On 19 October 2013 02:25, Timothy Arceri <span dir="ltr"><<a href="mailto:t_arceri@yahoo.com.au" target="_blank">t_arceri@yahoo.com.au</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im"><br>
<br>
On Fri, 2013-10-18 at 10:26 -0700, Paul Berry wrote:<br>
> On 5 October 2013 04:21, Timothy Arceri <<a href="mailto:t_arceri@yahoo.com.au">t_arceri@yahoo.com.au</a>> wrote:<br>
<br>
<br>
</div><div class="im">> General comment: it seems redundant to have "arb_arrays_of_arrays" in<br>
> the folder name and "array-of-array-" as a prefix to each parser test.<br>
> Can we remove "array-of-array-" from the parser test file names (so<br>
> for example<br>
> tests/spec/arb_arrays_of_arrays/compiler/array-of-array-uniform.vert<br>
> becomes tests/spec/arb_arrays_of_arrays/compiler/uniform.vert).<br>
<br>
</div>Sure.<br>
<div class="im"><br>
><br>
> Calling this test "new syntax" is confusing.  All three of these<br>
> syntaxes are new:<br>
><br>
><br>
> vec4[3][2] a;<br>
> vec4[2] a[3];<br>
><br>
> vec4 a[3][2];<br>
><br>
><br>
> I'd suggest a naming convention that just names the syntax elements in<br>
> the order they appear.  So for instance:<br>
><br>
><br>
> vec4[3][2] a; // tested by *-array-array-var<br>
><br>
> vec4[2] a[3]; // tested by *-array-var-array<br>
><br>
> vec4 a[3][2]; // tested by *-var-array-array<br>
<br>
</div>Ok, yes I like this much better. I didn't really like the other naming<br>
much either I just copied it from some of the existing glsl tests that<br>
test for a fail against this format.<br>
<div class="im">><br>
> <br>
>         @@ -0,0 +1,17 @@<br>
>         +/* [config]<br>
>         + * expect_result: pass<br>
>         + * glsl_version: 1.20<br>
>         + * require_extensions: GL_ARB_arrays_of_arrays<br>
>         + * [end config]<br>
>         + */<br>
>         +#version 120<br>
>         +#extension GL_ARB_arrays_of_arrays: enable<br>
>         +<br>
>         +attribute vec4 vert;<br>
>         +<br>
>         +void foo(vec4 [2] x[2]);<br>
>         +<br>
>         +void main()<br>
>         +{<br>
><br>
><br>
> It would be nice to include a call to the function here in main(), so<br>
> that we can verify that the compiler's type checking logic correctly<br>
> deduces that the function can be called.<br>
<br>
</div>Sure.<br>
<div><div class="h5">><br>
> <br>
>         +  gl_Position = vert;<br>
>         +}<br>
>         diff --git<br>
>         a/tests/spec/arb_arrays_of_arrays/compiler/array-of-array-function-parameter-declaration.vert b/tests/spec/arb_arrays_of_arrays/compiler/array-of-array-function-parameter-declaration.vert<br>
>         new file mode 100644<br>
>         index 0000000..60fec71<br>
>         --- /dev/null<br>
>         +++<br>
>         b/tests/spec/arb_arrays_of_arrays/compiler/array-of-array-function-parameter-declaration.vert<br>
>         @@ -0,0 +1,17 @@<br>
>         +/* [config]<br>
>         + * expect_result: pass<br>
>         + * glsl_version: 1.20<br>
>         + * require_extensions: GL_ARB_arrays_of_arrays<br>
>         + * [end config]<br>
>         + */<br>
>         +#version 120<br>
>         +#extension GL_ARB_arrays_of_arrays: enable<br>
>         +<br>
>         +attribute vec4 vert;<br>
>         +<br>
>         +void foo(vec4 x[2][3]);<br>
>         +<br>
>         +void main()<br>
>         +{<br>
><br>
><br>
> Same comment applies here.<br>
><br>
> <br>
>         +  gl_Position = vert;<br>
>         +}<br>
><br>
><br>
> Can we also add a test to verify that the following works:<br>
><br>
> void foo(vec4[3][2] x);<br>
><br>
><br>
> (this is explicitly allowed by the spec).<br>
><br>
><br>
> A similar comment goes for all the other tests in this patch.<br>
<br>
</div></div>ok will do.<br>
<div class="im"><br>
<br>
><br>
> As a side note, are you planning to add other tests in subsequent<br>
> patches?  Glancing at the spec, it seems like there's a lot more that<br>
> still needs to be tested.<br>
<br>
</div>Yes I plan to send patches to cover more scenarios. I have been playing<br>
around with Mesa trying to implement the extension when time permits and<br>
have had these tests sitting around for a while. I thought I would<br>
submit what I had to get some feedback before continuing work on more as<br>
it seems I will have to create a fairly large amount of tests, I'm glad<br>
I did as it would have been a pain to have to go back retrospectively<br>
and rename them all, but I'm sorry if I have wasted your time this was<br>
not my intention. I will try submit the remaining tests as a series for<br>
the compiler tests rather than sending in bits and pieces.<br></blockquote><div><br></div><div>You weren't wasting my time at all.  I wish more people would submit things in small batches and get feedback early.  It makes the whole process run more smoothly.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Thanks for the feedback.<br>
<br>
Tim<br>
</blockquote></div><br></div></div>