- Several memcheck options are now dynamically changeable.
Use valgrind --help-dyn-options to list them.
+ - The release 3.15 introduced a backward incompatible change for
+ some suppression entries related to preadv and pwritev syscalls.
+ When reading a suppression entry using the unsupported 3.14 format,
+ valgrind will now produce a warning to say the suppression entry will not
+ work, and suggest the needed change.
+
* ==================== OTHER CHANGES ====================
* New and modified GDB server monitor features:
416464 Fix false reports for uninitialized memory for PR_CAPBSET_READ/DROP
416667 gcc10 ppc64le impossible constraint in 'asm' in test_isa.
416753 new 32bit time syscalls for 2038+
+417075 pwritev(vector[...]) suppression ignored
+ 417075 is not fixed, but incompatible supp entries are detected
+ and a warning is produced for these.
417187 [MIPS] Conditional branch problem since 'grail' changes
417238 Test memcheck/tests/vbit-test fails on mips64 BE
417266 Make memcheck/tests/linux/sigqueue usable with musl
count * sizeof(struct vki_iovec))) {
vec = (struct vki_iovec *)(Addr)vector;
for (i = 0; i < count; i++) {
+ /* Note: building such a dynamic error string is *not*
+ a pattern to follow. See bug 417075. */
VG_(snprintf) (tmp, 30, "%s(vector[%d])", str, i);
PRE_MEM_WRITE( tmp, (Addr)vec[i].iov_base, vec[i].iov_len );
}
count * sizeof(struct vki_iovec))) {
vec = (struct vki_iovec *)(Addr)vector;
for (i = 0; i < count; i++) {
+ /* Note: building such a dynamic error string is *not*
+ a pattern to follow. See bug 417075. */
VG_(snprintf) (tmp, 30, "%s(vector[%d])", str, i);
PRE_MEM_READ( tmp, (Addr)vec[i].iov_base, vec[i].iov_len );
}
(see pub_tool_tooliface.h print_extra_suppression_info).
If no 'a', 's' or 'extra' of interest needs to be recorded, just use
- NULL for them. */
+ NULL for them.
+
+ ATTENTION: 's' should not contain information that is (too) specific
+ to an instance of an error. For example, 's' can clearly not contain
+ an address, as otherwise no way the user can build a suppression entry
+ matching such a variable error extra string. It should preferrably not
+ contain offset or array indexes, for similar reason.
+ In other words, 's' should be NULL or should be a static string.
+ Finally, if you change the string 's' from one release to another
+ for the same error, you will introduce backward incompatible changes
+ with the suppression files produced for previous releases.
+ So, don't do that ! */
extern void VG_(maybe_record_error) ( ThreadId tid, ErrorKind ekind,
Addr a, const HChar* s, void* extra );
'print_error' dictates whether to print the error, which is a bit of a
hack that's useful sometimes if you just want to know if the error would
be suppressed without possibly printing it. 'count_error' dictates
- whether to add the error in the error total count (another mild hack). */
+ whether to add the error in the error total count (another mild hack).
+
+ ATTENTION: read the 'ATTENTION' above for VG_(maybe_record_error) ! */
extern Bool VG_(unique_error) ( ThreadId tid, ErrorKind ekind,
Addr a, const HChar* s, void* extra,
ExeContext* where, Bool print_error,
eof = VG_(get_line) ( fd, bufpp, nBufp, lineno );
if (eof) return False;
VG_(set_supp_string)(su, VG_(strdup)("mc.resi.1", *bufpp));
+ if (VG_(strcmp) (*bufpp, "preadv(vector[...])") == 0
+ || VG_(strcmp) (*bufpp, "pwritev(vector[...])") == 0) {
+ /* Report the incompatible change introduced in 3.15
+ when reading a unsupported 3.14 or before entry.
+ See bug 417075. */
+ VG_(umsg)("WARNING: %s is an obsolete suppression line "
+ "not supported in valgrind 3.15 or later.\n"
+ "You should replace [...] by a specific index"
+ " such as [0] or [1] or [2] or similar\n\n", *bufpp);
+ }
} else if (VG_(get_supp_kind)(su) == LeakSupp) {
// We might have the optional match-leak-kinds line
MC_LeakSuppExtra* lse;