Commit Graph

10207 Commits

Author SHA1 Message Date
Carl Love
f356faf958 Oops, forgot to add the new files before the commit for r13534.
Bugzilla 324518

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13535
2013-09-05 21:22:37 +00:00
Carl Love
bbe72ab090 The current VEX code is not properly handling a non-zero TH field in the
dcbt instruction, which is valid for several forms of data cache block
touch instructions.  The VEX commit 2761 fixed the missing support in
VEX/priv/guest_ppc_toIR.c.  This commit adds tests for the the non-zero
fields to the test cases for 32 and 64-bit modes.

Bugzilla 324518

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13534
2013-09-05 19:50:41 +00:00
Carl Love
e3568e0210 The flag for compiling test none/tests/ppc32/test_isa_2_07_part2.c was
incorrectly set to FLAG_M64 instead of FLAG_M32.  Fixed the flag.  The 
issue was reported in Bugzilla 324546.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13533
2013-09-05 17:59:03 +00:00
Philippe Waroquiers
6e3bb2af58 Fix 324514 gdbserver monitor cmd output behaviour consistency + allow user
to put a "marker" msg in process log output

* v.info n_errs_found accepts optional msg, added in the output of
   the monitor command.

* use VG_(printf) rather than VG_(gdb_printf) when output of command
  should be redirected according to v.set gdb_output|log_output|mixed_output

* also avoid calling gdb_printf in output sink processing
  to output zero bytes, as gdb_printf expects to have a null terminated
  string, which is not ensured when 0 bytes have to be output.

* some minor reformatting (replace char* xxx by char *xxx).




git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13532
2013-09-04 21:42:43 +00:00
Julian Seward
fa7163e50f Add a bunch of suppressions for 64-bit OSX 10.8 processes. This is a
huge kludge in that the right fix is to write proper syscall wrappers
for the new threading syscalls in 10.8, but that hasn't happened yet.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13531
2013-09-04 07:32:48 +00:00
Julian Seward
1e4c2d926b PRE(workq_ops): handle KI_WQOPS_QUEUE_REQTHREADS without complaining.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13530
2013-09-04 07:31:10 +00:00
Julian Seward
d13136fcee check_uuid_matches: fix infinite loop following rewrite of this
function during big overhaul of the debuginfo reader earlier this
year.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13529
2013-09-04 06:17:44 +00:00
Mark Wielaard
363d971e32 Reuse (shared) cachegrind source files in callgrind directly.
The callgrind Makefile.am had a common sources list that included
../cachegrind/cg_arch.c. This doesn't play well with automake and
subdir-objects. Especially make distclean was broken because some
.deps files were removed multiple times.

Just include the shared source file directly into the callgrind
source file that needs it (cg_arch.c in sim.c).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13528
2013-09-03 15:22:14 +00:00
Julian Seward
5d7649ffe9 Rename cg-arch.c to cg_arch.c so as to be consistent with other
filenames, including cg_arch.h :)  No functional change.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13527
2013-09-03 08:39:28 +00:00
Dejan Jevtic
63d3dd8351 mips32/mips64: Add tests for lwl and lwr for mips32 and mips64.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13526
2013-09-02 15:35:12 +00:00
Julian Seward
c09895b8e3 MacOS only: fix somee compiler complaints about casting from pointers
and integers of a different size.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13525
2013-09-02 13:36:25 +00:00
Julian Seward
47dbd5a4ca Fixes and kludges (mostly the latter) needed to run graphical
apps on	  OSX 10.8:

* port_create_vanilla: deal with the fact that ports get looked
  up before they get registered in the allocated_ports list.  I
  think this is	 a side effect of ..

