]> git.ipfire.org Git - thirdparty/valgrind.git/log
thirdparty/valgrind.git
13 years agos390: Remove insns for 128-bit BFP and merge with 32/64-bit. This
Florian Krohm [Mon, 10 Sep 2012 23:44:37 +0000 (23:44 +0000)] 
s390: Remove insns for 128-bit BFP and merge with 32/64-bit. This
eliminates code duplication.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2523

13 years agos390: More prep work bfp reorg. In the future unary/binary/ternary
Florian Krohm [Mon, 10 Sep 2012 03:09:04 +0000 (03:09 +0000)] 
s390: More prep work bfp reorg. In the future unary/binary/ternary
operations on bfp data will no longer require a rounding mode in the
s390_insn. Only type conversion operations need a rounding mode.
So in this patch S390_BFP_CONVERT is introduced and
S390_BFP128_CONVERT_TO/FROM are consolidated to S390_BFP128_CONVERT.
This also makes the representation of bfp and bfp128 symmetric.
s390_insn gets a new variant: s390_convert.
The type conversion ops get their own data type now: s390_conv_t

git-svn-id: svn://svn.valgrind.org/vex/trunk@2522

13 years agovalgrind: Support Xen toolstack process ioctls
Bart Van Assche [Sun, 9 Sep 2012 18:30:17 +0000 (18:30 +0000)] 
valgrind: Support Xen toolstack process ioctls

From: Ian Campbell <Ian.Campbell@citrix.com>

Under Xen the toolstack is responsible for managing the domains in
the system, e.g. creating, destroying, and otherwise manipulating
them.

To do this it uses a number of ioctls on the /proc/xen/privcmd
device. Most of these (the MMAPBATCH ones) simply set things up such
that a subsequenct mmap call will map the desired guest memory. Since
valgrind has no way of knowing what the memory contains we assume
that it is all initialised (to do otherwise would require valgrind to
be observing the complete state of the system and not just the given
process).

The most interesting ioctl is XEN_IOCTL_PRIVCMD_HYPERCALL which
allows the toolstack to make arbitrary hypercalls. Although the
mechanism here is specific to the OS of the guest running the
toolstack the hypercalls themselves are defined solely by the
hypervisor. Therefore I have split support for this ioctl into a part
in syswrap-linux.c which handles the ioctl itself and passes things
onto a new syswrap-xen.c which handles the specifics of the
hypercalls themselves. Porting this to another OS should just be a
matter of wiring up syswrap-$OS.c to decode the ioctl and call into
syswrap-xen.c. In the future we may want to split this into
syswrap-$ARCH-xen.c but for now this is x86 only.

The hypercall coverage here is pretty small but is enough to get
reasonable(-ish) results out of the xl toolstack when listing,
creating and destroying domains.

One issue is that the hypercalls which are exlusively used by the
toolstacks (as opposed to those used by guest operating systems) are
not considered a stable ABI, since the hypervisor and the lowlevel
tools are considered a matched pair. This covers the sysctl and
domctl hypercalls which are a fairly large chunk of the support
here. I'm not sure how to solve this without invoking a massive
amount of duplication. Right now this targets the Xen unstable
interface (which will shortly be released as Xen 4.2), perhaps I can
get away with deferring this problem until the first change .

On the plus side the vast majority of hypercalls are not of interest
to the toolstack (they are used by guests) so we can get away without
implementing them.

Note: a hypercall only reads as many words from the ioctl arg
struct as there are actual arguments to that hypercall and the
toolstack only initialises the arguments which are used. However
there is no space in the DEFN_PRE_TEMPLATE prototype to allow this to
be communicated from syswrap-xen.c back to syswrap-linux.c. Since a
hypercall can have at most 5 arguments I have hackily stolen ARG8 for
this purpose.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12963

13 years agos390: Prepare for bfp reorg. Change the emit functions for the
Florian Krohm [Sun, 9 Sep 2012 18:18:25 +0000 (18:18 +0000)] 
s390: Prepare for bfp reorg. Change the emit functions for the
convert-to-fixed and load-rounded instructions to emit the extended
form. E.g. change s390_emit_CEFBR to s390_emit_CEFBRA. In the future
we will take advantage of those insns if the host's hardware facilities
allow it.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2521

13 years agos390: Add asserts to s390_emit_XYZ functions for convert-to/from-logical.
Florian Krohm [Sun, 9 Sep 2012 18:12:28 +0000 (18:12 +0000)] 
s390: Add asserts to s390_emit_XYZ functions for convert-to/from-logical.
This should have been part of r2496 when those functions were added.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2520

