Commit Graph

5325 Commits

Author SHA1 Message Date
Julian Seward
29ff6066e9 Add a new flag, --child-silent-after-fork=no|yes [no]. When enabled,
causes child processes after fork to fall completely silent, which can
make the output a lot less confusing.  In addition it is pretty much
essential in XML output mode, so as to avoid mixing up any child XML
output with the parent's.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7177
2007-11-17 22:29:25 +00:00
Julian Seward
e83bc0c180 Don't pollute the XML output if the program terminates with a signal,
and for a couple of other minor warnings.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7176
2007-11-17 21:31:48 +00:00
Julian Seward
db29debc13 Make handling of setuid executables marginally more sensible, as
suggested in #119404.

Prior to this commit, if the current traced process attempted to
execve a setuid executable, an error was always returned.  The revised
behaviour is:

If the current (traced) process attempts to execve a setuid
executable:

* If --trace-children=yes is not in effect, the execve is allowed.

* If --trace-children=yes is in effect, the execve is disallowed
  (as at present), but an error message is printed (unless in XML mode),
  so at least the execve does not fail silently any more.

As per discussion on #119404 we could probably do a lot better, but
these changes are at least simple, useful and uncontroversial.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7175
2007-11-17 21:11:57 +00:00
Julian Seward
2ab03ee95d Makefile.tool-inplace.am: correctly handle tool names with dashes in,
using same changes to magic sed scripts as were recently applied to
Makefile.install.am.




git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7174
2007-11-17 18:35:54 +00:00
Julian Seward
5e2a8da202 Spelling fixes and misc tidying for the manual. (Brian Gough)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7173
2007-11-17 09:43:25 +00:00
Julian Seward
71dbabbf30 Update.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7172
2007-11-17 02:46:42 +00:00
Julian Seward
cb12a8770d Stack registration stuff: don't dereference NULL pointers (Eric
Sharkey, #150044).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7171
2007-11-17 02:05:57 +00:00
Julian Seward
8dd547a530 Don't segfault on syscall (SYS_io_destroy, 0). (Jakub Jelinek) Fixes
#147325.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7170
2007-11-17 01:49:06 +00:00
Julian Seward
4044188f76 Add support for private futexes (whatever they might be). Patch from
Eric Dumazet.  Fixes #146781.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7169
2007-11-17 01:35:08 +00:00
Julian Seward
f0a790693c Don't crap out when malloc_stats is called; instead just have a no-op
implementation of it.  Fixes #145559.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7168
2007-11-16 22:29:27 +00:00
Julian Seward
760e1d046e Make one redirect mandatory for ppc64-linux.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7167
2007-11-16 19:39:49 +00:00
Julian Seward
5d69e35fdc Make one of the ppc32-linux initial redirects mandatory, and add
further comments.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7166
2007-11-16 18:45:40 +00:00
Julian Seward
f245d83cc4 Introduce the concept of a 'mandatory redirection'. A redirection
says (essentially) "I am the replacement for function foo in object w/
soname bar.so".  Now, if a redirection is mandatory, and bar.so is
loaded but foo is not found in its symbol table, then V aborts.

The initial motivation for this is making Memcheck work sanely on
glibc-2.6.X ppc32-linux.  We really need to intercept 'strlen' in
ld.so right from startup.  If ld.so does not have a visible 'strlen'
symbol, Memcheck generates an impossible number of errors resulting
from highly tuned strlen implementation in ld.so, and is completely
unusable -- the resulting undefinedness eventually seeps everywhere.




git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7165
2007-11-16 18:32:40 +00:00
Julian Seward
9bf9f81786 Avoid hundreds of warnings from -Winline on gcc-4.3:
In dump.c, gcc complains that 'param max-stack-frame-growth' would be
exceeded, so remove 'inline' spec.

All other warnings are of the form 'call is unlikely and code size
would grow'.  These aren't interesting.  Remove -Winline.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7164
2007-11-16 12:31:27 +00:00
Julian Seward
9fd225ac18 Back out bogus strict-aliasing hacks and use -fno-strict-aliasing by
default.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7163
2007-11-16 12:02:43 +00:00
Julian Seward
40eb3fba0f Change the baseline optimisation level from -O to -O2.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7162
2007-11-16 10:05:47 +00:00
Julian Seward
059f31901b Update.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7161
2007-11-16 04:01:57 +00:00
Julian Seward
bf6574af7c Rename a couple more UInts which really should be SVals.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7160
2007-11-16 03:55:48 +00:00
Julian Seward
7cf42600a1 Add a regression test for #152022.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7159
2007-11-15 22:33:32 +00:00
Julian Seward
f3198010f6 Give shadow values their own type (SVal) for the usual
good-software-engineering-practice reasons.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7158
2007-11-14 15:53:11 +00:00
Julian Seward
305c78526c Update the list of unfixed bugs. Depressingly long.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7156
2007-11-13 22:00:20 +00:00
Julian Seward
fd7a6b5363 Intercept __memcpy_chk, which appears in glibc-2.6.1. Also fix some
backslash uglyness.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7155
2007-11-13 20:52:29 +00:00
Julian Seward
194fd7160a Even more suppressions for glibc-2.6.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7154
2007-11-13 20:51:26 +00:00
Nicholas Nethercote
f57a498ccf Another attempt at fixing some Massif regtest failures.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7153
2007-11-12 07:05:07 +00:00
Nicholas Nethercote
982c23d403 Fix verbose output filtering for Massif.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7152
2007-11-12 01:16:24 +00:00
Julian Seward
de4a349062 More glibc-2.6 suppressions.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7151
2007-11-12 01:01:08 +00:00
Nicholas Nethercote
b8e2d6e145 - Make other integer CLO macros more correct, as I did for VG_NUM_CLO in the
last commit.
- Add a VG_DBL_CLO for fractional arguments.
- Make Massif's --threshold and --peak-inaccuracy arguments fractional.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7150
2007-11-11 22:15:58 +00:00
Nicholas Nethercote
13c597f709 Add four 'strtoll' variants, which are like 'atoll' but let you detect if
the string converted wasn't entirely numeric.  Using them for numeric
command-line options -- previously if you had a option "--foo=<n>", where
<n> is supposed to be an integer, then "--foo=blah" would be interpreted as
"--foo=0", because the "blah" would be converted to zero and the remaining
chars wouldn't be noticed.

