Re: [Mesa-dev] [PATCH] r600: compare structure elements instead of doing a memcmp

2018-07-02 Thread Roland Scheidegger
Looks good to me. Although I wonder if it wouldn't be a good idea to make sure it's actually all initialized (via memset). But I think that's not quite consistently handled the same everywhere (that is, some things are memset, some are not). (There might be similar bugs lurking elswhere, but OTOH t

[Mesa-dev] [PATCH] r600: compare structure elements instead of doing a memcmp

2018-07-01 Thread Gert Wollny
From: Gert Wollny Structures might be padded by the compiler and these padding bytes remain un-initialized which in turn makes memcmp return a difference where from the logical point of view there is none. Fixes valgrind: Conditional jump or move depends on uninitialised value(s) at