194 Commits

Author SHA1 Message Date
Nicholas Nethercote
5dfe01a847 With the recent VG_(message) change,
VALGRIND_{PRINTF,PRINTF_BACKTRACE,INTERNAL_PRINTF} were no longer appending
newlines.  This meant that --trace-malloc=yes spewed everything onto a
single line, among other things.

Rather than adding the newline back in, I chose to offically change their
behaviour to not add the newlines, as this is more flexible (and the reason
for the underlying VG_(message) change).  I updated all the relevant places
I could find.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10694
2009-08-03 01:38:56 +00:00
Nicholas Nethercote
a3fe17b34b Print the command being run at startup. It wraps to avoid going over 80
chars wide whenever possible.  Finishes off bug 197933.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10657
2009-07-29 23:34:49 +00:00
Nicholas Nethercote
fb2fa41714 Add Valgrind version back into the preamble.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10572
2009-07-24 04:47:04 +00:00
Nicholas Nethercote
75b92a2ec9 Shorten the preamble by moving some of it into the --help output. This
partly fixes bug 197933.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10451
2009-07-14 06:55:05 +00:00
Bart Van Assche
1f3866629f Updated filter after the modification of Valgrind's startup message in r10447.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10448
2009-07-14 06:31:26 +00:00
Nicholas Nethercote
5715955132 Fix a couple of tests that could be built with the wrong options, including
the -m32/-m64 option.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10440
2009-07-13 22:20:00 +00:00
Julian Seward
e818cd9481 Only run none/tests/amd64/bug127521-64 on machines supporting cmpxchg16b.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10433
2009-07-12 13:17:18 +00:00
Nicholas Nethercote
b05a2a18d7 This commit merges the BUILD_TWEAKS branch onto the trunk. It has the
following improvements:

- Arch/OS/platform-specific files are now included/excluded via the
  preprocessor, rather than via the build system.  This is more consistent
  (we use the pre-processor for small arch/OS/platform-specific chunks
  within files) and makes the build system much simpler, as the sources for
  all programs are the same on all platforms.

- Vast amounts of cut+paste Makefile.am code has been factored out.  If a
  new platform is implemented, you need to add 11 extra Makefile.am lines.
  Previously it was over 100 lines.

- Vex has been autotoolised.  Dependency checking now works in Vex (no more
  incomplete builds).  Parallel builds now also work.  --with-vex no longer
  works;  it's little use and a pain to support.  VEX/Makefile is still in
  the Vex repository and gets overwritten at configure-time;  it should
  probably be renamed Makefile-gcc to avoid possible problems, such as
  accidentally committing a generated Makefile.  There's a bunch of hacky
  copying to deal with the fact that autotools don't handle same-named files
  in different directories.  Julian plans to rename the files to avoid this
  problem.

- Various small Makefile.am things have been made more standard automake
  style, eg. the use of pkginclude/pkglib prefixes instead of rolling our
  own.

- The existing five top-level Makefile.am include files have been
  consolidated into three.

- Most Makefile.am files now are structured more clearly, with comment
  headers separating sections, declarations relating to the same things next
  to each other, better spacing and layout, etc.

- Removed the unused exp-ptrcheck/tests/x86 directory.

- Renamed some XML files.

- Factored out some duplicated dSYM handling code.

- Split auxprogs/ into auxprogs/ and mpi/, which allowed the resulting
  Makefile.am files to be much more standard.

- Cleaned up m_coredump by merging a bunch of files that had been
  overzealously separated.

