summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorThiago Marcos P. Santos <thiago@mapbox.com>2016-06-08 14:57:46 +0300
committerThiago Marcos P. Santos <thiago@mapbox.com>2016-06-09 19:56:35 +0300
commit8bbb7216367890b9a8d0e5bc7899d180e3af1e87 (patch)
treed887e2658b0769918cb641c734189a6402102170 /scripts
parentfd8753748267de7c7a729c53e714ba6f55fa06b4 (diff)
downloadqtlocation-mapboxgl-8bbb7216367890b9a8d0e5bc7899d180e3af1e87.tar.gz
[Qt][build] Updated valgrind supression and make it a target for Qt
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/valgrind.sh16
-rw-r--r--scripts/valgrind.sup159
2 files changed, 141 insertions, 34 deletions
diff --git a/scripts/valgrind.sh b/scripts/valgrind.sh
new file mode 100755
index 0000000000..009e18c432
--- /dev/null
+++ b/scripts/valgrind.sh
@@ -0,0 +1,16 @@
+#!/usr/bin/env bash
+
+set -e
+set -o pipefail
+
+PARAMS="\
+ --leak-check=full \
+ --show-leak-kinds=definite \
+ --errors-for-leak-kinds=definite \
+ --error-exitcode=1 \
+ --gen-suppressions=all \
+ --suppressions=scripts/valgrind.sup"
+
+export VALGRIND_LIB=$(.mason/mason prefix valgrind latest)/lib/valgrind
+
+$(.mason/mason prefix valgrind latest)/bin/valgrind $PARAMS $@
diff --git a/scripts/valgrind.sup b/scripts/valgrind.sup
index fcde049d9c..f21f54be54 100644
--- a/scripts/valgrind.sup
+++ b/scripts/valgrind.sup
@@ -1,91 +1,182 @@
{
- Valgrind gets confused with buffers managed by the graphics driver
+ Graphics driver buffers
Memcheck:Leak
...
- obj:/usr/*/dri/r600_dri.so
+ obj:*/r600_dri.*
+ obj:*/r600_dri.*
+ obj:*/r600_dri.*
...
}
{
- GLFW _glfwCreateCursor()
+ Graphics driver buffers
Memcheck:Leak
- match-leak-kinds: reachable
...
- obj:/usr/*/libX11.so.6.3.0
+ obj:*/i965_dri.*
+ obj:*/i965_dri.*
+ obj:*/i965_dri.*
...
- fun:_glfwCreateCursor
+}
+{
+ Graphics driver buffers
+ Memcheck:Leak
+ ...
+ obj:*/nouveau_dri.*
+ obj:*/nouveau_dri.*
+ obj:*/nouveau_dri.*
...
}
{
- GLFW _glfwPlatform*()
+ Ubuntu 16.04 - GLFW
Memcheck:Leak
- match-leak-kinds: reachable
...
- fun:_glfwPlatform*
+ fun:glfwInit
...
}
{
- Buffer managed by OpenGL?
+ Ubuntu 16.04 - GLFW
Memcheck:Cond
...
- fun:_ZN4mbgl*Uniform*
+ fun:glfwInit
...
- fun:_ZN8GLFWView10invalidateEv
+}
+{
+ Ubuntu 16.04 - Qt + glib
+ Memcheck:Cond
+ fun:g_utf8_offset_to_pointer
...
}
{
- Buffer managed by OpenGL?
+ Ubuntu 16.04 - Qt + glib
Memcheck:Cond
- fun:_ZNSt7__equalILb0EE5equalIPKfS3_EEbT_S4_T0_
...
- fun:_ZN4mbgl7Painter11renderLayerERKNS_10StyleLayerEPKNS_4Tile2IDEPKSt5arrayIfLm16EE
+ fun:g_signal_emit_valist
+ ...
+ fun:*QApplicationPrivate*
+ ...
+}
+{
+ Ubuntu 16.04 - Qt + X11
+ Memcheck:Param
+ writev(vector[...])
+ ...
+ obj:*/libxcb.*
+ fun:xcb_flush
+ ...
}
{
- Valgrind doesn't like our make_unique (C++14 polyfill)
+ Ubuntu 16.04 - Qt + X11
Memcheck:Leak
- match-leak-kinds: reachable
- fun:malloc
...
- fun:_ZN4mbgl4util11make_unique*
+ fun:_XmbTextListToTextProperty
+ ...
+ fun:*QWidget*setVisible*
...
}
{
- dlopen doing its magic
+ Ubuntu 16.04 - Qt + Fontconfig
Memcheck:Leak
- match-leak-kinds: reachable
...
- fun:_dl_open
+ obj:*/libfontconfig.*
+ obj:*/libfontconfig.*
+ ...
+ fun:FcFontRenderPrepare
...
}
{
- X11 false positive
+ Ubuntu 16.04 - Qt + Fontconfig
Memcheck:Leak
- match-leak-kinds: reachable
...
- obj:/usr/*/libX11.so.6.3.0
+ obj:*/libfontconfig.*
+ obj:*/libfontconfig.*
...
- fun:_XrmInitParseInfo
+ fun:FcPatternAddInteger
...
}
{
- OpenSSL false positive
+ Ubuntu 16.04 - Qt + Fontconfig
Memcheck:Leak
...
- fun:CRYPTO_malloc
+ obj:*/libfontconfig.*
+ obj:*/libfontconfig.*
+ ...
+ fun:FcConfigParseAndLoad
...
}
{
- OpenSSL false positive
+ Ubuntu 16.04 - Qt + Dbus
Memcheck:Leak
...
- fun:CRYPTO_realloc
+ fun:dbus_connection_send_with_reply
...
+ fun:*QWidget*
}
{
- Libcurl false positive
+ Ubuntu 16.04 - Qt + Dbus
+ Memcheck:Leak
+ ...
+ fun:px_proxy_factory_get_proxies
+ obj:*/libQt5Network.*
+}
+{
+ Ubuntu 16.04 - Qt
Memcheck:Leak
- fun:malloc
...
- obj:/usr/*/libcurl.so.4.3.0
- fun:curl_multi_socket_action
+ fun:*QGuiApplicationPrivate*createEventDispatcher*
+ fun:*QCoreApplication*init*
+ ...
+}
+{
+ Ubuntu 16.04 - Qt
+ Memcheck:Leak
+ ...
+ fun:*QWidget*setWindowTitle*
+ ...
+}
+{
+ Ubuntu 16.04 - Qt
+ Memcheck:Leak
+ ...
+ fun:*QNetworkConfigurationManagerPrivate*updateConfigurations*
+ ...
+}
+{
+ Ubuntu 16.04 - Mysterious leak when running utests
+ Memcheck:Leak
+ fun:calloc
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+}
+{
+ Ubuntu 16.04 - Mysterious leak when running utests
+ Memcheck:Leak
+ fun:malloc
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+ obj:*
+}
+{
+ Ubuntu 14.04 - Travis CI bot using swrast
+ Memcheck:Cond
+ fun:do_stencil_test
+ fun:_swrast_stencil_and_ztest_span
+ fun:_swrast_write_rgba_span
+ fun:draw_wide_line
...
}