13 years agoRestore unwind regs structure if VG_(use_CF_info) fails on MIPS.
Petar Jovanovic [Sun, 9 Sep 2012 01:56:56 +0000 (01:56 +0000)] 
Restore unwind regs structure if VG_(use_CF_info) fails on MIPS.

If VG_(use_CF_info) fails to find the next frame using loaded debug symbols, it
will still change the data in uregs. Thus, we need to have uregs_copy before
calling VG_(use_CF_info), and restore uregs if the call returns wrong data.
This fixes drd/tests/tc04_free_lock on MIPS.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12962

13 years agoCorrecting how load/store doubles are modelled on MIPS for big-endian.
Petar Jovanovic [Sun, 9 Sep 2012 01:10:59 +0000 (01:10 +0000)] 
Correcting how load/store doubles are modelled on MIPS for big-endian.

One of the previous changes, r2511, was correct for little-endian and introduced
a regression for big-endian MIPS. This corrects the endianness issues.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2519

13 years agos390: Fix another mixup. Did not cause problems due to same
Florian Krohm [Fri, 7 Sep 2012 21:18:42 +0000 (21:18 +0000)] 
s390: Fix another mixup. Did not cause problems due to same
field offset.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2518

13 years agoFix a mixup. This never caused a problem because the fields happened
Florian Krohm [Fri, 7 Sep 2012 15:00:53 +0000 (15:00 +0000)] 
Fix a mixup. This never caused a problem because the fields happened
to have the same offset.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2517

13 years agoUpdate Subversion ignore list
Bart Van Assche [Thu, 6 Sep 2012 14:29:24 +0000 (14:29 +0000)] 
Update Subversion ignore list

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12961

13 years agodrd: Suppress race reports on .got sections too
Bart Van Assche [Thu, 6 Sep 2012 14:08:26 +0000 (14:08 +0000)] 
drd: Suppress race reports on .got sections too

This is a slightly modified version of a patch provided by Petar Jovanovic
<petar.jovanovic@rt-rk.com>.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12960

13 years agoAnnounce bug fix in NEWS.
Florian Krohm [Thu, 6 Sep 2012 03:26:50 +0000 (03:26 +0000)] 
Announce bug fix in NEWS.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12959

13 years agos390: Add a testcase for condition code computation for
Florian Krohm [Thu, 6 Sep 2012 03:22:16 +0000 (03:22 +0000)] 
s390: Add a testcase for condition code computation for
convert-to-fixed. See VEX r2516. Part of fixing bugzilla #306054.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12958

13 years agos390: Fix condition code computation for convert-to-fixed/logical
Florian Krohm [Thu, 6 Sep 2012 03:13:22 +0000 (03:13 +0000)] 
s390: Fix condition code computation for convert-to-fixed/logical
insns. Previously the condition code was computed based on the
to-be-converted value only. But that is not sufficient as testcase
none/tests/s390x/rounding-1 shows. The rounding mode needs to be
considered, too. Therefore, the rounding mode is now stored in the
flags thunk as well (in IRRoundingMode encoding). Note, that this is
done for *all* convert-to-fixed/logical insns. It's possible that some
of them do not need the rounding mode but I did not bother exploring
the fine print. Setting the rounding mode as it was on the incoming
insn certainly will not be detrimental so we can as well do it.
This patch fixes bugzilla #306054.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2516

13 years agos390: The load-rounded insns also need to issue an emulation
Florian Krohm [Wed, 5 Sep 2012 20:05:20 +0000 (20:05 +0000)] 
s390: The load-rounded insns also need to issue an emulation
warning when the floating point extension is not present and
m3 != 0.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2515

13 years agos390: Non-functional change.
Florian Krohm [Wed, 5 Sep 2012 19:54:08 +0000 (19:54 +0000)] 
s390: Non-functional change.
Rename enable_rounding_mode to enable_bfp_rounding_mode in
anticipation of dfp coming. Change its return value to be an
IRTemp which will be handy soon. Fix all call-sites.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2514

13 years agoBinary floating point cleanup. This was an area that was hushed up
Florian Krohm [Wed, 5 Sep 2012 04:19:09 +0000 (04:19 +0000)] 
Binary floating point cleanup. This was an area that was hushed up
a bit when the s390 port was first committed. Time to get it in shape.

This patch
- completes s390_round_t to list all rounding modes that can appear
  in a convert-to instruction