* .. various syscalls: add stub (no-op) wrappers



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13524
2013-09-02 13:07:16 +00:00
Julian Seward
187c2be40d Make wqthread_hijack work with the OSX 10.8 kernel.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13523
2013-09-02 13:02:58 +00:00
Julian Seward
a89859bded add_mapping_callback on Darwin: also produce a ChangedSeg record in
the case where V's record of the permissions for a range differs from
that of the kernel's.  The lack of this caused synthetic segfaults
("can't translate here") from m_translate on OSX 10.8 for pretty much
any graphical .



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13522
2013-09-02 13:02:02 +00:00
Julian Seward
a93f4ff9c9 Rename configure.in to configure.ac to make more recent auto*s happy,
and also add the automake option "subdir-objects".  As advisde by
Tromey and Mjw.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13521
2013-09-02 12:44:52 +00:00
Florian Krohm
6855a0a148 s390: Fix Makefile.am. Essentially, revert r13317 which does not seem to
be necessary. The additional DIST_INSN_TESTS variable was causing problems
in check_makefile_consistecy which reported false errors. I suspect this
is because my awk is mawk and not gawk.
Also add dfp_utils.h which was missing in the tarball from 'make dist'.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13520
2013-08-31 16:02:15 +00:00
Philippe Waroquiers
a44190db93 Fix misleading comment, as VG_(releasePA) is deleting the PA when zero ref count
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13519
2013-08-30 15:48:16 +00:00
Florian Krohm
c5fd4773ed Add missing headers and such so that 'make dist' works again.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13518
2013-08-29 17:59:27 +00:00
Dejan Jevtic
6fa3517d39 mips64: Add some test cases for mips64 in vbit-test.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13517
2013-08-28 10:03:45 +00:00
Florian Krohm
089f1ef803 When XML mode is selected messages from VALGRIND_PRINTF and friends
should go to the XML stream not stderr.  Fixes BZ 322807.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13516
2013-08-27 15:17:53 +00:00
Mark Wielaard
acbf92d975 Support mmxext (integer sse) subset on i386 (athlon). Bug #323713
Some processors like the AMD Athlon "Classic" support mmxext,
a sse1 subset. This subset is not properly detected by VEX.
The subset uses the same encoding as the sse1 instructions.

The subset is described at:
  http://support.amd.com/us/Embedded_TechDocs/22466.pdf
  https://en.wikipedia.org/wiki/3DNow!#3DNow.21_extensions

Detects mmxext subset from cpuid information (and enables it
when full sse1 is found). Also fixes the prereq of
none/tests/x86/insn_mmxext.vgtest so that it also runs when
full sse1 (and not just the mmxext subset) is found.
It already passed on such configurations. With the VEX patch
(r2745) it also passes with just the mmxext subset.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13515
2013-08-27 10:23:23 +00:00
Mark Wielaard
25212a2525 Test cases for 128-bit --partial-loads-ok=no|yes on x86 need a prereq on sse.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13514
2013-08-27 10:16:21 +00:00
Bart Van Assche
045b8ab23e valgrind.h: Add MinGW64 support
From: Makoto Kato <m_kato@ga2.so-net.ne.jp>


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13513
2013-08-25 06:10:24 +00:00
Bart Van Assche
4b22f8042d Update Subversion ignore lists
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13512
2013-08-24 18:00:27 +00:00
Bart Van Assche
038beeccc0 drd: Fix bug #323905
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13511
2013-08-24 17:53:00 +00:00
Bart Van Assche
de32048275 coregrind/m_debuginfo: Add VG_(DebugInfo_get_bss_avma)() and VG_(DebugInfo_get_bss_size)()
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13510
2013-08-24 17:52:26 +00:00
Bart Van Assche
46135647c9 drd: Add command-line option --trace-sectsuppr
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13509
2013-08-24 17:51:18 +00:00
Bart Van Assche
d73260d5b0 drd/tests/concurrent_close: Add
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13508
2013-08-24 17:50:38 +00:00
Dejan Jevtic
420374fad9 mips32: Fix a problem with gdb invoker.
This patch fixes the endian issue with gdb invoker on mips32
big endian. Now we are using pointer to long long and
we don't need to sign extend registers. On mips32 o32 abi
we need to make extra stack space when we are calling
function.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13507
2013-08-22 06:04:08 +00:00
Carl Love
5ee7af623f The file tests/ppc32/power_ISA2_05.stdout.exp_Without_FPPO was a link
to file tests/ppc64/power_ISA2_05.stdout.exp_Without_FPPO.  That was a 
commit error as the output for ppc32 and ppc64 are different.  Replaced
the link with the correct real file of expected results.  See bugzilla
81535.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13506
2013-08-21 19:47:19 +00:00
Carl Love
75b1670dcb The file tests/ppc32/power_ISA2_05.stdout.exp_Without_FPPO was a link
to file tests/ppc64/power_ISA2_05.stdout.exp_Without_FPPO.  That was a 
commit error as the output for ppc32 and ppc64 are different.  Remove
the file and commit to remove the link.

