[Mesa-dev] [PATCH] glsl/tests: Add UINT64 and INT64 types

tournier.elie tournier.elie at gmail.com
Tue Feb 21 09:54:12 UTC 2017


On 13 February 2017 at 20:35, Rhys Kidd <rhyskidd at gmail.com> wrote:

>
> On Mon, Feb 13, 2017 at 9:43 AM Elie Tournier <tournier.elie at gmail.com>
> wrote:
>
>> Seems good to me.
>>
>> Reviewed-by: Elie Tournier <tournier.elie at gmail.com>
>>
>
> Thanks Elie.
>
> Given we are both "new-er" Mesa contributors I might wait for one more
> Reviewed-by before asking for it to be merged.
>

Ping.
Are you OK with this patch? If yes, can you merge it please?
Thanks
Elie

>
>
>> On Sat, Feb 11, 2017 at 05:31:09PM -0500, Rhys Kidd wrote:
>> > glsl/tests/uniform_initializer_utils.cpp:83:14: warning: enumeration
>> value ‘GLSL_TYPE_UINT64’ not handled in switch [-Wswitch]
>> >        switch (type->base_type) {
>> >               ^
>> > glsl/tests/uniform_initializer_utils.cpp:83:14: warning: enumeration
>> value ‘GLSL_TYPE_INT64’ not handled in switch [-Wswitch]
>> >
>> > Fixes: 8ce53d4a2f3 ("glsl: Add basic ARB_gpu_shader_int64 types")
>> > Signed-off-by: Rhys Kidd <rhyskidd at gmail.com>
>> > ---
>> >  src/compiler/glsl/tests/uniform_initializer_utils.cpp | 18
>> ++++++++++++++++++
>> >  1 file changed, 18 insertions(+)
>> >
>> > diff --git a/src/compiler/glsl/tests/uniform_initializer_utils.cpp
>> b/src/compiler/glsl/tests/uniform_initializer_utils.cpp
>> > index ec64be1..2a1a168 100644
>> > --- a/src/compiler/glsl/tests/uniform_initializer_utils.cpp
>> > +++ b/src/compiler/glsl/tests/uniform_initializer_utils.cpp
>> > @@ -96,6 +96,12 @@ generate_data_element(void *mem_ctx, const glsl_type
>> *type,
>> >        case GLSL_TYPE_DOUBLE:
>> >        data.d[i] = double(values[idx]);
>> >        break;
>> > +      case GLSL_TYPE_UINT64:
>> > +      data.u64[i] = (uint64_t) values[idx];
>> > +      break;
>> > +      case GLSL_TYPE_INT64:
>> > +      data.i64[i] = (int64_t) values[idx];
>> > +      break;
>> >        case GLSL_TYPE_ATOMIC_UINT:
>> >        case GLSL_TYPE_STRUCT:
>> >        case GLSL_TYPE_ARRAY:
>> > @@ -130,6 +136,12 @@ generate_data_element(void *mem_ctx, const
>> glsl_type *type,
>> >        case GLSL_TYPE_DOUBLE:
>> >        ASSERT_EQ(data.d[i], val->value.d[i]);
>> >        break;
>> > +      case GLSL_TYPE_UINT64:
>> > +      ASSERT_EQ(data.u64[i], val->value.u64[i]);
>> > +      break;
>> > +      case GLSL_TYPE_INT64:
>> > +      ASSERT_EQ(data.i64[i], val->value.i64[i]);
>> > +      break;
>> >        case GLSL_TYPE_ATOMIC_UINT:
>> >        case GLSL_TYPE_STRUCT:
>> >        case GLSL_TYPE_ARRAY:
>> > @@ -236,6 +248,12 @@ verify_data(gl_constant_value *storage, unsigned
>> storage_array_size,
>> >        case GLSL_TYPE_DOUBLE:
>> >           EXPECT_EQ(val->value.d[i], *(double *)&storage[i*2].i);
>> >           break;
>> > +      case GLSL_TYPE_UINT64:
>> > +         EXPECT_EQ(val->value.u64[i], *(uint64_t *)&storage[i*2].i);
>> > +         break;
>> > +      case GLSL_TYPE_INT64:
>> > +         EXPECT_EQ(val->value.i64[i], *(int64_t *)&storage[i*2].i);
>> > +         break;
>> >           case GLSL_TYPE_ATOMIC_UINT:
>> >        case GLSL_TYPE_STRUCT:
>> >        case GLSL_TYPE_ARRAY:
>> > --
>> > 2.9.3
>> >
>> > _______________________________________________
>> > mesa-dev mailing list
>> > mesa-dev at lists.freedesktop.org
>> > https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20170221/59b8fc57/attachment-0001.html>


More information about the mesa-dev mailing list