- adapts function encode_rounding_mode accordingly
- ensures that all s390_round_t -> IRRoundingMode conversions go through
  encode_rounding_mode

git-svn-id: svn://svn.valgrind.org/vex/trunk@2513

13 years agoAdd vassert for DFP shift value to make sure shift value is an immediate value.
Carl Love [Tue, 4 Sep 2012 22:09:48 +0000 (22:09 +0000)] 
Add vassert for DFP shift value to make sure shift value is an immediate value.
V-bit tester was putting shift value in a register for the DFP shift
instructions causing the test to crash, see bugzilla #305948.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2512

13 years agoLoad/store doubles on MIPS are modeled through Ity_F64 rather than two Ity_F32.
Petar Jovanovic [Tue, 4 Sep 2012 13:45:42 +0000 (13:45 +0000)] 
Load/store doubles on MIPS are modeled through Ity_F64 rather than two Ity_F32.

This patch changes how the load/store doublewords are modeled on MIPS.
Previously, this was modeled through two Ity_F32s which caused test reports to
be different to expected.
This fixes memcheck/tests/fprw.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2511

13 years agoEnable testing of primops on ARM platforms. (Florian Krohm)
Julian Seward [Mon, 3 Sep 2012 21:59:28 +0000 (21:59 +0000)] 
Enable testing of primops on ARM platforms.  (Florian Krohm)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12957

13 years agoUse "orr r9,r9,r9" as the magic insn for IR injection on ARM and
Julian Seward [Mon, 3 Sep 2012 21:51:02 +0000 (21:51 +0000)] 
Use "orr r9,r9,r9" as the magic insn for IR injection on ARM and
Thumb, since r13 is disallowed for many instructions in the Thumb
encoding.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12956

13 years agoAdd ARM front/back end support for IR injection.
Julian Seward [Mon, 3 Sep 2012 21:48:42 +0000 (21:48 +0000)] 
Add ARM front/back end support for IR injection.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2510

13 years agoUpdate testcase as a followup to VEX r2509.
Florian Krohm [Mon, 3 Sep 2012 17:45:15 +0000 (17:45 +0000)] 
Update testcase as a followup to VEX r2509.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12955

13 years agos390: Undo part of r2501. The "convert to fixed" opcodes always have an m3
Florian Krohm [Mon, 3 Sep 2012 17:41:22 +0000 (17:41 +0000)] 
s390: Undo part of r2501. The "convert to fixed" opcodes always have an m3
field -- independent of the floating point extension facility.
So do not issue an emulation warning for those opcodes.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2509

13 years agos390: Ensure proper size when calling get_otrack_shadow_offset_wrk.
Florian Krohm [Mon, 3 Sep 2012 17:34:22 +0000 (17:34 +0000)] 
s390: Ensure proper size when calling get_otrack_shadow_offset_wrk.
Also handle EMNOTE.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12954

13 years agoAdd bugzilla number.
Florian Krohm [Mon, 3 Sep 2012 15:39:19 +0000 (15:39 +0000)] 
Add bugzilla number.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12953

13 years agoUpdate, tracking merged-to-3_8 fixes.
Julian Seward [Mon, 3 Sep 2012 07:24:30 +0000 (07:24 +0000)] 
Update, tracking merged-to-3_8 fixes.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12952

13 years agoUpdate.
Julian Seward [Sun, 2 Sep 2012 21:53:17 +0000 (21:53 +0000)] 
Update.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12950

13 years agoUpdate.
Julian Seward [Sun, 2 Sep 2012 21:20:27 +0000 (21:20 +0000)] 
Update.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12949

13 years ago"Fix" stack bounds check when compiled by Clang 4.0. Fix from Andrew
Julian Seward [Sun, 2 Sep 2012 21:17:36 +0000 (21:17 +0000)] 
"Fix" stack bounds check when compiled by Clang 4.0.  Fix from Andrew
Morrow, analysis by Florian Krohm.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12947

13 years agoImprove callgrind performance by 4 to 8% using UNLIKELY
Philippe Waroquiers [Sun, 2 Sep 2012 20:26:23 +0000 (20:26 +0000)] 
Improve callgrind performance by 4 to 8% using UNLIKELY
Performance improvements from 4 to 8% obtained on amd64 on the perf tests by:
1. using UNLIKELY inside tracing macros
2. avoid calling CLG_(switch_thread)(tid) on the hot patch setup_bbcc
   unless tid differs from CLG_(current_tid).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12939