See bugzilla 81535.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13505
2013-08-21 19:46:50 +00:00
Mark Wielaard
4c915d378b Accept glibc 2.18 as valid.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13504
2013-08-21 14:47:52 +00:00
Julian Seward
2cdb43b1fe Minor tidying of the generalised V128/V256 shadow helper returns
that landed in r13500.  No functional change.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13503
2013-08-18 10:20:22 +00:00
Julian Seward
4e8daaee05 Make sure that sh-mem-vec256 is only built on platforms that can
assemble the relevant instructions.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13502
2013-08-18 10:00:59 +00:00
Julian Seward
423678ee8a Add test cases for 256-bit --partial-loads-ok=no|yes, by generalising the
128-bit versions.  (Patrick J. LoPresti, lopresti@gmail.com).  Bug 294285.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13501
2013-08-16 08:34:10 +00:00
Julian Seward
cd24a631d9 Add support for direct V256 shadow helper returns -- memcheck side.
(Patrick J. LoPresti, lopresti@gmail.com).  Bug 294285.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13500
2013-08-16 08:31:29 +00:00
Julian Seward
535aed86cd Avoid a compiler warning.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13499
2013-08-15 21:18:21 +00:00
Florian Krohm
dc73345601 Followup to VEX r2742 which eliminates IRExprP__VECRET and IRExprP__BBPTR
and adds Iex_VECRET and Iex_BBPTR.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13498
2013-08-15 20:55:42 +00:00
Dejan Jevtic
7ad5daf816 mips32: Delete unnecessary exp files.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13497
2013-08-15 13:48:28 +00:00
Dejan Jevtic
47e3a1b8a7 mips32/mips64: Fix compiler warnings.
Fix some compiler warnings when compiling Valgrind for mips32/mips64.
Clean up exp files for mips32 BE and LE.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13496
2013-08-15 13:37:29 +00:00
Philippe Waroquiers
4d8ec8f74a kludge to bypass inner valgrind mmap failing due to not observed outer mmap
Some tests are failing in an "outer/inner" setup with an "out of memory"
situation reported by the inner (e.g. memcheck/tests/err_disable4.vgtest).

Looks like this is because the inner valgrind aspacemgr believes
a segment is free and can be used, but segment is in fact used by the outer.
This can happen as the inner cannot observe the outer mmap, and so
inner aspacemgr can be out of sync with the kernel and the outer.

This kludge bypasses the problem: if the fixed mmap fails in the inner,
the inner retries without the fixed.
This is a kludge as the proper solution would be to have a correct
state of aspacemgr in the inner. This however implies a more in-depth surgery
in the outer/inner setup (to have e.g. the outer informing the inner of
its own mmap or alternatively having the inner asking the outer about the
mmap advisory).

Kludge is preferred (at least now) as this kludge is activated only
for the inner (and for darwin, but that was already like that).

Of course, this kludge does not the state of the inner aspacemgr
matching the outer and kernel state.
So, other problems might be detected e.g. if inner aspacemgr does a check
comparing its status with kernel status.

The patch also ensures the inner reports the memory status of the
outer (using a client request) when an out of memory situation is detected.
This helps understanding what goes wrong.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13495
2013-08-12 22:17:47 +00:00
Carl Love
95d8477491 Initial ISA 2.07 support for POWER8-tuned libc
The IBM Power ISA 2.07 has been published on power.org, and IBM's new POWER8
processor is under development to implement that ISA. This patch provides
initial runtime and testsuite support for running Valgrind on POWER8 systems
running a soon-to-be released Linux distribution. This Linux distro will
include a POWER8-tuned libc that uses a subset of the new instructions from
ISA 2.07.  Since virtually all applications link with libc, it would be
impossible to run an application under Valgrind on this distro without adding
support for these new instructions to Valgrind, so that's the intent of this
patch. Note that applications built on this distro will *not* employ new POWER8
instructions by default. There are roughly 150 new instructions in the Power
ISA 2.07, including hardware transaction management (HTM). Support for these
new instructions (modulo the subset included in this bug) will be added to
Valgrind in a phased approach, similar to what we did for Power ISA 2.06.