Fixed an incorrect command-line option in two massif tests that this change
exposed.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7149
2007-11-11 21:58:21 +00:00
Nicholas Nethercote
aed0f8cceb Add some seemingly unnecessary initialisations to shut GCC 4.0.2 up.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7148
2007-11-11 21:12:28 +00:00
Julian Seward
dc77d6e27a In vg_SP_update_pass (stack-pointer-change analysis code), correctly
handle partial updates of SP.  Tricky.  This fixes #152022.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7147
2007-11-11 18:56:39 +00:00
Julian Seward
d511a7a7df Add some Helgrind suppressions for LinuxThreads.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7146
2007-11-11 06:13:01 +00:00
Julian Seward
3eb7b05a75 Avoid compilation warnings from gcc-3.2 (about 'index' shadowing a built-in global)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7145
2007-11-11 05:59:22 +00:00
Julian Seward
141fb3f15d Comment-only change.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7144
2007-11-11 05:58:41 +00:00
Julian Seward
565f0a4d32 Don't hang on some old systems, since that makes the entire regtest
system hang.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7143
2007-11-11 05:52:36 +00:00
Julian Seward
59ab2f14b8 Ensure omega.h is copied into the installation tree at 'make install' time.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7142
2007-11-11 01:20:14 +00:00
Julian Seward
5af7d1d73d Followup to r7105: stop gcc complaining about violations of ANSI C
aliasing rules by casting through (char*) as an intermediate type,
rather than through (void*).  This seems at least moderately
justifiable since the ANSI C standard explicitly says that any object
may be accessed through a char pointer.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7141
2007-11-10 22:50:13 +00:00
Julian Seward
caa1e5d417 Fix bogus grammar in r7139.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7140
2007-11-10 22:19:42 +00:00
Julian Seward
88c1e8eb76 Clarify reason for existence of track_pre_thread_ll_create/_exit.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7139
2007-11-10 22:13:03 +00:00
Julian Seward
c2382a8097 Include omega.h in the distribution tarball, else building from the
tarball fails.  As it stands omega.h is not installed into
$prefix/include/valgrind, so cannot be used in client requests.
Perhaps it should be.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7138
2007-11-10 20:21:11 +00:00
Julian Seward
543f58ba79 Remove old Helgrind suppressions.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7137
2007-11-10 20:12:23 +00:00
Julian Seward
f862c19d42 Fix compilation on ppc platforms.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7136
2007-11-10 13:33:56 +00:00
Julian Seward
e8d00c4eff Back out r7132.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7135
2007-11-10 12:44:56 +00:00
Nicholas Nethercote
3aacee8b1b Filter out some of Massif's verbose output that varies from machine to
machine, caused by them getting slightly different stack traces.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7134
2007-11-10 04:18:39 +00:00
Nicholas Nethercote
d95559802b Changed Massif to record the 'slop' heap bytes caused by rounding asked-for
sizes up to a multiple of 8 (or whatever --alignment is).  This is combined
with the "admin" bytes, resulting in the "extra" bytes.  Added
VG_(malloc_usable_size) to the tool interface to support this.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7133
2007-11-10 04:08:08 +00:00
Nicholas Nethercote
e4a44c6078 fix toolname in Helgrind suppressions
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7132
2007-11-10 03:27:42 +00:00
Julian Seward
969c77b267 Rename in the manual.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7130
2007-11-09 23:59:49 +00:00
Julian Seward
edccec4447 Stop xsltproc barfing on un-escaped '&'.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7129
2007-11-09 23:59:14 +00:00
Julian Seward
af406f51e9 Merge (from branches/THRCHECK) misc build-system changes. Nothing
significant.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7128
2007-11-09 23:30:51 +00:00
Julian Seward
e63e873227 Merge (from branches/THRCHECK) r7043:
Allow a test to have any number of .stderr.exp* files, so long as at
least one is found.  In fact the comments in the code that claimed
that .stderr.exp[0-9] are the only ones allowed were misleading;
.stderr.exp* has always been allowed.  The only functional change here
is to mandate that at least one such file exists; prior to the change
the script mandated that at least a .stderr.exp (with no other suffix)
file existed.

Purpose is to allow collections of .stderr.exp files with suffixes
arranged in some meaningful way, eg, foo.stderr.exp-glibc25-amd64.
This might help in making testsuites more maintainable when there
have to be multiple .stderr.exp files.  Naming them merely as
.stderr.exp1, .stderr.exp2, etc, makes it impossible to remember
what the differences between the files actually is.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7127
2007-11-09 23:29:46 +00:00
Julian Seward
28af011553 I got a bit confused with glibc-2.6.X suppressions whilst merging from
branches/THRCHECK (sorry Dirk).  I'll fix them shortly.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7126
2007-11-09 23:26:54 +00:00