13 years agoAdd testcase to check the emulation warning for new supported opcodes
Florian Krohm [Sun, 2 Sep 2012 18:10:34 +0000 (18:10 +0000)] 
Add testcase to check the emulation warning for new supported opcodes
on hosts without floating point extension facility.
See companion patch VEX r2501.
Part of fixing bugzilla #306098.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12935

13 years agoSupport the variety of "convert to/from fixed" and "load rounded" opcodes
Florian Krohm [Sun, 2 Sep 2012 18:07:08 +0000 (18:07 +0000)] 
Support the variety of "convert to/from fixed" and "load rounded" opcodes
that have an additional m3 and/or m4 field.
Add emulation warning EmWarn_S390X_fpext_rounding and issue it in case
the current opcode cannot be emulated correctly (i.e. with the specified
rounding mode).
New function: emulation_warning.
Part of fixing bugzilla #306098.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2501

13 years agoRemove alignment checks for VMPSADBW, VPHMINPOSUW, VPALIGNR since they
Julian Seward [Sun, 2 Sep 2012 12:13:34 +0000 (12:13 +0000)] 
Remove alignment checks for VMPSADBW, VPHMINPOSUW, VPALIGNR since they
do not apply to the AVX versions of these instructions.  Fixes #305926.
(Jakub Jelinek, jakub@redhat.com)

git-svn-id: svn://svn.valgrind.org/vex/trunk@2499

13 years agoChange s390-features to allow testing for absence of a feature.
Florian Krohm [Sun, 2 Sep 2012 03:30:38 +0000 (03:30 +0000)] 
Change s390-features to allow testing for absence of a feature.
This is infintely less painful than to find out how to invert
the condition in a test prerequisite.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12928

13 years agoFix an uninitialised variable found be BEAM.
Florian Krohm [Sat, 1 Sep 2012 23:48:09 +0000 (23:48 +0000)] 
Fix an uninitialised variable found be BEAM.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12927

13 years agoFix Makefile.am for fpext_fail testcase.
Florian Krohm [Sat, 1 Sep 2012 23:43:03 +0000 (23:43 +0000)] 
Fix Makefile.am for fpext_fail testcase.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12926

13 years agoUpdate.
Julian Seward [Sat, 1 Sep 2012 20:33:46 +0000 (20:33 +0000)] 
Update.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12925

13 years agoMark two fixes for s390x as [390] because they weren't fixed for 3.8.0
Florian Krohm [Sat, 1 Sep 2012 20:23:59 +0000 (20:23 +0000)] 
Mark two fixes for s390x as [390] because they weren't fixed for 3.8.0

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12924

13 years agoGuard against negative symbol sizes in ELF symbol tables, which
Julian Seward [Sat, 1 Sep 2012 20:08:35 +0000 (20:08 +0000)] 
Guard against negative symbol sizes in ELF symbol tables, which
lead to assertion failures in ML_(find_rx_mapping).  Most closely
related to #304980.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12923

13 years agos390: Mark a few more function parameters as unused.
Florian Krohm [Sat, 1 Sep 2012 20:01:39 +0000 (20:01 +0000)] 
s390: Mark a few more function parameters as unused.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2498

13 years agos390: Add testcase for emulation failure.
Florian Krohm [Sat, 1 Sep 2012 17:55:10 +0000 (17:55 +0000)] 
s390: Add testcase for emulation failure.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12922

13 years agos390: Generate an emulation failure if an insn is encountered that
Florian Krohm [Sat, 1 Sep 2012 17:54:09 +0000 (17:54 +0000)] 
s390: Generate an emulation failure if an insn is encountered that
requires the floating point extension facility but the host does not
have it. Factored out function emulation_failure.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2497

13 years agos390: Valgrind-side changes to fixing bugzilla #274695:
Florian Krohm [Sat, 1 Sep 2012 00:15:45 +0000 (00:15 +0000)] 
s390: Valgrind-side changes to fixing bugzilla #274695:
Testcase, vbit tester update, memcheck support for the new IROps,
NEWS announcement and opcode list update.
Patch by Christian Borntraeger (borntraeger@de.ibm.com).
Vbit tester tweaks by myself.
Fixes bugzilla #274695.
See also companion patch VEX r2496.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12921

13 years agos390: Add support for the "convert from/to logical" instruction family.
Florian Krohm [Sat, 1 Sep 2012 00:12:11 +0000 (00:12 +0000)] 
s390: Add support for the "convert from/to logical" instruction family.
A few (7) new IROps are introduced.
Patch by Christian Borntraeger (borntraeger@de.ibm.com).
Fixes bugzilla #274695.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2496