Bugzilla 322294, VEX commit 2740

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13494
2013-08-12 18:04:22 +00:00
Julian Seward
7665cd062f Add test cases for 128-bit shadow loads with
--partial-loads-ok={yes,no} for x86 targets.  Bug #294285.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13493
2013-08-12 16:10:38 +00:00
Julian Seward
97b2e2d175 * rename the memcheck/tests/amd64/sh-mem-vec128*stderr.exp* files
so as to specify an endianness
* add two missing symlinks


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13492
2013-08-12 11:47:52 +00:00
Julian Seward
2666efe140 Add test cases for 128-bit shadow loads with --partial-loads-ok={yes,no}
in such a way that they can be shared across targets that support 128 bit
loads, as required.  amd64 only right now.  Adds memcheck/tests/common
to hold this stuff.  Bug #294285.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13491
2013-08-12 10:42:49 +00:00
Carl Love
2313dbf69e The following instructions were introduced in the Power ISA 2.05
(i.e., POWER6) - lfdp - stfdp - lfdpx - stfdpx These instructions were promptly
deprecated (phased out) in ISA 2.06 (i.e., POWER7). Recent updates in binutils
no longer supports these instructions unless the assembler is invoked with
'-mpower6'. When 'make check' is run on valgrind when using such a newer
binutils and running on a ppc64 system newer than POWER6, you get the
following build error:
y
pc64_linux=1 -DVGPV_ppc64_linux_vanilla=1 -DVGA_SEC_ppc32=1 -DVGP_SEC_ppc64_linux=1 -Winline -Wall -Wshadow -g -Winline -Wall -Wshadow -g -I../../../include -m64 -Wno-long-long -Wwrite-strings -fno-stack-protector -Wno-write-strings -MT power_ISA2_05-power_ISA2_05.o -MD -MP -MF .deps/power_ISA2_05-power_ISA2_05.Tpo -c -o power_ISA2_05-power_ISA2_05.o `test -f 'power_ISA2_05.c' || echo './'`power_ISA2_05.c
/tmp/cciGIkGG.s:Assembler messages:
/tmp/cciGIkGG.s:387: Error: operand out of domain (31 is not a multiple of 4)
/tmp/cciGIkGG.s:387: Error: syntax error; found `,', expected `('
/tmp/cciGIkGG.s:387: Error: junk at end of line: `,9'
/tmp/cciGIkGG.s:478: Error: operand out of domain (31 is not a multiple of 4)
/tmp/cciGIkGG.s:478: Error: syntax error; found `,', expected `('
/tmp/cciGIkGG.s:478: Error: junk at end of line: `,9'
make[2]: *** [power_ISA2_05-power_ISA2_05.o] Error 1
make[2]: Leaving directory `/tmp/Valgrind_review/valgrind_ISA2_05/memcheck/tests/ppc64'
make[1]: *** [check-am] Error 2
make[1]: Leaving directory `/tmp/Valgrind_review/valgrind_ISA2_05/memcheck/tests/ppc64' make: *** [check-recursive] Error 1

This patch fixes the problem by adding a configure check to determine if these
phased out instructions are supported by the binutils, and the result of that
configure check is used to decide whether or not to compile in the source for
testing these instructions.

Bugzilla 323116

committed by Carl Love, carll@us.ibm.com

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13490
2013-08-09 21:55:45 +00:00
Julian Seward
9ae14ce848 A comprehensive test case for 128 bit shadow vector loads in the case
of partial addressibility, for --shadow-loads-ok=yes and =no.  Not
portable and not hooked up to the test/build system yet.

Pertains to #294285.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13489
2013-08-08 10:56:08 +00:00
Julian Seward
f865a853ee Fix # 294285: --partial-loads-ok does not work for 16-byte SSE loads
(core fixes for the memcheck handling of 128 bit loads)
(Patrick J. LoPresti, lopresti@gmail.com)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13488
2013-08-08 10:41:46 +00:00
Julian Seward
4e3134f897 Fix fallout from r13486: "virtual" is a C++ reserved word and so this
header causes breakage in the C++ tests in the tree.  Rename it.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13487
2013-08-08 09:05:37 +00:00
Julian Seward
f7cd4044d5 Add support for a bunch of DRM Ioctls. Fixes #207815.
(Robert Bragg, bob@o-hand.com)


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13486
2013-08-08 08:09:29 +00:00