The net result is 630 fewer lines of Makefile.am code, or 897 if you exclude
the added Makefile.vex.am, or 997 once the hacky file copying for Vex is
removed.  And the build system is much simpler.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10364
2009-06-24 00:37:09 +00:00
Nicholas Nethercote
07045477ca Merge the DARWIN branch onto the trunk.
I tried using 'svn merge' to do the merge but it did a terrible job and
there were bazillions of conflicts.  So instead I just took the diff between
the branch and trunk  at r10155, applied the diff to the trunk, 'svn add'ed
the added files (no files needed to be 'svn remove'd) and committed.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10156
2009-05-28 01:53:07 +00:00
Nicholas Nethercote
5e249a1ba4 Merge r9897 (x86_amd64_features.c simplifcation) from the DARWIN branch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9898
2009-05-18 06:23:25 +00:00
Nicholas Nethercote
4150356821 Merge part (filter tweaks) of 8943 from the DARWIN branch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9893
2009-05-18 05:29:41 +00:00
Nicholas Nethercote
d834611463 Merge r9600 (separate VG_ and ML_ definitions for C and asm files) from the
DARWIN branch.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9601
2009-04-24 04:57:07 +00:00
Nicholas Nethercote
dcea4e928e Removed some Darwin-specific code that crept in from the DARWIN branch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9599
2009-04-24 04:28:15 +00:00
Nicholas Nethercote
52cf1f5f05 Merge r9103 and r9105 (add --ignore-fn to Massif) from the Darwin branch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9567
2009-04-17 04:26:41 +00:00
Nicholas Nethercote
13e765c304 Merged r9546..r9548 (moved blockfault, and filtering fixes) from the DARWIN
branch.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9549
2009-04-15 07:11:36 +00:00
Nicholas Nethercote
e230aa9551 These three files should have been added in r9537.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9544
2009-04-15 05:35:00 +00:00
Nicholas Nethercote
f3f801ed48 Merge r9533..9536 (add tests/{asm.h,sys_mman.h,malloc.h} from the DARWIN
branch.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9537
2009-04-15 03:12:43 +00:00
Nicholas Nethercote
0c4d4b5d1a Test fixes for systems that have debug info installed for libc and
libpthread.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9353
2009-03-10 23:39:12 +00:00
Nicholas Nethercote
1d75b1ac58 Some tweaks to make more tests pass, or get closer to passing, on
--enable-only32bit builds on my Ubuntu box:

- For all tests, replace all operator new/new[]/delete/delete[] variants
  with a common form, eg. "...operator new...".  This makes
  exp-ptrcheck/tests/ccc and memcheck/tests/mismatches pass.

- For Helgrind tests, replace all libpthread paths with "/...libpthread...",
  as is done for libc paths.  This avoids problems when /lib32/libpthread.so
  is the path.  No extra tests pass, but many of them get a lot closer to
  passing.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9333
2009-03-10 03:34:00 +00:00
Nicholas Nethercote
f061fac766 This should have been added to the last commit.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9317
2009-03-04 04:18:33 +00:00
Nicholas Nethercote
4c23a0b3e9 tests/arch_test is currently being used for two purposes:
- by vg_regtest for determining if a directory name matches an architecture;
- by various .vgtest files for detecting x86/AMD64 features.

This commit splits it in two for the two different purposes, which makes
things clearer.

Specific changes

- Moved the x86/AMD64 feature detection stuff out of arch_test.c, and
  into the new x86_amd64_feature.c.  Updated the relevant .vgtest files for
  the change.

- In vg_regtest, now a prereq command must return 0 (prereq satisfied) or 1
  (prereq not satisfied).  Anything else makes vg_regtest abort.  This
  makes obvious any problems with prereq tests rather than just making the
  tests skip innocuously.  (We previously had exactly such a problem on the
  DARWIN branch;  the x86 feature detection tests caused segfaults so the
  tests were incorrectly skipped.  This change will catch any similar future
  problem.)

- Changed os_test from a script to a C program, matching cpu_test.

- Removed some unintentional darwin stuff from platform_test.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9316
2009-03-04 04:15:16 +00:00
Nicholas Nethercote
2bd30d545e Remove darwin code that crept into the trunk.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9314
2009-03-04 01:23:04 +00:00
Nicholas Nethercote
c070233e77 Merge r9283 (lackey testing fixes) from the DARWIN branch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9284
2009-02-26 22:26:45 +00:00
Nicholas Nethercote
95f49af2f2 Use 'diff -u' for regtests if it's supported, its output it much easier to
read than plain 'diff'.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9263
2009-02-25 04:57:56 +00:00
Nicholas Nethercote
e67c3fc54e Remove toobig-allocs.c -- it was unreliable and didn't test any
functionality of note.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9261
2009-02-25 04:34:44 +00:00
Nicholas Nethercote
a3d4b19255 Cleanup this Makefile.am like other recent test Makefile.am files.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9226
2009-02-23 01:03:06 +00:00
Nicholas Nethercote
cf6cd2bb31 Stack traces for Memcheck's syscall param errors are terribly unreliable, so
I changed it to just filter the entire stack trace out for these errors (both
normal and XML cases).  The syscall name is still present in the error
string.  This allows a one or more alternative expected output files to be
removed for several tests, which is A Very Good Thing.

Also, I killed filter_test_paths because it was weird and clumsy and the
above change obviated most of its use and the remaining effects could be
achieved in other ways.

Also, I fixed up the scalar* tests a little and they now pass on my machine,
(and hopefully at least some other machines) for the first time ever!


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9178
2009-02-16 05:11:49 +00:00
Nicholas Nethercote
108768ee98 Merge r9175 (don't run inappropriate OS- and platform-specific tests) from
the DARWIN branch.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9176
2009-02-16 00:42:10 +00:00
Nicholas Nethercote
f3240d6950 Filter out everything after "(below main)" in a line. This will help with
Darwin, for which such entries can occur within the executable, rather than
within libc.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9142
2009-02-12 00:51:50 +00:00
Nicholas Nethercote
f0f8b48fcf Merge the non-Darwin parts of r9140 (install vgpreload .dSYMs), just to keep
the trunk and DARWIN branch in sync.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9141
2009-02-12 00:30:02 +00:00
Nicholas Nethercote
5e97a0524e Filter out "(core dumped)" after "Bus error" for consistency. This makes
shell_zerolength pass on my Ubuntu 8.10 machine.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9134
2009-02-11 00:21:53 +00:00
Nicholas Nethercote
ed322feb84 Rename all the arch/OS/platform-related variables in configure.in to make it
clearer what they mean:
- They all have VGCONF_ prefixes now, to indicate they come out of
  configure.in (and are clearly distinguished from the VGA_/VGO_/VGP_
  #defines passed in to C files).
- The ones that refer to the primary *or* secondary platform have _INCLUDES_
  in them.
- The ones that are in all-caps have a _CAPS suffix.

So, for example, what was VGP_X86_LINUX is now
VGCONF_PLATFORMS_INCLUDE_X86_LINUX, which is more verbose but also a lot
clearer.  The names of the #defines used in the C files (VGA_x86, VGO_linux,
etc) are unchanged.

cputest.c: changed to reflect the Valgrind installation's capabilities,
rather than the machine's capabilities.  In particular, if
--enable-only32bit is used on a 64-bit machine, then this program will claim
to only support 32-bits.  Also use the VGA/VGO/VGP macros which are clearer
than the __i386__ ones.  (This is partially merged from the DARWIN branch.)

configure.in: clean up the comments, distinguish different sections more
clearly, and generally make it more readable.

valgrind.pc.in: try to make this more accurate.  I doubt anyone's using it.
It doesn't appear to be set up to handle dual-architecture builds.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9031
2009-01-22 21:56:32 +00:00
Tom Hughes
6917b2e4e4 SSE3 and SSSE3 are two different things, so add a proper SSSE3 feature
test and use that to guard the SSSE3 tests.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@8942
2009-01-12 15:26:59 +00:00
Julian Seward
40399aab00 Fix longstanding bug in dual-arch support, which originated in
memcheck/tests/Makefile.am and was copied into drd/tests/Makefile.am.

When building regtests for a 32-bit only build on a 64-bit CPU, the
use of $(VG_ARCH) in these Makefiles is incorrect, because VG_ARCH
will be set to the 64-bit architecture, not the 32-bit architecture.

See comments on VG_ARCH_PRI and VG_ARCH_MAX in configure.in for more
details.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@8623
2008-09-19 09:02:19 +00:00
Bart Van Assche
2ae55aa144 Filtered out platform-dependent error messages.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7744
2008-03-22 07:52:44 +00:00
Nicholas Nethercote
2e4c67743e Ignore Emacs temporary files. Also, produce the correct .diff filename when
the .exp filename has a non-numeric suffix.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7538
2008-03-02 22:48:14 +00:00
Nicholas Nethercote
745f47f01c Make comments reflect the code.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7494
2008-02-27 18:10:19 +00:00
Julian Seward
e70c4211ff Marginally enhance help message.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7258
2007-11-30 21:24:05 +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
Nicholas Nethercote
62eed24c67 Merged the MASSIF2 branch to the trunk. Main changes:
- ms_main.c: completely overhauled.

- massif/tests/*:  lots of them now.

- massif/perf/:  added.

- massif/hp2ps:  removed.  No longer used.

- vg_regtest: renamed the previously unused "posttest" notion to "post".
  Using it for checking ms_print's output.

Although the code has changed dramatically, as has the form of the tool's
output, the information presented in the output is basically the same,
although it's now (hopefully) much more useful.  So the tool name is
unchanged.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7069
2007-11-01 04:40:37 +00:00
Julian Seward
043bf89f2a Minor tidying for regtests on AIX.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6395
2006-12-12 01:38:15 +00:00
Nicholas Nethercote
8b2049f475 Update a comment.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6373
2006-11-26 22:49:58 +00:00
Nicholas Nethercote
aa2ce63f67 Add --valgrind-lib, to complement --valgrind, to the regtests script
(from Dave Nomura).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6338
2006-10-23 18:38:35 +00:00
Julian Seward
5b26b045dd Change a bunch of pointer <-> int casts to pointer <-> long casts so
as to stop gcc complaining so much on 64-bit platforms.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6306
2006-10-17 11:09:03 +00:00
Julian Seward
2e44b6c1d4 Don't use -C0 for diff; apparently this is a GNU-ism.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6300
2006-10-17 02:24:51 +00:00
Julian Seward
68452584af Merge r6143: Deal with ppc{32,64}-aix5.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6279
2006-10-17 01:49:50 +00:00
Julian Seward
dbe5eabe5c Merge r6142:
Minor enhancements, including dealing with 6-digit PIDs, dealing with
object names of the form "foo.a(bar.o)", and removing debuglog level
zero output.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6278
2006-10-17 01:48:41 +00:00
Julian Seward
6be6614e3a Regression tests for SSE3 support.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5997
2006-08-05 12:22:52 +00:00
Julian Seward
d419c4762b Read extra args for all tests from $EXTRA_REGTEST_OPTS, which is
useful (eg) for running tests with --sanity-level= set.  Print a
big warning before and after the tests if it is set.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5931
2006-05-26 00:13:21 +00:00
Tom Hughes
e09a583342 Suppress any source filename in a "(below main)" line in a stack trace.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5847
2006-04-13 12:44:31 +00:00