You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(122) |
Nov
(152) |
Dec
(69) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(6) |
Feb
(25) |
Mar
(73) |
Apr
(82) |
May
(24) |
Jun
(25) |
Jul
(10) |
Aug
(11) |
Sep
(10) |
Oct
(54) |
Nov
(203) |
Dec
(182) |
2004 |
Jan
(307) |
Feb
(305) |
Mar
(430) |
Apr
(312) |
May
(187) |
Jun
(342) |
Jul
(487) |
Aug
(637) |
Sep
(336) |
Oct
(373) |
Nov
(441) |
Dec
(210) |
2005 |
Jan
(385) |
Feb
(480) |
Mar
(636) |
Apr
(544) |
May
(679) |
Jun
(625) |
Jul
(810) |
Aug
(838) |
Sep
(634) |
Oct
(521) |
Nov
(965) |
Dec
(543) |
2006 |
Jan
(494) |
Feb
(431) |
Mar
(546) |
Apr
(411) |
May
(406) |
Jun
(322) |
Jul
(256) |
Aug
(401) |
Sep
(345) |
Oct
(542) |
Nov
(308) |
Dec
(481) |
2007 |
Jan
(427) |
Feb
(326) |
Mar
(367) |
Apr
(255) |
May
(244) |
Jun
(204) |
Jul
(223) |
Aug
(231) |
Sep
(354) |
Oct
(374) |
Nov
(497) |
Dec
(362) |
2008 |
Jan
(322) |
Feb
(482) |
Mar
(658) |
Apr
(422) |
May
(476) |
Jun
(396) |
Jul
(455) |
Aug
(267) |
Sep
(280) |
Oct
(253) |
Nov
(232) |
Dec
(304) |
2009 |
Jan
(486) |
Feb
(470) |
Mar
(458) |
Apr
(423) |
May
(696) |
Jun
(461) |
Jul
(551) |
Aug
(575) |
Sep
(134) |
Oct
(110) |
Nov
(157) |
Dec
(102) |
2010 |
Jan
(226) |
Feb
(86) |
Mar
(147) |
Apr
(117) |
May
(107) |
Jun
(203) |
Jul
(193) |
Aug
(238) |
Sep
(300) |
Oct
(246) |
Nov
(23) |
Dec
(75) |
2011 |
Jan
(133) |
Feb
(195) |
Mar
(315) |
Apr
(200) |
May
(267) |
Jun
(293) |
Jul
(353) |
Aug
(237) |
Sep
(278) |
Oct
(611) |
Nov
(274) |
Dec
(260) |
2012 |
Jan
(303) |
Feb
(391) |
Mar
(417) |
Apr
(441) |
May
(488) |
Jun
(655) |
Jul
(590) |
Aug
(610) |
Sep
(526) |
Oct
(478) |
Nov
(359) |
Dec
(372) |
2013 |
Jan
(467) |
Feb
(226) |
Mar
(391) |
Apr
(281) |
May
(299) |
Jun
(252) |
Jul
(311) |
Aug
(352) |
Sep
(481) |
Oct
(571) |
Nov
(222) |
Dec
(231) |
2014 |
Jan
(185) |
Feb
(329) |
Mar
(245) |
Apr
(238) |
May
(281) |
Jun
(399) |
Jul
(382) |
Aug
(500) |
Sep
(579) |
Oct
(435) |
Nov
(487) |
Dec
(256) |
2015 |
Jan
(338) |
Feb
(357) |
Mar
(330) |
Apr
(294) |
May
(191) |
Jun
(108) |
Jul
(142) |
Aug
(261) |
Sep
(190) |
Oct
(54) |
Nov
(83) |
Dec
(22) |
2016 |
Jan
(49) |
Feb
(89) |
Mar
(33) |
Apr
(50) |
May
(27) |
Jun
(34) |
Jul
(53) |
Aug
(53) |
Sep
(98) |
Oct
(206) |
Nov
(93) |
Dec
(53) |
2017 |
Jan
(65) |
Feb
(82) |
Mar
(102) |
Apr
(86) |
May
(187) |
Jun
(67) |
Jul
(23) |
Aug
(93) |
Sep
(65) |
Oct
(45) |
Nov
(35) |
Dec
(17) |
2018 |
Jan
(26) |
Feb
(35) |
Mar
(38) |
Apr
(32) |
May
(8) |
Jun
(43) |
Jul
(27) |
Aug
(30) |
Sep
(43) |
Oct
(42) |
Nov
(38) |
Dec
(67) |
2019 |
Jan
(32) |
Feb
(37) |
Mar
(53) |
Apr
(64) |
May
(49) |
Jun
(18) |
Jul
(14) |
Aug
(53) |
Sep
(25) |
Oct
(30) |
Nov
(49) |
Dec
(31) |
2020 |
Jan
(87) |
Feb
(45) |
Mar
(37) |
Apr
(51) |
May
(99) |
Jun
(36) |
Jul
(11) |
Aug
(14) |
Sep
(20) |
Oct
(24) |
Nov
(40) |
Dec
(23) |
2021 |
Jan
(14) |
Feb
(53) |
Mar
(85) |
Apr
(15) |
May
(19) |
Jun
(3) |
Jul
(14) |
Aug
(1) |
Sep
(57) |
Oct
(73) |
Nov
(56) |
Dec
(22) |
2022 |
Jan
(3) |
Feb
(22) |
Mar
(6) |
Apr
(55) |
May
(46) |
Jun
(39) |
Jul
(15) |
Aug
(9) |
Sep
(11) |
Oct
(34) |
Nov
(20) |
Dec
(36) |
2023 |
Jan
(79) |
Feb
(41) |
Mar
(99) |
Apr
(169) |
May
(48) |
Jun
(16) |
Jul
(16) |
Aug
(57) |
Sep
(83) |
Oct
(89) |
Nov
(97) |
Dec
(30) |
2024 |
Jan
(25) |
Feb
(73) |
Mar
(76) |
Apr
(122) |
May
(46) |
Jun
(44) |
Jul
(27) |
Aug
(30) |
Sep
(33) |
Oct
(67) |
Nov
(91) |
Dec
(70) |
2025 |
Jan
(44) |
Feb
(36) |
Mar
(85) |
Apr
(100) |
May
(138) |
Jun
(55) |
Jul
(107) |
Aug
(20) |
Sep
|
Oct
|
Nov
|
Dec
|
From: John P. A. G. <gla...@ph...> - 2025-06-05 15:40:41
|
Hi, there used to be an out-of-tree port of Valgrind for Solaris SPARC by Ivo Raisr et al. that he talked about at FOSDEM [1]. The repository was hosted on Bitbucket but the repository has been taken down, unfortunately [2]. Does anyone have a copy of that repository including the commit history by any chance? I did find repository snapshots in the form of tarballs on archive.org, but these are missing the commit history. I would like to have the real repository though to be able to extract the patches and reapply them against the current upstream sources. Thanks, Adrian > [1] https://archive.fosdem.org/2017/schedule/event/valgrind_sparcv9/ > [2] https://bitbucket.org/iraisr/valgrind-solaris -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer `. `' Physicist `- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913 |
From: Mark W. <ma...@so...> - 2025-06-03 17:26:49
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=b8891a4c5d139b8c327ee20c37066d601fc56b0a commit b8891a4c5d139b8c327ee20c37066d601fc56b0a Author: Martin Cermak <mc...@re...> Date: Tue Jun 3 13:43:18 2025 +0200 ltp tests: Use new LTP 20250530, allow for filtering valgrind output Use fresh LTP 20250530. Allow for filtering valgrind output: In some cases the LTP tests intentionally work with SIGSEGV. This happens e.g. with the mmap18 and select03 testcases. Valgrind detects SIGSEGV and reports that as a failure. Such report can't be suppressed using the suppressions mechanism. That's why this update comes with "output filters". Filters are scripts that read from their stdin, and write filtered output to their stdout. Filters reside in auxprogs/filters. This update comes with 2 filters: For mmap18, and for select03. They are awk scripts. Except for filters, this update also blacklists testcase fork13 because it is slow. It is possible to add comments prefixed with the '#' sign (implicitly - because they don't match any testcase name), so a comment is added too. This update also introduces new default valgrind --vgdb=no switch. It improves valgrind behavior with nftw01 nftw6401 setfsgid04 setfsgid03_16 and symlink03 testcases. These were previously complaining like this: ==22969== could not unlink /tmp/vgdb-pipe-from-vgdb-to-22969-by-root-on ... Diff: --- auxprogs/Makefile.am | 4 ++-- auxprogs/filters/mmap18 | 29 +++++++++++++++++++++++++++++ auxprogs/filters/select03 | 18 ++++++++++++++++++ auxprogs/ltp-excludes.txt | 2 ++ auxprogs/ltp-tester.sh | 46 ++++++++++++++++++++++++++-------------------- 5 files changed, 77 insertions(+), 22 deletions(-) diff --git a/auxprogs/Makefile.am b/auxprogs/Makefile.am index 4a10fb1cf8..97eb9501eb 100644 --- a/auxprogs/Makefile.am +++ b/auxprogs/Makefile.am @@ -155,8 +155,8 @@ endif endif # Linux Test Project -LTP_VERSION=20250130 -LTP_SHA256_SUM=02e4ec326be54c3fd92968229a468c02c665d168a8a673edc38a891f7395ae10 +LTP_VERSION=20250530 +LTP_SHA256_SUM=27586ba78eac1e40cd422add2842f1ad70f09fea55da3bd6a25e10feb786d4f2 LTP_TAR_NAME=ltp-full-$(LTP_VERSION).tar.xz LTP_URL=https://github.com/linux-test-project/ltp/releases/download/$(LTP_VERSION)/$(LTP_TAR_NAME) LTP_TAR=$(AUX_CHECK_DIR)/$(LTP_TAR_NAME) diff --git a/auxprogs/filters/mmap18 b/auxprogs/filters/mmap18 new file mode 100755 index 0000000000..edaf9c15d0 --- /dev/null +++ b/auxprogs/filters/mmap18 @@ -0,0 +1,29 @@ +#!/bin/awk -f + +# Filter out stuff like the following, since it is expected output for the select03 testcase: + +# mmap18: unempty log2.filtered: +# ==24613== +# ==24613== Process terminating with default action of signal 11 (SIGSEGV): dumping core +# ==24613== Access not within mapped region at address 0x4B3AFF8 +# ==24613== at 0x401F86: check_depth_recursive (mmap18.c:118) +# ==24613== If you believe this happened as a result of a stack +# ==24613== overflow in your program's main thread (unlikely but +# ==24613== possible), you can try to increase the size of the +# ==24613== main thread stack using the --main-stacksize= flag. +# ==24613== The main thread stack size used in this run was 8388608. +# ==24620== +# ==24620== Process terminating with default action of signal 11 (SIGSEGV): dumping core +# ==24620== Access not within mapped region at address 0x4B2EFF8 +# ==24620== at 0x401F86: check_depth_recursive (mmap18.c:118) +# ==24620== If you believe this happened as a result of a stack +# ==24620== overflow in your program's main thread (unlikely but +# ==24620== possible), you can try to increase the size of the +# ==24620== main thread stack using the --main-stacksize= flag. +# ==24620== The main thread stack size used in this run was 8388608. + +skip = 0 +/==[0-9][0-9]*==/ { skip = 1 } +/Process terminating with default action of signal 11/ { skip = 1; skipblock=1 } +/The main thread stack size used in this run was/ { skip = 1; skipblock=0 } +!skip && !skipblock { print } diff --git a/auxprogs/filters/select03 b/auxprogs/filters/select03 new file mode 100755 index 0000000000..368a884e7c --- /dev/null +++ b/auxprogs/filters/select03 @@ -0,0 +1,18 @@ +#!/bin/awk -f + +# Filter out stuff like the following, since it is expected output for the select03 testcase: + +# ==22396== +# ==22396== Process terminating with default action of signal 11 (SIGSEGV): dumping core +# ==22396== Bad permissions for mapped region at address 0x483B000 +# ==22396== at 0x4946397: select (in /usr/lib64/libc.so.6) +# ==22396== by 0x4020BA: run (select_var.h:26) +# ==22396== by 0x40B30C: fork_testrun (tst_test.c:1566) +# ==22396== by 0x40D4EF: tst_run_tcases (tst_test.c:1918) +# ==22396== by 0x401D4D: main (tst_test.h:725) + +skip = 0 +/==[0-9][0-9]*==/ { skip = 1 } +/Process terminating with default action of signal 11/ { skip = 1; skipblock=1 } +/by.*main.*tst_test.h/ { skip = 1; skipblock=0 } +!skip && !skipblock { print } diff --git a/auxprogs/ltp-excludes.txt b/auxprogs/ltp-excludes.txt index 236d779426..275fd74854 100644 --- a/auxprogs/ltp-excludes.txt +++ b/auxprogs/ltp-excludes.txt @@ -1,5 +1,7 @@ +# Exclude the following syscall tests because they are too slow: bind06 epoll-ltp +fork13 fork14 futex_cmp_requeue01 futex_cmp_requeue02 diff --git a/auxprogs/ltp-tester.sh b/auxprogs/ltp-tester.sh index 54d807b0c2..ba8fd8be47 100755 --- a/auxprogs/ltp-tester.sh +++ b/auxprogs/ltp-tester.sh @@ -11,7 +11,9 @@ ORIG_PATH=$PATH SCRIPT_SRC=$(dirname $0) LOGDIR=${LOGDIR:-$LTP_SRC_DIR/ltp/tests} DIFFCMD="diff -u" -VALGRIND="${VALGRIND:-$LTP_SRC_DIR/../../../vg-in-place}" +# vgdb sensitive testcase: e.g. nftw01 nftw6401 setfsgid04 setfsgid03_16 symlink03 +VGARGS="-q --vgdb=no" +VALGRIND="${VALGRIND:-$LTP_SRC_DIR/../../../vg-in-place} ${VGARGS}" # For parallel testing, consider IO intensive jobs, take nproc into account PARALLEL_JOBS=${PARALLEL_JOBS:-$(nproc)} # TESTS env var may be specified to restrict testing to selected test cases @@ -37,24 +39,27 @@ doTest () pushd $dir >/dev/null PATH="$ORIG_PATH:$PWD" ./$exe >$l/log1std 2>$l/log1err ||: - $VALGRIND -q --tool=none --log-file=$l/log2 ./$exe >$l/log2std 2>$l/log2err ||: - $VALGRIND -q --tool=memcheck --log-file=$l/log3 ./$exe >$l/log3std 2>$l/log3err ||: - - # We want to make sure that LTP syscall tests give identical - # results with and without valgrind. The test logs go to the - # stderr. They aren't identical across individual runs. The - # differences include port numbers, temporary files, test - # output ordering changes and more. They aren't trivially - # comparable. We resort to comparing at least the final - # summary of individual test results - tail -10 $l/log1err | grep -E "^(passed|failed|broken|skipped|warnings)" > $l/log1summary ||: - tail -10 $l/log2err | grep -E "^(passed|failed|broken|skipped|warnings)" > $l/log2summary ||: - tail -10 $l/log3err | grep -E "^(passed|failed|broken|skipped|warnings)" > $l/log3summary ||: + $VALGRIND --tool=none --log-file=$l/log2 ./$exe >$l/log2std 2>$l/log2err ||: + $VALGRIND --tool=memcheck --log-file=$l/log3 ./$exe >$l/log3std 2>$l/log3err ||: + + for i in "$l"/log{1std,1err,2,2std,2err,3,3std,3err}; do + echo "# cat $(basename $i)" >> $LOGDIR/$exe.log + cat $i >> $LOGDIR/$exe.log + done + + echo "# errors" >> $LOGDIR/$exe.log + + # If there is a logfile filter, apply it + if test -f "${SCRIPT_SRC}/filters/${exe}"; then + cat $l/log2 | ${SCRIPT_SRC}/filters/${exe} > $l/log2.filtered + else + cat $l/log2 > $l/log2.filtered + fi # Check logs, report errors pushd $l >/dev/null - if test -s log2; then - echo -e "${exe}: unempty log2:\n$(cat log2)" | tee -a $LOGDIR/$exe.log + if test -s log2.filtered; then + echo -e "${exe}: unempty log2.filtered:\n$(cat log2.filtered)" | tee -a $LOGDIR/$exe.log rv="FAIL" fi @@ -63,17 +68,18 @@ doTest () rv="FAIL" fi - if ! ${DIFFCMD} log1summary log2summary >/dev/null; then - echo -e "${exe}: ${DIFFCMD} log1summary log2summary:\n$(${DIFFCMD} log1summary log2summary)" | tee -a $LOGDIR/$exe.log + if ! ${DIFFCMD} log1err log2err >/dev/null; then + echo -e "${exe}: ${DIFFCMD} log1err log2err:\n$(${DIFFCMD} log1err log2err)" | tee -a $LOGDIR/$exe.log rv="FAIL" fi - if ! ${DIFFCMD} log2summary log3summary >/dev/null; then - echo -e "${exe}: ${DIFFCMD} log2summary log3summary:\n$(${DIFFCMD} log2summary log3summary)" | tee -a $LOGDIR/$exe.log + if ! ${DIFFCMD} log2err log3err >/dev/null; then + echo -e "${exe}: ${DIFFCMD} log2err log3err:\n$(${DIFFCMD} log2err log3err)" | tee -a $LOGDIR/$exe.log rv="FAIL" fi # synthetize automake style testlogs for bunsen import + echo "# result" >> $LOGDIR/$exe.log echo ":test-result: $rv" | tee -a $LOGDIR/$exe.log > $LOGDIR/$exe.trs popd >/dev/null popd >/dev/null |
From: Mark W. <ma...@kl...> - 2025-06-02 13:00:51
|
Hi, On Sun, 2025-06-01 at 17:47 +0200, Paul Floyd wrote: > On 6/1/25 15:22, Mark Wielaard wrote: > > I think an upgrade to GPLv3+ for valgrind is a good idea. It would > > also allow us to upgrade some gdbserver parts (various files under > > coregrind/m_gdbserver). Note that the new vgstack utility is already > > derived from GPLv3+ code. > > > > We could make that a goal for 3.26.0 (or maybe that deserves finally > > going to 4.0?) for our October release. I can contact the FSF legal > > team to ask if they want to help with or see any issues with such an > > upgrade if we want to incorporate more GPLv3+ code from the core > > toolchain projects. > > Licence-wise, I don't have much of an opinion. It would be nice to be > able to integrate code more easily. > > There are two kinds of projects that might get impacted. Third-party > ports, I guess they will just accept moving to GPL3+. Yes. Or they keep on 3.25.x. But I hope the long term goal of any third-party port would be to eventually get included upstream. Although I admit we have at times been really slow incorporating new ports. > Then there is VEX. > The main project that I know of is PyVEX https://github.com/angr/pyvex > which seems to be under a BSD licence. That looks wrong to me to start with. I think that is not deliberately wrong, just slightly confused. They should probably mention top-level that they are (re)distributing various parts under the GPL (see e.g. the pyvex_c and vex subdirs, which properly carry GPL notices). Which means the project as a whole also is distributed GPL, even if parts of the source code could also be reused under the BSD license as long as it isn't derived from the GPL parts. Cheers, Mark |
From: Paul F. <pj...@wa...> - 2025-06-01 15:47:22
|
On 6/1/25 15:22, Mark Wielaard wrote: > I think an upgrade to GPLv3+ for valgrind is a good idea. It would > also allow us to upgrade some gdbserver parts (various files under > coregrind/m_gdbserver). Note that the new vgstack utility is already > derived from GPLv3+ code. > > We could make that a goal for 3.26.0 (or maybe that deserves finally > going to 4.0?) for our October release. I can contact the FSF legal > team to ask if they want to help with or see any issues with such an > upgrade if we want to incorporate more GPLv3+ code from the core > toolchain projects. Hi all Licence-wise, I don't have much of an opinion. It would be nice to be able to integrate code more easily. There are two kinds of projects that might get impacted. Third-party ports, I guess they will just accept moving to GPL3+. Then there is VEX. The main project that I know of is PyVEX https://github.com/angr/pyvex which seems to be under a BSD licence. That looks wrong to me to start with. A+ Paul |
From: Mark W. <ma...@kl...> - 2025-06-01 13:23:07
|
Hi, On Sun, Jun 01, 2025 at 12:11:15PM +0200, Florian Krohm wrote: > One might think: re-using objdump code is a no-brainer. Except, it > isn't because binutils is licensed GPL 3 or later. In contrast > valgrind is licensed GPL 2 or later. > > In my lay opinion there seem to be two possibilities if we want to pursue this: > 1) change the valgrind license to be GPL 3 or later > 2) carve out the disassembly machinery from binutils, make it a library > and put it in libiberty which is LGPL 2 (we already use the GCC demangler > from there) > > I have not investigated #2. I would expect this task to be > non-trivial and it also includes a license change for some binutils > code. > So I'm wondering what people here think about a valgrind license > change or whether there are other alternatives that I may have > missed. I think an upgrade to GPLv3+ for valgrind is a good idea. It would also allow us to upgrade some gdbserver parts (various files under coregrind/m_gdbserver). Note that the new vgstack utility is already derived from GPLv3+ code. We could make that a goal for 3.26.0 (or maybe that deserves finally going to 4.0?) for our October release. I can contact the FSF legal team to ask if they want to help with or see any issues with such an upgrade if we want to incorporate more GPLv3+ code from the core toolchain projects. Cheers, Mark |
From: Florian K. <fl...@ei...> - 2025-06-01 10:24:43
|
Greetings. Supporting the many extended mnemonics for s390 vector insns is a pain and the code is not exactly pretty. So an obvious thought is: why reinvent the wheel when we have objdump which perfectly does the job and is the reference implementation for disassembling anyway. So I took a crack at that and converted the s390 VEX code to use whatever is needed from binutils / objdump. I have a fully operational patch. Obviously, this could be done for other architectures as well. One might think: re-using objdump code is a no-brainer. Except, it isn't because binutils is licensed GPL 3 or later. In contrast valgrind is licensed GPL 2 or later. In my lay opinion there seem to be two possibilities if we want to pursue this: 1) change the valgrind license to be GPL 3 or later 2) carve out the disassembly machinery from binutils, make it a library and put it in libiberty which is LGPL 2 (we already use the GCC demangler from there) I have not investigated #2. I would expect this task to be non-trivial and it also includes a license change for some binutils code. So I'm wondering what people here think about a valgrind license change or whether there are other alternatives that I may have missed. Thank you for your consideration, Florian Addendum: implementation detail The following files from binutils are needed (for s390 only): <binutils>/include/dis-asm.h <binutils>/include/opcode/s390.h <binutils>/opcodes/dis-init.c <binutils>/opcodes/s390-dis.c <binutils>/opcodes/s390-opc.c <binutils>/opcodes/s390-opc.tab (a generated file) In valgrind these files reside next to each other in the new VEX/priv/objudmp directory |
From: Paul F. <pa...@so...> - 2025-06-01 06:09:44
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=b13cc3d1abbdc427534c1d92d63472a97f1ffacc commit b13cc3d1abbdc427534c1d92d63472a97f1ffacc Author: Paul Floyd <pj...@wa...> Date: Sun Jun 1 08:09:14 2025 +0200 doc: add xml protocol 5 and 6 files to EXTRA_DIST Diff: --- docs/Makefile.am | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/Makefile.am b/docs/Makefile.am index 68a3da5617..607e514947 100644 --- a/docs/Makefile.am +++ b/docs/Makefile.am @@ -76,6 +76,8 @@ EXTRA_DIST = \ internals/why-no-libc.txt \ internals/xml-output.txt \ internals/xml-output-protocol4.txt \ + internals/xml-output-protocol5.txt \ + internals/xml-output-protocol6.txt \ lib/line-wrap.xsl \ lib/vg_basic.css \ lib/vg-fo.xsl \ |
From: Cyril H. <ch...@su...> - 2025-05-30 08:19:47
|
Good news everyone, the Linux Test Project test suite stable release for *May 2025* has been released. Since the last release 282 patches by 33 authors were merged. Patch review is what most of the projects struggle with and LTP is no different. If you can spare some effort helping with the patch review is more than welcomed. NOTABLE CHANGES =============== * New tests - kvm_vmx01 test for emulated VMREAD/VMWRITE instructions - kvm_vmx02 test for Intel VMX virtualized APIC - flock07 test for EINTR error - move_mount03 test for mount beneath top mount - fanotify24 test for FAN_PRE_ACCESS and FAN_DENY_ERRNO - unshare03 check for EMFILE when unsharing fd would hit the limits - fcntl40 test fcntl F_CREATED_QUERY - ioctl_fiemap01 functionality test for fiemap ioctl() - unshare04 tests that unshare(CLONE_NEWNS) unshares CWD - mmap22 test for new MAP_DROPPABLE flag * Increased coverage - fanotify13 test case for FAN_DELETE_SELF - fanotify05 test reporting overflow event with FAN_REPORT_FD_ERROR - fanotify21 test reporting event with RDWR fd on RO mount - fanotify21 test reporting fd open errors with FAN_REPORT_FD_ERROR - flock02 test for EWOULDBLOCK errno - fchownat03 more tests for invalid inputs - fanotify14 test invalid init flags with permission and pre-content events - fanotify03 test cases for permission events on children - pause01 tests now for more signals not just EINTR - setrlimit06 test resource limit64 for process * Removed tests - The test_controllers.sh is now disabled when v2 hierarchy is present - A few old and broken tests were removed from test_controllers.sh * kirk was updated to version 2.1 see the release notes at: https://github.com/linux-test-project/kirk/releases * New test catalogue generated from test metadata is live at: https://linux-test-project.readthedocs.io/en/latest/users/test_catalog.html * We have a new metadata extractor for a shell and first test that is parsed: https://linux-test-project.readthedocs.io/en/latest/users/test_catalog.html#vma05-sh * A few tests have been fixed not to be miscompiled by gcc-15 - we had problems with changes in structure zero initializations where suddenly anonymous unions were not zero initialized anymore - and also with optimzer changes that now remove malloc() + free() pairs if the memmory is no touched between the calls * The tst_brk() behavior has finally been clarified and fixed, for details see LTP commit a1f82704c28d ("lib/tst_test.c: Fix tst_brk() handling"). * New library test now have reproducible output that leaves out data that change between runs from the output, it's enabled with setting env variable LTP_REPRODUCIBLE_OUTPUT=1 * Our github CI is now connected to patchwork and runs LTP compilation tests for patches: https://patchwork.ozlabs.org/project/ltp/list/ * The LTP_SINGLE_FS_TYPE now honors test specific filesystem skiplists and thus can be used for general testing. There is new variable TST_FORCE_SINGLE_FS_TYPE that ignores skiplists and is supposed to be used for test development (which was previously the case for LTP_SINGLE_FS_TYPE). * The ipc runtest file that cointained only pipeio test was merged into syscalls runtest file * The horrible mess in testcases/kernel/mem/lib/ library was untangled into smaller pieces * 43 testcases were converted to the new test library + The usual amount of fixes and cleanups NOTABLE CHANGES IN IMA TESTS ============================ brought to you by Petr Vorel * Add support to load predefined example IMA policy with LTP_IMA_LOAD_POLICY=1 environment variable. This allows to run tests which are otherwise skipped due required policy not being loaded. SUT should be rebooted after each IMA tests (unless CONFIG_IMA_WRITE_POLICY=y` the policy can be written only once or policies can influence each other). * Added additional ToMToU and open-writer violation tests (new in kernel v6.14) * IMA: Allow to disable LSM warnings and use it for IMA (avoid misleading warnings) + Add some example IMA policies DOWNLOAD AND LINKS ================== The latest version of the test-suite contains 3000+ tests for the Linux and can be downloaded at: https://github.com/linux-test-project/ltp/releases/tag/20250530 The project pages as well as GIT repository are hosted on GitHub: https://github.com/linux-test-project/ltp If you ever wondered how to write a LTP testcase, don't miss our developer documentation at: https://linux-test-project.readthedocs.io/en/latest/developers/test_case_tutorial.html And our library API documentation at: https://linux-test-project.readthedocs.io/en/latest/developers/api_c_tests.html Patches, new tests, bugs, comments or questions should go to to our mailing list at lt...@li.... CREDITS ======= Many thanks to the people contributing to this release: git shortlog -s -e -n 20250130.. 80 Petr Vorel <pv...@su...> 25 Cyril Hrubis <ch...@su...> 24 Ricardo B. Marlière <rb...@su...> 22 Martin Doucha <md...@su...> 21 Andrea Cervesato <and...@su...> 17 Ma Xinjian via ltp <lt...@li...> 14 Li Wang <li...@re...> 13 Amir Goldstein <ami...@gm...> 11 Xinjian Ma (Fujitsu) <max...@fu...> 10 Jan Stancek <jst...@re...> 10 Wei Gao <we...@su...> 5 Mimi Zohar <zo...@li...> 4 Shiyang Ruan <rua...@fu...> 3 Avinesh Kumar <ak...@su...> 3 Jeff Moyer <jm...@re...> 2 Edward Liaw <ed...@go...> 2 lufei <lu...@un...> 1 Ajay Kaher <aja...@br...> 1 Binh Hoang <ht...@gm...> 1 Dan Carpenter <dan...@li...> 1 Jan Polensky <ja...@li...> 1 Jin Guojie <guo...@gm...> 1 John Morin <Joh...@gd...> 1 Li Xiaosong <rj...@16...> 1 Luiz Capitulino <lu...@re...> 1 Ross Burton <ros...@ar...> 1 Siddhesh Poyarekar <sid...@go...> 1 Stuart R. Anderson <and...@ne...> 1 T.J. Mercier <tjm...@go...> 1 Xiao Liang <xi...@re...> 1 Zhao Mengmeng <zha...@ky...> 1 dy455990 <dy4...@al...> 1 wangxuewen <wan...@ky...> And also thanks to patch reviewers: git log 20250130.. | grep -Ei '(reviewed|acked)-by:' | sed 's/.*by: //' | sort | uniq -c | sort -n -r 108 Petr Vorel <pv...@su...> 71 Andrea Cervesato <and...@su...> 62 Cyril Hrubis <ch...@su...> 53 Li Wang <li...@re...> 11 Mimi Zohar <zo...@li...> 9 Martin Doucha <md...@su...> 7 Jan Stancek <jst...@re...> 7 Ricardo B. Marlière <ri...@ma...> 6 Jan Kara <ja...@su...> 5 Avinesh Kumar <ak...@su...> -- Cyril Hrubis ch...@su... |
From: Paul F. <pa...@so...> - 2025-05-30 06:51:43
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=7208eb445f32eefb4397757f004e65882c9a4083 commit 7208eb445f32eefb4397757f004e65882c9a4083 Author: Paul Floyd <pj...@wa...> Date: Fri May 30 08:47:00 2025 +0200 FreeBSD syscalls: change two more warnings sysctl gave me a hard time when I first started working on FreeBSD but that warning should only be without -q change the unhandled kenv warning to a VG_(unimplemented), which will terminate Valgrind rather than just print a warning. There are still a few aio warnings. Really they should be promoted to some kind of fully fledged warning (maybe a core warning). I'm not sure that it's worth the effort as I suspect that aio is not much used. Diff: --- coregrind/m_syswrap/syswrap-freebsd.c | 10 +++++++--- memcheck/tests/freebsd/scalar.c | 3 --- memcheck/tests/freebsd/scalar.stderr.exp | 17 ----------------- memcheck/tests/freebsd/scalar.stderr.exp-x86 | 17 ----------------- 4 files changed, 7 insertions(+), 40 deletions(-) diff --git a/coregrind/m_syswrap/syswrap-freebsd.c b/coregrind/m_syswrap/syswrap-freebsd.c index 41b0cc38b2..3f4b6ca712 100644 --- a/coregrind/m_syswrap/syswrap-freebsd.c +++ b/coregrind/m_syswrap/syswrap-freebsd.c @@ -2082,8 +2082,10 @@ PRE(sys___sysctl) if (ML_(safe_to_deref)((void*)(Addr)ARG4, sizeof(vki_size_t))) { PRE_MEM_WRITE("sysctl(oldp)", (Addr)ARG3, *(vki_size_t *)ARG4); } else { - VG_(dmsg)("Warning: Bad oldlenp address %p in sysctl\n", - (void *)(Addr)ARG4); + if (VG_(clo_verbosity) >= 1) { + VG_(dmsg)("Warning: Bad oldlenp address %p in sysctl\n", + (void *)(Addr)ARG4); + } SET_STATUS_Failure ( VKI_EFAULT ); } } else { @@ -3691,7 +3693,9 @@ PRE(sys_kenv) case VKI_KENV_DUMP: break; default: - VG_(dmsg)("Warning: Bad action %" FMT_REGWORD "u in kenv\n", ARG1); + VG_(message)(Vg_UserMsg, "unhandled kenv cmd %" FMT_REGWORD "u", ARG1); + VG_(unimplemented) ("unhandled kenv cmd"); + break; } } diff --git a/memcheck/tests/freebsd/scalar.c b/memcheck/tests/freebsd/scalar.c index eddde2f428..bae3d943bc 100644 --- a/memcheck/tests/freebsd/scalar.c +++ b/memcheck/tests/freebsd/scalar.c @@ -1405,9 +1405,6 @@ int main(void) GO(SYS_kenv, "(KENV_DUMP) 4s 0m"); SY(SYS_kenv, x0+3, x0+2, x0+3, x0+4); FAIL; - GO(SYS_kenv, "(bogus) 4s 0m"); - SY(SYS_kenv, x0+20, x0+2, x0+3, x0+4); FAIL; - /* SYS_lchflags 391 */ GO(SYS_lchflags, "2s 1m"); SY(SYS_lchflags, x0+1, x0+2); FAIL; diff --git a/memcheck/tests/freebsd/scalar.stderr.exp b/memcheck/tests/freebsd/scalar.stderr.exp index d632beea42..2e6ca39b49 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp +++ b/memcheck/tests/freebsd/scalar.stderr.exp @@ -1481,7 +1481,6 @@ Syscall param sysctl(oldlenp) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: Bad oldlenp address 0x........ in sysctl --------------------------------------------------------- 202: SYS___sysctl (putnew) 4s 2m --------------------------------------------------------- @@ -2984,22 +2983,6 @@ Syscall param kenv(value) contains uninitialised byte(s) Syscall param kenv(len) contains uninitialised byte(s) ... ---------------------------------------------------------- -390: SYS_kenv (bogus) 4s 0m ---------------------------------------------------------- -Syscall param kenv(action) contains uninitialised byte(s) - ... - -Syscall param kenv(name) contains uninitialised byte(s) - ... - -Syscall param kenv(value) contains uninitialised byte(s) - ... - -Syscall param kenv(len) contains uninitialised byte(s) - ... - -Warning: Bad action 20 in kenv --------------------------------------------------------- 391: SYS_lchflags 2s 1m --------------------------------------------------------- diff --git a/memcheck/tests/freebsd/scalar.stderr.exp-x86 b/memcheck/tests/freebsd/scalar.stderr.exp-x86 index 7a9af94e8a..24c7caac04 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp-x86 +++ b/memcheck/tests/freebsd/scalar.stderr.exp-x86 @@ -1481,7 +1481,6 @@ Syscall param sysctl(oldlenp) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: Bad oldlenp address 0x........ in sysctl --------------------------------------------------------- 202: SYS___sysctl (putnew) 4s 2m --------------------------------------------------------- @@ -2990,22 +2989,6 @@ Syscall param kenv(value) contains uninitialised byte(s) Syscall param kenv(len) contains uninitialised byte(s) ... ---------------------------------------------------------- -390: SYS_kenv (bogus) 4s 0m ---------------------------------------------------------- -Syscall param kenv(action) contains uninitialised byte(s) - ... - -Syscall param kenv(name) contains uninitialised byte(s) - ... - -Syscall param kenv(value) contains uninitialised byte(s) - ... - -Syscall param kenv(len) contains uninitialised byte(s) - ... - -Warning: Bad action 20 in kenv --------------------------------------------------------- 391: SYS_lchflags 2s 1m --------------------------------------------------------- |
From: Paul F. <pa...@so...> - 2025-05-30 06:33:41
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=ebc73366045855c6cf5069ae6841d3a887bd0ba0 commit ebc73366045855c6cf5069ae6841d3a887bd0ba0 Author: Paul Floyd <pj...@wa...> Date: Fri May 30 08:31:48 2025 +0200 FreeBSD sigprocmask syscall: do not print warnings when -q is set Equivalent to bug504904 and bug504909 Diff: --- coregrind/m_syswrap/syswrap-freebsd.c | 22 +++++++++++++++------- memcheck/tests/freebsd/scalar.stderr.exp | 3 --- memcheck/tests/freebsd/scalar.stderr.exp-x86 | 3 --- 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/coregrind/m_syswrap/syswrap-freebsd.c b/coregrind/m_syswrap/syswrap-freebsd.c index 8fcfe10904..41b0cc38b2 100644 --- a/coregrind/m_syswrap/syswrap-freebsd.c +++ b/coregrind/m_syswrap/syswrap-freebsd.c @@ -3197,13 +3197,17 @@ PRE(sys_sigprocmask) if (ARG2 != 0 && !ML_(safe_to_deref)((void *)(Addr)ARG2, sizeof(vki_sigset_t))) { - VG_(dmsg)("Warning: Bad set handler address %p in sigprocmask\n", + if (VG_(clo_verbosity) >= 1) { + VG_(dmsg)("Warning: Bad set handler address %p in sigprocmask\n", (void *)(Addr)ARG2); + } SET_STATUS_Failure ( VKI_EFAULT ); } else if (ARG3 != 0 && !ML_(safe_to_deref)((void *)(Addr)ARG3, sizeof(vki_sigset_t))) { - VG_(dmsg)("Warning: Bad oldset address %p in sigprocmask\n", - (void *)(Addr)ARG3); + if (VG_(clo_verbosity) >= 1) { + VG_(dmsg)("Warning: Bad oldset address %p in sigprocmask\n", + (void *)(Addr)ARG3); + } SET_STATUS_Failure ( VKI_EFAULT ); } else { SET_STATUS_from_SysRes(VG_(do_sys_sigprocmask)(tid, ARG1 /*how*/, @@ -3922,14 +3926,18 @@ PRE(sys_sigaction) if (ARG2 != 0 && ! ML_(safe_to_deref)((void *)(Addr)ARG2, sizeof(struct vki_sigaction))) { - VG_(umsg)("Warning: bad act handler address %p in sigaction()\n", - (void *)(Addr)ARG2); + if (VG_(clo_verbosity) >= 1) { + VG_(umsg)("Warning: bad act handler address %p in sigaction()\n", + (void *)(Addr)ARG2); + } SET_STATUS_Failure ( VKI_EFAULT ); } else if ((ARG3 != 0 && ! ML_(safe_to_deref)((void *)(Addr)ARG3, sizeof(struct vki_sigaction)))) { - VG_(umsg)("Warning: bad oact handler address %p in sigaction()\n", - (void *)(Addr)ARG3); + if (VG_(clo_verbosity) >= 1) { + VG_(umsg)("Warning: bad oact handler address %p in sigaction()\n", + (void *)(Addr)ARG3); + } SET_STATUS_Failure ( VKI_EFAULT ); } else { if (ARG2 != 0) { diff --git a/memcheck/tests/freebsd/scalar.stderr.exp b/memcheck/tests/freebsd/scalar.stderr.exp index 24b7ba2bbd..d632beea42 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp +++ b/memcheck/tests/freebsd/scalar.stderr.exp @@ -2429,7 +2429,6 @@ Syscall param sigprocmask(oset) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: Bad oldset address 0x........ in sigprocmask --------------------------------------------------------- 340: SYS_sigprocmask 3s 2m --------------------------------------------------------- @@ -2450,7 +2449,6 @@ Syscall param sigprocmask(oset) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: Bad set handler address 0x........ in sigprocmask --------------------------------------------------------- 341: SYS_sigsuspend 1s 1m --------------------------------------------------------- @@ -3227,7 +3225,6 @@ Syscall param sigaction(oact) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: bad act handler address 0x........ in sigaction() --------------------------------------------------------- 417: SYS_sigreturn 1s 1m --------------------------------------------------------- diff --git a/memcheck/tests/freebsd/scalar.stderr.exp-x86 b/memcheck/tests/freebsd/scalar.stderr.exp-x86 index 788dfbd7c0..7a9af94e8a 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp-x86 +++ b/memcheck/tests/freebsd/scalar.stderr.exp-x86 @@ -2435,7 +2435,6 @@ Syscall param sigprocmask(oset) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: Bad oldset address 0x........ in sigprocmask --------------------------------------------------------- 340: SYS_sigprocmask 3s 2m --------------------------------------------------------- @@ -2456,7 +2455,6 @@ Syscall param sigprocmask(oset) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: Bad set handler address 0x........ in sigprocmask --------------------------------------------------------- 341: SYS_sigsuspend 1s 1m --------------------------------------------------------- @@ -3236,7 +3234,6 @@ Syscall param sigaction(oact) points to unaddressable byte(s) ... Address 0x........ is not stack'd, malloc'd or (recently) free'd -Warning: bad act handler address 0x........ in sigaction() --------------------------------------------------------- 417: SYS_sigreturn 1s 1m --------------------------------------------------------- |
From: Mark W. <ma...@so...> - 2025-05-29 22:41:05
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=47f2f1df4112e9befe2d0039d7e4f6c957669b6e commit 47f2f1df4112e9befe2d0039d7e4f6c957669b6e Author: Martin Cermak <mc...@re...> Date: Wed May 28 18:04:46 2025 +0200 Hide "client tried to modify addresses" warnings when -q (quiet) is set When -q is set, that is when verbosity is 0, the "client tried to modify addresses" warning should be hidden. Also remove the warning from {freebsd,solaris}/scalar.stderr.exp Reproducer: TESTS=munmap03 make -j$(nproc) ltpchecks https://bugs.kde.org/show_bug.cgi?id=504919 Diff: --- NEWS | 1 + coregrind/m_syswrap/syswrap-generic.c | 8 +++++--- memcheck/tests/freebsd/scalar.stderr.exp | 1 - memcheck/tests/freebsd/scalar.stderr.exp-x86 | 1 - memcheck/tests/solaris/scalar.stderr.exp | 1 - 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/NEWS b/NEWS index dab995c632..041d7afdf3 100644 --- a/NEWS +++ b/NEWS @@ -38,6 +38,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 504466 Double close causes SEGV 504904 Hide "bad act handler address" warnings when -q (quiet) flag is set 504909 Hide "Bad oldset address" warnings when -q (quiet) flag is set +504919 Hide "client tried to modify addresses" warnings when -q (quiet) set 504936 Add FreeBSD amd64 sysarch subcommands AMD64_SET_TLSBASE and AMD64_GET_TLSBASE diff --git a/coregrind/m_syswrap/syswrap-generic.c b/coregrind/m_syswrap/syswrap-generic.c index 98cbb172fd..f8d73e1973 100644 --- a/coregrind/m_syswrap/syswrap-generic.c +++ b/coregrind/m_syswrap/syswrap-generic.c @@ -121,9 +121,11 @@ Bool ML_(valid_client_addr)(Addr start, SizeT size, ThreadId tid, syscallname, start, start+size-1, (Int)ret); if (!ret && syscallname != NULL) { - VG_(message)(Vg_UserMsg, "Warning: client syscall %s tried " - "to modify addresses %#lx-%#lx\n", - syscallname, start, start+size-1); + if (VG_(clo_verbosity) >= 1) { + VG_(message)(Vg_UserMsg, "Warning: client syscall %s tried " + "to modify addresses %#lx-%#lx\n", + syscallname, start, start+size-1); + } if (VG_(clo_verbosity) > 1) { VG_(get_and_pp_StackTrace)(tid, VG_(clo_backtrace_size)); } diff --git a/memcheck/tests/freebsd/scalar.stderr.exp b/memcheck/tests/freebsd/scalar.stderr.exp index 59ed185242..24b7ba2bbd 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp +++ b/memcheck/tests/freebsd/scalar.stderr.exp @@ -610,7 +610,6 @@ Syscall param mprotect(len) contains uninitialised byte(s) Syscall param mprotect(prot) contains uninitialised byte(s) ... -Warning: client syscall mprotect tried to modify addresses 0x........-0x........ --------------------------------------------------------- 75: SYS_madvise 3s 0m --------------------------------------------------------- diff --git a/memcheck/tests/freebsd/scalar.stderr.exp-x86 b/memcheck/tests/freebsd/scalar.stderr.exp-x86 index 091a1770d6..788dfbd7c0 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp-x86 +++ b/memcheck/tests/freebsd/scalar.stderr.exp-x86 @@ -610,7 +610,6 @@ Syscall param mprotect(len) contains uninitialised byte(s) Syscall param mprotect(prot) contains uninitialised byte(s) ... -Warning: client syscall mprotect tried to modify addresses 0x........-0x........ --------------------------------------------------------- 75: SYS_madvise 3s 0m --------------------------------------------------------- diff --git a/memcheck/tests/solaris/scalar.stderr.exp b/memcheck/tests/solaris/scalar.stderr.exp index d80bc27d07..e7951dae77 100644 --- a/memcheck/tests/solaris/scalar.stderr.exp +++ b/memcheck/tests/solaris/scalar.stderr.exp @@ -618,7 +618,6 @@ Syscall param shmsys_shmdt(opcode) contains uninitialised byte(s) Syscall param shmsys_shmdt(shmaddr) contains uninitialised byte(s) ... -Warning: client syscall shmdt tried to modify addresses 0x........-0x........ --------------------------------------------------------- 52: SYS_shmsys (SHMGET) 4s 0m --------------------------------------------------------- |
From: Mark W. <ma...@so...> - 2025-05-29 22:15:36
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=4540c465868f18943e649c686e83e33688711887 commit 4540c465868f18943e649c686e83e33688711887 Author: Martin Cermak <mc...@re...> Date: Wed May 28 14:50:49 2025 +0200 Hide "Bad oldset address" warnings when -q (quiet) flag is set When valgrind is run with -q, messages like "Warning: Bad oldset address 0xFFFFFFFFFFFFFFFF in sigprocmask" be hidden. Reproducer: TESTS=rt_sigprocmask02 make ltpchecks https://bugs.kde.org/show_bug.cgi?id=504909 Diff: --- NEWS | 1 + coregrind/m_syswrap/syswrap-linux.c | 12 ++++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/NEWS b/NEWS index 374b14d0b1..dab995c632 100644 --- a/NEWS +++ b/NEWS @@ -37,6 +37,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 504341 Valgrind killed by LTP syscall testcase setrlimit05 504466 Double close causes SEGV 504904 Hide "bad act handler address" warnings when -q (quiet) flag is set +504909 Hide "Bad oldset address" warnings when -q (quiet) flag is set 504936 Add FreeBSD amd64 sysarch subcommands AMD64_SET_TLSBASE and AMD64_GET_TLSBASE diff --git a/coregrind/m_syswrap/syswrap-linux.c b/coregrind/m_syswrap/syswrap-linux.c index 0106e1661f..be936ecbe1 100644 --- a/coregrind/m_syswrap/syswrap-linux.c +++ b/coregrind/m_syswrap/syswrap-linux.c @@ -4661,14 +4661,18 @@ PRE(sys_rt_sigprocmask) SET_STATUS_Failure( VKI_EINVAL ); else if (ARG2 != 0 && ! ML_(safe_to_deref)((void *)(Addr)ARG2, sizeof(vki_sigset_t))) { - VG_(dmsg)("Warning: Bad set handler address %p in sigprocmask\n", - (void *)(Addr)ARG2); + if (VG_(clo_verbosity) >= 1) { + VG_(dmsg)("Warning: Bad set handler address %p in sigprocmask\n", + (void *)(Addr)ARG2); + } SET_STATUS_Failure ( VKI_EFAULT ); } else if (ARG3 != 0 && ! ML_(safe_to_deref)((void *)(Addr)ARG3, sizeof(vki_sigset_t))) { - VG_(dmsg)("Warning: Bad oldset address %p in sigprocmask\n", - (void *)(Addr)ARG3); + if (VG_(clo_verbosity) >= 1) { + VG_(dmsg)("Warning: Bad oldset address %p in sigprocmask\n", + (void *)(Addr)ARG3); + } SET_STATUS_Failure ( VKI_EFAULT ); } |
From: Mark W. <ma...@so...> - 2025-05-29 22:03:29
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=ad6ca3e69358e440b4841cecf0ebed5aa7351d69 commit ad6ca3e69358e440b4841cecf0ebed5aa7351d69 Author: Martin Cermak <mc...@re...> Date: Wed May 28 12:09:44 2025 +0200 Hide bad act handler address warning when -q is set When valgrind is run with -q, messages like "Warning: bad act handler address 0xFFFFFFFFFFFFFFFF in rt_sigaction()" should be hidden. https://bugs.kde.org/show_bug.cgi?id=504904 Diff: --- NEWS | 1 + coregrind/m_syswrap/syswrap-linux.c | 12 ++++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/NEWS b/NEWS index 7cf33d52e5..374b14d0b1 100644 --- a/NEWS +++ b/NEWS @@ -36,6 +36,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 504265 FreeBSD: missing syscall wrappers for fchroot and setcred 504341 Valgrind killed by LTP syscall testcase setrlimit05 504466 Double close causes SEGV +504904 Hide "bad act handler address" warnings when -q (quiet) flag is set 504936 Add FreeBSD amd64 sysarch subcommands AMD64_SET_TLSBASE and AMD64_GET_TLSBASE diff --git a/coregrind/m_syswrap/syswrap-linux.c b/coregrind/m_syswrap/syswrap-linux.c index fa2ab9e9fe..0106e1661f 100644 --- a/coregrind/m_syswrap/syswrap-linux.c +++ b/coregrind/m_syswrap/syswrap-linux.c @@ -4610,14 +4610,18 @@ PRE(sys_rt_sigaction) if (ARG2 != 0 && ! ML_(safe_to_deref)((void *)(Addr)ARG2, sizeof(vki_sigaction_toK_t))) { - VG_(umsg)("Warning: bad act handler address %p in rt_sigaction()\n", - (void *)(Addr)ARG2); + if (VG_(clo_verbosity) >= 1) { + VG_(umsg)("Warning: bad act handler address %p in rt_sigaction()\n", + (void *)(Addr)ARG2); + } SET_STATUS_Failure ( VKI_EFAULT ); } else if ((ARG3 != 0 && ! ML_(safe_to_deref)((void *)(Addr)ARG3, sizeof(vki_sigaction_fromK_t)))) { - VG_(umsg)("Warning: bad oldact handler address %p in rt_sigaction()\n", - (void *)(Addr)ARG3); + if (VG_(clo_verbosity) >= 1) { + VG_(umsg)("Warning: bad oldact handler address %p in rt_sigaction()\n", + (void *)(Addr)ARG3); + } SET_STATUS_Failure ( VKI_EFAULT ); } else { |
From: Paul F. <pa...@so...> - 2025-05-29 20:08:00
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=3a17beb90d7aebe094ff764885a888bad43b1b2c commit 3a17beb90d7aebe094ff764885a888bad43b1b2c Author: Paul Floyd <pj...@wa...> Date: Thu May 29 22:06:21 2025 +0200 regtest arm: one fix for building with clang Diff: --- memcheck/tests/leak.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/memcheck/tests/leak.h b/memcheck/tests/leak.h index f9a2db290d..6b44503276 100644 --- a/memcheck/tests/leak.h +++ b/memcheck/tests/leak.h @@ -152,10 +152,10 @@ /* 32bit arm */ #define CLEAR_CALLER_SAVED_REGS \ do { \ - __asm__ __volatile__ ("mov %r0, $0\n\t"); \ - __asm__ __volatile__ ("mov %r1, $0\n\t"); \ - __asm__ __volatile__ ("mov %r2, $0\n\t"); \ - __asm__ __volatile__ ("mov %r3, $0\n\t"); \ + __asm__ __volatile__ ("mov r0, $0\n\t"); \ + __asm__ __volatile__ ("mov r1, $0\n\t"); \ + __asm__ __volatile__ ("mov r2, $0\n\t"); \ + __asm__ __volatile__ ("mov r3, $0\n\t"); \ } while (0) #elif defined(__aarch64__) /* 64bit arm */ |
From: Paul F. <pa...@so...> - 2025-05-29 19:32:37
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=2fa8581c4974db57de80de915d16ce299eb9aa84 commit 2fa8581c4974db57de80de915d16ce299eb9aa84 Author: Khem Raj <raj...@gm...> Date: Wed May 14 09:29:33 2025 -0700 Use portable syntax for pushsection directive in inline assembly '@' does not work with clang inline assembler, but '%' works with both gcc and clang. Therefore use '%' to make it more portable Fixes <inline asm>:1:41: error: expected '%<type>' or "<type>" Signed-off-by: Khem Raj <raj...@gm...> Diff: --- coregrind/vg_preloaded.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c index 5bec51d760..e4c2dbc21c 100644 --- a/coregrind/vg_preloaded.c +++ b/coregrind/vg_preloaded.c @@ -55,7 +55,7 @@ /* Note: The "MS" section flags are to remove duplicates. */ #define DEFINE_GDB_PY_SCRIPT(script_name) \ asm("\ -.pushsection \".debug_gdb_scripts\", \"MS\",@progbits,1\n\ +.pushsection \".debug_gdb_scripts\", \"MS\",%progbits,1\n\ .byte 1 /* Python */\n\ .asciz \"" script_name "\"\n\ .popsection \n\ |
From: Paul F. <pa...@so...> - 2025-05-29 07:58:52
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=f7b087df5ccd4ac1c0803a5dfd168327dc25286c commit f7b087df5ccd4ac1c0803a5dfd168327dc25286c Author: Paul Floyd <pj...@wa...> Date: Thu May 29 08:52:28 2025 +0200 Bug 504936 - Add FreeBSD amd64 sysarch subcommands AMD64_SET_TLSBASE and AMD64_GET_TLSBASE Diff: --- NEWS | 2 ++ VEX/priv/guest_amd64_helpers.c | 3 ++- VEX/pub/libvex_guest_amd64.h | 7 +++++-- coregrind/m_syswrap/syswrap-amd64-freebsd.c | 24 +++++++++++++++++++++++- include/vki/vki-freebsd.h | 9 ++++++++- memcheck/mc_machine.c | 1 + 6 files changed, 41 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 1450dfba82..7cf33d52e5 100644 --- a/NEWS +++ b/NEWS @@ -36,6 +36,8 @@ are not entered into bugzilla tend to get forgotten about or ignored. 504265 FreeBSD: missing syscall wrappers for fchroot and setcred 504341 Valgrind killed by LTP syscall testcase setrlimit05 504466 Double close causes SEGV +504936 Add FreeBSD amd64 sysarch subcommands AMD64_SET_TLSBASE and + AMD64_GET_TLSBASE To see details of a given bug, visit https://bugs.kde.org/show_bug.cgi?id=XXXXXX diff --git a/VEX/priv/guest_amd64_helpers.c b/VEX/priv/guest_amd64_helpers.c index b4e37fcbd6..8313d58b47 100644 --- a/VEX/priv/guest_amd64_helpers.c +++ b/VEX/priv/guest_amd64_helpers.c @@ -2665,6 +2665,7 @@ void amd64g_dirtyhelper_FINIT ( VexGuestAMD64State* gst ) { Int i; gst->guest_FTOP = 0; + gst->pad1 = 0; for (i = 0; i < 8; i++) { gst->guest_FPTAG[i] = 0; /* empty */ gst->guest_FPREG[i] = 0; /* IEEE754 64-bit zero */ @@ -4831,7 +4832,7 @@ void LibVEX_GuestAMD64_initialise ( /*OUT*/VexGuestAMD64State* vex_state ) vex_state->guest_GS_CONST = 0; vex_state->guest_IP_AT_SYSCALL = 0; - vex_state->pad1 = 0; + vex_state->guest_TLSBASE = 0; } diff --git a/VEX/pub/libvex_guest_amd64.h b/VEX/pub/libvex_guest_amd64.h index 8f6bb560cb..9be073a21f 100644 --- a/VEX/pub/libvex_guest_amd64.h +++ b/VEX/pub/libvex_guest_amd64.h @@ -170,8 +170,11 @@ typedef been interrupted by a signal. */ ULong guest_IP_AT_SYSCALL; - /* Padding to make it have an 16-aligned size */ - ULong pad3; + /* Used on FreeBSD as part of a mechanism to allow signal handlers + to use TLS. */ + ULong guest_TLSBASE; + + /* Add padding here to make it have an 16-aligned size */ } VexGuestAMD64State; diff --git a/coregrind/m_syswrap/syswrap-amd64-freebsd.c b/coregrind/m_syswrap/syswrap-amd64-freebsd.c index e1316eac3e..4c69e762bd 100644 --- a/coregrind/m_syswrap/syswrap-amd64-freebsd.c +++ b/coregrind/m_syswrap/syswrap-amd64-freebsd.c @@ -128,13 +128,18 @@ PRE(sys_sysarch) PRE_REG_READ2(int, "sysarch", int, number, void *, args); switch (ARG1) { case VKI_AMD64_SET_FSBASE: - PRINT("sys_amd64_set_fsbase ( %#lx )", ARG2); + case VKI_AMD64_SET_TLSBASE: + PRINT("sys_amd64_set_%ssbase ( %#lx )", (ARG1 == VKI_AMD64_SET_FSBASE ? "f" : "tl"), ARG2); if (ML_(safe_to_deref)((void**)ARG2, sizeof(void*))) { /* On FreeBSD, the syscall loads the %gs selector for us, so do it now. */ tst = VG_(get_ThreadState)(tid); p = (void**)ARG2; tst->arch.vex.guest_FS_CONST = (UWord)*p; + if (ARG1 == VKI_AMD64_SET_TLSBASE) { + tst->arch.vex.guest_TLSBASE = (UWord)*p; + // kernel also calls "set_pcb_flags(pcb, PCB_TLSBASE);" + } /* "do" the syscall ourselves; the kernel never sees it */ SET_STATUS_Success2((ULong)*p, tst->arch.vex.guest_RDX ); } else { @@ -165,6 +170,22 @@ PRE(sys_sysarch) tst = VG_(get_ThreadState)(tid); SET_STATUS_Success2( tst->arch.vex.guest_FPTAG[0], tst->arch.vex.guest_FPTAG[0] ); break; + //case VKI_AMD64_SET_PKRU: + //case VKI_AMD64_CLEAR_PKRU: + case VKI_AMD64_GET_TLSBASE: + PRINT("sys_amd64_get_tlsbase ( %#lx )", ARG2); + PRE_MEM_WRITE( "amd64_get_fsbase(basep)", ARG2, sizeof(void *) ); + if (ML_(safe_to_deref)((void**)ARG2, sizeof(void*))) { + /* "do" the syscall ourselves; the kernel never sees it */ + tst = VG_(get_ThreadState)(tid); + SET_STATUS_Success2( tst->arch.vex.guest_TLSBASE, tst->arch.vex.guest_RDX ); + } else { + SET_STATUS_Failure( VKI_EINVAL ); + } + break; + + PRINT("sys_amd64_set_tlsbase ( %#lx )", ARG2); + break; default: VG_(message) (Vg_UserMsg, "unhandled sysarch cmd %lu", ARG1); VG_(unimplemented) ("unhandled sysarch cmd"); @@ -179,6 +200,7 @@ POST(sys_sysarch) break; case VKI_AMD64_GET_FSBASE: case VKI_AMD64_GET_XFPUSTATE: + case VKI_AMD64_GET_TLSBASE: POST_MEM_WRITE( ARG2, sizeof(void *) ); break; default: diff --git a/include/vki/vki-freebsd.h b/include/vki/vki-freebsd.h index 2539979995..6be56c27ad 100644 --- a/include/vki/vki-freebsd.h +++ b/include/vki/vki-freebsd.h @@ -1857,12 +1857,19 @@ struct vki_ptrace_vm_entry { #define VKI_I386_GET_GSBASE 9 #define VKI_I386_SET_GSBASE 10 #define VKI_I386_GET_XFPUSTATE 11 +#define VKI_I386_SET_PKRU 12 +#define VKI_I386_CLEAR_PKRU 13 #define VKI_AMD64_GET_FSBASE 128 #define VKI_AMD64_SET_FSBASE 129 #define VKI_AMD64_GET_GSBASE 130 #define VKI_AMD64_SET_GSBASE 131 -#define VKI_AMD64_GET_XFPUSTATE 132 +#define VKI_AMD64_GET_XFPUSTATE 132 +#define VKI_AMD64_SET_PKRU 133 +#define VKI_AMD64_CLEAR_PKRU 134 +#define VKI_AMD64_GET_TLSBASE 135 +#define VKI_AMD64_SET_TLSBASE 136 + //---------------------------------------------------------------------- // From sys/module.h diff --git a/memcheck/mc_machine.c b/memcheck/mc_machine.c index 34df0011ac..b0026a6bd5 100644 --- a/memcheck/mc_machine.c +++ b/memcheck/mc_machine.c @@ -647,6 +647,7 @@ static Int get_otrack_shadow_offset_wrk ( Int offset, Int szB ) if (o == GOF(DFLAG) && sz == 8) return -1; /* slot used for %CH */ if (o == GOF(RIP) && sz == 8) return -1; /* slot unused */ if (o == GOF(IP_AT_SYSCALL) && sz == 8) return -1; /* slot unused */ + if (o == GOF(TLSBASE) && sz == 8) return -1; /* slot unused */ if (o == GOF(IDFLAG) && sz == 8) return -1; /* slot used for %DH */ if (o == GOF(ACFLAG) && sz == 8) return -1; /* slot unused */ if (o == GOF(FS_CONST) && sz == 8) return -1; /* slot unused */ |
From: Florian K. <fk...@so...> - 2025-05-28 21:09:30
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=c164b5714172e7678ab258545c2bc0127f21a318 commit c164b5714172e7678ab258545c2bc0127f21a318 Author: Florian Krohm <fl...@ei...> Date: Wed May 28 21:07:44 2025 +0000 s390x: Remove a fixs390. Add an explanation. Diff: --- VEX/priv/host_s390_defs.h | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/VEX/priv/host_s390_defs.h b/VEX/priv/host_s390_defs.h index dcdb6713e9..48fbac7644 100644 --- a/VEX/priv/host_s390_defs.h +++ b/VEX/priv/host_s390_defs.h @@ -706,8 +706,18 @@ typedef struct { s390_amode *guest_IA; } xassisted; struct { - /* fixs390: I don't think these are really needed - as the gsp and the offset are fixed no ? */ + /* Note: these fields are needed. Here's why: + These fields are amodes for accessing the host_EvC_COUNTER and + host_EvC_FAILADDR fields in the guest state. + When guest and host architecture are both s390x then we know that + the displacement in evcheck::counter is + offsetof(VexGuestS390XState, host_EvC_COUNTER) and likewise for + the displacement in evcheck::fail_addr. There would be no point + to build these amodes in the first place because we could just + hardwire the displacements in s390_insn_evcheck_emit. + However in a multi-arch setting the amodes point to the + host_EvC_COUNTER/FAILADDR fields in a *different* guest state and + those offsets are not known. So we do need to build the amodes. */ s390_amode *counter; /* dispatch counter */ s390_amode *fail_addr; } evcheck; |
From: Paul F. <pa...@so...> - 2025-05-27 10:43:57
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=f8cd77bec1e3050cb101942b9c18f7d30912bda9 commit f8cd77bec1e3050cb101942b9c18f7d30912bda9 Author: Paul Floyd <pj...@wa...> Date: Tue May 27 12:41:32 2025 +0200 regtest warning: suppress -Walloc-size-larger-than= warning in memcheck calloc-overflow.c Diff: --- memcheck/tests/Makefile.am | 1 + 1 file changed, 1 insertion(+) diff --git a/memcheck/tests/Makefile.am b/memcheck/tests/Makefile.am index db6cd17863..860cb2076f 100644 --- a/memcheck/tests/Makefile.am +++ b/memcheck/tests/Makefile.am @@ -678,6 +678,7 @@ accounting_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_ALLOC_SIZE_LARGER_THAN@ badfree_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_FREE_NONHEAP_OBJECT@ bug155125_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNUSED_RESULT@ @FLAG_W_NO_ALLOC_SIZE_LARGER_THAN@ bug472219_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_UNINITIALIZED@ +calloc_overflow_CFLAGS = ${AM_CFLAGS} @FLAG_W_NO_ALLOC_SIZE_LARGER_THAN@ malloc_usable_CFLAGS = ${AM_CFLAGS} @FLAG_W_NO_MAYBE_UNINITIALIZED@ @FLAG_W_NO_UNINITIALIZED@ mallinfo_CFLAGS = $(AM_CFLAGS) -Wno-deprecated-declarations malloc3_CFLAGS = $(AM_CFLAGS) @FLAG_W_NO_ALLOC_SIZE_LARGER_THAN@ |
From: Paul F. <pa...@so...> - 2025-05-26 20:05:54
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=988d80f0e7789b6d04734125ef340db282da7322 commit 988d80f0e7789b6d04734125ef340db282da7322 Author: Paul Floyd <pj...@wa...> Date: Mon May 26 22:02:35 2025 +0200 regtest warnings: fix unused returns and missing noexcept specifiers GCC 15.1.1 is still giving a -Walloc-size-larger-than= warning for memcheck calloc-overflow.c Diff: --- drd/tests/timed_mutex.cpp | 4 ++-- massif/tests/overloaded-new.cpp | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drd/tests/timed_mutex.cpp b/drd/tests/timed_mutex.cpp index fa7464ea5b..97ac320964 100644 --- a/drd/tests/timed_mutex.cpp +++ b/drd/tests/timed_mutex.cpp @@ -10,7 +10,7 @@ int global; void f() { auto now=std::chrono::steady_clock::now(); - test_mutex.try_lock_until(now + std::chrono::seconds(11)); + (void)test_mutex.try_lock_until(now + std::chrono::seconds(11)); --global; std::this_thread::sleep_for(std::chrono::seconds(1)); test_mutex.unlock(); @@ -23,7 +23,7 @@ int main() std::thread t(f); std::this_thread::sleep_for(std::chrono::seconds(1)); auto now=std::chrono::steady_clock::now(); - test_mutex.try_lock_until(now + std::chrono::seconds(11)); + (void)test_mutex.try_lock_until(now + std::chrono::seconds(11)); ++global; test_mutex.unlock(); t.join(); diff --git a/massif/tests/overloaded-new.cpp b/massif/tests/overloaded-new.cpp index 5ad92894e9..edea12b742 100644 --- a/massif/tests/overloaded-new.cpp +++ b/massif/tests/overloaded-new.cpp @@ -19,7 +19,7 @@ __attribute__((noinline)) void* operator new (std::size_t n) return (void*)12345; } -__attribute__((noinline)) void* operator new (std::size_t n, std::nothrow_t const &) +__attribute__((noinline)) void* operator new (std::size_t n, std::nothrow_t const &) noexcept { return (void*)23456; } @@ -29,7 +29,7 @@ __attribute__((noinline)) void* operator new[] (std::size_t n) return (void*)34567; } -__attribute__((noinline)) void* operator new[] (std::size_t n, std::nothrow_t const &) +__attribute__((noinline)) void* operator new[] (std::size_t n, std::nothrow_t const &) noexcept { return (void*)45678; } @@ -54,12 +54,12 @@ __attribute__((noinline)) void* operator new[](std::size_t size, std::align_val_ return (void*)89012; } -__attribute__((noinline)) void operator delete (void* p) +__attribute__((noinline)) void operator delete (void* p) noexcept { } -__attribute__((noinline)) void operator delete[] (void* p) +__attribute__((noinline)) void operator delete[] (void* p) noexcept { } |
From: Paul F. <pa...@so...> - 2025-05-26 06:23:59
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=6dd49fc455dbf0310eef9de6067e47fac0ce92b8 commit 6dd49fc455dbf0310eef9de6067e47fac0ce92b8 Author: Paul Floyd <pj...@wa...> Date: Mon May 26 08:21:23 2025 +0200 regtest PPC: update a few XML expecteds after bug390310 Diff: --- drd/tests/bar_bad_xml.stderr.exp | 1 - helgrind/tests/filter_xml | 1 + helgrind/tests/tc06_two_races_xml.stderr.exp | 2 +- .../tests/tc06_two_races_xml.stderr.exp-freebsd | 2 +- none/tests/Makefile.am | 1 + none/tests/fdleak_ipv4_xml.stderr.exp-ppc64be | 128 +++++++++++++++++++++ none/tests/file_dclose_xml.stderr.exp-nomain | 3 - 7 files changed, 132 insertions(+), 6 deletions(-) diff --git a/drd/tests/bar_bad_xml.stderr.exp b/drd/tests/bar_bad_xml.stderr.exp index c6150b8995..603492527c 100644 --- a/drd/tests/bar_bad_xml.stderr.exp +++ b/drd/tests/bar_bad_xml.stderr.exp @@ -204,7 +204,6 @@ destroy a barrier that has waiting threads destroy a barrier that was never initialised - <status> <state>FINISHED</state> <time>...</time> diff --git a/helgrind/tests/filter_xml b/helgrind/tests/filter_xml index e9475f04a2..0dc77f7a44 100755 --- a/helgrind/tests/filter_xml +++ b/helgrind/tests/filter_xml @@ -41,6 +41,7 @@ my %patterns = ( "Using Valgrind-([^\\s]*)" => "X.Y.X", "Copyright \\(C\\) ([0-9]{4}-[0-9]{4}).*" => "XXXX-YYYY", '<fn>pthread_.*(@\*)</fn>' => "", + "<suppressed>(.*)</suppressed>" => "...", "<suppressed_contexts>(.*)</suppressed_contexts>" => "..." ); diff --git a/helgrind/tests/tc06_two_races_xml.stderr.exp b/helgrind/tests/tc06_two_races_xml.stderr.exp index 800ef543f4..8948505a73 100644 --- a/helgrind/tests/tc06_two_races_xml.stderr.exp +++ b/helgrind/tests/tc06_two_races_xml.stderr.exp @@ -257,7 +257,7 @@ <error_summary> <errors>4</errors> <error_contexts>4</error_contexts> - <suppressed>7</suppressed> + <suppressed>...</suppressed> <suppressed_contexts>...</suppressed_contexts> </error_summary> diff --git a/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd b/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd index 724649cb6f..e8cda5ff60 100644 --- a/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd +++ b/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd @@ -249,7 +249,7 @@ <error_summary> <errors>4</errors> <error_contexts>4</error_contexts> - <suppressed>7</suppressed> + <suppressed>...</suppressed> <suppressed_contexts>...</suppressed_contexts> </error_summary> diff --git a/none/tests/Makefile.am b/none/tests/Makefile.am index 18924b34f3..ca01f9e42d 100644 --- a/none/tests/Makefile.am +++ b/none/tests/Makefile.am @@ -158,6 +158,7 @@ EXTRA_DIST = \ fdleak_fcntl.stderr.exp fdleak_fcntl.vgtest \ fdleak_fcntl_xml.stderr.exp fdleak_fcntl_xml.vgtest \ fdleak_ipv4.stderr.exp fdleak_ipv4.stdout.exp fdleak_ipv4.vgtest \ + fdleak_ipv4_xml.stderr.exp-ppc64be \ fdleak_ipv4_xml.stderr.exp-ppc64le \ fdleak_ipv4_xml.stderr.exp fdleak_ipv4_xml.stdout.exp \ fdleak_ipv4_xml.vgtest fdleak_ipv4_xml.stderr.exp-nomain \ diff --git a/none/tests/fdleak_ipv4_xml.stderr.exp-ppc64be b/none/tests/fdleak_ipv4_xml.stderr.exp-ppc64be new file mode 100644 index 0000000000..204592a557 --- /dev/null +++ b/none/tests/fdleak_ipv4_xml.stderr.exp-ppc64be @@ -0,0 +1,128 @@ +<?xml version="1.0"?> + +<valgrindoutput> + +<protocolversion>6</protocolversion> +<protocoltool>none</protocoltool> + +<preamble> + <line>Nulgrind, the minimal Valgrind tool</line> + <line>Copyright...</line> + <line>Using Valgrind...</line> + <line>Command: ./fdleak_ipv4</line> +</preamble> + +<pid>...</pid> +<ppid>...</ppid> +<tool>none</tool> + +<args> + <vargv> + <exe>...</exe> + <arg>--command-line-only=yes</arg> + <arg>--memcheck:leak-check=no</arg> + <arg>--tool=none</arg> + <arg>--track-fds=yes</arg> + <arg>--xml=yes</arg> + <arg>--xml-fd=2</arg> + <arg>--child-silent-after-fork=yes</arg> + </vargv> + <argv> + <exe>...</exe> + </argv> +</args> + +<status> + <state>RUNNING</state> + <time>...</time> +</status> + +<error> + <unique>0x........</unique> + <tid>...</tid> + <kind>FdBadClose</kind> + <fd>4</fd> + <what>...</what> + <stack> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>client</fn> + <dir>...</dir> + <file>fdleak_ipv4.c</file> + <line>70</line> + </frame> + </stack> + <auxwhat>Previously closed</auxwhat> + <stack> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>client</fn> + <dir>...</dir> + <file>fdleak_ipv4.c</file> + <line>69</line> + </frame> + </stack> + <auxwhat>Originally opened</auxwhat> + <stack> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>client</fn> + <dir>...</dir> + <file>fdleak_ipv4.c</file> + <line>68</line> + </frame> + </stack> +</error> + +<status> + <state>FINISHED</state> + <time>...</time> +</status> + +<error> + <unique>0x........</unique> + <tid>...</tid> + <kind>FdNotClosed</kind> + <fd>3</fd> + <what>...</what> + <stack> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>client</fn> + <dir>...</dir> + <file>fdleak_ipv4.c</file> + <line>51</line> + </frame> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>main</fn> + <dir>...</dir> + <file>fdleak_ipv4.c</file> + <line>90</line> + </frame> + </stack> +</error> + +<errorcounts> + <pair> + <count>1</count> + <unique>0x........</unique> + </pair> +</errorcounts> + +<suppcounts> +</suppcounts> + +<error_summary> + <errors>2</errors> + <error_contexts>2</error_contexts> + <suppressed>0</suppressed> + <suppressed_contexts>0</suppressed_contexts> +</error_summary> + +</valgrindoutput> diff --git a/none/tests/file_dclose_xml.stderr.exp-nomain b/none/tests/file_dclose_xml.stderr.exp-nomain index 6c5406c032..bd424eaed9 100644 --- a/none/tests/file_dclose_xml.stderr.exp-nomain +++ b/none/tests/file_dclose_xml.stderr.exp-nomain @@ -80,7 +80,6 @@ time passes and we close 3 again </stack> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -93,6 +92,4 @@ time passes and we close 3 again </pair> </errorcounts> - </valgrindoutput> - |
From: Paul F. <pa...@so...> - 2025-05-25 19:08:11
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=7786b075abef51ca3d84b9717915f04b32950b32 commit 7786b075abef51ca3d84b9717915f04b32950b32 Author: Paul Floyd <pj...@wa...> Date: Sun May 11 15:41:10 2025 +0200 Bug 390310 - Output summaries in XML files Original patch contributed by ren...@fr... Diff: --- coregrind/m_errormgr.c | 15 +- coregrind/m_libcassert.c | 9 +- coregrind/m_libcprint.c | 6 +- coregrind/m_main.c | 6 +- coregrind/m_scheduler/scheduler.c | 2 +- docs/internals/xml-output-protocol6.txt | 246 +++++++++++++++++++++ drd/tests/annotate_barrier_xml.stderr.exp | 6 +- .../annotate_trace_memory_xml.stderr.exp-32bit | 6 +- ...nnotate_trace_memory_xml.stderr.exp-32bit-clang | 6 +- .../annotate_trace_memory_xml.stderr.exp-64bit | 6 +- drd/tests/annotate_trace_memory_xml.stderr.exp-arm | 6 +- .../annotate_trace_memory_xml.stderr.exp-mips32 | 6 +- drd/tests/bar_bad_xml.stderr.exp | 5 +- drd/tests/bar_bad_xml.stderr.exp-freebsd | 6 +- drd/tests/bar_bad_xml.stderr.exp-no-barrier | 5 +- drd/tests/bar_bad_xml.stderr.exp-nohang | 6 +- drd/tests/bar_bad_xml.stderr.exp-solaris | 6 +- drd/tests/fp_race_xml.stderr.exp | 6 +- drd/tests/fp_race_xml.stderr.exp-mips32-be | 5 +- drd/tests/fp_race_xml.stderr.exp-mips32-le | 5 +- drd/tests/fp_race_xml.stderr.exp-solaris | 2 +- drd/tests/thread_name_xml.stderr.exp | 6 +- helgrind/tests/filter_xml | 3 +- helgrind/tests/tc06_two_races_xml.stderr.exp | 11 +- .../tests/tc06_two_races_xml.stderr.exp-freebsd | 11 +- memcheck/mc_leakcheck.c | 93 +++++--- memcheck/mc_malloc_wrappers.c | 23 +- memcheck/tests/Makefile.am | 2 +- memcheck/tests/client-msg-as-xml.stderr.exp | 7 +- .../tests/exit_on_first_error_with_xml.stderr.exp | 2 +- memcheck/tests/filter_xml | 9 +- .../tests/freebsd/aligned_alloc_xml.stderr.exp | 8 +- .../freebsd/delete_sized_mismatch_xml.stderr.exp | 8 +- memcheck/tests/gone_abrt_xml.stderr.exp | 8 +- memcheck/tests/gone_abrt_xml.stderr.exp-freebsd | 10 +- memcheck/tests/gone_abrt_xml.stderr.exp-solaris | 8 +- memcheck/tests/long_namespace_xml.stderr.exp | 8 +- .../tests/long_namespace_xml.stderr.exp-freebsd | 103 +++++++++ memcheck/tests/mismatches_xml.stderr.exp | 8 +- memcheck/tests/mismatches_xml.stderr.exp2 | 8 +- memcheck/tests/posix_memalign_xml.stderr.exp | 8 +- memcheck/tests/realloc_size_zero_xml.stderr.exp | 5 +- ...d_aligned_new_delete_misaligned1_xml.stderr.exp | 8 +- ...d_aligned_new_delete_misaligned2_xml.stderr.exp | 8 +- ...d_aligned_new_delete_misaligned3_xml.stderr.exp | 8 +- memcheck/tests/threadname_xml.stderr.exp | 11 +- memcheck/tests/xml1.stderr.exp | 10 +- memcheck/tests/xml1.stderr.exp-s390x-mvc | 10 +- none/tests/double_close_range_xml.stderr.exp | 5 +- none/tests/fdleak_cmsg_xml.stderr.exp | 5 +- none/tests/fdleak_cmsg_xml.stderr.exp-ppc64le | 2 +- none/tests/fdleak_creat_xml.stderr.exp | 5 +- none/tests/fdleak_dup2_xml.stderr.exp | 5 +- none/tests/fdleak_dup_xml.stderr.exp | 5 +- none/tests/fdleak_fcntl_xml.stderr.exp | 5 +- none/tests/fdleak_ipv4_xml.stderr.exp | 11 +- none/tests/fdleak_ipv4_xml.stderr.exp-nomain | 35 ++- none/tests/fdleak_ipv4_xml.stderr.exp-ppc64le | 11 +- none/tests/fdleak_open_xml.stderr.exp | 5 +- none/tests/fdleak_pipe_xml.stderr.exp | 5 +- none/tests/fdleak_socketpair_xml.stderr.exp | 5 +- .../tests/fdleak_socketpair_xml.stderr.exp-illumos | 5 +- none/tests/file_dclose_xml.stderr.exp | 5 +- none/tests/file_dclose_xml.stderr.exp-nomain | 2 +- none/tests/socket_close_xml.stderr.exp | 5 +- none/tests/socket_close_xml.stderr.exp-ppc64le | 2 +- none/tests/xml-track-fds.stderr.exp | 5 +- 67 files changed, 687 insertions(+), 211 deletions(-) diff --git a/coregrind/m_errormgr.c b/coregrind/m_errormgr.c index 2ce919482f..8dfeefeed3 100644 --- a/coregrind/m_errormgr.c +++ b/coregrind/m_errormgr.c @@ -1116,8 +1116,10 @@ static Bool show_used_suppressions ( void ) any_supp = True; } - if (VG_(clo_xml)) + if (VG_(clo_xml)) { VG_(printf_xml)("</suppcounts>\n"); + VG_(printf_xml)("\n"); + } return any_supp; } @@ -1134,10 +1136,19 @@ void VG_(show_all_errors) ( Int verbosity, Bool xml, Int show_error_list) if (verbosity == 0 && show_error_list == 0) return; - /* If we're printing XML, just show the suppressions and stop. */ + /* If we're printing XML, show the suppressions, the summary and stop. */ if (xml) { if (show_error_list > 0) (void)show_used_suppressions(); + VG_(printf_xml)("<error_summary>\n" + " <errors>%u</errors>\n" + " <error_contexts>%u</error_contexts>\n" + " <suppressed>%u</suppressed>\n" + " <suppressed_contexts>%u</suppressed_contexts>\n" + "</error_summary>\n", + n_errs_found, n_err_contexts, + n_errs_suppressed, n_supp_contexts ); + VG_(printf_xml)("\n"); return; } diff --git a/coregrind/m_libcassert.c b/coregrind/m_libcassert.c index c6380d4e0b..38b064021f 100644 --- a/coregrind/m_libcassert.c +++ b/coregrind/m_libcassert.c @@ -498,6 +498,10 @@ static void report_and_quit ( const HChar* report, True, // stack_usage False, // exited_threads startRegsIN); + + if (VG_(clo_xml)) // After flushing outputs + VG_(printf_xml)("</valgrindoutput>\n"); + VG_(printf)( "\n" "Note: see also the FAQ in the source distribution.\n" @@ -535,9 +539,6 @@ void VG_(assert_fail) ( Bool isCore, const HChar* expr, const HChar* file, bugs_to = VG_(details).bug_reports_to; } - if (VG_(clo_xml)) - VG_(printf_xml)("</valgrindoutput>\n"); - // Treat vg_assert2(0, "foo") specially, as a panicky abort if (VG_STREQ(expr, "0")) { VG_(printf)("\n%s: %s:%d (%s): the 'impossible' happened.\n", @@ -567,8 +568,6 @@ __attribute__ ((noreturn)) static void panic ( const HChar* name, const HChar* report, const HChar* str, const UnwindStartRegs* startRegs ) { - if (VG_(clo_xml)) - VG_(printf_xml)("</valgrindoutput>\n"); VG_(printf)("\n%s: the 'impossible' happened:\n %s\n", name, str); report_and_quit(report, startRegs); } diff --git a/coregrind/m_libcprint.c b/coregrind/m_libcprint.c index 593889da9d..390c0a01ae 100644 --- a/coregrind/m_libcprint.c +++ b/coregrind/m_libcprint.c @@ -151,11 +151,7 @@ void VG_(print_preamble)(Bool logging_to_fd) VG_(printf_xml)("\n"); VG_(printf_xml)("<valgrindoutput>\n"); VG_(printf_xml)("\n"); - /* track-fds introduced some new elements. */ - if (VG_(clo_track_fds)) - VG_(printf_xml)("<protocolversion>5</protocolversion>\n"); - else - VG_(printf_xml)("<protocolversion>4</protocolversion>\n"); + VG_(printf_xml)("<protocolversion>6</protocolversion>\n"); VG_(printf_xml)("<protocoltool>%s</protocoltool>\n", VG_(clo_toolname)); VG_(printf_xml)("\n"); } diff --git a/coregrind/m_main.c b/coregrind/m_main.c index 4da156fb94..128e4298c1 100644 --- a/coregrind/m_main.c +++ b/coregrind/m_main.c @@ -2309,9 +2309,7 @@ void shutdown_actions_NORETURN( ThreadId tid, // affects what order the messages come. //-------------------------------------------------------------- // First thing in the post-amble is a blank line. - if (VG_(clo_xml)) - VG_(printf_xml)("\n"); - else if (VG_(clo_verbosity) > 0) + if (VG_(clo_verbosity) > 0 && !VG_(clo_xml)) VG_(message)(Vg_UserMsg, "\n"); if (VG_(clo_xml)) { @@ -2353,9 +2351,7 @@ void shutdown_actions_NORETURN( ThreadId tid, } if (VG_(clo_xml)) { - VG_(printf_xml)("\n"); VG_(printf_xml)("</valgrindoutput>\n"); - VG_(printf_xml)("\n"); } VG_(sanity_check_general)( True /*include expensive checks*/ ); diff --git a/coregrind/m_scheduler/scheduler.c b/coregrind/m_scheduler/scheduler.c index 51ba343616..1623dda5a0 100644 --- a/coregrind/m_scheduler/scheduler.c +++ b/coregrind/m_scheduler/scheduler.c @@ -1982,7 +1982,7 @@ Int print_client_message( ThreadId tid, const HChar *format, VG_(get_and_pp_StackTrace)( tid, VG_(clo_backtrace_size) ); if (VG_(clo_xml)) - VG_(printf_xml)( "</clientmsg>\n" ); + VG_(printf_xml)( "</clientmsg>\n\n" ); return count; } diff --git a/docs/internals/xml-output-protocol6.txt b/docs/internals/xml-output-protocol6.txt new file mode 100644 index 0000000000..071ed11825 --- /dev/null +++ b/docs/internals/xml-output-protocol6.txt @@ -0,0 +1,246 @@ +==================================================================== + +11 May 2025 + +Protocol 6 is now always used (unlike protocol 5 which was only +used with--track-fds). The main difference is that the xml output +now contains error summaries. + +==================================================================== + + +Global error summary +-------------------- + +Previously, the non-xml output contained a summary of errors and +suppressions used, like this: + +==3166== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 3 from 3) + +This was not included in the xml output. Starting with protocol 6 it will +be included. The above example would produce + +<error_summary> + <errors>1</errors> + <error_contexts>1</error_contexts> + <suppressed>3</suppressed> + <suppressed_contexts>3</suppressed_contexts> +</error_summary> + +Memcheck heap and leak summaries +-------------------------------- + +Memcheck produces two summaries that were not generated for XML. +These are the heap summary, such as + +==80874== HEAP SUMMARY: +==80874== in use at exit: 720 bytes in 5 blocks +==80874== total heap usage: 5 allocs, 0 frees, 720 bytes allocated + +This now generates with --xml=yes + +<heap_summary> + <memory_in_use_at_exit> + <bytes>720</bytes> + <blocks>5</blocks> + </memory_in_use_at_exit> + <total_heap_usage> + <allocs>5</allocs> + <frees>0</frees> + <bytes_allocated>720</bytes_allocated> + </total_heap_usage> +</heap_summary> + +<all_heap_blocks_freed>false</all_heap_blocks_freed> + +The final summary is the leak summary. An example of the non-xml output +is as follows: + +==24152== LEAK SUMMARY: +==24152== definitely lost: 48 bytes in 3 blocks +==24152== indirectly lost: 32 bytes in 2 blocks +==24152== possibly lost: 96 bytes in 6 blocks +==24152== still reachable: 64 bytes in 4 blocks +==24152== suppressed: 0 bytes in 0 blocks + +The example above now produces with xml output + +<leak_summary> + <definitely_lost> + <bytes>48</bytes> + <in_blocks>3</in_blocks> + </definitely_lost> + <indirectly_lost> + <bytes>32</bytes> + <in_blocks>2</in_blocks> + </indirectly_lost> + <possibly_lost> + <bytes>96</bytes> + <in_blocks>6</in_blocks> + </possibly_lost> + <still_reachable> + <bytes>64</bytes> + <in_blocks>4</in_blocks> + </still_reachable> + <suppressed> + <bytes>0</bytes> + <in_blocks>0</in_blocks> + </suppressed> +</leak_summary> + + +COMMON ELEMENTS +--------------- +BYTES and BLOCKS elements are common to the HEAP and LEAK summaries. + +The BYTES element is + +* <bytes>INT</bytes> + +This field indicates the number of bytes of memory that are not deallocated +at exit or user leak check. + +The BLOCKS element is + +* <blocks>INT</blocks> + +The block fields contains the number of blocks that have not been deallocated +at exit or user leak check. + + +HEAP SUMMARY +------------ + +The heap summary is contained in a heap_summary element. It contains the +following sub-elements: + +* <memory_in_use_at_exit>BYTES AND BLOCKS ELEMENTS</memory_in_use_at_exit> + +The second sub-element of heap_summary indicates the total heap usage. + +* <total_heap_usage>ALLOCS FREES AND BYTES ELEMENTS</total_heap_usage> + +The ALLOCS element is + +* <allocs>INT</allocs> + +This indicates the total number of allocations during the program run. + +The FREES element is + +* <frees>INT</frees> + +This indicates the total number of deallocation during the program run. + +The BYTES element is + +* <bytes_allocated>INT</bytes_allocated> + +This indicates the total number of bytes allocated during the program run. + + +ERROR SUMMARY +------------- + +The error summary is contained in an error_summary element. It contains the +following sub-elements: + +* <errors>INT</errors> + +This field indicates the number of unsuppressed errors that were encountered. + +* <error_contexts>INT</error_contexts> + +This field indicated the number of unique unsuppressed error contexts. + +* <suppressed>INT</suppressed> + +This is the number of errors that were suppressed. + +* <suppressed_contexts>INT</suppressed_contexts> + +This is the number of unique error contexts used by the suppressions. + +LEAK SUMMARY +------------ + +The leak summary is contained in a leak_summary element. + +The leak summary sub-elements are: + +* <definitely_lost>BYTES AND BLOCKS ELEMENTS</definitely_lost> + +Memory that was definitely lost. + +* <indirectly_lost>BYTES AND BLOCKS ELEMENTS</indirectly_lost> + +Memory that was indirectly lost. + +* <possibly_lost>BYTES AND BLOCKS ELEMENTS</possibly_lost> + +Memory that was lost but memcheck cannot determine if it is +definitely lost or still reachable. + +* <still_reachable> BYTES BLOCKS AND (optional) REACHABLE_HEURISTIC ELEMENTS</still_reachable> + +Memory that was still reachable at exit or the user leak check. + +If the --leak-check-heuristics= option was used then the still_reachable element +may contain further details on the memory and kind of heuristic that the block(s). +correspond to. + +The REACHABLE_HEURISTIC format is + <reachable_heuristic> + <kind>KIND</kind> + <bytes>INT</bytes> + <blocks>INT</blocks> + </reachable_heuristic> + +KIND is one of: + none, stdstring, length64, newarray, multipleinheritance + +* <suppressed>BYTES AND BLOCK ELEMENTS</suppressed> + +Information concerning the amount leaked that was suppressed. + + +Addendum +-------- + +Unfortunately the xml-output-protocol documents were not updated +to reflect some of the memcheck error conditions that were added. +This omission is being rectified here. + +* memcheck error element kind + + Added on 2023-03-10 + + ReallocSizeZero + + realloc() called with a size of zero. + + Added on 2023-09-02 + + InvalidSizeAndAlignment + + an aligned allocation was requested with an invalid size such + as a non-multiple of the alignment + + InvalidAlignment + + an alignment was used that is not allowed such as a non-power + of two + + InvalidSize + + a size of zero was used with an aligned allocation + + MismatchedAllocateDeallocateSize + + the size used for a sized deallocation does not match the + size of the allocated block + + MismatchedAllocateDeallocateAlignment + + the alignment used for a deallocation does not match the + alignment requested when the block was allocated diff --git a/drd/tests/annotate_barrier_xml.stderr.exp b/drd/tests/annotate_barrier_xml.stderr.exp index b34c787e8e..702926c180 100644 --- a/drd/tests/annotate_barrier_xml.stderr.exp +++ b/drd/tests/annotate_barrier_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -284,7 +284,6 @@ </error> Done. - <status> <state>FINISHED</state> <time>...</time> @@ -323,5 +322,6 @@ Done. <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit b/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit index 888084b410..7688aaae74 100644 --- a/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit +++ b/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -287,7 +287,6 @@ uint64_t </stack> </trace> Done. - <status> <state>FINISHED</state> <time>...</time> @@ -298,5 +297,6 @@ Done. <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit-clang b/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit-clang index 13c7a9e5a3..057f96054a 100644 --- a/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit-clang +++ b/drd/tests/annotate_trace_memory_xml.stderr.exp-32bit-clang @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -287,7 +287,6 @@ uint64_t </stack> </trace> Done. - <status> <state>FINISHED</state> <time>...</time> @@ -298,5 +297,6 @@ Done. <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/annotate_trace_memory_xml.stderr.exp-64bit b/drd/tests/annotate_trace_memory_xml.stderr.exp-64bit index 8a62b6c460..6f4e8ff4a9 100644 --- a/drd/tests/annotate_trace_memory_xml.stderr.exp-64bit +++ b/drd/tests/annotate_trace_memory_xml.stderr.exp-64bit @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -251,7 +251,6 @@ uint64_t </stack> </trace> Done. - <status> <state>FINISHED</state> <time>...</time> @@ -262,5 +261,6 @@ Done. <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/annotate_trace_memory_xml.stderr.exp-arm b/drd/tests/annotate_trace_memory_xml.stderr.exp-arm index 2af2455ca0..146d6574d2 100644 --- a/drd/tests/annotate_trace_memory_xml.stderr.exp-arm +++ b/drd/tests/annotate_trace_memory_xml.stderr.exp-arm @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -299,7 +299,6 @@ uint64_t </stack> </trace> Done. - <status> <state>FINISHED</state> <time>...</time> @@ -310,5 +309,6 @@ Done. <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/annotate_trace_memory_xml.stderr.exp-mips32 b/drd/tests/annotate_trace_memory_xml.stderr.exp-mips32 index 9fc793a418..ef85978354 100644 --- a/drd/tests/annotate_trace_memory_xml.stderr.exp-mips32 +++ b/drd/tests/annotate_trace_memory_xml.stderr.exp-mips32 @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -323,7 +323,6 @@ uint64_t </stack> </trace> Done. - <status> <state>FINISHED</state> <time>...</time> @@ -334,5 +333,6 @@ Done. <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/bar_bad_xml.stderr.exp b/drd/tests/bar_bad_xml.stderr.exp index 8539f75c77..c6150b8995 100644 --- a/drd/tests/bar_bad_xml.stderr.exp +++ b/drd/tests/bar_bad_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -231,5 +231,6 @@ destroy a barrier that was never initialised <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/bar_bad_xml.stderr.exp-freebsd b/drd/tests/bar_bad_xml.stderr.exp-freebsd index 24ac7fe952..460d7f77a4 100644 --- a/drd/tests/bar_bad_xml.stderr.exp-freebsd +++ b/drd/tests/bar_bad_xml.stderr.exp-freebsd @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -251,7 +251,6 @@ destroy a barrier that was never initialised </first_observed_at> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -282,5 +281,6 @@ destroy a barrier that was never initialised <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/bar_bad_xml.stderr.exp-no-barrier b/drd/tests/bar_bad_xml.stderr.exp-no-barrier index 1b7db90d3e..26ee071ec1 100644 --- a/drd/tests/bar_bad_xml.stderr.exp-no-barrier +++ b/drd/tests/bar_bad_xml.stderr.exp-no-barrier @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -209,5 +209,6 @@ destroy a barrier that was never initialised <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/bar_bad_xml.stderr.exp-nohang b/drd/tests/bar_bad_xml.stderr.exp-nohang index a47cd603b7..14e2fcf457 100644 --- a/drd/tests/bar_bad_xml.stderr.exp-nohang +++ b/drd/tests/bar_bad_xml.stderr.exp-nohang @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -229,7 +229,6 @@ destroy a barrier that was never initialised </stack> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -260,5 +259,6 @@ destroy a barrier that was never initialised <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/bar_bad_xml.stderr.exp-solaris b/drd/tests/bar_bad_xml.stderr.exp-solaris index acb965656e..59a0c89d51 100644 --- a/drd/tests/bar_bad_xml.stderr.exp-solaris +++ b/drd/tests/bar_bad_xml.stderr.exp-solaris @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -276,7 +276,6 @@ destroy a barrier that was never initialised </first_observed_at> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -311,5 +310,6 @@ destroy a barrier that was never initialised <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/fp_race_xml.stderr.exp b/drd/tests/fp_race_xml.stderr.exp index 05ffe71e52..17409062be 100644 --- a/drd/tests/fp_race_xml.stderr.exp +++ b/drd/tests/fp_race_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -81,7 +81,6 @@ <trace><text>drd_post_thread_join joiner = 1, joinee = 2, new vc: [ ... ]</text></trace> <trace><text>drd_thread_finished tid = 1</text></trace> - <status> <state>FINISHED</state> <time>...</time> @@ -100,5 +99,6 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/fp_race_xml.stderr.exp-mips32-be b/drd/tests/fp_race_xml.stderr.exp-mips32-be index 2960a39077..d5bfdd99fe 100644 --- a/drd/tests/fp_race_xml.stderr.exp-mips32-be +++ b/drd/tests/fp_race_xml.stderr.exp-mips32-be @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -154,5 +154,6 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/fp_race_xml.stderr.exp-mips32-le b/drd/tests/fp_race_xml.stderr.exp-mips32-le index a0edb5e894..d6703d6415 100644 --- a/drd/tests/fp_race_xml.stderr.exp-mips32-le +++ b/drd/tests/fp_race_xml.stderr.exp-mips32-le @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -154,5 +154,6 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/drd/tests/fp_race_xml.stderr.exp-solaris b/drd/tests/fp_race_xml.stderr.exp-solaris index 05ffe71e52..2063aa4f0e 100644 --- a/drd/tests/fp_race_xml.stderr.exp-solaris +++ b/drd/tests/fp_race_xml.stderr.exp-solaris @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> diff --git a/drd/tests/thread_name_xml.stderr.exp b/drd/tests/thread_name_xml.stderr.exp index 36b53604e8..0e47f5fff4 100644 --- a/drd/tests/thread_name_xml.stderr.exp +++ b/drd/tests/thread_name_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>drd</protocoltool> <preamble> @@ -388,7 +388,6 @@ thread_func instance 10 </stack> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -439,5 +438,6 @@ thread_func instance 10 <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/helgrind/tests/filter_xml b/helgrind/tests/filter_xml index cc0b71ea07..e9475f04a2 100755 --- a/helgrind/tests/filter_xml +++ b/helgrind/tests/filter_xml @@ -40,7 +40,8 @@ my %patterns = ( "0x([0-9a-zA-Z]+)" => "........", "Using Valgrind-([^\\s]*)" => "X.Y.X", "Copyright \\(C\\) ([0-9]{4}-[0-9]{4}).*" => "XXXX-YYYY", - '<fn>pthread_.*(@\*)</fn>' => "" + '<fn>pthread_.*(@\*)</fn>' => "", + "<suppressed_contexts>(.*)</suppressed_contexts>" => "..." ); # List of XML sections to be ignored. diff --git a/helgrind/tests/tc06_two_races_xml.stderr.exp b/helgrind/tests/tc06_two_races_xml.stderr.exp index a442a285e3..800ef543f4 100644 --- a/helgrind/tests/tc06_two_races_xml.stderr.exp +++ b/helgrind/tests/tc06_two_races_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>helgrind</protocoltool> <preamble> @@ -245,7 +245,6 @@ <xauxwhat><text>declared at tc06_two_races.c:9</text> <file>tc06_two_races.c</file> <line>9</line> </xauxwhat> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -255,5 +254,11 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary> + <errors>4</errors> + <error_contexts>4</error_contexts> + <suppressed>7</suppressed> + <suppressed_contexts>...</suppressed_contexts> +</error_summary> +</valgrindoutput> diff --git a/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd b/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd index 65a79a759b..724649cb6f 100644 --- a/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd +++ b/helgrind/tests/tc06_two_races_xml.stderr.exp-freebsd @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>helgrind</protocoltool> <preamble> @@ -237,7 +237,6 @@ <xauxwhat><text>declared at tc06_two_races.c:9</text> <file>tc06_two_races.c</file> <line>9</line> </xauxwhat> </error> - <status> <state>FINISHED</state> <time>...</time> @@ -247,5 +246,11 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary> + <errors>4</errors> + <error_contexts>4</error_contexts> + <suppressed>7</suppressed> + <suppressed_contexts>...</suppressed_contexts> +</error_summary> +</valgrindoutput> diff --git a/memcheck/mc_leakcheck.c b/memcheck/mc_leakcheck.c index 83a2b74e2a..3099a04dd9 100644 --- a/memcheck/mc_leakcheck.c +++ b/memcheck/mc_leakcheck.c @@ -1722,7 +1722,9 @@ static void print_results(ThreadId tid, LeakCheckParams* lcp) VG_(XT_delete)(leak_xt); } - if (VG_(clo_verbosity) > 0 && !VG_(clo_xml)) { + UInt (*umsg_or_xml)( const HChar *, ... ) + = VG_(clo_xml) ? VG_(printf_xml) : VG_(umsg); + if (VG_(clo_verbosity) > 0) { HChar d_bytes[31]; HChar d_blocks[31]; # define DBY(new,old) \ @@ -1732,23 +1734,42 @@ static void print_results(ThreadId tid, LeakCheckParams* lcp) MC_(snprintf_delta) (d_blocks, sizeof(d_blocks), (new), (old), \ lcp->deltamode) - VG_(umsg)("LEAK SUMMARY:\n"); - VG_(umsg)(" definitely lost: %'lu%s bytes in %'lu%s blocks\n", + umsg_or_xml(VG_(clo_xml) ? "<leak_summary>\n" : "LEAK SUMMARY:\n"); + umsg_or_xml(VG_(clo_xml) ? + " <definitely_lost>\n" + " <bytes>%'lu%s</bytes>\n" + " <blocks>%'lu%s</blocks>\n" + " </definitely_lost>\n" : + " definitely lost: %'lu%s bytes in %'lu%s blocks\n", MC_(bytes_leaked), DBY (MC_(bytes_leaked), old_bytes_leaked), MC_(blocks_leaked), DBL (MC_(blocks_leaked), old_blocks_leaked)); - VG_(umsg)(" indirectly lost: %'lu%s bytes in %'lu%s blocks\n", + umsg_or_xml(VG_(clo_xml) ? + " <indirectly_lost>\n" + " <bytes>%'lu%s</bytes>\n" + " <blocks>%'lu%s</blocks>\n" + " </indirectly_lost>\n" : + " indirectly lost: %'lu%s bytes in %'lu%s blocks\n", MC_(bytes_indirect), DBY (MC_(bytes_indirect), old_bytes_indirect), MC_(blocks_indirect), DBL (MC_(blocks_indirect), old_blocks_indirect)); - VG_(umsg)(" possibly lost: %'lu%s bytes in %'lu%s blocks\n", + umsg_or_xml(VG_(clo_xml) ? + " <possibly_lost>\n" + " <bytes>%'lu%s</bytes>\n" + " <blocks>%'lu%s</blocks>\n" + " </possibly_lost>\n" : + " possibly lost: %'lu%s bytes in %'lu%s blocks\n", MC_(bytes_dubious), DBY (MC_(bytes_dubious), old_bytes_dubious), MC_(blocks_dubious), DBL (MC_(blocks_dubious), old_blocks_dubious)); - VG_(umsg)(" still reachable: %'lu%s bytes in %'lu%s blocks\n", + umsg_or_xml(VG_(clo_xml) ? + " <still_reachable>\n" + " <bytes>%'lu%s</bytes>\n" + " <blocks>%'lu%s</blocks>\n" : + " still reachable: %'lu%s bytes in %'lu%s blocks\n", MC_(bytes_reachable), DBY (MC_(bytes_reachable), old_bytes_reachable), MC_(blocks_reachable), @@ -1756,15 +1777,21 @@ static void print_results(ThreadId tid, LeakCheckParams* lcp) for (i = 0; i < N_LEAK_CHECK_HEURISTICS; i++) if (old_blocks_heuristically_reachable[i] > 0 || MC_(blocks_heuristically_reachable)[i] > 0) { - VG_(umsg)(" of which " + umsg_or_xml(VG_(clo_xml) ? "" : " of which " "reachable via heuristic:\n"); break; } for (i = 0; i < N_LEAK_CHECK_HEURISTICS; i++) if (old_blocks_heuristically_reachable[i] > 0 || MC_(blocks_heuristically_reachable)[i] > 0) - VG_(umsg)(" %-19s: " - "%'lu%s bytes in %'lu%s blocks\n", + umsg_or_xml(VG_(clo_xml) ? + " <reachable_heuristic>\n" + " <kind>%ls</kind>\n" + " <bytes>%'lu%s</bytes>\n" + " <blocks>%'lu%s</blocks>\n" + " </reachable_heuristic>\n" : + " %-19s: " + "%'lu%s bytes in %'lu%s blocks\n", pp_heuristic(i), MC_(bytes_heuristically_reachable)[i], DBY (MC_(bytes_heuristically_reachable)[i], @@ -1772,32 +1799,41 @@ static void print_results(ThreadId tid, LeakCheckParams* lcp) MC_(blocks_heuristically_reachable)[i], DBL (MC_(blocks_heuristically_reachable)[i], old_blocks_heuristically_reachable[i])); - VG_(umsg)(" suppressed: %'lu%s bytes in %'lu%s blocks\n", - MC_(bytes_suppressed), - DBY (MC_(bytes_suppressed), old_bytes_suppressed), + if (VG_(clo_xml) && MC_(bytes_reachable)) { + umsg_or_xml(" </still_reachable>\n"); + } + umsg_or_xml(VG_(clo_xml) ? + " <suppressed>\n" + " <bytes>%'lu%s</bytes>\n" + " <blocks>%'lu%s</blocks>\n" + " </suppressed>\n" : + " suppressed: %'lu%s bytes in %'lu%s blocks\n", + MC_(bytes_suppressed), + DBY (MC_(bytes_suppressed), old_bytes_suppressed), MC_(blocks_suppressed), DBL (MC_(blocks_suppressed), old_blocks_suppressed)); if (lcp->mode != LC_Full && (MC_(blocks_leaked) + MC_(blocks_indirect) + MC_(blocks_dubious) + MC_(blocks_reachable)) > 0) { if (lcp->requested_by_monitor_command) - VG_(umsg)("To see details of leaked memory, " - "give 'full' arg to leak_check\n"); + umsg_or_xml(VG_(clo_xml) ? "" : "To see details of leaked memory, " + "give 'full' arg to leak_check\n"); else - VG_(umsg)("Rerun with --leak-check=full to see details " - "of leaked memory\n"); + umsg_or_xml(VG_(clo_xml) ? "" : "Rerun with --leak-check=full to " + "see details of leaked memory\n"); } if (lcp->mode == LC_Full && MC_(blocks_reachable) > 0 && !RiS(Reachable,lcp->show_leak_kinds)) { - VG_(umsg)("Reachable blocks (those to which a pointer " - "was found) are not shown.\n"); + umsg_or_xml(VG_(clo_xml) ? "" : "Reachable blocks (those to which a " + "pointer was found) are not shown.\n"); if (lcp->requested_by_monitor_command) - VG_(umsg)("To see them, add 'reachable any' args to leak_check\n"); + umsg_or_xml(VG_(clo_xml) ? "" : "To see them, add 'reachable any' " + "args to leak_check\n"); else - VG_(umsg)("To see them, rerun with: --leak-check=full " - "--show-leak-kinds=all\n"); + umsg_or_xml(VG_(clo_xml) ? "" : "To see them, rerun with: " + "--leak-check=full --show-leak-kinds=all\n"); } - VG_(umsg)("\n"); + umsg_or_xml(VG_(clo_xml) ? "</leak_summary>\n\n" : "\n"); #undef DBL #undef DBY } @@ -2056,11 +2092,17 @@ void MC_(detect_memory_leaks) ( ThreadId tid, LeakCheckParams* lcp) VG_(OSetGen_Destroy) (lr_table); lr_table = NULL; } - if (VG_(clo_verbosity) >= 1 && !VG_(clo_xml)) { - VG_(umsg)("All heap blocks were freed -- no leaks are possible\n"); - VG_(umsg)("\n"); + if (VG_(clo_verbosity) >= 1) { + if (!VG_(clo_xml)) { + VG_(umsg)("All heap blocks were freed -- no leaks are possible\n"); + VG_(umsg)("\n"); + } else + VG_(printf_xml)("<all_heap_blocks_freed>true</all_heap_blocks_freed>\n\n"); } return; + } else { + if (VG_(clo_verbosity) >= 1 && VG_(clo_xml)) + VG_(printf_xml)("<all_heap_blocks_freed>false</all_heap_blocks_freed>\n\n"); } // Sanity check -- make sure they don't overlap. One exception is that @@ -2301,4 +2343,3 @@ void MC_(who_points_at) ( Addr address, SizeT szB) /*--------------------------------------------------------------------*/ /*--- end ---*/ /*--------------------------------------------------------------------*/ - diff --git a/memcheck/mc_malloc_wrappers.c b/memcheck/mc_malloc_wrappers.c index 48f26902cd..584afa50ea 100644 --- a/memcheck/mc_malloc_wrappers.c +++ b/memcheck/mc_malloc_wrappers.c @@ -1229,8 +1229,6 @@ void MC_(print_malloc_stats) ( void ) if (VG_(clo_verbosity) == 0) return; - if (VG_(clo_xml)) - return; /* Count memory still in use. */ VG_(HT_ResetIter)(MC_(malloc_list)); @@ -1239,6 +1237,27 @@ void MC_(print_malloc_stats) ( void ) nbytes += (ULong)mc->szB; } + if (VG_(clo_xml)) { + VG_(printf_xml)( + "<heap_summary>\n" + " <memory_in_use_at_exit>\n" + " <bytes>%'llu</bytes>\n" + " <blocks>%'lu</blocks>\n" + " </memory_in_use_at_exit>\n" + " <total_heap_usage>\n" + " <allocs>%'lu</allocs>\n" + " <frees>%'lu</frees>\n" + " <bytes_allocated>%'llu</bytes_allocated>\n" + " </total_heap_usage>\n" + "</heap_summary>\n" + "\n", + nbytes, nblocks, + cmalloc_n_mallocs, + cmalloc_n_frees, cmalloc_bs_mallocd + ); + return; + } + VG_(umsg)( "HEAP SUMMARY:\n" " in use at exit: %'llu bytes in %'lu blocks\n" diff --git a/memcheck/tests/Makefile.am b/memcheck/tests/Makefile.am index 928ac16e6a..db6cd17863 100644 --- a/memcheck/tests/Makefile.am +++ b/memcheck/tests/Makefile.am @@ -257,7 +257,7 @@ EXTRA_DIST = \ leak-segv-jmp.vgtest leak-segv-jmp.stderr.exp \ lks.vgtest lks.stdout.exp lks.supp lks.stderr.exp \ long_namespace_xml.vgtest long_namespace_xml.stdout.exp \ - long_namespace_xml.stderr.exp \ + long_namespace_xml.stderr.exp long_namespace_xml.stderr.exp-freebsd \ long-supps.vgtest long-supps.stderr.exp long-supps.supp \ mallinfo.stderr.exp mallinfo.vgtest \ malloc_free_fill.vgtest \ diff --git a/memcheck/tests/client-msg-as-xml.stderr.exp b/memcheck/tests/client-msg-as-xml.stderr.exp index af97c61ab4..609f5826b4 100644 --- a/memcheck/tests/client-msg-as-xml.stderr.exp +++ b/memcheck/tests/client-msg-as-xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -81,10 +81,13 @@ <time>...</time> </status> +<heap_summary>...</heap_summary> + <errorcounts> </errorcounts> <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/exit_on_first_error_with_xml.stderr.exp b/memcheck/tests/exit_on_first_error_with_xml.stderr.exp index 3a02ca5323..6061fc19a4 100644 --- a/memcheck/tests/exit_on_first_error_with_xml.stderr.exp +++ b/memcheck/tests/exit_on_first_error_with_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> diff --git a/memcheck/tests/filter_xml b/memcheck/tests/filter_xml index 9244706c36..2c63cddbcb 100755 --- a/memcheck/tests/filter_xml +++ b/memcheck/tests/filter_xml @@ -22,13 +22,20 @@ sed "s/operator delete\[\](void\*, unsigned int/operator delete[](void*, unsigne sed "s/4294967295/18446744073709551615/" | sed "s/malloc_zone_memalign/posix_memalign/" | perl -p -e "s/(m_replacemalloc\/)?vg_replace_malloc.c/vg_replace_malloc.c/" | +perl -0 -p -e "s/<heap_summary>.*<\/heap_summary>/<heap_summary>...<\/heap_summary>/s" | +perl -0 -p -e "s/<error_summary>.*<\/error_summary>/<error_summary>...<\/error_summary>/s" | +perl -0 -p -e "s/<leak_summary>.*<\/leak_summary>/<leak_summary>...<\/leak_summary>/s" | perl -0 -p -e "s/<suppcounts>.*<\/suppcounts>/<suppcounts>...<\/suppcounts>/s" | perl -p -e "s/<time>.*<\/time>/<time>...<\/time>/s" | perl -0 -p -e "s/<vargv>.*<\/vargv>/<vargv>...<\/vargv>/s" | +perl -0 -p -e "s/<suppressed>.*<\/suppressed>/<suppressed>...<\/suppressed>/s" | +perl -0 -p -e "s/<suppressed_contexts>.*<\/suppressed_contexts>/<suppressed_from>...<\/suppressed_from>/s" | # Remove stack traces for Syscall param errors (see filter_stderr for more). # Chops everything within <stack>...</stack>. -perl -p -0 -e 's/(<what>Syscall param[^\n]*\n)([^\n]*(stack|frame|ip|obj|fn|dir|file|line)[^\n]*\n)+/$1/gs' +perl -p -0 -e 's/(<what>Syscall param[^\n]*\n)([^\n]*(stack|frame|ip|obj|fn|dir|file|line)[^\n]*\n)+/$1/gs' | + +sed "/<all_heap_blocks_freed>/,+1d" # Collected wisdom re Perl magic incantation: # diff --git a/memcheck/tests/freebsd/aligned_alloc_xml.stderr.exp b/memcheck/tests/freebsd/aligned_alloc_xml.stderr.exp index 13066ae537..70b85b8d5f 100644 --- a/memcheck/tests/freebsd/aligned_alloc_xml.stderr.exp +++ b/memcheck/tests/freebsd/aligned_alloc_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -78,12 +78,13 @@ </stack> </error> - <status> <state>FINISHED</state> <time>...</time> </status> +<heap_summary>...</heap_summary> + <errorcounts> <pair> <count>...</count> @@ -97,5 +98,6 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/freebsd/delete_sized_mismatch_xml.stderr.exp b/memcheck/tests/freebsd/delete_sized_mismatch_xml.stderr.exp index 55225906f9..f63cdadb90 100644 --- a/memcheck/tests/freebsd/delete_sized_mismatch_xml.stderr.exp +++ b/memcheck/tests/freebsd/delete_sized_mismatch_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -116,12 +116,13 @@ </stack> </error> - <status> <state>FINISHED</state> <time>...</time> </status> +<heap_summary>...</heap_summary> + <errorcounts> <pair> <count>...</count> @@ -135,5 +136,6 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/gone_abrt_xml.stderr.exp b/memcheck/tests/gone_abrt_xml.stderr.exp index b0faf73bdc..9f7b1f52fc 100644 --- a/memcheck/tests/gone_abrt_xml.stderr.exp +++ b/memcheck/tests/gone_abrt_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -48,16 +48,18 @@ aborting ... </stack> </fatal_signal> - <status> <state>FINISHED</state> <time>...</time> </status> +<heap_summary>...</heap_summary> + <errorcounts> </errorcounts> <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/gone_abrt_xml.stderr.exp-freebsd b/memcheck/tests/gone_abrt_xml.stderr.exp-freebsd index c97485faf4..04643bbffa 100644 --- a/memcheck/tests/gone_abrt_xml.stderr.exp-freebsd +++ b/memcheck/tests/gone_abrt_xml.stderr.exp-freebsd @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -48,16 +48,20 @@ aborting ... </stack> </fatal_signal> - <status> <state>FINISHED</state> <time>...</time> </status> +<heap_summary>...</heap_summary> + +<leak_summary>...</leak_summary> + <errorcounts> </errorcounts> <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/gone_abrt_xml.stderr.exp-solaris b/memcheck/tests/gone_abrt_xml.stderr.exp-solaris index a6c88df27e..1c307433fa 100644 --- a/memcheck/tests/gone_abrt_xml.stderr.exp-solaris +++ b/memcheck/tests/gone_abrt_xml.stderr.exp-solaris @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -50,16 +50,18 @@ aborting ... </stack> </fatal_signal> - <status> <state>FINISHED</state> <time>...</time> </status> +<heap_summary>...</heap_summary> + <errorcounts> </errorcounts> <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/long_namespace_xml.stderr.exp b/memcheck/tests/long_namespace_xml.stderr.exp index 775fac002b..5229965921 100644 --- a/memcheck/tests/long_namespace_xml.stderr.exp +++ b/memcheck/tests/long_namespace_xml.stderr.exp @@ -2,7 +2,7 @@ <valgrindoutput> -<protocolversion>4</protocolversion> +<protocolversion>6</protocolversion> <protocoltool>memcheck</protocoltool> <preamble> @@ -80,12 +80,13 @@ </stack> </error> - <status> <state>FINISHED</state> <time>...</time> </status> +<heap_summary>...</heap_summary> + <errorcounts> <pair> <count>...</count> @@ -95,5 +96,6 @@ <suppcounts>...</suppcounts> -</valgrindoutput> +<error_summary>...</error_summary> +</valgrindoutput> diff --git a/memcheck/tests/long_namespace_xml.stderr.exp-freebsd b/memcheck/tests/long_namespace_xml.stderr.exp-freebsd new file mode 100644 index 0000000000..e4a9b08fc9 --- /dev/null +++ b/memcheck/tests/long_namespace_xml.stderr.exp-freebsd @@ -0,0 +1,103 @@ +<?xml version="1.0"?> + +<valgrindoutput> + +<protocolversion>6</protocolversion> +<protocoltool>memcheck</protocoltool> + +<preamble> + <line>...</line> + <line>...</line> + <line>...</line> + <line>...</line> +</preamble> + +<pid>...</pid> +<ppid>...</ppid> +<tool>memcheck</tool> + +<args> + <vargv>...</vargv> + <argv> + <exe>./long_namespace_xml</exe> + </argv> +</args> + +<status> + <state>RUNNING</state> + <time>...</time> +</status> + +<error> + <unique>0x........</unique> + <tid>...</tid> + <kind>InvalidWrite</kind> + <what>Invalid write of size 1</what> + <stack> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>_ZN5304abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqr stuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyza bcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghij klmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrs tuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzab cdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz5304ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFG HIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOP QRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXY ZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGH IJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQ RSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZ1fEv</fn> + <dir>...</dir> + <file>long_namespace_xml.cpp</file> + <line>...</line> + </frame> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>main</fn> + <dir>...</dir> + <file>long_namespace_xml.cpp</file> + <line>...</line> + </frame> + </stack> + <auxwhat>Address 0x........ is 1 bytes after a block of size 4 alloc'd</auxwhat> + <stack> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>malloc</fn> + <dir>...</dir> + <file>vg_replace_malloc.c</file> + <line>...</line> + </frame> + <frame> + <ip>0x........</ip> + <obj>...</obj> + <fn>_ZN5304abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqr stuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyza bcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmn... [truncated message content] |
From: Paul F. <pa...@so...> - 2025-05-24 16:44:20
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=c6b85a3a50f66a55da775f9ad112bb1317e809e1 commit c6b85a3a50f66a55da775f9ad112bb1317e809e1 Author: Paul Floyd <pj...@wa...> Date: Sat May 24 18:43:03 2025 +0200 FreeBSD: change vgdb traces to use PTRACE_CONTINUE rather than Linux PTRACE_CONT Diff: --- coregrind/vgdb-invoker-freebsd.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/coregrind/vgdb-invoker-freebsd.c b/coregrind/vgdb-invoker-freebsd.c index df34e0a151..607e059919 100644 --- a/coregrind/vgdb-invoker-freebsd.c +++ b/coregrind/vgdb-invoker-freebsd.c @@ -260,7 +260,7 @@ Bool waitstopped (pid_t pid, int signal_expected, const char *msg) ERROR(errno, "PT_LWPINFO failed: signal lost !!!!\n"); signal_queue_sz--; } else { - DEBUG(1, "waitstopped PTRACE_CONT, queuing signal %d" + DEBUG(1, "waitstopped PTRACE_CONTINUE, queuing signal %d" " si_signo %d si_pid %d\n", signal_received, newsiginfo->si_signo, newsiginfo->si_pid); } @@ -270,7 +270,7 @@ Bool waitstopped (pid_t pid, int signal_expected, const char *msg) res = ptrace (PT_CONTINUE, pid, (caddr_t)1, signal_received); } if (res != 0) { - ERROR(errno, "waitstopped PTRACE_CONT\n"); + ERROR(errno, "waitstopped PTRACE_CONTINUE\n"); return False; } } @@ -392,7 +392,7 @@ void restore_and_detach (pid_t pid) if (signal_queue_sz > 0) { int i; for (i = 0; i < signal_queue_sz; i++) { - DEBUG(1, "PTRACE_CONT to transmit queued signal %d\n", + DEBUG(1, "PTRACE_CONTINUE to transmit queued signal %d\n", signal_queue[i].si_signo); res = ptrace (PT_CONTINUE, pid_of_save_regs, (caddr_t)1, signal_queue[i].si_signo); @@ -590,7 +590,7 @@ Bool invoker_invoke_gdbserver (pid_t pid) pid_of_save_regs_continued = False; - /* We PTRACE_CONT-inue pid. + /* We PTRACE_CONTINUE pid. Either gdbserver will be invoked directly (if all threads are interruptible) or gdbserver will be called soon by the scheduler. In the first case, @@ -609,7 +609,7 @@ Bool invoker_invoke_gdbserver (pid_t pid) pid_of_save_regs_continued = True; /* Wait for SIGSTOP generated by m_gdbserver.c give_control_back_to_vgdb */ stopped = waitstopped (pid, SIGSTOP, - "waitpid status after PTRACE_CONT to invoke"); + "waitpid status after PTRACE_CONTINUE to invoke"); if (stopped) { /* Here pid has properly stopped on the break. */ pid_of_save_regs_continued = False; |
From: Paul F. <pa...@so...> - 2025-05-24 07:45:36
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=03fe737a1c583c5ec7231b5c146bcfdf7e8cb048 commit 03fe737a1c583c5ec7231b5c146bcfdf7e8cb048 Author: Paul Floyd <pj...@wa...> Date: Sat May 24 09:44:07 2025 +0200 Darwin: removing trailing ... from suppressions They don't serve any purpose Diff: --- darwin11.supp | 1 - darwin12.supp | 10 ---------- darwin13.supp | 8 -------- darwin14.supp | 10 ---------- darwin15.supp | 13 ------------- darwin16.supp | 15 --------------- darwin17.supp | 15 --------------- 7 files changed, 72 deletions(-) diff --git a/darwin11.supp b/darwin11.supp index f2fd6f58a3..7f87399763 100644 --- a/darwin11.supp +++ b/darwin11.supp @@ -72,7 +72,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } ################ diff --git a/darwin12.supp b/darwin12.supp index d83982498c..c3f47c15b9 100644 --- a/darwin12.supp +++ b/darwin12.supp @@ -357,7 +357,6 @@ fun:malloc_zone_?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -367,7 +366,6 @@ fun:?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -378,7 +376,6 @@ ... fun:map_images_nolock fun:map_images - ... } { @@ -389,7 +386,6 @@ ... fun:map_images_nolock fun:map_images - ... } { @@ -399,7 +395,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -409,7 +404,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -419,7 +413,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -429,7 +422,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -439,7 +431,6 @@ fun:?alloc ... fun:_libxpc_initializer - ... } { @@ -449,7 +440,6 @@ fun:malloc fun:realloc fun:new_sem_from_pool - ... } ##----------------------------------------------------------------------## diff --git a/darwin13.supp b/darwin13.supp index 6ef99e91c7..41478738f7 100644 --- a/darwin13.supp +++ b/darwin13.supp @@ -31,7 +31,6 @@ fun:_objc_init fun:_os_object_init fun:libSystem_initializer - ... } { @@ -41,7 +40,6 @@ fun:malloc_zone_?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -51,7 +49,6 @@ fun:?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -62,7 +59,6 @@ ... fun:map_images_nolock fun:map_images - ... } { @@ -73,7 +69,6 @@ ... fun:map_images_nolock fun:map_images - ... } { @@ -83,7 +78,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -93,7 +87,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -103,7 +96,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { diff --git a/darwin14.supp b/darwin14.supp index 63fe2b4e67..8ba4e9d71e 100644 --- a/darwin14.supp +++ b/darwin14.supp @@ -32,7 +32,6 @@ fun:_os_object_init fun:libdispatch_init fun:libSystem_initializer - ... } #{ @@ -52,7 +51,6 @@ fun:?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -63,7 +61,6 @@ ... fun:map_images_nolock fun:map_images - ... } { @@ -74,7 +71,6 @@ ... fun:map_images_nolock fun:map_images - ... } { @@ -84,7 +80,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -94,7 +89,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -104,7 +98,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } #{ @@ -131,7 +124,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } { @@ -141,7 +133,6 @@ fun:?alloc ... fun:libSystem_atfork_child - ... } { @@ -152,7 +143,6 @@ fun:__smakebuf ... fun:printf - ... } ############################################ diff --git a/darwin15.supp b/darwin15.supp index a383d24b68..159e7f66c9 100644 --- a/darwin15.supp +++ b/darwin15.supp @@ -32,7 +32,6 @@ fun:_os_object_init fun:libdispatch_init fun:libSystem_initializer - ... } { @@ -41,7 +40,6 @@ fun:malloc_zone_?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -51,7 +49,6 @@ fun:?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -62,7 +59,6 @@ ... fun:map_images_nolock fun:map_2_images - ... } { @@ -73,7 +69,6 @@ ... fun:map_images_nolock fun:map_2_images - ... } { @@ -83,7 +78,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -93,7 +87,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -103,7 +96,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } #{ @@ -130,7 +122,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } { @@ -140,7 +131,6 @@ fun:?alloc ... fun:libSystem_atfork_child - ... } { @@ -151,7 +141,6 @@ fun:__smakebuf ... fun:printf - ... } { @@ -198,7 +187,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -208,7 +196,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } diff --git a/darwin16.supp b/darwin16.supp index 18dda6a703..ae31a97a9e 100644 --- a/darwin16.supp +++ b/darwin16.supp @@ -32,7 +32,6 @@ fun:_os_object_init fun:libdispatch_init fun:libSystem_initializer - ... } { @@ -41,7 +40,6 @@ fun:malloc_zone_?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -51,7 +49,6 @@ fun:?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -62,7 +59,6 @@ ... fun:map_images_nolock fun:map_2_images - ... } { @@ -73,7 +69,6 @@ ... fun:map_images_nolock fun:map_2_images - ... } { @@ -83,7 +78,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -93,7 +87,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -103,7 +96,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } #{ @@ -130,7 +122,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } { @@ -140,7 +131,6 @@ fun:?alloc ... fun:libSystem_atfork_child - ... } { @@ -151,7 +141,6 @@ fun:__smakebuf ... fun:printf - ... } { @@ -198,7 +187,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -208,7 +196,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } @@ -529,7 +516,6 @@ Memcheck:Cond fun:bcmp fun:_ZN16ImageLoaderMachO18validateFirstPagesEPK21linkedit_data_commandiPKhmxRKN11ImageLoader11LinkContextE - ... } { @@ -537,7 +523,6 @@ Memcheck:Value8 fun:bcmp fun:_ZN16ImageLoaderMachO18validateFirstPagesEPK21linkedit_data_commandiPKhmxRKN11ImageLoader11LinkContextE - ... } { diff --git a/darwin17.supp b/darwin17.supp index e58b494222..996688654f 100644 --- a/darwin17.supp +++ b/darwin17.supp @@ -32,7 +32,6 @@ fun:_os_object_init fun:libdispatch_init fun:libSystem_initializer - ... } { @@ -41,7 +40,6 @@ fun:malloc_zone_?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -51,7 +49,6 @@ fun:?alloc ... fun:dyld_register_image_state_change_handler - ... } { @@ -62,7 +59,6 @@ ... fun:map_images_nolock fun:map_2_images - ... } { @@ -73,7 +69,6 @@ ... fun:map_images_nolock fun:map_2_images - ... } { @@ -83,7 +78,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -93,7 +87,6 @@ fun:malloc_zone_?alloc ... fun:libSystem_initializer - ... } { @@ -103,7 +96,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } #{ @@ -130,7 +122,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } { @@ -140,7 +131,6 @@ fun:?alloc ... fun:libSystem_atfork_child - ... } { @@ -151,7 +141,6 @@ fun:__smakebuf ... fun:printf - ... } { @@ -198,7 +187,6 @@ fun:?alloc ... fun:libSystem_initializer - ... } { @@ -208,7 +196,6 @@ fun:malloc_zone_memalign ... fun:_ZN4dyld24initializeMainExecutableEv - ... } @@ -529,7 +516,6 @@ Memcheck:Cond fun:bcmp fun:_ZN16ImageLoaderMachO18validateFirstPagesEPK21linkedit_data_commandiPKhmxRKN11ImageLoader11LinkContextE - ... } { @@ -537,7 +523,6 @@ Memcheck:Value8 fun:bcmp fun:_ZN16ImageLoaderMachO18validateFirstPagesEPK21linkedit_data_commandiPKhmxRKN11ImageLoader11LinkContextE - ... } { |
From: Paul F. <pa...@so...> - 2025-05-24 06:41:56
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=432ba029f77a63a27c46d51a28c5f359176cebb8 commit 432ba029f77a63a27c46d51a28c5f359176cebb8 Author: Paul Floyd <pj...@wa...> Date: Sat May 24 08:39:40 2025 +0200 README_DEVELOPERS: add some platform specific notres for running regtest Diff: --- README_DEVELOPERS | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/README_DEVELOPERS b/README_DEVELOPERS index 0be02b7dae..4444a17500 100644 --- a/README_DEVELOPERS +++ b/README_DEVELOPERS @@ -70,6 +70,44 @@ are also created, for emulating automake-style testsuites, as expected by tools such as bunsen.) +Platform-specific setup for regression tests +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +On some platforms some setup is required otherwise some of the tests +will fail. + +Inherited inotifier file descriptors +------------------------------------ +Seen on openSUSE amd64 KDE, all processes seem to inherit an inotify +file descriptor which interferes with some of the fdleak tests in the +none directory. Here is an example + +lsof | grep inotify | grep bash +bash 13128 paulf 31r a_inode 0,14 0 46 inotify + +I don't know how to turn this off completely. You can close the +file descriptor for the current shell by using + +MY_INOTIFIER=$(lsof 2>&1 | grep $$ | grep inotify | awk '{print $4}' | sed 's/r//') + +if [ -n ${MY_INOTIFIER} ] ; then + exec {MY_INOTIFIER}<&- +fi + +FreeBSD kernel modules and stack guard page +------------------------------------------- +The sctp and mqueuefs kernel modules need to be loaded. As root + +kldload sctp mqueuefs + +Additionally FreeBSD has strange belt and braces thread stack protection +with both the kernel and the allocated thread stack providing guard pages. +This interferes with the memcheck descr_belowsp test. The extra kernel +guard page can be turned off with the following command run as root + +sysctl security.bsd.stack_guard_page=0 + + Running the performance tests ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To build and run all the performance tests, run "make [--quiet] perf". |
From: Paul F. <pa...@so...> - 2025-05-22 19:39:15
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=bcb1146c7d889083a8040941590b2a21f40f8b18 commit bcb1146c7d889083a8040941590b2a21f40f8b18 Author: Paul Floyd <pj...@wa...> Date: Thu May 22 21:38:20 2025 +0200 regtest: update none cmdline expecteds for non-linux Diff: --- none/tests/cmdline1.stdout.exp-non-linux | 2 +- none/tests/cmdline2.stdout.exp-non-linux | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/none/tests/cmdline1.stdout.exp-non-linux b/none/tests/cmdline1.stdout.exp-non-linux index d36db3976e..4049d5ab2f 100644 --- a/none/tests/cmdline1.stdout.exp-non-linux +++ b/none/tests/cmdline1.stdout.exp-non-linux @@ -30,7 +30,7 @@ usage: valgrind [options] prog-and-args startup exit abexit valgrindabexit all none --track-fds=no|yes|all track open file descriptors? [no] all includes reporting inherited file descriptors - --modify-fds=no|high modify newly open file descriptors? [no] + --modify-fds=no|yes|high modify newly open file descriptors? [no] --time-stamp=no|yes add timestamps to log messages? [no] --log-fd=<number> log messages to file descriptor [2=stderr] --log-file=<file> log messages to <file> diff --git a/none/tests/cmdline2.stdout.exp-non-linux b/none/tests/cmdline2.stdout.exp-non-linux index 5a44b3bfac..d709ea365d 100644 --- a/none/tests/cmdline2.stdout.exp-non-linux +++ b/none/tests/cmdline2.stdout.exp-non-linux @@ -30,7 +30,7 @@ usage: valgrind [options] prog-and-args startup exit abexit valgrindabexit all none --track-fds=no|yes|all track open file descriptors? [no] all includes reporting inherited file descriptors - --modify-fds=no|high modify newly open file descriptors? [no] + --modify-fds=no|yes|high modify newly open file descriptors? [no] --time-stamp=no|yes add timestamps to log messages? [no] --log-fd=<number> log messages to file descriptor [2=stderr] --log-file=<file> log messages to <file> |