Commit Graph

9523 Commits

Author SHA1 Message Date
Philippe Waroquiers
ff24dfeb57 Some updates in release-HOWTO.txt
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12816
2012-08-02 21:01:13 +00:00
Julian Seward
dc0ca811ec Un-break the build on OSX < 10.8 following r12814
(which was initial OSX 10.8 support)


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12815
2012-08-02 18:51:51 +00:00
Julian Seward
f0c0f9f3ce Add initial support for MacOSX 10.8. Note this is still very borked
and pretty much unusable for real work.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12814
2012-08-02 18:25:04 +00:00
Julian Seward
0b3c2d6642 Back out r12466, which stopped non-MAP_FIXED mmaps by the client on
Darwin from returning address zero (however insane that is).  r12466
appears to cause other applications to break (TextEdit, for one).


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12813
2012-08-02 10:40:31 +00:00
Tom Hughes
a5ee19625f Add BZ#304054 to NEWS.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12812
2012-08-02 09:26:38 +00:00
Tom Hughes
bd2c11aa99 Ensure CALL_FN_xx macros align the stack properly
The CALL_FN_xx macros  in valgrind.h perform function calls by
signalling to valgrind using the client request system. Because
they are making function calls which are invisible to the compiler
they need to make sure that any stack alignment constraints
imposed by the ABI are enforced when making the call.

This commit enforces 16 byte alignment for x86, amd64, ppc32 and
ppc64 platforms, and 8 byte alignment for arm platforms.

It does not touch s390x where the ABI requires 8 byte alignment to
be maintained at all times, not just when making a function call.

It also does not touch mips32 as I'm not currently aware what if
any alignment constraints exist there.

