diff --git a/tools/run-valgrind.py b/tools/run-valgrind.py index 67fa424584e..bfb67d36194 100755 --- a/tools/run-valgrind.py +++ b/tools/run-valgrind.py @@ -37,7 +37,9 @@ NODE_ROOT = path.dirname(path.dirname(path.abspath(__file__))) VALGRIND_ARGUMENTS = [ 'valgrind', '--error-exitcode=1', - '--smc-check=all', + '--smc-check=all-non-file', + '--suppressions=' + path.join(NODE_ROOT, 'tools', 'valgrind.supp'), + '--gen-suppressions=all', ] if len(sys.argv) < 2: @@ -50,7 +52,8 @@ if not path.exists(executable): sys.exit(1) # Compute the command line. -command = VALGRIND_ARGUMENTS + [executable] + sys.argv[2:] +command = VALGRIND_ARGUMENTS + [executable, '--zero-fill-buffers'] +command += sys.argv[2:] # Run valgrind. process = subprocess.Popen(command, stderr=subprocess.PIPE) diff --git a/tools/valgrind.supp b/tools/valgrind.supp new file mode 100644 index 00000000000..420c9a5171c --- /dev/null +++ b/tools/valgrind.supp @@ -0,0 +1,106 @@ +{ + + Helgrind:Race + ... + fun:_ZN4node12_GLOBAL__N_1L20PlatformWorkerThreadEPv + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v88platform7tracing17TracingController31GetCategoryGroupEnabledInternalEPKc + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v86Locker8IsActiveEv + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v86Locker10InitializeEPNS_7IsolateE + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v88internal7Isolate15SetEmbeddedBlobEPKhj + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v88internal4Heap14SetStackLimitsEv + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v88internal7Isolate23CurrentEmbeddedBlobSizeEv + ... +} +{ + + Helgrind:Race + ... + fun:_ZN2v88internal7Isolate19CurrentEmbeddedBlobEv + ... +} +{ + + Memcheck:Param + epoll_ctl(event) + fun:epoll_ctl + fun:uv__io_poll + ... + obj:/home/sqrt/src/node/master/out/Release/node +} +{ + + Memcheck:Cond + ... + fun:_ZN2v88internal9ExitFrame23GetStateForFramePointerEmPNS0_10StackFrame5StateE + ... +} +{ + + Memcheck:Leak + match-leak-kinds: possible + ... + fun:pthread_create* + fun:_ZN4node9inspector12_GLOBAL__N_1L23StartDebugSignalHandlerEv + ... +} +{ + + Memcheck:Param + ioctl(generic) + fun:* + fun:uv__fs_copyfile + ... +} +{ + + Memcheck:Param + epoll_pwait(sigmask) + fun:* + fun:uv__io_poll + ... +} +{ + + Helgrind:Race + ... + fun:uv_loop_close + fun:_ZN4node18CheckedUvLoopCloseEP9uv_loop_s + fun:_ZZN4node23WorkerThreadsTaskRunner20DelayedTaskScheduler5StartEvENUlPvE_4_FUNES2_ + ... +}