[Mesa-dev] [PATCH 6/9] glsl/blob: add valgrind checks that written data is defined
Emil Velikov
emil.l.velikov at gmail.com
Mon Jun 26 14:22:21 UTC 2017
On 26 June 2017 at 10:40, Nicolai Hähnle <nhaehnle at gmail.com> wrote:
> From: Nicolai Hähnle <nicolai.haehnle at amd.com>
>
> Undefined data will eventually trigger a valgrind error while computing
> its CRC32 while writing it into the disk cache, but at that point, it is
> basically impossible to track down where the undefined data came from.
>
> With this change, finding the origin of undefined data becomes easy.
> ---
> src/compiler/Makefile.am | 2 ++
> src/compiler/glsl/blob.c | 12 ++++++++++++
> 2 files changed, 14 insertions(+)
>
> diff --git a/src/compiler/Makefile.am b/src/compiler/Makefile.am
> index d52da91..dcbd63e 100644
> --- a/src/compiler/Makefile.am
> +++ b/src/compiler/Makefile.am
> @@ -32,24 +32,26 @@ AM_CPPFLAGS = \
> -I$(top_srcdir)/src/compiler/glsl\
> -I$(top_srcdir)/src/compiler/glsl/glcpp\
> -I$(top_builddir)/src/compiler/nir \
> -I$(top_srcdir)/src/compiler/nir \
> -I$(top_srcdir)/src/gallium/include \
> -I$(top_srcdir)/src/gallium/auxiliary \
> -I$(top_srcdir)/src/gtest/include \
> $(DEFINES)
>
> AM_CFLAGS = \
> + $(VALGRIND_CFLAGS) \
You can move this to AM_CPPFLAGS above and drop the duplicate line in CXXFLAGS.
> $(VISIBILITY_CFLAGS) \
> $(MSVC2013_COMPAT_CFLAGS)
>
> AM_CXXFLAGS = \
> + $(VALGRIND_CFLAGS) \
> $(VISIBILITY_CXXFLAGS) \
> $(MSVC2013_COMPAT_CXXFLAGS)
>
With the above, patch is
Reviewed-by: Emil Velikov <emil.velikov at collabora.com>
-Emil
More information about the mesa-dev
mailing list