VG_MINIMAL_SETJMP and VG_MINIMAL_LONGJMP introduced in r12067.
With this commit, it should be possible to build a working 64 bit
Valgrind using the default gcc as supplied with Xcode 4.1 on OSX 10.7.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12070
VG_MINIMAL_LONGJMP directly, rather than using __builtin_setjmp
and __builtin_longjmp, since clang-2.9 miscompiles the latter
(by completely ignoring it.)
Also, add comment about the return type for VG_MINIMAL_SETJMP.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12067
* configure.in support
* new supp file darwin11.supp
* comment out many intercepts in mc_replace_strmem.c and
vg_replace_malloc.c that are apparently unnecessary for Darwin
* add minimal handling for the following new syscalls and mach traps:
mach_port_set_context
task_get_exception_ports
getaudit_addr
psynch_mutexwait
psynch_mutexdrop
psynch_cvbroad
psynch_cvsignal
psynch_cvwait
psynch_rw_rdlock
psynch_rw_wrlock
psynch_rw_unlock
psynch_cvclrprepost
* wqthread_hijack on amd64-darwin: deal with
tst->os_state.pthread having an apparently different offset,
which caused an assertion failure
* m_debuginfo: for 32 bit processes on Lion, use the DebugInfoFSM
cleanup added in r12041/12042 to handle apparently new dyld
behaviour, which is to map text areas r-- first and only
vm_protect them later to r-x.
The following cleanups remain to be done
* remove apparently pointless, commented out wrapper macro
invokations in mc_replace_strmem.c, eg
//MEMMOVE(VG_Z_DYLD, memmove)
(or determine that they are still necessary, and uncomment)
* ditto in vg_replace_malloc.c, plus general VGO_darwin cleanups
there
* write proper syscall wrappers for
mach_port_set_context
task_get_exception_ports
getaudit_addr
psynch_mutexwait
psynch_mutexdrop
psynch_cvbroad
psynch_cvsignal
psynch_cvwait
psynch_rw_rdlock
psynch_rw_wrlock
psynch_rw_unlock
psynch_cvclrprepost
These are currently just no-ops and may be causing Memcheck to
report false undef-value errors
* figure out why it doesn't work properly unless built with gcc-4.2 on
Lion.
gcc-4.2 is the "normal" gcc (i686-apple-darwin11-gcc-4.2.1). Plain
gcc is the hybrid gcc-front-end clang-back-end thing
(i686-apple-darwin11-llvm-gcc-4.2). Whereas on Snow Leopard, plain
gcc is the normal gcc.
The symptoms of the failure are that wqthread_hijack in
syswrap-amd64-linux.c hits this /*NOTREACHED*/ vg_assert(0); right
at the end (you need a pretty complex threaded app to trigger this),
which makes me think that either ML_(wqthread_continue_NORETURN) or
call_on_new_stack_0_1 do return, which they are not expected to.
* figure out if some of the uninitialised value errors reported in
system libraries on are caused by Memcheck being confused by LLVM
generated code, as per bug #242137
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12043
functions to include the ability to give a priority to each function,
as well as a tag indicating its behavioural class. Add logic in
m_redir.c to resolve conflicting redirections with the same eclass but
different priorities by preferring the redirection with the higher
priority. Use all of the above in mc_replace_strmem.c, to cause a
conflict between redirections for "memcpy" and "memcpy@GLIBC_2.2.5" to
be resolved in favour of the latter (the non-overlap-checking
version).
This is all related to the massive swamp that is #275284.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11991
memcpy/memmove redirection stopped working in glibc 2.14/x86_64), but
don't fix the problem yet. Should be no end-user visible change.
* in m_redir.c, when processing redirection specifications, consider
all the names associated with an address, not just the primary name.
* add plumbing to support the notion of "behavioural equivalence class
tags" of redirect/wrap functions. These can be used by m_redir to
resolve some situations in which the available set of redirect
specifications causes some address to get redirected to two
different functions. (Framework is in place, but such resolution is
not implemented yet.)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11984
with only one symbol. Instead, allow an address to have arbitrarily
many names. This reflects reality better, particularly for systemy
libraries such as glibc and ld.so, and is background work needed for
fixing #275284. This is not in itself a fix for #275284. A followup
commit to un-break compilation on OSX will follow shortly.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11981
VALGRIND_{DISABLE,ENABLE}_ERROR_REPORTING, which allow a thread to
temporarily disable reporting of errors it makes. This is useful for
making Memcheck behave sanely in the presence of some MPI
implementations. Also mark up libmpiwrap.c accordingly.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11910
* performance and scalability improvements
* show locks held by both threads in a race
* show all 4 locks involved in a lock order violation
* better delimited error messages
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11824
--vgdb-error=N is specified, print a bit of text telling the user the
magic commands to give GDB in order to attach to the process.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11822
perf_event_open some time after we added it, so correct the name
wherever it appears to match the current kernel source.
Also fixup the PRE handler to do the check correctly, using the
size field of the structure to work out how much data there is.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11804
swapping the roles of the VALGRIND_DO_CLIENT_REQUEST() and
VALGRIND_DO_CLIENT_REQUEST_EXPR() macros. Also, many __attribute__((unused))
declarations on variables have been eliminated. Closes#269778.
Note: so far this patch has been tested on x86/Linux, amd64/Linux and
ppc64/Linux but not yet on any other supported CPU/OS combination.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11755
and not doing so leads to compiler warnings for functions that tail
call this one, which themselves are marked "attribute noreturn".
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11732
for ppc32-linux, that works for gcc >= 4.4. Related to #259977.
(modified version of patch from Maynard Johnson <maynardj@us.ibm.com>)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11689
__builtin_setjmp and __builtin_longjmp so that they can be selectively
replaced, on a platform by platform basis. Does not change any
functionality. Related to #259977.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11687
side components. (Florian Krohm <britzel@acm.org> and Christian
Borntraeger <borntraeger@de.ibm.com>). Fixes#243404.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11604
VG_(newSizedXA)) since r11571 removes the only use of the
functionality that r11568 introduces.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11573
identical to VG_(newXA) but allows passing in a size hint. In the
case where the likely final size of the XArray is known at creation
time, this allows avoiding the repeated (implicit) resizing and
copying of the array as elements are added, which can save a vast
amount of dynamic memory allocation turnover.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11568
don't assert in their regtests on ARM. (Value is the same in both
ARM and Thumb mode, fortunately.)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11432
bug 243270 comments 47 and 48:
* use __builtin_dwarf_cfa(), not __builtin_frame_address(0), to get the CFA
* use correct register specifier in VALGRIND_CFI_PROLOGUE
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11416
by disabling creation of .cfi directives on Darwin, until such time
as someone can figure out how to do this.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11407