Fixes BZ#304054 and observed alignment faults on amd64 when running
the regtests using a valgrind compiled with gcc 4.7 releases.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12811
2012-08-02 09:23:45 +00:00
Philippe Waroquiers
a3a7ba3ebf Avoid asserting when a segment is mapped both rw and rx.
If a segment is mapped with permission rwx, then map->rx
and map->rw will be true.
But due to the if (map->rx) {
                 ...
               } else if (map->rw) {
                 ...
the  (map->rw) part will not be executed.
If this mapping is the one which "gives" the nonempty rw map,
then this mapping will not be seen, and the following
vg_assert(has_nonempty_rw);
will fail.

This assert can be reproduced by doing
setarch i686 -X
./vg-in-place --tool=none none/tests/map_unmap

Note: the setarch i686 -X above has as effect to make all read
mapping also executable. So, a rw mapping becomes rwx and then
triggers the above asserts.

The setarch i686 -X also introduces a discrepancy between
the kernel mappings (rwx) and the valgrind aspacemgr view
(which believes it is a rw mapping).
This discrepancy causes a crash if giving --sanity-level=3.
A possible fix is to have valgrind calling the personality system call
and detecting if the READ_IMPLIES_EXEC bit (the -X arg to setarch)
was set, and then modify aspacemgr so that all read mapped segments
are automatically mapped x also.

This commit is the minimal fix allowing to run executables
launched with this READ_IMPLIES_EXEC.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12810
2012-08-01 22:27:29 +00:00
Philippe Waroquiers
36ca11463d Remove --vex-iropt-precise-memory-exns, implement --vex-iropt-register-updates
* Option --vex-iropt-precise-memory-exns has been removed.
  It is replaced by --vex-iropt-register-updates which accepts
  3 values : 'unwindregs-at-mem-access' (replacing
  --vex-iropt-precise-memory-exns=no), 'allregs-at-mem-access'
  (replacing --vex-iropt-precise-memory-exns=yes)
  and a new value 'allregs-at-each-insn'.
  'allregs-at-each-insn' allows the Valgrind gdbserver to always
  show up to date values to GDB.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12809
2012-08-01 22:03:12 +00:00
Julian Seward
63da47e2c2 Add test cases for "VCVT.F32.{S,U}32 S[d], S[d], #frac_bits"
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12808
2012-08-01 22:01:05 +00:00
Philippe Waroquiers
d045b4236a Implement --redzone-size and --core-redzone-size
* For tools replacing the malloc library (e.g. Memcheck, Helgrind, ...),
  the option --redzone-size=<number> allows to control the padding 
  blocks (redzones) added before and after each client allocated block.
  Smaller redzones decrease the memory needed by Valgrind. Bigger
  redzones increase the chance to detect blocks overrun or underrun.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12807
2012-07-31 22:17:28 +00:00
Florian Krohm
572800ce5a Remove entries with deprecated spellings (essentially duplicates).
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12806
2012-07-30 16:18:19 +00:00
Florian Krohm
bf20eec2a1 When parsing guest_s390_toIR.c also recognize opcodes with digits
in their name.
Also add more alternate opcode spellings.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12805
2012-07-30 16:16:24 +00:00
Florian Krohm
3630d97fcf Testcases for CU42. Part of fixing bugzilla #289839.
Update opcode table.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12804
2012-07-28 22:20:03 +00:00
Florian Krohm
b7b54defa7 Updates for s390x
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12803
2012-07-28 22:10:41 +00:00
Florian Krohm
d073e8f615 Minor tweaks. A few comments were out of synch with source.
Add another test.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12802
2012-07-28 21:59:34 +00:00
Florian Krohm
793d6da89c Fix error message in testcase
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12801
2012-07-28 20:39:51 +00:00
Bart Van Assche
6c92e97588 drd: Avoid that invoking pthread_cancel() from a program analyzed with DRD triggers a crash on Fedora 17
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12800
2012-07-28 14:35:48 +00:00
Bart Van Assche
24d9acaac7 drd: Revert r12651 because it didn't change drd's behavior on any platform
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12799
2012-07-28 14:32:03 +00:00
Bart Van Assche
e0b75e7c95 Spelling fixes: developpers -> developers; curiosly -> curiously
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12798
2012-07-28 13:06:45 +00:00
Bart Van Assche
c94aeb7469 Update Subversion ignore list
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12797
2012-07-28 13:05:32 +00:00
Philippe Waroquiers
f5a8694d7b clarify 2 NEWS entries to indicate that these are for tool developpers.
(NB: I am wondering if these entries should be put in NEWS at all.
Is NEWS targetted at end users only ?
Or at "tool developper users also' ?)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12796
2012-07-28 12:23:48 +00:00
Bart Van Assche
e1927cde20 none/tests/amd64/Makefile.am: Uses not only AVX instructions but PCLMULQDQ too
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12795
2012-07-28 11:13:47 +00:00
Petar Jovanovic
0717c59552 MIPS specific expected output for memcheck/tests/sigkill.
MIPS has different signal values, so it has to have its own expected output for
the tests that deal with signal values.
This fixes (false) failure in memcheck/tests/sigkill.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12794
2012-07-27 22:35:35 +00:00
Philippe Waroquiers
7685c36a5e Have one test testing the ? suppr matching wildcard character.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12793
2012-07-27 21:56:08 +00:00
Florian Krohm
0e3bd988be Fix compiler warning.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12792
2012-07-27 20:53:47 +00:00
Petar Jovanovic
ae2aec93f0 MIPS specific exp-out for none/tests/async-sigs.
MIPS has different signal values, so it has to have its own expected output for
the tests that deal with signal values.
This fixes (false) failure in none/tests/async-sigs.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12791
2012-07-27 16:25:32 +00:00
Philippe Waroquiers
499d4754d0 micro-optimisation in m_libcbase.c cmp functions
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12790
2012-07-26 22:44:07 +00:00
Philippe Waroquiers
90fa385006 Improve suppression matching performance when fun or obj is a simple string
Idea is from Julian, possible bugs are mine.

If the fun or obj is a simple string and not a patter (so no *, no ?),
use a simple string comparison rather than a call to a wildcard matching.

On a leak search with a lot of reachable loss records and a lot of suppr,
it improves the speed of the leak search by 10 to 15%.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12789
2012-07-26 21:37:36 +00:00
Bart Van Assche
e9a1dc1962 none/tests/amd64/pcmpstr64: Update expected output after r12780
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12788
2012-07-26 06:49:38 +00:00
Florian Krohm
2d5ecc012c Due to s390's dealings with invalid insns we need to do two things
- advance the guest_IA to the next insn after raising the signal
- adjusting the address in a complaint to point to the failing insn
  (after guest_IA has been advanced)
Update testcases .exp files.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12787
2012-07-26 02:41:31 +00:00
Florian Krohm
203ba59aaa Apply first_ip_delta also when only one frame is requested
for the back-trace.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12786
2012-07-26 02:14:28 +00:00
Florian Krohm
1709090cc8 Improve complaints. Enabled by VEX r2449.
Line numbers are still bad. But that is a GCC issue.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12785
2012-07-26 02:03:16 +00:00
Philippe Waroquiers
b30612fef7 re-re-clarify the doc about registers and flags gdbsrv up-to-date-ness
Following discussions on valdev and re-measurement, clarify the clarification.




git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12784
2012-07-25 21:58:40 +00:00
Philippe Waroquiers
fba5e95cd9 remove 303624 from 3_7_BUGSTATUS.txt (was fixed in rev 12758, already in NEWS)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12783
2012-07-25 19:58:37 +00:00
Josef Weidendorfer
6eaedfc09e Added fixed bug 303963
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12782
2012-07-25 12:13:29 +00:00
Julian Seward
ffcff15682 Partial update of bug fixes (I think it is still out of date though.)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12781
2012-07-25 11:02:01 +00:00
Josef Weidendorfer
d09681ca70 Additions to PCMPxSTRx tests to check fix for bug 303963.
Some tests used movdqa triggering a seg fault. Use movdqu instead.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12780
2012-07-25 09:49:26 +00:00
Florian Krohm
58e19c0bd3 Fix testcase and update results.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12779
2012-07-24 20:37:50 +00:00
Philippe Waroquiers
668df8d006 Better document the limitation of gdbsrv for registers and flags values
During investigations of 303963, Josef found that flags are not always
up to date and that --vex-guest-max-insns=1 ensures flags values
are (more?) correct.

=> enhance the paragraph in the gdbserver limitations to reference
this option and give an idea of the performance impact of the other
options helping to increase the precision of registers and flags.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12778
2012-07-24 20:24:39 +00:00
Philippe Waroquiers
244ccd72d3 Have perf/vg_perf handling EXTRA_REGTEST_OPTS
Similarly to tests/vg_regtest, allow to run all perf tests with extra options.
(note: it was preferred to use the same env var name).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12777
2012-07-24 19:47:46 +00:00
Florian Krohm
068a951cf7 Update expected results.
This is the companion patch to VEX r2444 which backs out the special
handling for the 00 opcode.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12776
2012-07-23 18:05:52 +00:00
Florian Krohm
e9a06dcf87 Pass first_ip_delta to VG_(record_depth_1_ExeContext) as the function
cannot figure it out by itself.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12775
2012-07-23 15:40:41 +00:00
Florian Krohm
b6d2730e1c Eliminate magic constant. Use VG_(clo_backtrace_size) instead.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12774
2012-07-23 15:05:22 +00:00
Petar Jovanovic
89c5f88c45 Avoid checking for bitset initialization if futex_wait_bitset is meant to fail.
Glibc deliberately passes random value for the sixth parameter when calling
FUTEX_WAIT_BITSET | FUTEX_CLOCK_REALTIME. This is a regular case of using the
Futex API, so V should not complain that "Syscall param futex(val3) contains
uninitialised byte(s)", if the futex does not have a specified value initially.
For more info, see function pthread_initialize_minimal_internal at:
glibc/nptl/nptl-init.c.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12773
2012-07-23 00:11:10 +00:00
Julian Seward
c7048d5921 Add 'aesdec' to the set of insns checked for assembler level SSE4.2
support (Rich Coe) and tidy up a couple of other bits of assembly by
giving them trashed-register lists.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12772
2012-07-22 11:10:08 +00:00
Florian Krohm
da2bfe57dc Add testcases for CU24. Part of fixing #289839.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12771
2012-07-21 17:42:54 +00:00
Julian Seward
b28dc65ac6 No need to list m_gdbserver.c twice in the Makefile.am.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12770
2012-07-21 10:11:51 +00:00
Julian Seward
e7e5f7c6fe Localise "struct reg regs[]".
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12769
2012-07-21 10:10:44 +00:00
Julian Seward
1e2d0f70ac ppc64-linux _start: don't assume ._start_in_C_linux -- the function
descriptor for _start_in_C_linux -- actually exists.  Instead call the
entry point directly.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12768
2012-07-21 10:08:29 +00:00
Philippe Waroquiers
9f4932eeec Document Helgrind limitation that old access stack traces have maximum 8 entries
#define N_FRAMES 8
(defined in libhb_core.c:3888)

implies that 'other thread' stack traces are limited to 8,
even with a bigger --num-callers.

=> document this in the manual to avoid that a user believes this is a
bug in the stack trace logic of Valgrind.




git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12767
2012-07-20 23:40:35 +00:00