9127 Commits

Author SHA1 Message Date
Philippe Waroquiers
308074c716 Fix leak of range_list (see below an example) in readdwarf3.c.
(found by running regression tests with an outer memcheck).

(validated by running all regression tests "natively" on x86 and amd64,
and re-running regressions tests with outer memcheck).

==7500== 160 bytes in 2 blocks are definitely lost in loss record 75 of 246
==7500==    at 0x2803CEF7: vgPlain_arena_malloc (m_mallocfree.c:1599)
==7500==    by 0x280AAFA5: vgModuleLocal_dinfo_zalloc (misc.c:48)
==7500==    by 0x2804E2A4: vgPlain_newXA (m_xarray.c:68)
==7500==    by 0x280B3CD6: unitary_range_list (readdwarf3.c:703)
==7500==    by 0x280B66CF: parse_var_DIE (readdwarf3.c:1631)
==7500==    by 0x280BA0A6: read_DIE (readdwarf3.c:3248)
==7500==    by 0x280BA170: read_DIE (readdwarf3.c:3269)
==7500==    by 0x280BABC4: T.364 (readdwarf3.c:3611)
==7500==    by 0x280BC634: vgModuleLocal_new_dwarf3_reader (readdwarf3.c:4035)
==7500==    by 0x280609F4: vgModuleLocal_read_elf_debug_info (readelf.c:2529)
==7500==    by 0x2805BD31: vgPlain_di_notify_mmap (debuginfo.c:610)
==7500==    by 0x280362E3: valgrind_main (m_main.c:1944)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12419
2012-03-06 20:35:20 +00:00
Florian Krohm
cdea28bfba Update bug reporting URL.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12418
2012-03-06 15:54:28 +00:00
Florian Krohm
f41f7ad456 Fix a testcase. Constraint was incorrect allowing r0 to be used
for the EX insn. Patch by Christian Borntraeger (borntraeger@de.ibm.com).


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12417
2012-03-05 23:12:47 +00:00
Philippe Waroquiers
c0883bddd7 * Improve documentation of --vgdb=full
* make a reference to --vex-iropt-precise-memory-exns=yes 
  to obtain up to date registers values.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12416
2012-03-05 22:09:20 +00:00
Florian Krohm
d58aa28f82 Avoid possibly unaligned memory access.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12415
2012-03-03 18:46:05 +00:00
Philippe Waroquiers
74d44d1764 * README_DEVELOPERS : complete/enhance the section about outer/inner
* manual-core.xml : fix a typo
* include/pub_tool_inner.h : new file, defining macros for inner annotation
  include/Makefile.am : reference this new file.
* syswrap-linux.c : when ENABLE_INNER, register the stacks for the outer.
   (otherwise, nothing works properly).
* m_redir.c : avoid inner interpreting the outer vgpreload instructions.
* sema.c : annotate the semaphore with RWLOCK annotations for helgrind
* ticket-lock-linux.c : similar.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12414
2012-03-03 12:01:48 +00:00
Bart Van Assche
d5ba78f638 none/tests/mq.c: Fix a copy-paste bug
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12413
2012-03-02 09:57:14 +00:00
Philippe Waroquiers
7ec5224de5 In case VALGRIND_MALLOCLIKE_BLOCK is wrongly used, output
the execontext where the overlapping blocks have been reported
before crashing.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12412
2012-03-01 22:00:36 +00:00
Tom Hughes
35cc294c29 Handle prlimit64 the same way we do getrlimit and setrlimit, with
some requests trapped and handled by valgrind.