13 years agoComment only change.
Florian Krohm [Thu, 30 Aug 2012 22:57:47 +0000 (22:57 +0000)] 
Comment only change.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2495

13 years agos390: Detect floating point extension facility. Update s390-features.c
Florian Krohm [Thu, 30 Aug 2012 20:30:32 +0000 (20:30 +0000)] 
s390: Detect floating point extension facility. Update s390-features.c

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12920

13 years agos390: Add floating point extension facility to hwcaps.
Florian Krohm [Thu, 30 Aug 2012 20:28:00 +0000 (20:28 +0000)] 
s390: Add floating point extension facility to hwcaps.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2494

13 years agoAdd FAC_BIT macro to simplify correct testing for facility bits.
Florian Krohm [Thu, 30 Aug 2012 18:47:56 +0000 (18:47 +0000)] 
Add FAC_BIT macro to simplify correct testing for facility bits.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12919

13 years agoUpdate filter_stderr due to changed warning message.
Florian Krohm [Thu, 30 Aug 2012 15:29:48 +0000 (15:29 +0000)] 
Update filter_stderr due to changed warning message.
Unbreaks callgrind regtests on s390.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12918

13 years agoFix build on Darwin. Patch by Rich Coe (rcoe@wi.rr.com).
Florian Krohm [Thu, 30 Aug 2012 15:12:59 +0000 (15:12 +0000)] 
Fix build on Darwin. Patch by Rich Coe (rcoe@wi.rr.com).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12917

13 years agoEnable V-bit testing on x86.
Florian Krohm [Wed, 29 Aug 2012 22:40:50 +0000 (22:40 +0000)] 
Enable V-bit testing on x86.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12916

13 years agoAdd list of files to svn:ignore here
Florian Krohm [Wed, 29 Aug 2012 18:41:58 +0000 (18:41 +0000)] 
Add list of files to svn:ignore here

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12915

13 years agoEnable V-bit testing on ppc32.
Florian Krohm [Wed, 29 Aug 2012 17:45:13 +0000 (17:45 +0000)] 
Enable V-bit testing on ppc32.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12914

13 years agoFix address computation in IR injection. When loading / storing a
Florian Krohm [Wed, 29 Aug 2012 17:40:52 +0000 (17:40 +0000)] 
Fix address computation in IR injection. When loading / storing a
128-bit value as 2 64-bit values, the two memory locations are 8 bytes
apart. Always. Everywhere. Due to a thinko this was busted on 32-bit
eachines.
Also add an assert that values requiring more than 128 bit are currently
not supported.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2493

13 years agoFix printf formats for uint64_t values.
Florian Krohm [Wed, 29 Aug 2012 15:21:15 +0000 (15:21 +0000)] 
Fix printf formats for uint64_t values.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12913

13 years agoFix IR injection for ppc32. Need to use mkSzImm not mkU64...
Florian Krohm [Wed, 29 Aug 2012 15:00:13 +0000 (15:00 +0000)] 
Fix IR injection for ppc32. Need to use mkSzImm not mkU64...

git-svn-id: svn://svn.valgrind.org/vex/trunk@2492

13 years agoAdd VALGRIND_VEX_INJECT_IR for ppc32. Should have been included
Florian Krohm [Wed, 29 Aug 2012 14:59:13 +0000 (14:59 +0000)] 
Add VALGRIND_VEX_INJECT_IR for ppc32. Should have been included
in r12906.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12912

13 years agos390: Fix the default cache configuration. As z10-EC has an L3
Florian Krohm [Wed, 29 Aug 2012 02:50:56 +0000 (02:50 +0000)] 
s390: Fix the default cache configuration. As z10-EC has an L3
cache, use that instead of the L2 -- bringing the code in synch
with documentation.
Also improve the warning message to be more meaningful.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12911

13 years agovbit tester: Disable Iop_CmpLT64S and Iop_CmpLE64S for ppc because
Florian Krohm [Tue, 28 Aug 2012 23:38:49 +0000 (23:38 +0000)] 
vbit tester: Disable Iop_CmpLT64S and Iop_CmpLE64S for ppc because
they cause assertion failures.
Do not test Iop_CmpORDxyz on ppc because the vbit tester does not
support them. This is just so we don't have to add another .exp file for ppc.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12910

