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
(96) |
Sep
(151) |
Oct
(74) |
Nov
|
Dec
|
From: Martin C. <mc...@so...> - 2025-10-10 07:21:55
|
https://sourceware.org/cgit/valgrind/commit/?id=a04974ddcb51fbb24b1e44b1f9c98d0a11356cca commit a04974ddcb51fbb24b1e44b1f9c98d0a11356cca Author: Martin Cermak <mc...@re...> Date: Thu Oct 2 17:11:50 2025 +0200 Update the LTP version in valgrind testsuite to v20250930 Update the LTP version in valgrind testsuite to v20250930. All patches from auxprogs/ltp-patches were accepted by LTP upstream and included in the release, so these can now be dropped locally. https://bugs.kde.org/show_bug.cgi?id=510169 Diff: --- NEWS | 1 + auxprogs/Makefile.am | 9 +-- ...2-bit-powerpc-syscall-defs-don-t-leak-to-.patch | 41 ------------ .../0002-Introduce-LTP_QUIET-env-var.patch | 73 ---------------------- ...-sure-the-scanf-address-format-is-at-leas.patch | 39 ------------ 5 files changed, 4 insertions(+), 159 deletions(-) diff --git a/NEWS b/NEWS index 7335f05b33..ca3f9fca4a 100644 --- a/NEWS +++ b/NEWS @@ -147,6 +147,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 509567 unhandled amd64-linux syscall: 443 (quotactl_fd) 509642 Add missing ppc64-linux syswraps 509643 Add missing s390x-linux syswraps +510169 Update the LTP version in valgrind testsuite to 20250930 To see details of a given bug, visit https://bugs.kde.org/show_bug.cgi?id=XXXXXX diff --git a/auxprogs/Makefile.am b/auxprogs/Makefile.am index 0ce348ef54..d96e7fd0a9 100644 --- a/auxprogs/Makefile.am +++ b/auxprogs/Makefile.am @@ -20,10 +20,7 @@ LTP_FILTERS = \ filters/prctl10 \ filters/select03 -LTP_PATCHES = \ - ltp-patches/0001-Make-sure-32-bit-powerpc-syscall-defs-don-t-leak-to-.patch \ - ltp-patches/0002-Introduce-LTP_QUIET-env-var.patch \ - ltp-patches/0003-mmap04-Make-sure-the-scanf-address-format-is-at-leas.patch +LTP_PATCHES = EXTRA_DIST = \ docs/valgrind-listener-manpage.xml \ @@ -173,8 +170,8 @@ endif endif # Linux Test Project -LTP_VERSION=20250530 -LTP_SHA256_SUM=27586ba78eac1e40cd422add2842f1ad70f09fea55da3bd6a25e10feb786d4f2 +LTP_VERSION=20250930 +LTP_SHA256_SUM=048fa4d69ddbe8a94aa15da9bdc85713ab07a0abbc3de2b8bdd9757644aef1e4 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/ltp-patches/0001-Make-sure-32-bit-powerpc-syscall-defs-don-t-leak-to-.patch b/auxprogs/ltp-patches/0001-Make-sure-32-bit-powerpc-syscall-defs-don-t-leak-to-.patch deleted file mode 100644 index bd1fb1dd63..0000000000 --- a/auxprogs/ltp-patches/0001-Make-sure-32-bit-powerpc-syscall-defs-don-t-leak-to-.patch +++ /dev/null @@ -1,41 +0,0 @@ -From a90b2aac69028bd6b9e0fcc1e36760639b937b99 Mon Sep 17 00:00:00 2001 -From: Martin Cermak <mc...@re...> -Date: Mon, 4 Aug 2025 21:46:52 +0200 -Subject: [PATCH] Make sure 32-bit powerpc syscall defs don't leak to 64-bit - powerpc systems - -generate_syscalls.sh generates the syscalls.h header at the configure -time. At the moment, that header has a set of 32-bit syscalls defined -with the __powerpc__ gate, plus another set of 64-bit syscalls defined -with the __powerpc64__ gate. For 32-bit powerpc systems that's fine. -But for a 64-bit powerpc system this means that both sets of syscalls -become defined, which isn't right. - -Thing is that on a 64-bit powerpc system, both __powerpc__ and -__powerpc64__ are defined compiler macros, while on a 32-bit powerpc -system, only the former is defined while the latter is not. - -That said, the correct gate for a 32-bit only powerpc code is: - #if defined(__powerpc__) && !defined(__powerpc64__) - -Without this patch, e.g. __NR_clock_gettime64 def leaks to -64-bit powerpc systems, which is wrong. This patch fixes it. ---- - include/lapi/syscalls/generate_syscalls.sh | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/include/lapi/syscalls/generate_syscalls.sh b/include/lapi/syscalls/generate_syscalls.sh -index b17c72ddf..19f280dfb 100755 ---- a/include/lapi/syscalls/generate_syscalls.sh -+++ b/include/lapi/syscalls/generate_syscalls.sh -@@ -78,6 +78,7 @@ while IFS= read -r arch; do - parisc) echo "#ifdef __hppa__" ;; - loongarch64) echo "#ifdef __loongarch__" ;; - arm64) echo "#ifdef __aarch64__" ;; -+ powerpc) echo "#if defined(__powerpc__) && !defined(__powerpc64__)" ;; - *) echo "#ifdef __${arch}__" ;; - esac - --- -2.48.1 - diff --git a/auxprogs/ltp-patches/0002-Introduce-LTP_QUIET-env-var.patch b/auxprogs/ltp-patches/0002-Introduce-LTP_QUIET-env-var.patch deleted file mode 100644 index a77162bfca..0000000000 --- a/auxprogs/ltp-patches/0002-Introduce-LTP_QUIET-env-var.patch +++ /dev/null @@ -1,73 +0,0 @@ -From 183df3240f8e7ca38fbe2fd472c31c9417ae7eb2 Mon Sep 17 00:00:00 2001 -From: Martin Cermak <mc...@re...> -Date: Tue, 16 Sep 2025 15:46:40 +0200 -Subject: [PATCH] Introduce LTP_QUIET env var - -Introduce LTP_QUIET env variable. When set to 1 or y, it will -suppress printing TCONF, TWARN, TINFO, and TDEBUG messages. ---- - lib/tst_test.c | 11 +++++++++++ - 1 file changed, 11 insertions(+) - -diff --git a/lib/tst_test.c b/lib/tst_test.c -index 92872cc89..609a7b075 100644 ---- a/lib/tst_test.c -+++ b/lib/tst_test.c -@@ -68,6 +68,7 @@ static int iterations = 1; - static float duration = -1; - static float timeout_mul = -1; - static int reproducible_output; -+static int quiet_output; - - struct context { - int32_t lib_pid; -@@ -307,15 +308,19 @@ static void print_result(const char *file, const int lineno, int ttype, - res = "TBROK"; - break; - case TCONF: -+ if (quiet_output) return; - res = "TCONF"; - break; - case TWARN: -+ if (quiet_output) return; - res = "TWARN"; - break; - case TINFO: -+ if (quiet_output) return; - res = "TINFO"; - break; - case TDEBUG: -+ if (quiet_output) return; - res = "TDEBUG"; - break; - default: -@@ -670,6 +675,7 @@ static void print_help(void) - fprintf(stderr, "LTP_DEV_FS_TYPE Filesystem used for testing (default: %s)\n", DEFAULT_FS_TYPE); - fprintf(stderr, "LTP_ENABLE_DEBUG Print debug messages (set 1 or y)\n"); - fprintf(stderr, "LTP_REPRODUCIBLE_OUTPUT Values 1 or y discard the actual content of the messages printed by the test\n"); -+ fprintf(stderr, "LTP_QUIET Values 1 or y will suppress printing TCONF, TWARN, TINFO, and TDEBUG messages\n"); - fprintf(stderr, "LTP_SINGLE_FS_TYPE Specifies filesystem instead all supported (for .all_filesystems)\n"); - fprintf(stderr, "LTP_FORCE_SINGLE_FS_TYPE Testing only. The same as LTP_SINGLE_FS_TYPE but ignores test skiplist.\n"); - fprintf(stderr, "LTP_TIMEOUT_MUL Timeout multiplier (must be a number >=1)\n"); -@@ -1361,6 +1367,7 @@ static void do_setup(int argc, char *argv[]) - { - char *tdebug_env = getenv("LTP_ENABLE_DEBUG"); - char *reproducible_env = getenv("LTP_REPRODUCIBLE_OUTPUT"); -+ char *quiet_env = getenv("LTP_QUIET"); - - if (!tst_test) - tst_brk(TBROK, "No tests to run"); -@@ -1391,6 +1398,10 @@ static void do_setup(int argc, char *argv[]) - (!strcmp(reproducible_env, "1") || !strcmp(reproducible_env, "y"))) - reproducible_output = 1; - -+ if (quiet_env && -+ (!strcmp(quiet_env, "1") || !strcmp(quiet_env, "y"))) -+ quiet_output = 1; -+ - assert_test_fn(); - - TCID = tcid = get_tcid(argv); --- -2.48.1 - diff --git a/auxprogs/ltp-patches/0003-mmap04-Make-sure-the-scanf-address-format-is-at-leas.patch b/auxprogs/ltp-patches/0003-mmap04-Make-sure-the-scanf-address-format-is-at-leas.patch deleted file mode 100644 index 7956999b33..0000000000 --- a/auxprogs/ltp-patches/0003-mmap04-Make-sure-the-scanf-address-format-is-at-leas.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 6c3a6a6f625b58e8dc611cc12bc6015dc8dd5b32 Mon Sep 17 00:00:00 2001 -From: Mark Wielaard <ma...@kl...> -Date: Thu, 18 Sep 2025 17:16:05 +0200 -Subject: [PATCH] mmap04: Make sure the scanf address format is at least 8 hex - chars - -The addresses in /proc/self/maps are at least 8 hex chars. Zeros are -added to the front of the address when shorter (both on 32bit and -64bit systems). - -Under valgrind the mmaps used in kernel/syscalls/mmap/mmap04.c come -out very low in the address space and might be shorter than 8 hex -chars. This causes the scanf to fail: -mmap04.c:62: TBROK: Expected 1 conversions got 0 FILE '/proc/self/maps' - -Fix this by using "%08" PRIxPTR when creating the fmt used. - -Signed-off-by: Mark Wielaard <ma...@kl...> ---- - testcases/kernel/syscalls/mmap/mmap04.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/testcases/kernel/syscalls/mmap/mmap04.c b/testcases/kernel/syscalls/mmap/mmap04.c -index 4a050b7b50da..5b28180df29b 100644 ---- a/testcases/kernel/syscalls/mmap/mmap04.c -+++ b/testcases/kernel/syscalls/mmap/mmap04.c -@@ -58,7 +58,8 @@ static void run(unsigned int i) - - addr2 = SAFE_MMAP(addr1 + pagesize, pagesize, tc->prot, tc->flags | MAP_FIXED, -1, 0); - -- sprintf(fmt, "%" PRIxPTR "-%%*x %%s", (uintptr_t)addr2); -+ /* A /proc/self/maps address is at least 8 hex (left zero padded) */ -+ sprintf(fmt, "%08" PRIxPTR "-%%*x %%s", (uintptr_t)addr2); - SAFE_FILE_LINES_SCANF("/proc/self/maps", fmt, perms); - - if (!strcmp(perms, tc->exp_perms)) { --- -2.51.0 - |
From: Mark W. <ma...@kl...> - 2025-10-09 20:03:17
|
Hi Valgrind hackers, Normally we do a major releases in April and October. We did do a minor 3.25.1 release in May. And the VALGRIND_3_25_BRANCH does contain a couple more backported fixes. But the main branch has 350+ more commits so it is time to prepare for a new major release. I am proposing to do a release on Friday October 24. With an RC1 a week before, Friday October 17. And possibly an RC2 in between if we find some big issue for which we like more testing. There are a couple of things I like to add before RC1: - Update to GPLv3+. We discussed this on the list and then with some core developers asking for advice from the FSF Legal and Compliance team. I'll post a patch tomorrow with the full rational, so we can discuss it before applying for RC1. - Don't warn about fcntl F_GETFD with --track-fds https://bugs.kde.org/show_bug.cgi?id=510436 --track-fds=bad is great, but Paul correctly pointed out that there has to be a way for an application to explicitly check for bad fds that doesn't generate an error. - Removing glibc extra syscall frames might crash https://bugs.kde.org/show_bug.cgi?id=507188 This seems to only happen on i386 debian, but it a generic issue with syscall frame filtering. And if I have time I also like to finish the removal of artificial frames from the backtraces. There is already support for tracking these artificial frams since commit f7dccaab11b8 "Rewrite DWARF inlined subroutine handling to work cross CU". But they aren't yet filtered. - On Fedora 43 (beta) for amd64 we get some make regtest failures I haven't really investigated yet, but on f42 we get zero failures, so it would be nice to see what updates caused the new failures. Please let me know what you believe are blockers for the release or fixes you really would like to see in. Thanks, Mark |
From: Andreas A. <ar...@so...> - 2025-10-09 11:49:37
|
https://sourceware.org/cgit/valgrind/commit/?id=32fcdbfafd623569df800d2a1fa351c11f10a128 commit 32fcdbfafd623569df800d2a1fa351c11f10a128 Author: Andreas Arnez <ar...@li...> Date: Thu Oct 9 13:42:39 2025 +0200 s390x: Make IBM z17 known to Valgrind Make the IBM z17 machine model 9175 known to Valgrind. Also add the expected output of the s390x-specific "ecag" test case on an IBM z17, so the test case succeeds on that system. Diff: --- VEX/pub/libvex.h | 3 ++- coregrind/m_machine.c | 1 + none/tests/s390x/Makefile.am | 2 +- none/tests/s390x/ecag.stdout.exp-z17 | 21 +++++++++++++++++++++ tests/s390x_features.c | 1 + 5 files changed, 26 insertions(+), 2 deletions(-) diff --git a/VEX/pub/libvex.h b/VEX/pub/libvex.h index e580160d30..bfa94d033f 100644 --- a/VEX/pub/libvex.h +++ b/VEX/pub/libvex.h @@ -158,7 +158,8 @@ typedef #define VEX_S390X_MODEL_Z14_ZR1 15 #define VEX_S390X_MODEL_Z15 16 #define VEX_S390X_MODEL_Z16 17 -#define VEX_S390X_MODEL_UNKNOWN 18 /* always last in list */ +#define VEX_S390X_MODEL_Z17 18 +#define VEX_S390X_MODEL_UNKNOWN 19 /* always last in list */ #define VEX_S390X_MODEL_MASK 0x3F #define VEX_HWCAPS_S390X_LDISP (1<<6) /* Long-displacement facility */ diff --git a/coregrind/m_machine.c b/coregrind/m_machine.c index eaa18b0b61..bba498f989 100644 --- a/coregrind/m_machine.c +++ b/coregrind/m_machine.c @@ -624,6 +624,7 @@ static UInt VG_(get_machine_model)(void) { "8562", VEX_S390X_MODEL_Z15 }, { "3931", VEX_S390X_MODEL_Z16 }, { "3932", VEX_S390X_MODEL_Z16 }, + { "9175", VEX_S390X_MODEL_Z17 }, }; Int model, n, fh; diff --git a/none/tests/s390x/Makefile.am b/none/tests/s390x/Makefile.am index 22b8128bba..dda923acc6 100644 --- a/none/tests/s390x/Makefile.am +++ b/none/tests/s390x/Makefile.am @@ -48,7 +48,7 @@ EXTRA_DIST = \ bfp-XxC.vgtest bfp-XxC.stderr.exp bfp-XxC.post.exp \ ecag.stdout.exp-z10ec ecag.stdout.exp-z196 ecag.stdout.exp-zec12 \ ecag.stdout.exp-z13 ecag.stdout.exp-z14 ecag.stdout.exp-z15 \ - ecag.stdout.exp-z16 \ + ecag.stdout.exp-z16 ecag.stdout.exp-z17 \ op00.stderr.exp op00.vgtest \ dfp-XxC.vgtest dfp-XxC.stderr.exp dfp-XxC.post.exp \ dfp-XiC.vgtest dfp-XiC.stderr.exp dfp-XiC.post.exp \ diff --git a/none/tests/s390x/ecag.stdout.exp-z17 b/none/tests/s390x/ecag.stdout.exp-z17 new file mode 100644 index 0000000000..4708b2a835 --- /dev/null +++ b/none/tests/s390x/ecag.stdout.exp-z17 @@ -0,0 +1,21 @@ +L1 topology: separate data and instruction; private +L1 cache line size data: 256 +L1 cache line size insn: 256 +L1 total cachesize data: 131072 +L1 total cachesize insn: 131072 +L1 set. assoc. data: 8 +L1 set. assoc. insn: 8 +L2 topology: unified data and instruction; private +L2 cache line size data: 256 +L2 cache line size insn: 256 +L2 total cachesize data: 37748736 +L2 total cachesize insn: 37748736 +L2 set. assoc. data: 18 +L2 set. assoc. insn: 18 +L3 topology: unified data and instruction; shared +L3 cache line size data: 256 +L3 cache line size insn: 256 +L3 total cachesize data: 377487360 +L3 total cachesize insn: 377487360 +L3 set. assoc. data: 180 +L3 set. assoc. insn: 180 diff --git a/tests/s390x_features.c b/tests/s390x_features.c index 507f3ab2f8..e0d4de76ce 100644 --- a/tests/s390x_features.c +++ b/tests/s390x_features.c @@ -120,6 +120,7 @@ model_info models[] = { { "8562", "z15" }, { "3931", "z16" }, { "3932", "z16" }, + { "9175", "z17" }, }; |
From: Florian K. <fk...@so...> - 2025-10-07 12:41:09
|
https://sourceware.org/cgit/valgrind/commit/?id=0329ab2021727242f31adfd665f602a8a6163aa8 commit 0329ab2021727242f31adfd665f602a8a6163aa8 Author: Florian Krohm <fl...@ei...> Date: Tue Oct 7 12:39:38 2025 +0000 Document that --vex-guest-chase=not ought to be used when doing IR injection. Fixes https://bugs.kde.org/show_bug.cgi?id=506453 Diff: --- NEWS | 1 + VEX/priv/ir_inject.c | 4 ++++ memcheck/tests/vbit-test/vbit-test-sec.vgtest | 2 +- memcheck/tests/vbit-test/vbit-test.vgtest | 2 +- 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index bdf175eac8..7335f05b33 100644 --- a/NEWS +++ b/NEWS @@ -987,6 +987,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 451843 valgrind fails to start on a FreeBSD system which enforces W^X 495483 Control building documentation via BUILD_DOCS 506211 Constant folding improvements +506453 Unexpected behaviour with IR injection and vex-guest-chase=yes 509157 riscv64: Shift instructions can behave wrong To see details of a given bug, visit diff --git a/VEX/priv/ir_inject.c b/VEX/priv/ir_inject.c index 04228538f1..b447f6e946 100644 --- a/VEX/priv/ir_inject.c +++ b/VEX/priv/ir_inject.c @@ -27,6 +27,10 @@ The GNU General Public License is contained in the file COPYING. */ +/* !!! When running valgrind on applications that use IR injection + !!! --vex-guest-chase=no should be given on the command line. This + !!! avoids that vex_inject_ir is called speculatively. +*/ #include "libvex_basictypes.h" #include "libvex_ir.h" #include "libvex.h" diff --git a/memcheck/tests/vbit-test/vbit-test-sec.vgtest b/memcheck/tests/vbit-test/vbit-test-sec.vgtest index 2d3c9389da..8d84e7e90b 100644 --- a/memcheck/tests/vbit-test/vbit-test-sec.vgtest +++ b/memcheck/tests/vbit-test/vbit-test-sec.vgtest @@ -1,3 +1,3 @@ prog: vbit-test-sec prereq: test -x vbit-test-sec -vgopts: -q --expensive-definedness-checks=yes +vgopts: -q --expensive-definedness-checks=yes --vex-guest-chase=no diff --git a/memcheck/tests/vbit-test/vbit-test.vgtest b/memcheck/tests/vbit-test/vbit-test.vgtest index a05890566b..198c62351c 100644 --- a/memcheck/tests/vbit-test/vbit-test.vgtest +++ b/memcheck/tests/vbit-test/vbit-test.vgtest @@ -1,2 +1,2 @@ prog: vbit-test -vgopts: -q --expensive-definedness-checks=yes +vgopts: -q --expensive-definedness-checks=yes --vex-guest-chase=no |
From: Paul F. <pa...@so...> - 2025-10-06 07:01:52
|
https://sourceware.org/cgit/valgrind/commit/?id=e55d0db975c69f0f4c0feae78d64fc8a7196351f commit e55d0db975c69f0f4c0feae78d64fc8a7196351f Author: Paul Floyd <pj...@wa...> Date: Sun Sep 28 03:39:45 2025 +0000 FreeBSD regtest: update setcred expected from arm64 Still have an unexpected extra error on amd64 Diff: --- memcheck/tests/freebsd/setcred.stderr.exp | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/memcheck/tests/freebsd/setcred.stderr.exp b/memcheck/tests/freebsd/setcred.stderr.exp index 629ceacf84..8766361c09 100644 --- a/memcheck/tests/freebsd/setcred.stderr.exp +++ b/memcheck/tests/freebsd/setcred.stderr.exp @@ -1,29 +1,37 @@ Syscall param setcred(wcred) points to unaddressable byte(s) at 0x........: setcred (in /...libc...) - by 0x........: main (setcred.cpp:23) + by 0x........: main (setcred.cpp:28) Address 0x........ is not stack'd, malloc'd or (recently) free'd Syscall param setcred(flags) contains uninitialised byte(s) at 0x........: setcred (in /...libc...) - by 0x........: main (setcred.cpp:26) + by 0x........: main (setcred.cpp:33) Syscall param setcred(wcred) contains uninitialised byte(s) at 0x........: setcred (in /...libc...) - by 0x........: main (setcred.cpp:26) + by 0x........: main (setcred.cpp:33) Syscall param setcred(size) contains uninitialised byte(s) at 0x........: setcred (in /...libc...) - by 0x........: main (setcred.cpp:26) + by 0x........: main (setcred.cpp:33) Syscall param setcred(wcred) points to unaddressable byte(s) at 0x........: setcred (in /...libc...) - by 0x........: main (setcred.cpp:26) + by 0x........: main (setcred.cpp:33) Address 0x........ is not stack'd, malloc'd or (recently) free'd +Syscall param setcred(flags) contains uninitialised byte(s) + at 0x........: setcred (in /...libc...) + by 0x........: main (setcred.cpp:38) + +Syscall param setcred(size) contains uninitialised byte(s) + at 0x........: setcred (in /...libc...) + by 0x........: main (setcred.cpp:43) + Syscall param setcred(wcred) points to uninitialised byte(s) at 0x........: setcred (in /...libc...) - by 0x........: main (setcred.cpp:31) + by 0x........: main (setcred.cpp:50) Address 0x........ is 0 bytes inside a block of size 48 alloc'd at 0x........: ...operator new... (vg_replace_malloc.c:...) - by 0x........: main (setcred.cpp:28) + by 0x........: main (setcred.cpp:47) |
From: Paul F. <pa...@so...> - 2025-10-06 06:56:55
|
https://sourceware.org/cgit/valgrind/commit/?id=ea1ec47ce1a8f29bf01412869b6a07e5ee6a2976 commit ea1ec47ce1a8f29bf01412869b6a07e5ee6a2976 Author: Paul Floyd <pj...@wa...> Date: Mon Oct 6 10:55:34 2025 +0200 FreeBSD setcred syscall: use arg3 for size Not really our job to check that thwe size is right. Also revamp the secred testcase. Diff: --- coregrind/m_syswrap/syswrap-freebsd.c | 2 +- memcheck/tests/freebsd/setcred.cpp | 33 +++++++++++++++++++++++++++------ 2 files changed, 28 insertions(+), 7 deletions(-) diff --git a/coregrind/m_syswrap/syswrap-freebsd.c b/coregrind/m_syswrap/syswrap-freebsd.c index eb8a160586..2c3bffa1c2 100644 --- a/coregrind/m_syswrap/syswrap-freebsd.c +++ b/coregrind/m_syswrap/syswrap-freebsd.c @@ -7154,7 +7154,7 @@ PRE(sys_setcred) { PRINT("sys_setcred(%" FMT_REGWORD "u, %#" FMT_REGWORD "x, %" FMT_REGWORD "u)", ARG1, ARG2, ARG3); PRE_REG_READ3(int, "setcred", u_int, flags, const struct setcred*, wcred, size_t, size); - PRE_MEM_READ("setcred(wcred)", ARG2, sizeof(struct vki_setcred)); + PRE_MEM_READ("setcred(wcred)", ARG2, ARG3); } // SYS_exterrctl 592 diff --git a/memcheck/tests/freebsd/setcred.cpp b/memcheck/tests/freebsd/setcred.cpp index 464de08efe..619d1959f1 100644 --- a/memcheck/tests/freebsd/setcred.cpp +++ b/memcheck/tests/freebsd/setcred.cpp @@ -1,6 +1,8 @@ #include <sys/ucred.h> #include <cstring> #include <cstdlib> +#include <cerrno> +#include <cassert> static long x0; @@ -10,25 +12,44 @@ int main() x0 = px[0]; struct setcred cred1; struct setcred* cred2; - int flags1{0}; - int flags2; + int flags1{SETCREDF_RUID}; + int flags2{SETCREDF_SUPP_GROUPS}; size_t size1{sizeof(cred1)}; + int ret; std::memset(&cred1, 250, sizeof(cred1)); // needs to be root to work correctly - setcred(flags1, &cred1, size1); + ret = setcred(flags1, &cred1, size1); + assert(ret == -1); + assert(errno == EPERM); // not accessible - setcred(flags1, nullptr, size1); + ret = setcred(flags1, nullptr, size1); + assert(ret == -1); + assert(errno == EFAULT); // uninit - setcred(flags2, (struct setcred*)x0, size1+x0); + ret = setcred(flags2+x0, (struct setcred*)x0, size1+x0); + assert(ret == -1); + assert(errno == EFAULT); + + // invalid flags + ret = setcred(9999+x0, &cred1, sizeof(cred1)); + assert(ret == -1); + assert(errno == EINVAL); + + // invalid size + ret = setcred(flags1, &cred1, 3+x0); + assert(ret == -1); + assert(errno == EINVAL); cred2 = new struct setcred; // uninit memory - setcred(flags1, cred2, size1); + ret = setcred(flags1, cred2, size1); + assert(ret == -1); + assert(errno == EPERM); delete cred2; free(px); |
From: Paul F. <pa...@so...> - 2025-10-06 05:32:25
|
https://sourceware.org/cgit/valgrind/commit/?id=c6092d4230fd2533374555213632e77b95a33a5d commit c6092d4230fd2533374555213632e77b95a33a5d Author: Paul Floyd <pj...@wa...> Date: Sun Sep 28 02:11:58 2025 +0000 FreeBSD vgdb: ensure stack is 16byte aligned for invoker I haven't seen any issues but there's no harm in being certain. Diff: --- coregrind/vgdb-invoker-freebsd.c | 1 + 1 file changed, 1 insertion(+) diff --git a/coregrind/vgdb-invoker-freebsd.c b/coregrind/vgdb-invoker-freebsd.c index 607e059919..4a89fb37dd 100644 --- a/coregrind/vgdb-invoker-freebsd.c +++ b/coregrind/vgdb-invoker-freebsd.c @@ -561,6 +561,7 @@ Bool invoker_invoke_gdbserver (pid_t pid) reg_mod.r_rip = shared64->invoke_gdbserver; #elif defined(VGA_arm64) reg_mod.x[0] = check; + sp &= ~0xf; // keep the stack aligned on 16 bytes ... reg_mod.sp = sp; reg_mod.elr = shared64->invoke_gdbserver; /* put NULL return address in Link Register */ |
From: Paul F. <pa...@so...> - 2025-10-03 18:58:34
|
https://sourceware.org/cgit/valgrind/commit/?id=3bcda36cf8f02c87ff900a0e06984b7e46a34e4f commit 3bcda36cf8f02c87ff900a0e06984b7e46a34e4f Author: Paul Floyd <pj...@wa...> Date: Fri Oct 3 20:54:15 2025 +0200 getdents* syswrap: only check proc fd/fdinfo on Linux and Solaris Keep check for __NR_getdents and use a check for __NR_getdents64 Diff: --- coregrind/m_syswrap/syswrap-generic.c | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/coregrind/m_syswrap/syswrap-generic.c b/coregrind/m_syswrap/syswrap-generic.c index 296ebdd910..0d13cea5e9 100644 --- a/coregrind/m_syswrap/syswrap-generic.c +++ b/coregrind/m_syswrap/syswrap-generic.c @@ -3994,7 +3994,7 @@ PRE(sys_getdents) PRE_MEM_WRITE( "getdents(dirp)", ARG2, ARG3 ); } -#if !defined(VGO_freebsd) // Darwin as well? +#if defined(VGO_linux) || defined(VGO_solaris) /* Check if the given file descriptor points to a /proc/PID/fd or /proc/PID/fdinfo directory. Returns True if it's a directory we should filter Valgrind FDs from. */ @@ -4049,7 +4049,7 @@ static Bool should_keep_fd_entry(const HChar *name) /* Make sure we really need the proc filtering using (32bit) getdents, which not every linux arch implements. */ -#if defined(VGO_linux) && defined(__NR_getdents) +#if defined(__NR_getdents) /* Filter and compact dirent entries */ static SizeT filter_dirent_entries(struct vki_dirent *dirp, SizeT orig_size) @@ -4073,7 +4073,7 @@ static SizeT filter_dirent_entries(struct vki_dirent *dirp, SizeT orig_size) return new_size; } -#endif /* defined(VGO_linux) && defined(__NR_getdents) */ +#endif /* defined(__NR_getdents) */ /* Filter and compact dirent64 entries */ static SizeT filter_dirent64_entries(struct vki_dirent64 *dirp, SizeT orig_size) @@ -4098,11 +4098,9 @@ static SizeT filter_dirent64_entries(struct vki_dirent64 *dirp, SizeT orig_size) return new_size; } -#endif - /* Make sure we really need the proc filtering using (32bit) getdents, which not every linux arch implements. */ -#if defined(VGO_linux) && defined(__NR_getdents) +#if defined(__NR_getdents) /* Filter out Valgrind's internal file descriptors from getdents results with refill capability. When entries are filtered out, attempts to read more entries to avoid empty results. @@ -4132,9 +4130,7 @@ static SizeT filter_valgrind_fds_from_getdents_with_refill(Int fd, struct vki_di return new_size; } -#endif /* defined(VGO_linux) && defined(__NR_getdents) */ - -#if !defined(VGO_freebsd) // Darwin as well? +#endif /* defined(__NR_getdents) */ /* Filter out Valgrind's internal file descriptors from getdents64 results with refill capability. Same logic as getdents version but for 64-bit dirent structures. @@ -4165,7 +4161,7 @@ static SizeT filter_valgrind_fds_from_getdents64_with_refill(Int fd, struct vki_ return new_size; } -#endif +#endif /* defined(VGO_linux) || defined(VGO_solaris) */ POST(sys_getdents) { @@ -4175,7 +4171,7 @@ POST(sys_getdents) /* Make sure we really need the proc filtering using (32bit) getdents, which not every linux arch implements. */ -#if defined(VGO_linux) && defined(__NR_getdents) +#if (defined(VGO_linux) || defined(VGO_solaris)) && defined(__NR_getdents) /* Only filter Valgrind FDs when listing /proc/PID/fd or /proc/PID/fdinfo directories */ if (is_proc_fd_directory(ARG1)) { @@ -4188,13 +4184,13 @@ POST(sys_getdents) if (result_size != RES) SET_STATUS_Success(result_size); } -#endif /* defined(VGO_linux) && defined(__NR_getdents) */ +#endif /* (defined(VGO_linux) || defined(VGO_solaris)) && defined(__NR_getdents) */ POST_MEM_WRITE( ARG2, result_size ); } } -#if !defined(VGO_freebsd) +#if defined(__NR_getdents64) PRE(sys_getdents64) { @@ -4229,7 +4225,7 @@ POST(sys_getdents64) } } -#endif +#endif /* defined(__NR_getdents64) */ PRE(sys_getgroups) { |
From: Florian K. <fk...@so...> - 2025-10-03 16:33:25
|
https://sourceware.org/cgit/valgrind/commit/?id=c0e022d1a8a973c4872f497b79ccb8e0a51adae9 commit c0e022d1a8a973c4872f497b79ccb8e0a51adae9 Author: Florian Krohm <fl...@ei...> Date: Fri Oct 3 16:31:59 2025 +0000 Add BZ 495483 to NEWS. Darn I keep forgetting this.... Diff: --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index e4722a7293..bdf175eac8 100644 --- a/NEWS +++ b/NEWS @@ -985,6 +985,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 451626 Syscall param bpf(attr->raw_tracepoint.name) points to unaddressable byte(s) 451827 [ppc64le] VEX temporary storage exhausted with several vbpermq instructions 451843 valgrind fails to start on a FreeBSD system which enforces W^X +495483 Control building documentation via BUILD_DOCS 506211 Constant folding improvements 509157 riscv64: Shift instructions can behave wrong |
From: Florian K. <fk...@so...> - 2025-10-03 16:29:29
|
https://sourceware.org/cgit/valgrind/commit/?id=9c0c0e41d8b72825606da0db897a419c59658a56 commit 9c0c0e41d8b72825606da0db897a419c59658a56 Author: Florian Krohm <fl...@ei...> Date: Fri Oct 3 16:26:55 2025 +0000 Control building documentation (BZ 495483) Introduce Makefile variable BUILD_DOCS with these possible values: none - does not build any documentation all - builds all documentation html - builds HTML docs but skips building PDFs BUILD_ALL_DOCS is still recognised for backward compatibility and is mapped to BUILD_DOCS like so: If not specified --> BUILD_DOCS=all BUILD_ALL_DOCS=yes --> BUILD_DOCS=all BUILD_ALL_DOCS=no --> BUILD_DOCS=html README_DEVELOPERS adjusted. Fixes https://bugs.kde.org/show_bug.cgi?id=495483 Diff: --- README_DEVELOPERS | 2 +- docs/Makefile.am | 35 ++++++++++++++++++++++++++++------- 2 files changed, 29 insertions(+), 8 deletions(-) diff --git a/README_DEVELOPERS b/README_DEVELOPERS index 22e229bd49..5d9fb823f9 100644 --- a/README_DEVELOPERS +++ b/README_DEVELOPERS @@ -37,7 +37,7 @@ will also attempt to build the documentation. If you only want to test whether the generated tarball is complete and runs regression tests successfully, building documentation is not needed. - make dist BUILD_ALL_DOCS=no + make dist BUILD_DOCS=none If you insist on building documentation some embarrassing instructions can be found in docs/README. diff --git a/docs/Makefile.am b/docs/Makefile.am index 8672e8dd21..7e5ed389c5 100644 --- a/docs/Makefile.am +++ b/docs/Makefile.am @@ -4,10 +4,26 @@ ## tools to do so is impractical / too difficult ##------------------------------------------------------------- -# Comment out the next line to skip building print docs. The default -# is not to skip building print docs. Note, after changing it -# you need to re-run autogen.sh and configure to make it take effect. -BUILD_ALL_DOCS=yes +# Building documentation is a pain. It takes longish and requires certain +# tools you may not have installed. +# The variable BUILD_DOCS allows you to control what documentation gets +# built: +# +# BUILD_DOCS=all builds all documentation +# BUILD_DOCS=html builds HTML docs but skips building PDFs +# BUILD_DOCS=none does not build any documentation +# +# Use it on the command line. E.g.: make dist BUILD_DOCS=none +# +ifndef BUILD_ALL_DOCS + BUILD_DOCS ?= all + else + ifeq "$(BUILD_ALL_DOCS)" "yes" + BUILD_DOCS ?= all + else + BUILD_DOCS ?= html + endif + endif # Whether to run xmlto pdf --with-fop # This is de fault, set to empty to use the default fo to pdf @@ -281,7 +297,7 @@ install-data-hook: cp $$f $(DESTDIR)$(mandir)/man1; \ fi \ done - ifeq ($(BUILD_ALL_DOCS),yes) + ifeq ($(BUILD_DOCS),all) set -e; \ if test -r index.pdf ; then \ mkdir -p $(DESTDIR)$(datadir)/doc/valgrind; \ @@ -297,18 +313,23 @@ install-data-hook: # This is done at 'make dist' time. It builds the html docs, print # docs and man pages and copies them into the docs/ directory in the # tarball. - ifeq ($(BUILD_ALL_DOCS),yes) + ifeq ($(BUILD_DOCS),none) +dist-hook: + + else + ifeq ($(BUILD_DOCS),all) dist-hook: FAQ.txt html-docs man-pages print-docs cp -r html $(distdir) cp FAQ.txt $(distdir)/.. cp *.1 $(distdir) cp print/index.pdf $(distdir) cp print/index.ps $(distdir) - else + else dist-hook: FAQ.txt html-docs man-pages cp -r html $(distdir) cp FAQ.txt $(distdir)/.. cp *.1 $(distdir) + endif endif distclean-local: |
From: Florian K. <fl...@ei...> - 2025-10-03 16:29:17
|
Hi Mark, thanks for taking the time. On 02.10.25 22:53, Mark Wielaard wrote: > > That looks nice (I do have a wording nitpick, but feel free to ignore > if you feel no-print is more clear than html). Agreed. > I wouldn't integrate the make dist with the post-regtest-checks > though. It wouldn't have caught the issue because it only generates > the tar ball. make distcheck would have caught it, but I think that > make distcheck should be a separate step/check (it does multiple > builds and takes a long time even with BUILD_DOCS=none). True enough. I am going to check this in with your suggested changes. Florian |
From: Paul F. <pj...@wa...> - 2025-10-03 12:00:34
|
On 10/3/25 08:36, Paul Floyd via Valgrind-developers wrote: > > > Neither FreeBSD nor macOS have dirent64/getdents64. Furthemore neither > has /proc and so they don't need any fd filtering. FreeBSD does have > freebsd11_dirent/freebsd11_getdents (which is also the kernel > interface) just to confuse matters slightly. > > I'm trying to work out what illumos and Solaris have. Certainly they > have /proc and also need fd filtering. illumos has dirent (native), > dirent32 (x86) and dirent64 (kernel amd64 and x86 > _LARGEFILE64_SOURCE). illumos headers have syscall numbers for > getdents and getdents64 but getdents64 seems to produce a SIGSYS. I'll > see what Solaris 11.4 does and try to work out why illumos has > getdents64 in the headers. > On Illumos, I see 3 combinations amd64 -> getdents uses syscall 81 SYS_getdents x86 -> getdents uses syscall 81 again x86 largefile -> getdents uses syscall 213 SYS_getdents64 I guess Solaris 11.4 is the same, but for amd64 only. A+ Paul |
From: Paul F. <pj...@wa...> - 2025-10-03 06:36:18
|
On 10/2/25 22:57, Mark Wielaard wrote: > Hi, > > On Thu, Oct 02, 2025 at 09:30:11AM -0700, Bart Van Assche via Valgrind-developers wrote: >> On 10/1/25 10:48 PM, Paul Floyd wrote: >>> +#if !defined(VGO_freebsd) // Darwin as well? >> Isn't adding this type of #ifdefs a software anti-pattern? Please >> consider adding a configure test for dirent64() and getdent64() and to >> test the appropriate HAVE_* macro here. > Note that the other checks for this feature use: > > #if defined(VGO_linux) && defined(__NR_getdents) > > It would be good to use the same guards everywhere. > > Were these guards placed wrongly? What was the actual build failure on > freebsd? Neither FreeBSD nor macOS have dirent64/getdents64. Furthemore neither has /proc and so they don't need any fd filtering. FreeBSD does have freebsd11_dirent/freebsd11_getdents (which is also the kernel interface) just to confuse matters slightly. I'm trying to work out what illumos and Solaris have. Certainly they have /proc and also need fd filtering. illumos has dirent (native), dirent32 (x86) and dirent64 (kernel amd64 and x86 _LARGEFILE64_SOURCE). illumos headers have syscall numbers for getdents and getdents64 but getdents64 seems to produce a SIGSYS. I'll see what Solaris 11.4 does and try to work out why illumos has getdents64 in the headers. A+ Paul |
From: Mark W. <ma...@kl...> - 2025-10-02 20:57:37
|
Hi, On Thu, Oct 02, 2025 at 09:30:11AM -0700, Bart Van Assche via Valgrind-developers wrote: > On 10/1/25 10:48 PM, Paul Floyd wrote: > >+#if !defined(VGO_freebsd) // Darwin as well? > > Isn't adding this type of #ifdefs a software anti-pattern? Please > consider adding a configure test for dirent64() and getdent64() and to > test the appropriate HAVE_* macro here. Note that the other checks for this feature use: #if defined(VGO_linux) && defined(__NR_getdents) It would be good to use the same guards everywhere. Were these guards placed wrongly? What was the actual build failure on freebsd? Thanks, Mark |
From: Mark W. <ma...@kl...> - 2025-10-02 20:53:16
|
Hi Florian, On Thu, Oct 02, 2025 at 12:26:16AM +0200, Florian Krohm wrote: > Sorry for that... I did run make post-regtest-checks but that was not good > enough. Please check out the attached patch in > https://bugs.kde.org/show_bug.cgi?id=495483 > which should help. That looks nice (I do have a wording nitpick, but feel free to ignore if you feel no-print is more clear than html). I wouldn't integrate the make dist with the post-regtest-checks though. It wouldn't have caught the issue because it only generates the tar ball. make distcheck would have caught it, but I think that make distcheck should be a separate step/check (it does multiple builds and takes a long time even with BUILD_DOCS=none). Cheers, Mark |
From: Paul F. <pj...@wa...> - 2025-10-02 19:55:40
|
On 02-10-25 16:30, Bart Van Assche via Valgrind-developers wrote: > On 10/1/25 10:48 PM, Paul Floyd wrote: >> +#if !defined(VGO_freebsd) // Darwin as well? > > Isn't adding this type of #ifdefs a software anti-pattern? Please > consider adding a configure test for dirent64() and getdent64() and to > test the appropriate HAVE_* macro here. Hi Bart For the moment I just want to be able to build on FreeBSD. This is going to take more than just checking for struct dirent64 and/or getdent64(). macOS doesn't have /proc. FreeBSD can have a /proc mounted but it's not done by default and it doesn't have any fd or fdinfo directories. So there's no point trying to filter out Valgrind's own file descriptors in these directories on those platforms. illumos is more like Linux, I'll check soon if it has getdent64 and the same or simular /proc contents. A+ Paul |
From: Alexandra H. <aha...@so...> - 2025-10-02 17:43:46
|
https://sourceware.org/cgit/valgrind/commit/?id=a08e6ed08f6b24ecf35d443b52e5db16ccb05f77 commit a08e6ed08f6b24ecf35d443b52e5db16ccb05f77 Author: Alexandra Hájková <aha...@re...> Date: Tue Sep 30 09:54:58 2025 -0400 getdents_filter.vgtest: Add filter_sort On some file systems the testfiles 1000 and 1001 come out in different order. Add filter_sort to sort the output lines to always appear at the same order. Diff: --- .gitignore | 1 + none/tests/Makefile.am | 3 ++- none/tests/filter_sort | 2 ++ none/tests/linux/getdents_filter.stdout.exp | 12 ++++++------ none/tests/linux/getdents_filter.vgtest | 1 + 5 files changed, 12 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index 645f261bcd..01dd2a3bc6 100644 --- a/.gitignore +++ b/.gitignore @@ -1916,6 +1916,7 @@ /none/tests/linux/open_client /none/tests/linux/pthread-stack /none/tests/linux/stack-overflow +/none/tests/linux/getdents_filter # /none/tests/mips32/ /none/tests/mips32/Makefile diff --git a/none/tests/Makefile.am b/none/tests/Makefile.am index f75de49f46..a95d66436d 100644 --- a/none/tests/Makefile.am +++ b/none/tests/Makefile.am @@ -92,7 +92,8 @@ dist_noinst_SCRIPTS = \ filter_stderr \ filter_timestamp \ filter_xml \ - allexec_prepare_prereq + allexec_prepare_prereq \ + filter_sort noinst_HEADERS = fdleak.h diff --git a/none/tests/filter_sort b/none/tests/filter_sort new file mode 100755 index 0000000000..5c376236c2 --- /dev/null +++ b/none/tests/filter_sort @@ -0,0 +1,2 @@ +#!/bin/sh +sort diff --git a/none/tests/linux/getdents_filter.stdout.exp b/none/tests/linux/getdents_filter.stdout.exp index c228ee81fd..7d29d0f664 100644 --- a/none/tests/linux/getdents_filter.stdout.exp +++ b/none/tests/linux/getdents_filter.stdout.exp @@ -1,9 +1,3 @@ -retry_test_start -retry:0 -retry:1 -retry:2 -retry:3 -retry_test_end 0 1 2 @@ -14,3 +8,9 @@ fdinfo:2 fdinfo:3 regular:1000 regular:1001 +retry:0 +retry:1 +retry:2 +retry:3 +retry_test_end +retry_test_start diff --git a/none/tests/linux/getdents_filter.vgtest b/none/tests/linux/getdents_filter.vgtest index eb5bd6cebd..612ebcec27 100644 --- a/none/tests/linux/getdents_filter.vgtest +++ b/none/tests/linux/getdents_filter.vgtest @@ -1,2 +1,3 @@ prog: getdents_filter vgopts: -q +stdout_filter: ../filter_sort |
From: Bart V. A. <bva...@ac...> - 2025-10-02 16:30:26
|
On 10/1/25 10:48 PM, Paul Floyd wrote: > +#if !defined(VGO_freebsd) // Darwin as well? Isn't adding this type of #ifdefs a software anti-pattern? Please consider adding a configure test for dirent64() and getdent64() and to test the appropriate HAVE_* macro here. Thanks, Bart. |
From: Paul F. <pa...@so...> - 2025-10-02 05:48:53
|
https://sourceware.org/cgit/valgrind/commit/?id=d01f7775d7544316139742a675bd0d49cf7dc3c1 commit d01f7775d7544316139742a675bd0d49cf7dc3c1 Author: Paul Floyd <pj...@wa...> Date: Thu Oct 2 07:46:59 2025 +0200 FreeBSD: fix build, FreeBSD has no dirent64 or getdent64 Need to check Darwin as well. Diff: --- coregrind/m_syswrap/syswrap-generic.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/coregrind/m_syswrap/syswrap-generic.c b/coregrind/m_syswrap/syswrap-generic.c index 3786e9cd89..296ebdd910 100644 --- a/coregrind/m_syswrap/syswrap-generic.c +++ b/coregrind/m_syswrap/syswrap-generic.c @@ -3994,6 +3994,8 @@ PRE(sys_getdents) PRE_MEM_WRITE( "getdents(dirp)", ARG2, ARG3 ); } +#if !defined(VGO_freebsd) // Darwin as well? + /* Check if the given file descriptor points to a /proc/PID/fd or /proc/PID/fdinfo directory. Returns True if it's a directory we should filter Valgrind FDs from. */ static Bool is_proc_fd_directory(Int fd) @@ -4096,6 +4098,8 @@ static SizeT filter_dirent64_entries(struct vki_dirent64 *dirp, SizeT orig_size) return new_size; } +#endif + /* Make sure we really need the proc filtering using (32bit) getdents, which not every linux arch implements. */ #if defined(VGO_linux) && defined(__NR_getdents) @@ -4130,6 +4134,8 @@ static SizeT filter_valgrind_fds_from_getdents_with_refill(Int fd, struct vki_di } #endif /* defined(VGO_linux) && defined(__NR_getdents) */ +#if !defined(VGO_freebsd) // Darwin as well? + /* Filter out Valgrind's internal file descriptors from getdents64 results with refill capability. Same logic as getdents version but for 64-bit dirent structures. Returns filtered size on success, or -1 if retry syscall failed. */ @@ -4159,6 +4165,8 @@ static SizeT filter_valgrind_fds_from_getdents64_with_refill(Int fd, struct vki_ return new_size; } +#endif + POST(sys_getdents) { vg_assert(SUCCESS); @@ -4186,6 +4194,8 @@ POST(sys_getdents) } } +#if !defined(VGO_freebsd) + PRE(sys_getdents64) { *flags |= SfMayBlock; @@ -4219,6 +4229,8 @@ POST(sys_getdents64) } } +#endif + PRE(sys_getgroups) { PRINT("sys_getgroups ( %ld, %#" FMT_REGWORD "x )", SARG1, ARG2); |
From: Florian K. <fl...@ei...> - 2025-10-01 22:26:34
|
On 01.10.25 16:43, Mark Wielaard wrote: > https://sourceware.org/cgit/valgrind/commit/?id=94b0aab338d0e102057308dedc50b3f3d5234e17 > > commit 94b0aab338d0e102057308dedc50b3f3d5234e17 > Author: Mark Wielaard <ma...@kl...> > Date: Wed Oct 1 16:42:17 2025 +0200 > > none/tests/Makefile.am: Add s390x/disasm-test to DIST_SUBDIRS Hi Mark, Sorry for that... I did run make post-regtest-checks but that was not good enough. Please check out the attached patch in https://bugs.kde.org/show_bug.cgi?id=495483 which should help. Thanks, Florian |
From: Mark W. <ma...@so...> - 2025-10-01 14:44:06
|
https://sourceware.org/cgit/valgrind/commit/?id=94b0aab338d0e102057308dedc50b3f3d5234e17 commit 94b0aab338d0e102057308dedc50b3f3d5234e17 Author: Mark Wielaard <ma...@kl...> Date: Wed Oct 1 16:42:17 2025 +0200 none/tests/Makefile.am: Add s390x/disasm-test to DIST_SUBDIRS Fixes: 6abf08f96a97 ("disasm-test: Makefile tweaks") Diff: --- none/tests/Makefile.am | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/none/tests/Makefile.am b/none/tests/Makefile.am index 58e7a52492..f75de49f46 100644 --- a/none/tests/Makefile.am +++ b/none/tests/Makefile.am @@ -77,7 +77,8 @@ if VGCONF_PLATFORMS_INCLUDE_X86_FREEBSD SUBDIRS += x86-freebsd endif -DIST_SUBDIRS = x86 amd64 ppc32 ppc64 arm arm64 s390x mips32 mips64 nanomips \ +DIST_SUBDIRS = x86 amd64 ppc32 ppc64 arm arm64 s390x s390x/disasm-test \ + mips32 mips64 nanomips \ riscv64 linux darwin solaris freebsd amd64-linux x86-linux \ amd64-darwin x86-darwin amd64-solaris x86-solaris x86-freebsd \ scripts . |
From: Florian K. <fk...@so...> - 2025-10-01 14:42:58
|
https://sourceware.org/cgit/valgrind/commit/?id=eed42ea290e362eaf333135f4fa53b8687005e54 commit eed42ea290e362eaf333135f4fa53b8687005e54 Author: Florian Krohm <fl...@ei...> Date: Wed Oct 1 14:42:23 2025 +0000 Add BZ 506211 to NEWS Diff: --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index 765d9d3d62..e4722a7293 100644 --- a/NEWS +++ b/NEWS @@ -985,6 +985,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 451626 Syscall param bpf(attr->raw_tracepoint.name) points to unaddressable byte(s) 451827 [ppc64le] VEX temporary storage exhausted with several vbpermq instructions 451843 valgrind fails to start on a FreeBSD system which enforces W^X +506211 Constant folding improvements 509157 riscv64: Shift instructions can behave wrong To see details of a given bug, visit |
From: Florian K. <fk...@so...> - 2025-10-01 12:49:49
|
https://sourceware.org/cgit/valgrind/commit/?id=6abf08f96a97bf12aac01cef97ed39936eb038b3 commit 6abf08f96a97bf12aac01cef97ed39936eb038b3 Author: Florian Krohm <fl...@ei...> Date: Wed Oct 1 12:48:12 2025 +0000 disasm-test: Makefile tweaks disasm-test/Makefile.am: Include Makefile.tool-tests.am not Makefile.all.am Also: do not build disasm-test on platforms other than s390x. There is no point doing so as you won't be able to run it in a meaningful way. Diff: --- Makefile.am | 1 - none/tests/Makefile.am | 2 +- none/tests/s390x/disasm-test/Makefile.am | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Makefile.am b/Makefile.am index a3150abb14..6c5b9f5b63 100644 --- a/Makefile.am +++ b/Makefile.am @@ -33,7 +33,6 @@ SUBDIRS = \ perf \ gdbserver_tests \ memcheck/tests/vbit-test \ - none/tests/s390x/disasm-test \ none/tests/iropt-test \ auxprogs \ mpi \ diff --git a/none/tests/Makefile.am b/none/tests/Makefile.am index 716ce000d3..58e7a52492 100644 --- a/none/tests/Makefile.am +++ b/none/tests/Makefile.am @@ -24,7 +24,7 @@ if VGCONF_ARCHS_INCLUDE_ARM64 SUBDIRS += arm64 endif if VGCONF_ARCHS_INCLUDE_S390X -SUBDIRS += s390x +SUBDIRS += s390x s390x/disasm-test endif if VGCONF_ARCHS_INCLUDE_MIPS32 SUBDIRS += mips32 diff --git a/none/tests/s390x/disasm-test/Makefile.am b/none/tests/s390x/disasm-test/Makefile.am index 5629d7d52d..150f38b321 100644 --- a/none/tests/s390x/disasm-test/Makefile.am +++ b/none/tests/s390x/disasm-test/Makefile.am @@ -1,4 +1,4 @@ -include $(top_srcdir)/Makefile.all.am +include $(top_srcdir)/Makefile.tool-tests.am EXTRA_DIST = disasm-test.vgtest disasm-test.stderr.exp \ disasm-test.post.exp |
From: Florian K. <fk...@so...> - 2025-10-01 12:20:04
|
https://sourceware.org/cgit/valgrind/commit/?id=09f6162dd7ca1e60ceeb6e7fac30a1f9a8cf6641 commit 09f6162dd7ca1e60ceeb6e7fac30a1f9a8cf6641 Author: Florian Krohm <fl...@ei...> Date: Wed Oct 1 12:19:13 2025 +0000 VEX: Remove algebraic simplification for shift IROps. Shl/Shr/Sar(0,x) ==> 0 Don't. Because doing so removes the undefined behaviour in case the shift amount is out of range. This is also consistent with what constant folding does in this case, namely, passing the undefined behaviour down the VEX pipeline. Diff: --- VEX/priv/ir_opt.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/VEX/priv/ir_opt.c b/VEX/priv/ir_opt.c index 4b07b27fc4..1b21c8e3ec 100644 --- a/VEX/priv/ir_opt.c +++ b/VEX/priv/ir_opt.c @@ -2623,13 +2623,6 @@ static IRExpr* fold_Expr_WRK ( IRExpr** env, IRExpr* e ) e2 = e->Iex.Binop.arg1; break; } - /* Shl8/Shl16/Shl32/Shl64(0,x) ==> 0 - Shr8/Shr16/Shr32/Shr64(0,x) ==> 0 - Sar8/Sar16/Sar32/Sar64(0,x) ==> 0 */ - if (isZeroU(e->Iex.Binop.arg1)) { - e2 = e->Iex.Binop.arg1; - break; - } break; case Iop_Or1: |
From: Florian K. <fk...@so...> - 2025-09-30 20:28:31
|
https://sourceware.org/cgit/valgrind/commit/?id=56f62f74ada99daf1a18cd1abe5309d4fc9c085c commit 56f62f74ada99daf1a18cd1abe5309d4fc9c085c Author: Florian Krohm <fl...@ei...> Date: Tue Sep 30 20:27:43 2025 +0000 Add BZ 509157 to NEWS. Diff: --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index d7367ba054..765d9d3d62 100644 --- a/NEWS +++ b/NEWS @@ -985,6 +985,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. 451626 Syscall param bpf(attr->raw_tracepoint.name) points to unaddressable byte(s) 451827 [ppc64le] VEX temporary storage exhausted with several vbpermq instructions 451843 valgrind fails to start on a FreeBSD system which enforces W^X +509157 riscv64: Shift instructions can behave wrong To see details of a given bug, visit https://bugs.kde.org/show_bug.cgi?id=XXXXXX |