Patch from Matthias Schwarzott via BZ#294047.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12411
2012-03-01 13:42:18 +00:00
Philippe Waroquiers
0eb5c19d3f After a fork, gdbserver_init can be called again.
Buffers should not be re-allocated in such a case.
(memory leak detected by running memcheck on memcheck)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12410
2012-02-28 22:37:44 +00:00
Philippe Waroquiers
ea0d3b9bf4 Fix leak found by running memcheck/tests/varinfo[1-6].vgtest
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12409
2012-02-28 20:10:05 +00:00
Julian Seward
adf73152fb Increase the size of buffers used for showing names when
--trace-flags= is set.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12408
2012-02-28 18:02:41 +00:00
Philippe Waroquiers
704e5c19d1 Fix one more leak detected by running memcheck in memcheck
(started to run regression tests in an outer)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12407
2012-02-27 21:52:45 +00:00
Julian Seward
1533236a47 Android only: make the debuginfo mapping hack more flexible.
Previously it looked for the debuginfo object for "/system/X" in
"/sdcard/symbols/system/X".  This commit removes the requirement for
"system" as the first path component, so the mapping is now "/X" (viz,
any absolute path) to "/sdcard/symbols/X".


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12406
2012-02-27 11:02:20 +00:00
Philippe Waroquiers
1d7a774336 Fix some memory leaks found by running memcheck on annotated memcheck.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12405
2012-02-26 21:26:00 +00:00
Florian Krohm
0f282be925 Tighten up initial guest/shodow state on s390x.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12404
2012-02-26 17:51:28 +00:00
Florian Krohm
c34cae2568 Announce.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12403
2012-02-26 17:01:22 +00:00
Philippe Waroquiers
fab0c4b100 Fix buffer overflow bug when building the target file.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12402
2012-02-24 11:25:58 +00:00
Philippe Waroquiers
8bdfefff73 Revision 12396 (replacing pkglib_DATA by vglib_DATA) missed
once place. This was breaking vg-in-place on platforms
needing gdbserver target description files.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12401
2012-02-24 08:33:56 +00:00
Tom Hughes
b02856120f Fedora 17 is merging /lib into /usr/lib so any suppression which
explicitly matches /lib/... needs to match /usr/lib/... as well.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12400
2012-02-23 12:54:50 +00:00
Julian Seward
a3e81d0d83 Implement malloc_size for the vg_default_zone on Darwin.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12399
2012-02-23 07:36:03 +00:00
Philippe Waroquiers
6a15dd16e4 Document the new --fair-sched option.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12398
2012-02-22 20:23:29 +00:00
Philippe Waroquiers
564e685793 Avoid having holes in the VgdbShared struct.
These holes are not initialized,
and writing these uninitialised bytes to the mapped file
causes an error being reported when running Valgrind
inside Valgrind. Having no holes avoid having this error.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12397
2012-02-22 19:47:27 +00:00
Tom Hughes
e9f922b442 Hide our use of pkglibdir to stop automake 1.11.2 and later complaining.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12396
2012-02-21 15:53:35 +00:00
Julian Seward
7d0b1685f1 Add test cases for MPSADBW. See #294048.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12395
2012-02-21 11:03:38 +00:00
Julian Seward
6b43662deb x86: don't forget to initialise guest %es from the host %es when
constructing the initial guest register state.  Fixes #291253.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12394
2012-02-21 08:38:04 +00:00
Julian Seward
5786c979e6 ARM/Thumb only: fix a bug in which stack unwinding halts in some
functions that do FP arithmetic.  This is due to the Dwarf3 CFI
mentioning Dwarf registers above N_CFI_REGS, in particular FP
registers, which have values of about 80.  This fixes the problem by
increasing N_CFI_REGS to a level that covers all known registers.
(n-i-bz)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12393
2012-02-20 15:33:24 +00:00
Florian Krohm
0160d2dfc6 With the change in VEX r2258 the guest IA will now also be accessed
in the low word only. Adjust code accordingly.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12392
2012-02-20 15:03:02 +00:00
Julian Seward
2d7e3fd85c Update status and build instructions for ICS (Android 4.0.3).
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12391
2012-02-17 15:13:55 +00:00
Julian Seward
48d927757d Add test cases for PHMINPOSUW (SSE 4.1). See #287301.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12390
2012-02-16 22:02:47 +00:00
Julian Seward
2ef374fd74 Add test cases for 16 bit PCMPxSTRx variants. See #293754.
(Eliot Moss, moss@cs.umass.edu)


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12389
2012-02-16 15:24:17 +00:00
Philippe Waroquiers
b66672b48f * compare vgdb-error with n_errs_shown, not with n_errs_found.
Using n_errs_shown allows the user to stop on an error
  identified in a previous run by counting errors shown.