13 years agoMake debug printout look nicer.
Florian Krohm [Tue, 28 Aug 2012 20:58:23 +0000 (20:58 +0000)] 
Make debug printout look nicer.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2491

13 years agoRemove .deps directory.
Florian Krohm [Tue, 28 Aug 2012 18:37:40 +0000 (18:37 +0000)] 
Remove .deps directory.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12909

13 years agodrd/tests: Add a test that verifies whether the pthread_cancel() intercept works
Bart Van Assche [Tue, 28 Aug 2012 18:17:27 +0000 (18:17 +0000)] 
drd/tests: Add a test that verifies whether the pthread_cancel() intercept works

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12908

13 years agodrd: Re-enable the pthread_cancel() intercept now that the CALL_FN_*() ABI
Bart Van Assche [Tue, 28 Aug 2012 17:57:09 +0000 (17:57 +0000)] 
drd: Re-enable the pthread_cancel() intercept now that the CALL_FN_*() ABI
violation has been fixed (r12811).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12907

13 years agoAdd a tester for V-bit propagation through IROps.
Florian Krohm [Tue, 28 Aug 2012 16:50:39 +0000 (16:50 +0000)] 
Add a tester for V-bit propagation through IROps.
The tester is located in memcheck/tests/vbit-test.
It needs the following support on the valgrind / VEX side:
(1) a new client request VG_USERREQ__VEX_INIT_FOR_IRI
(2) a new "special instruction" on all architectures inserted via
    VALGRIND_VEX_INJECT_IR
(3) VEX changes to detect the special insn and insert IR (ir_inject.c)

The README file in vbit-test has some more information.
See also VEX r2490.  Fixes bugzilla #300102.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12906

13 years agoVEX-side support for the V-bit tester.
Florian Krohm [Tue, 28 Aug 2012 16:49:30 +0000 (16:49 +0000)] 
VEX-side support for the V-bit tester.
- recognise the new "special instruction" for all architectures
  (ARM needs implementation work; x86 and ARM are untested)
- inject IR into the superblock
- type definition for the IR injection control block

git-svn-id: svn://svn.valgrind.org/vex/trunk@2490

13 years agos390: Add zEC12 machine model. Fix spelling for some older models.
Florian Krohm [Tue, 28 Aug 2012 13:33:10 +0000 (13:33 +0000)] 
s390: Add zEC12 machine model. Fix spelling for some older models.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12905

13 years agos390: Add the zEC12 machine model.
Florian Krohm [Tue, 28 Aug 2012 13:31:31 +0000 (13:31 +0000)] 
s390: Add the zEC12 machine model.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2489

13 years agoFix EXTRA_DIST. Add dummy .exp file to satisfy the consistency checker
Florian Krohm [Tue, 28 Aug 2012 00:38:47 +0000 (00:38 +0000)] 
Fix EXTRA_DIST. Add dummy .exp file to satisfy the consistency checker

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12904

13 years agos390: Add testcase for the ecag insn. Based on patch by
Florian Krohm [Sun, 26 Aug 2012 19:05:06 +0000 (19:05 +0000)] 
s390: Add testcase for the ecag insn. Based on patch by
Divya Vyas (divyvyas@linux.vnet.ibm.com). Update opcode list.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12903

13 years agos390: Add support for the ecag insn. Patch from Divya Vyas
Florian Krohm [Sun, 26 Aug 2012 18:58:13 +0000 (18:58 +0000)] 
s390: Add support for the ecag insn. Patch from Divya Vyas
(divyvyas@linux.vnet.ibm.com) with mods to terminate the super block
with EmFail in case the insn is not available on the host.
Part of fixing bugzilla #275800.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2488

13 years agoOn s390: Terminate the superblock with Ijk_EmFail if an stckf insn
Florian Krohm [Sun, 26 Aug 2012 14:32:28 +0000 (14:32 +0000)] 
On s390: Terminate the superblock with Ijk_EmFail if an stckf insn
is encountered but not supported on the host.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2487

13 years agoOn s390: detect presence of stckf hardware facility.
Florian Krohm [Sun, 26 Aug 2012 04:23:08 +0000 (04:23 +0000)] 
On s390: detect presence of stckf hardware facility.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12902

13 years agos390: Add STCKF hardware facility to hwcaps.
Florian Krohm [Sun, 26 Aug 2012 04:22:33 +0000 (04:22 +0000)] 
s390: Add STCKF hardware facility to hwcaps.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2486

13 years agoOn s390: Terminate the superblock with Ijk_EmFail if an stfle insn
Florian Krohm [Sun, 26 Aug 2012 03:41:56 +0000 (03:41 +0000)] 
On s390: Terminate the superblock with Ijk_EmFail if an stfle insn
is encountered but not supported on the host.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2485

13 years agoAdd sem_wait to list of ignored files.
Florian Krohm [Sun, 26 Aug 2012 03:24:01 +0000 (03:24 +0000)] 
Add sem_wait to list of ignored files.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12901

13 years agoFollowup patch to r12899, purely mechanical. Rename:
Florian Krohm [Sun, 26 Aug 2012 03:22:09 +0000 (03:22 +0000)] 
Followup patch to r12899, purely mechanical. Rename:
VexEmWarn -> VexEmNote
EmWarn_NUMBER -> EmNote_NUMBER
guest_EMWARN -> guest_EMNOTE
LibVEX_EmWarn_string -> LibVEX_EmNote_string
offB_EMWARN -> offB_EMNOTE
EmWarn_NONE -> EmNote_NONE
See also VEX r2484

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12900

13 years agoFollowup to r2483, purely mechanical. Rename:
Florian Krohm [Sun, 26 Aug 2012 03:20:07 +0000 (03:20 +0000)] 
Followup to r2483, purely mechanical. Rename:
VexEmWarn -> VexEmNote
EmWarn_NUMBER -> EmNote_NUMBER
guest_EMWARN -> guest_EMNOTE
LibVEX_EmWarn_string -> LibVEX_EmNote_string
offB_EMWARN -> offB_EMNOTE
EmWarn_NONE -> EmNote_NONE

git-svn-id: svn://svn.valgrind.org/vex/trunk@2484

13 years agoRename libvex_emwarn.h to libvex_emnote.h. See also VEX r2483.
Florian Krohm [Sat, 25 Aug 2012 21:48:22 +0000 (21:48 +0000)] 
Rename libvex_emwarn.h to libvex_emnote.h. See also VEX r2483.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12899

13 years agoRename libvex_emwarn.h to libvex_emnote.h and fix all
Florian Krohm [Sat, 25 Aug 2012 21:48:04 +0000 (21:48 +0000)] 
Rename libvex_emwarn.h to libvex_emnote.h and fix all
#include's. The renaming of guest_EMWARN, VexemWarn etc will
be done in a followup patch.
The rationale for all this is that we want to reuse the existing
machinery for emulation warnings also for emulation failures.
And that calls for some kind of neutral naming scheme.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2483

13 years agodrd: Correct semaphore tracing in case sem_*wait() did not wait. See also #305690.
Bart Van Assche [Sat, 25 Aug 2012 07:25:00 +0000 (07:25 +0000)] 
drd: Correct semaphore tracing in case sem_*wait() did not wait. See also #305690.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12898

13 years agoComment only change.
Florian Krohm [Sat, 25 Aug 2012 02:01:25 +0000 (02:01 +0000)] 
Comment only change.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2482

13 years agodrd: Handle non-zero sem_*wait() return values correctly. Fixes #305690.
Bart Van Assche [Fri, 24 Aug 2012 17:59:03 +0000 (17:59 +0000)] 
drd: Handle non-zero sem_*wait() return values correctly. Fixes #305690.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12897