* shows also n_errs_shown in monitor command v.info n_errs_found
* slightly clarified the manual, updated to new output of v.info n_errs_found



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12388
2012-02-15 22:29:30 +00:00
Florian Krohm
f35aec3ffd Announce bug fix.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12387
2012-02-15 04:05:52 +00:00
Florian Krohm
ea211346f8 Use LC_ALL=C for a controlled environment.
Patch by zzam@gentoo.org. Fixes #294055.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12386
2012-02-15 03:57:27 +00:00
Florian Krohm
1900c241eb Wire up a few more syscalls.
Patch by Christian Borntraeger (borntraeger@de.ibm.com).


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12385
2012-02-15 03:32:50 +00:00
Philippe Waroquiers
913ae97e07 * fix Bug 290655 - Add support for AESKEYGENASSIST instruction
(Valgrind part : test for AES instructions (AESKEYGENASSIST, AESIMC,
  AESENC, AESENCLAST, AESDEC, AESDECLAST).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12384
2012-02-14 21:35:46 +00:00
Julian Seward
036b1a4105 Change the garbage collection policy for the secondary VBit table
(that holds partially defined bytes), to GC more aggressively.
Details in the comments.  This largely avoids a sometimes massive
space leak, that has been observed (eg) running the Firefox test suite
on Memcheck.  Without this patch it cannot complete with 4 million
nodes in the table; with the patch it completes comfortably with 50000
ish nodes.  This reduces the total memory use needed for the run
from above 7GB down to 6.2GB.

Smaller improvements have been seen with other programs too.  Speed
does not appear to be negatively affected.

(Based on a patch, and analysis of the problem, by Philippe Waroquiers.)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12383
2012-02-14 12:11:47 +00:00
Bart Van Assche
eeeebbb33a Update Subversion ignore list
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12382
2012-02-13 08:50:32 +00:00
Bart Van Assche
6c7e4024f0 nightly build: Run nightly build also if only VEX has been modified. Check out matching revisions of Valgrind and VEX instead of using latest VEX when checking out the (today - 1) source code.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12381
2012-02-13 08:47:51 +00:00
Tom Hughes
3925f2d664 Only mark data which has actually been filled in by recvmsg as defined.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12380
2012-02-10 16:45:01 +00:00
Tom Hughes
b7ec723aa8 Improve messages for mmsg calls.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12379
2012-02-10 11:54:16 +00:00
Tom Hughes
3e8d8f5087 Correct system call name.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12378
2012-02-10 11:50:36 +00:00
Tom Hughes
0080aa8368 It turns out sendmmsg also updates the msg_len fields.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12377
2012-02-10 11:48:01 +00:00
Tom Hughes
baec53c5f1 Add support for the sendmmsg and recvmmsg system calls. Fixes BZ#277779.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12376
2012-02-10 11:30:09 +00:00
Tom Hughes
dc42e147f5 Add support for some SCSI ioctls. Patch from Jakub Jelinek on BZ#292627.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12375
2012-02-10 10:41:07 +00:00
Tom Hughes
74eb6fb3b4 Add support for process_vm_readv and process_vm_writev system calls.
Patch from Lénaïc Huard to fix BZ#292995.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12374
2012-02-10 09:39:37 +00:00
Tom Hughes
7104ded0a5 Add support for the F_GETOWN_EX and F_SETOWN_EX fcntl calls.
Patch from Jakub Jelinek to fix BZ#292626.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12373
2012-02-09 12:21:47 +00:00
Tom Hughes
09d83bf60b Implement the getcpu vsyscall on amd64 by forwarding it to the real
system call. Patch from Lénaïc Huard to fix BZ#187043.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12372
2012-02-09 11:54:16 +00:00
Tom Hughes
4c37a67dde Wire up getcpu on amd64. Patch from Lénaïc Huard to close BZ#292993.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12371
2012-02-09 11:48:28 +00:00
Tom Hughes
f65fa07cc9 Update linux system call lists.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12370
2012-02-09 11:38:10 +00:00