13 years agodrd/tests: Add test program that makes sem_trywait() return a non-zero value
Bart Van Assche [Fri, 24 Aug 2012 17:57:44 +0000 (17:57 +0000)] 
drd/tests: Add test program that makes sem_trywait() return a non-zero value
(provided by Graham Whitted <7wz69ejteg@snkmail.com> - see also #305690).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12896

13 years agoUpdate.
Julian Seward [Fri, 24 Aug 2012 16:53:02 +0000 (16:53 +0000)] 
Update.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12895

13 years agoRemove now-redundant comment that should have been removed in r2475.
Julian Seward [Fri, 24 Aug 2012 16:47:27 +0000 (16:47 +0000)] 
Remove now-redundant comment that should have been removed in r2475.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2481

13 years agoChange exp-sgcheck's memcpy implementation to be memmove-like (sigh)
Julian Seward [Fri, 24 Aug 2012 16:42:57 +0000 (16:42 +0000)] 
Change exp-sgcheck's memcpy implementation to be memmove-like (sigh)
since it appears that some part of the vast stack of libraries that
supports LibreOffice actually abuses it thusly.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12894

13 years agoImplement a wrapper for wcslen on Linux, assuming that
Julian Seward [Fri, 24 Aug 2012 14:44:27 +0000 (14:44 +0000)] 
Implement a wrapper for wcslen on Linux, assuming that
sizeof(wchar_t) == 4, which I believe to be true on both Linux
and MacOSX.  Fixes #298281.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12893

13 years agoFix skipping of block forms when this code is compiled by gcc 4.8 -- it
Julian Seward [Fri, 24 Aug 2012 14:38:56 +0000 (14:38 +0000)] 
Fix skipping of block forms when this code is compiled by gcc 4.8 -- it
has always been incorrect, modifying 'p' twice between sequence points.
Fixes #305513.  (Mark Wielaard, mjw@redhat.com)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12892

13 years agoFix up range checking in ML_(addLineInfo). Avoids assertion failure
Julian Seward [Fri, 24 Aug 2012 14:05:01 +0000 (14:05 +0000)] 
Fix up range checking in ML_(addLineInfo).  Avoids assertion failure
reported in #304980.  Based on a patch by Jiri Hruska (jirka@fud.cz).

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12891

13 years agoUpdate.
Julian Seward [Fri, 24 Aug 2012 00:06:17 +0000 (00:06 +0000)] 
Update.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12890

13 years agoAdd tests for MOVBE in 32 bit mode. See 304867. (Ambroz Bizjak,
Julian Seward [Thu, 23 Aug 2012 23:42:46 +0000 (23:42 +0000)] 
Add tests for MOVBE in 32 bit mode.  See 304867.  (Ambroz Bizjak,
ambrop7@gmail.com)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12889

13 years agoImplement MOVBE in 32 bit mode. Fixes #304867. (Ambroz Bizjak,
Julian Seward [Thu, 23 Aug 2012 23:39:49 +0000 (23:39 +0000)] 
Implement MOVBE in 32 bit mode.  Fixes #304867.  (Ambroz Bizjak,
ambrop7@gmail.com)

git-svn-id: svn://svn.valgrind.org/vex/trunk@2480

13 years agoAdd test cases for QDADD and QDSUB. See #305199. (Mans Rullgard,
Julian Seward [Thu, 23 Aug 2012 20:58:08 +0000 (20:58 +0000)] 
Add test cases for QDADD and QDSUB.  See #305199.  (Mans Rullgard,
mans@mansr.com)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12888

13 years agoImplement QDADD and QDSUB. Fixes #305199. (Mans Rullgard,
Julian Seward [Thu, 23 Aug 2012 20:56:17 +0000 (20:56 +0000)] 
Implement QDADD and QDSUB.  Fixes #305199.  (Mans Rullgard,
mans@mansr.com)

git-svn-id: svn://svn.valgrind.org/vex/trunk@2479

13 years agoFix LZCNT and TZCNT properly. Fixes #295808. (Jakub Jelinek,
Julian Seward [Thu, 23 Aug 2012 20:14:51 +0000 (20:14 +0000)] 
Fix LZCNT and TZCNT properly.  Fixes #295808.  (Jakub Jelinek,
jakub@redhat.com)

git-svn-id: svn://svn.valgrind.org/vex/trunk@2478

13 years agoRe-enable 'prefetch m8' and 'prefetchw m8'. Fixes #305321.
Julian Seward [Thu, 23 Aug 2012 19:47:05 +0000 (19:47 +0000)] 
Re-enable 'prefetch m8' and 'prefetchw m8'.  Fixes #305321.

git-svn-id: svn://svn.valgrind.org/vex/trunk@2477

13 years agoFix false positives in count_from_Status etc al. n-i-bz.
Julian Seward [Thu, 23 Aug 2012 19:25:12 +0000 (19:25 +0000)] 
Fix false positives in count_from_Status etc al.  n-i-bz.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12887

13 years agoIimplement 0F 7F encoding of movq between two registers. Fixes
Julian Seward [Thu, 23 Aug 2012 19:00:06 +0000 (19:00 +0000)] 
Iimplement 0F 7F encoding of movq between two registers.  Fixes
#305042.  (Mans Rullgard, mans@mansr.com)

git-svn-id: svn://svn.valgrind.org/vex/trunk@2476

13 years agoHandle a reg-reg encoding of MOVAPS. Fixes #289584.
Julian Seward [Thu, 23 Aug 2012 18:49:59 +0000 (18:49 +0000)] 
Handle a reg-reg encoding of MOVAPS.  Fixes #289584.
(Alexander Potapenko, glider@google.com)

git-svn-id: svn://svn.valgrind.org/vex/trunk@2475