]> git.ipfire.org Git - thirdparty/valgrind.git/log
thirdparty/valgrind.git
12 years agoUpdate list of ignored files.
Florian Krohm [Fri, 14 Feb 2014 08:30:28 +0000 (08:30 +0000)] 
Update list of ignored files.

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

12 years agomips64: Add BE version of cvm_lx_ins.stdout.exp
Petar Jovanovic [Thu, 13 Feb 2014 18:07:03 +0000 (18:07 +0000)] 
mips64: Add BE version of cvm_lx_ins.stdout.exp

Read-memory tests are endian sensitive.
Add BE version of cvm_lx_ins.stdout.exp that has been tested on
Cavium Octeon II in BE mode.

Related to Bugzilla issue 326444.

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

12 years agoarm64: implement the apply on all GP register.
Philippe Waroquiers [Wed, 12 Feb 2014 20:50:03 +0000 (20:50 +0000)] 
arm64: implement the apply on all GP register.
This is needed for leak search to work properly/not crash.

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

12 years agoMention that --vgdb=full bypasses the discard_translation gdbsrv problem
Philippe Waroquiers [Wed, 12 Feb 2014 20:48:18 +0000 (20:48 +0000)] 
Mention that --vgdb=full bypasses the discard_translation gdbsrv problem

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

12 years agoNo need to discard translation in gdbserver when --vgdb=full
Philippe Waroquiers [Wed, 12 Feb 2014 20:41:58 +0000 (20:41 +0000)] 
No need to discard translation in gdbserver when --vgdb=full
is given, as all instructions are in any case instrumented when
full is given.

This is (slightly) more efficient for full, and allows
to bypass the arm64 discard_translation problem caused by unchain
missing

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

12 years agoREADME.aarch64 : update status of gdbsrv for arm64
Philippe Waroquiers [Wed, 12 Feb 2014 00:02:05 +0000 (00:02 +0000)] 
README.aarch64 : update status of gdbsrv for arm64

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

12 years agoFix or implement various things to have V gdbsrv working on arm64
Philippe Waroquiers [Tue, 11 Feb 2014 23:50:16 +0000 (23:50 +0000)] 
Fix or implement various things to have V gdbsrv working on arm64
* better handle error recovery when calling remote_desc_activity
  (avoid exhausting safe fd range)
* fix small error in m_gdbserver/README_DEVELOPERS
* implemented mknod and poll syscall on mknodat and ppoll
  (mknod and poll are not directly supported on arm64)
* implement or fix various gdbsrv specific things needed for arm64
* changed assert condition in aspacemgr to VKI_SHMLBA >= VKI_PAGE_SIZE

With these changes, gdbserver integration seems to be basically working.
However, when breakpoints are placed or removed, discard_translations
causes an assert as the unchain has not been implemented yet for arm64 :

    --1118:1:gdbsrv   remove software_breakpoint at addr 0x400DE74 0x400DE74: _dl_debug_state (in /usr/lib64/ld-2.17.so)
    --1118:2:transtab   discard_translations(0x400de74, 2) req by m_gdbserver breakpoint remove
    --1118:2:transtab                       FAST, ec = 27

    vex: priv/main_main.c:1070 (LibVEX_UnChain): Assertion `0' failed.
    vex storage: T total 5480544 bytes allocated
    vex storage: P total 0 bytes allocated

    valgrind: the 'impossible' happened:
       LibVEX called failure_exit().
    ==1118==    at 0x3809E6B8: ??? (in /home/philippe/crossaarch64/trunk/Inst/lib/valgrind/none-arm64-linux)

    sched status:
      running_tid=1

What remains to be done:
  * arm64 xml register description files (allowing shadow registers to be looked at).
  * ptrace invoker : currently disabled for both arm and arm64
  * cpsr transfer to/from gdb to be looked at (see also arm equivalent code)

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

12 years ago- Handle KVM_CREATE_IRQCHIP, which does not take any parameter
Christian Borntraeger [Tue, 11 Feb 2014 15:15:31 +0000 (15:15 +0000)] 
- Handle KVM_CREATE_IRQCHIP, which does not take any parameter
  and returns 0 or -1.
- white space fixes around the KVM ioctls

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

12 years agos390: Fix s390_amode_for_guest_state. In general the offset relative
Florian Krohm [Tue, 11 Feb 2014 09:23:01 +0000 (09:23 +0000)] 
s390: Fix s390_amode_for_guest_state. In general the offset relative
to the guest state pointer may be more than the B12 addressing mode can
handle. Fall back and use a B20 addressing mode in those cases.

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

12 years agoIgnore executable. Should have been part of r13791.
Florian Krohm [Mon, 10 Feb 2014 17:52:35 +0000 (17:52 +0000)] 
Ignore executable. Should have been part of r13791.

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

12 years agoFix the ppc32 special-instruction magic sequence so it really does
Julian Seward [Mon, 10 Feb 2014 12:27:29 +0000 (12:27 +0000)] 
Fix the ppc32 special-instruction magic sequence so it really does
preserve the value of r0, as claimed.  Fixes #278808 (VEX side).

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

12 years agoFix the ppc32 special-instruction magic sequence so it really does
Julian Seward [Mon, 10 Feb 2014 12:26:12 +0000 (12:26 +0000)] 
Fix the ppc32 special-instruction magic sequence so it really does
preserve the value of r0, as claimed.  Fixes #278808 (Valgrind side).

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

12 years agoImplement more aarch64 vector insns:
Julian Seward [Mon, 10 Feb 2014 10:28:13 +0000 (10:28 +0000)] 
Implement more aarch64 vector insns:
{S,U}{MIN,MAX}  Vd.T, Vn.T, Vm.T (8bitx16lane variants)
{S,U}{MIN,MAX}V Vd.T, Vn.T, Vm.T (8bitx16lane variants)
FMOV (vector, immediate)
MOVI (vector, immediate)
FABS (vector)
FNEG (vector)
FMLA (vector)
FMLS (vector)
{AND,BIC,ORR,ORN} (vector)

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

12 years agoUpdate NEWS for VEX r2814
Tom Hughes [Sun, 9 Feb 2014 11:41:25 +0000 (11:41 +0000)] 
Update NEWS for VEX r2814

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

12 years agoAdd support for syscall on x86
Tom Hughes [Sun, 9 Feb 2014 11:40:20 +0000 (11:40 +0000)] 
Add support for syscall on x86

Patch from Ivo Raisr via BZ#330939 also fixes BZ#308729

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

12 years agoFix typo in poll wrapper
Tom Hughes [Sun, 9 Feb 2014 11:10:08 +0000 (11:10 +0000)] 
Fix typo in poll wrapper

Patch from Ivo Raisr via BZ#330941

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

12 years agodrd: Make the code added in r13792 portable
Bart Van Assche [Sun, 9 Feb 2014 09:10:14 +0000 (09:10 +0000)] 
drd: Make the code added in r13792 portable

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

12 years agodrd/tests/trylock: Make this test pass for glibc >= 2.18
Bart Van Assche [Sat, 8 Feb 2014 11:19:12 +0000 (11:19 +0000)] 
drd/tests/trylock: Make this test pass for glibc >= 2.18

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

12 years agodrd: Avoid that the drd/tests/pth_mutex_reinit test fails with glibc >= 2.18
Bart Van Assche [Sat, 8 Feb 2014 10:55:08 +0000 (10:55 +0000)] 
drd: Avoid that the drd/tests/pth_mutex_reinit test fails with glibc >= 2.18

Apparently with glibc >= 2.18 the value returned by pthread_mutexattr_gettype()
is not the same as the value passed to pthread_mutexattr_settype(). Add a
workaround for this glibc bug.

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

12 years agoThis commit is a fix for "Bug 330622 - Add test to regression suite for POWER
Carl Love [Sat, 8 Feb 2014 02:19:12 +0000 (02:19 +0000)] 
This commit is a fix for "Bug 330622 - Add test to regression suite for POWER
instruction: dcbzl" submitted by Anmol P. Paralkar <paralkar@freescale.com>

The patch adds the following files:

 none/tests/ppc64/data-cache-instructions.vgtest
 none/tests/ppc64/data-cache-instructions.c
 none/tests/ppc64/data-cache-instructions.stdout.exp
 none/tests/ppc64/data-cache-instructions.stderr.exp
 none/tests/ppc32/data-cache-instructions.stdout.exp
 none/tests/ppc32/data-cache-instructions.c
 none/tests/ppc32/data-cache-instructions.vgtest
 none/tests/ppc32/data-cache-instructions.stderr.exp
 tests/power_insn_available.c

The following files are modified:

 none/tests/ppc32/Makefile.am
 none/tests/ppc64/Makefile.am
 tests/Makefile.am

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

12 years agoFix V-bit tester failures introduced by VEX r2812.
Florian Krohm [Thu, 6 Feb 2014 18:53:30 +0000 (18:53 +0000)] 
Fix V-bit tester failures introduced by VEX r2812.

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

12 years agoImplement a few more vector aarch64 insns:
Julian Seward [Thu, 6 Feb 2014 12:57:58 +0000 (12:57 +0000)] 
Implement a few more vector aarch64 insns:
LD1 {vT.8h}, [xN|SP], #16
LD1 {vT.16b}, [xN|SP], #16
ST1 {vT.4h}, [xN|SP], #8
MUL  Vd.T, Vn.T, Vm.T
PMUL Vd.T, Vn.T, Vm.T  (fe only)
MLA  Vd.T, Vn.T, Vm.T
MLS  Vd.T, Vn.T, Vm.T
UMOV Xd/Wd, Vn.Ts[index]
SMOV Xd/Wd, Vn.Ts[index]

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

12 years agoCreate a list of all bugs reported after the 3.9.0 release
Julian Seward [Wed, 5 Feb 2014 14:00:16 +0000 (14:00 +0000)] 
Create a list of all bugs reported after the 3.9.0 release
(I think).

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

12 years agoShow a line in the output log when the client connects but the
Julian Seward [Wed, 5 Feb 2014 13:20:58 +0000 (13:20 +0000)] 
Show a line in the output log when the client connects but the
requested file is not found by the server.  This makes it easier to
diagnose client--server communications problems.

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

12 years agoUpdate.
Julian Seward [Wed, 5 Feb 2014 11:02:34 +0000 (11:02 +0000)] 
Update.

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

12 years agoImplement a few more vector aarch64 insns:
Julian Seward [Wed, 5 Feb 2014 11:01:19 +0000 (11:01 +0000)] 
Implement a few more vector aarch64 insns:
LD1 {vT.4s}, [xN|SP], #16
ADD Dd, Dn, Dm
SUB Dd, Dn, Dm
SMIN Vd.T, Vn.T, Vm.T
UMIN Vd.T, Vn.T, Vm.T
SMAX Vd.T, Vn.T, Vm.T
UMAX Vd.T, Vn.T, Vm.T
SMINV Vd.T, Vn.T, Vm.T
UMINV Vd.T, Vn.T, Vm.T
SMAXV Vd.T, Vn.T, Vm.T
UMAXV Vd.T, Vn.T, Vm.T
DUP Vd.T, Rn
FADD/FSUB/FMUL/FDIV32x4

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

12 years agomips64: Add tests that cover Cavium-specific load indexed instructions
Petar Jovanovic [Fri, 31 Jan 2014 12:49:22 +0000 (12:49 +0000)] 
mips64: Add tests that cover Cavium-specific load indexed instructions

Tests for lhux, lwux, and lbx for Cavium Octeon II.

Patch by Zahid Anwar, with changes.

Related to Bugzilla issue 326444.

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

12 years agomips64: Support for Cavium-specific load indexed instructions
Petar Jovanovic [Fri, 31 Jan 2014 12:14:20 +0000 (12:14 +0000)] 
mips64: Support for Cavium-specific load indexed instructions

Support for lhux, lwux, lbx for Cavium.

Patch by Zahid Anwar, with style changes.

Related to Bugzilla issue 326444.

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

12 years agoAdd support for the clock_adjtime system call.
Tom Hughes [Thu, 30 Jan 2014 22:33:02 +0000 (22:33 +0000)] 
Add support for the clock_adjtime system call.

Based on a patch from Stefan Sørensen on BZ#330469.

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

12 years agoBoth eventfd and eventfd2 have post handlers that we were failing
Tom Hughes [Thu, 30 Jan 2014 21:47:30 +0000 (21:47 +0000)] 
Both eventfd and eventfd2 have post handlers that we were failing
to call on most platforms. Fixes BZ #330459.

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

12 years agomips64: modify configure.ac to check for cavium supported toolchain
Petar Jovanovic [Wed, 29 Jan 2014 18:08:50 +0000 (18:08 +0000)] 
mips64: modify configure.ac to check for cavium supported toolchain

Modify configure to check if we can pass -march=octeon or -march=octeon2
flags to the compiler. This part is required as it gives us information how
to compile (i.e. whether to compile) tests specific for Cavium Octeon boards.

Patch by Zahid Anwar, with minor modifications.

Related to Bugzilla issue 326444.

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

12 years agomips64: detect Cavium Octeon II in mips_features
Petar Jovanovic [Wed, 29 Jan 2014 15:58:09 +0000 (15:58 +0000)] 
mips64: detect Cavium Octeon II in mips_features

Detect Cavium Octeon II CPU. This is needed as a prerequisite for
successful execution of cavium-octeon2 specific tests.

Patch by Zahid Anwar.

Related to Bugzilla issue 326444.

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

12 years agoImprove front and back end support for SIMD instructions on Arm64.
Julian Seward [Sun, 26 Jan 2014 19:11:14 +0000 (19:11 +0000)] 
Improve front and back end support for SIMD instructions on Arm64.

Implement the following instructions -- some but not necessarily
all laneage combinations:

  LD1 {vT.2d},  [Xn|SP]
  ST1 {vT.2d},  [Xn|SP]
  LD1 {vT.4s},  [Xn|SP]
  ST1 {vT.4s},  [Xn|SP]
  LD1 {vT.8h},  [Xn|SP]
  ST1 {vT.8h},  [Xn|SP]
  LD1 {vT.16b}, [Xn|SP]
  ST1 {vT.16b}, [Xn|SP]
  LD1 {vT.1d}, [Xn|SP]
  ST1 {vT.1d}, [Xn|SP]
  LD1 {vT.2s}, [Xn|SP]
  ST1 {vT.2s}, [Xn|SP]
  LD1 {vT.4h}, [Xn|SP]
  ST1 {vT.4h}, [Xn|SP]
  LD1 {vT.8b}, [Xn|SP]
  ST1 {vT.8b}, [Xn|SP]
  ST1 {vT.2d}, [xN|SP], #16
  LD1 {vT.2d}, [xN|SP], #16
  ST1 {vT.4s}, [xN|SP], #16
  ST1 {vT.8h}, [xN|SP], #16
  ST1 {vT.2s}, [xN|SP], #8
  SCVTF Vd, Vn
  UCVTF Vd, Vn
  FADD Vd,Vn,Vm   1
  FSUB Vd,Vn,Vm   2
  FMUL Vd,Vn,Vm   3
  FDIV Vd,Vn,Vm   4
  FMLA Vd,Vn,Vm   5
  FMLS Vd,Vn,Vm   6
  ADD Vd.T, Vn.T, Vm.T
  SUB Vd.T, Vn.T, Vm.T
  XTN {,2}
  DUP Vd.T, Vn.Ts[index]

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

12 years agoHandle and instrument an extra rounding-mode argument as added by
Julian Seward [Sun, 26 Jan 2014 18:36:52 +0000 (18:36 +0000)] 
Handle and instrument an extra rounding-mode argument as added by
vex r2809 to the following primops:

  Iop_Add32Fx4, Iop_Sub32Fx4, Iop_Mul32Fx4, Iop_Div32Fx4,
  Iop_Add64Fx2, Iop_Sub64Fx2, Iop_Mul64Fx2, Iop_Div64Fx2,
  Iop_Add64Fx4, Iop_Sub64Fx4, Iop_Mul64Fx4, Iop_Div64Fx4,
  Iop_Add32Fx8, Iop_Sub32Fx8, Iop_Mul32Fx8, Iop_Div32Fx8,

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

12 years agoMake the following primops take a third (initial) argument to
Julian Seward [Sun, 26 Jan 2014 18:34:23 +0000 (18:34 +0000)] 
Make the following primops take a third (initial) argument to
indicate the rounding mode to use, like their scalar cousins do:

  Iop_Add32Fx4  Iop_Sub32Fx4  Iop_Mul32Fx4  Iop_Div32Fx4
  Iop_Add64Fx2  Iop_Sub64Fx2  Iop_Mul64Fx2  Iop_Div64Fx2
  Iop_Add64Fx4  Iop_Sub64Fx4  Iop_Mul64Fx4  Iop_Div64Fx4
  Iop_Add32Fx8  Iop_Sub32Fx8  Iop_Mul32Fx8  Iop_Div32Fx8

Fix up the x86 and amd64 front ends to add fake rounding modes
(Irrm_NEAREST) when generating expressions using these primops.
Fix up the x86 and amd64 back ends to accept these as triops
rather than as binops, and ignore the first arg.

Add three more ir_opt folding rules to remove memcheck
instrumentation arising from instrumentation of known-defined
rounding modes.

Overall functional and performance effects should be zero.

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

12 years agoThis patch by adrian.sendroiu@freescale.com fixes the lrmw and stmw
Carl Love [Fri, 24 Jan 2014 16:44:08 +0000 (16:44 +0000)] 
This patch by adrian.sendroiu@freescale.com fixes the lrmw and stmw
instructions.

The patch also adds ppc32 and ppc64 test cases for the instructions.

The patch is a fix for bugzilla 329956 "valgrind crashes when lmw/stmw instructions are used on ppc64".

The VEX code commit is 2802

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

12 years agoThis patch by adrian.sendroiu@freescale.com fixes the lrmw and stmw
Carl Love [Fri, 24 Jan 2014 16:42:26 +0000 (16:42 +0000)] 
This patch by adrian.sendroiu@freescale.com fixes the lrmw and stmw
instructions.

The patch also adds ppc32 and ppc64 test cases for the instructions.

The patch is a fix for bugzilla 329956 "valgrind crashes when lmw/stmw instructions are used on ppc64".

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

12 years agoWhitespace-only change: restrict to 80 col width.
Julian Seward [Tue, 21 Jan 2014 16:33:51 +0000 (16:33 +0000)] 
Whitespace-only change: restrict to 80 col width.

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

12 years agoUpdate NEWS (platform changes section) with MIPS/Android
Petar Jovanovic [Fri, 17 Jan 2014 17:41:16 +0000 (17:41 +0000)] 
Update NEWS (platform changes section) with MIPS/Android

As of r13767, Valgrind supports MIPS32/Android.

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

12 years agomips64: Change the initial value of fpu registers.
Dejan Jevtic [Wed, 15 Jan 2014 16:26:31 +0000 (16:26 +0000)] 
mips64: Change the initial value of fpu registers.

Initial value of mips fpu registers should be nan instead of 0xffffffffffffffff.

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

12 years agoFix typo.
Julian Seward [Wed, 15 Jan 2014 14:30:24 +0000 (14:30 +0000)] 
Fix typo.

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

12 years agoIgnore testcase executable.
Florian Krohm [Wed, 15 Jan 2014 11:23:57 +0000 (11:23 +0000)] 
Ignore testcase executable.

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

12 years agoarm64: rename guest_SP to guest_XSP so as to avoid a name clash with
Julian Seward [Wed, 15 Jan 2014 10:25:55 +0000 (10:25 +0000)] 
arm64: rename guest_SP to guest_XSP so as to avoid a name clash with
guest_SP from s390 world.

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

12 years agoarm64: rename guest_SP to guest_XSP so as to avoid a name clash with
Julian Seward [Wed, 15 Jan 2014 10:25:21 +0000 (10:25 +0000)] 
arm64: rename guest_SP to guest_XSP so as to avoid a name clash with
guest_SP from s390 world.  Also back out the rename of guest_SP to
guest_s390_SP that caused s390 build breakage in r2803.

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

12 years agoUpdate implementation notes for the arm64-linux port.
Julian Seward [Mon, 13 Jan 2014 11:50:17 +0000 (11:50 +0000)] 
Update implementation notes for the arm64-linux port.

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

12 years agoInitial implementation of CFI based stack unwinding for arm64-linux.
Julian Seward [Mon, 13 Jan 2014 00:21:09 +0000 (00:21 +0000)] 
Initial implementation of CFI based stack unwinding for arm64-linux.

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

12 years agoMinor notes on arm64 register usages.
Julian Seward [Mon, 13 Jan 2014 00:18:51 +0000 (00:18 +0000)] 
Minor notes on arm64 register usages.

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

12 years agoVG_(bzero_inline): handle up to 12 words inline.
Julian Seward [Mon, 13 Jan 2014 00:17:54 +0000 (00:17 +0000)] 
VG_(bzero_inline): handle up to 12 words inline.

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

12 years agoAdd missing ULLs to some 64-bit immediates.
Julian Seward [Sun, 12 Jan 2014 18:23:45 +0000 (18:23 +0000)] 
Add missing ULLs to some 64-bit immediates.

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

12 years agoAdd test cases for AArch64 integer instructions (not wired up).
Julian Seward [Sun, 12 Jan 2014 13:12:11 +0000 (13:12 +0000)] 
Add test cases for AArch64 integer instructions (not wired up).

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

12 years agoAdd support for ARMv8 AArch64 (the 64 bit ARM instruction set).
Julian Seward [Sun, 12 Jan 2014 12:54:00 +0000 (12:54 +0000)] 
Add support for ARMv8 AArch64 (the 64 bit ARM instruction set).

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

12 years agoAdd support for ARMv8 AArch64 (the 64 bit ARM instruction set):
Julian Seward [Sun, 12 Jan 2014 12:49:10 +0000 (12:49 +0000)] 
Add support for ARMv8 AArch64 (the 64 bit ARM instruction set):
integer and FP instructions.

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

12 years agoadd --vgdb-prefix arg to callgrind_control
Philippe Waroquiers [Sat, 11 Jan 2014 13:56:48 +0000 (13:56 +0000)] 
add --vgdb-prefix arg to callgrind_control
If valgrind is started with --vgdb-prefix arg, then callgrind_control
cannot find and control this valgrind.
So, add an (optional) argument to callgrind_control,
and have callgrind tool report the needed vgdb prefix argument
if the user supplied this arg.

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

12 years agoThe value of AT_BASE should be the offset between where the ELF interpreter
Tom Hughes [Tue, 7 Jan 2014 22:27:57 +0000 (22:27 +0000)] 
The value of AT_BASE should be the offset between where the ELF interpreter
expected to be loaded (as expressed in the ELF headers) and where it was
actually loaded, and not (as valgrind was doing) the absolute value of the
load address for the interpreter.

Note that when prelink is not in use the two are normally the same, as the
intpreter (like all shared libraries) is normally linked with a zero load
address. When prelinked that is no longer true.

With that fixed, the hack to patch out AT_BASE to avoid confusing gdb on
systems where prelink is in use is no longer needed.

Fixes BZ#329612

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

12 years agomips32: Adding mips32/Android support to Valgrind.
Dejan Jevtic [Fri, 27 Dec 2013 09:06:55 +0000 (09:06 +0000)] 
mips32: Adding mips32/Android support to Valgrind.

Necessary changes to Valgrind to support mips32 on Android.

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

12 years agoAnnounce fix for BZ #327284.
Florian Krohm [Sat, 21 Dec 2013 17:59:50 +0000 (17:59 +0000)] 
Announce fix for BZ #327284.

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

12 years agoFix drd assert failure for monitor cmd execution when all threads blocked in syscall
Philippe Waroquiers [Sat, 21 Dec 2013 16:57:26 +0000 (16:57 +0000)] 
Fix drd assert failure for monitor cmd execution when all threads blocked in syscall

When all threads are blocked in a syscall, DRD_(thread_get_running_tid)()
returns (or can return?) a "valid" DrdThreadId (probably the last one
that was running ?).
However, in such a situation, VG_(get_running_tid)() returns 0 (as effectively
there is no thread running).

This discrepancy (drd_tid "valid" and "vg_tid" invalid) can (probably) only
happen with gdb monitor commands, as a thread can (normally) execute a
client request only when it is running.

However, vgdb can "force" the invocation of the gdb monitor client request,
even if no thread is running.
In such a case, the assert should not verify that drd_tid and vg_tid are
consistent.

To reproduce the problem:
  ./vg-in-place --tool=drd sleep 60
and in another window:
  ./coregrind/vgdb help
which then gives
  ...
  drd: drd_clientreq.c:84 (handle_client_request): Assertion 'DRD_(VgThreadIdToDrdThreadId)(vg_tid) == drd_tid' failed.
  ==4208==    at 0x3801DE1D: report_and_quit (m_libcassert.c:260)
  ==4208==    by 0x3801E034: vgPlain_assert_fail (m_libcassert.c:340)
  ==4208==    by 0x380026CC: handle_client_request (drd_clientreq.c:84)
  ==4208==    by 0x3806EE8F: handle_gdb_monitor_command (server.c:490)
  ==4208==    by 0x3806F07A: handle_query (server.c:580)
  ==4208==    by 0x3806FDB2: server_main (server.c:915)
  ==4208==    by 0x3806B01C: call_gdbserver (m_gdbserver.c:706)
  ==4208==    by 0x3806B8F2: vgPlain_invoke_gdbserver (m_gdbserver.c:892)
  ...

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

12 years agohave massif printing its stats for v.info stats
Philippe Waroquiers [Thu, 19 Dec 2013 19:10:20 +0000 (19:10 +0000)] 
have massif printing its stats for v.info stats

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

12 years agoCallgrind: support printing stats via vgdb
Josef Weidendorfer [Tue, 17 Dec 2013 15:12:06 +0000 (15:12 +0000)] 
Callgrind: support printing stats via vgdb

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

12 years agoFix 325714 Empty vgcore but RLIMIT_CORE is big enough (too big)
Philippe Waroquiers [Mon, 16 Dec 2013 22:52:20 +0000 (22:52 +0000)] 
Fix 325714  Empty vgcore but RLIMIT_CORE is big enough (too big)

Use ULong rather than UInt for coredump file size.

Tested manually by
  ulimit -c 4294967296
  ./vg-in-place ./gdbserver_tests/gone abort
valgrind creates vgcore.xxxxx unusable by GDB.

With the fix, GDB can read the core dump.

Patch from  Romain Geissler

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

12 years agomips32/64: Add extra suppression for mips32/64.
Dejan Jevtic [Mon, 16 Dec 2013 13:57:18 +0000 (13:57 +0000)] 
mips32/64: Add extra suppression for mips32/64.

After the thread is detached not all thread memory is freed. This memory (dtv-dynamic thread vector)
can be used by the main thread. There are two types of run-time handling of TLS.
Difference is in the position of memory. It can be either before the thread pointer or
after the thread pointer.
Taken form the document http://www.akkadia.org/drepper/tls.pdf:
"Variant I for the thread-local storage data structures were developed
as part of the IA-64 ABI. Being brand-new, compatibility was no issue. The thread
register for thread t is denoted by tpt. It points to a Thread Control Block (TCB) which
contains at offset zero a pointer to the dynamic thread vector dtvt for the thread.

Variant II has a similar structure. The only difference is that the thread pointer
points to a Thread Control Block of unspecified size and content. Somewhere the TCB
contains a pointer to the dynamic thread vector but it is not specified where. This is
under control of the run-time environment and the pointer must not be assumed to be
directly accessible; compilers are not allowed to emit code which directly access the
dtvt."

Because of this we have two types of error when the program ends:
possibly lost, and definitely lost.

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

12 years agoImplement gdbsrv "v.info stats" command giving statistics for valgrind core + tools
Philippe Waroquiers [Sun, 15 Dec 2013 20:24:43 +0000 (20:24 +0000)] 
Implement gdbsrv "v.info stats" command giving statistics for valgrind core + tools

* addition of VG_(needs_print_stats) in pub_tool_tooliface.h
* use the above in memcheck and helgrind
* output valgrind stats and calls print_stats in server.c

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

12 years agoFollowing svn r13758 (bug 328711), some further similar fixes,
Philippe Waroquiers [Thu, 12 Dec 2013 23:19:13 +0000 (23:19 +0000)] 
Following svn r13758 (bug 328711), some further similar fixes,

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

12 years agoBug 328711 valgrind.1 manpage "memcheck options" section is badly generated
Mark Wielaard [Thu, 12 Dec 2013 21:20:48 +0000 (21:20 +0000)] 
Bug 328711 valgrind.1 manpage "memcheck options" section is badly generated

Add missing para tags inside listitems. (Miroslav Franc, mfranc@redhat.com)

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

12 years agoSelect expensive add/sub/cmp interpretations for blocks containing
Julian Seward [Wed, 11 Dec 2013 16:49:46 +0000 (16:49 +0000)] 
Select expensive add/sub/cmp interpretations for blocks containing
Iop_GetMSBs8x16, since the presence of those usually implies PMOVMSKB
instructions in the block, which can mean "inlined string operations".
Reduces the noise level a lot in some icc12 -O2 generated sequences.

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

12 years agoLibVEX_GuestAMD64_initialise(): give an initial value for
Julian Seward [Wed, 11 Dec 2013 16:47:59 +0000 (16:47 +0000)] 
LibVEX_GuestAMD64_initialise(): give an initial value for
guest_ACFLAG.  Kinda worrying that this was missing.

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

12 years agodrd/tests/std_atomic: Add
Bart Van Assche [Tue, 10 Dec 2013 17:56:20 +0000 (17:56 +0000)] 
drd/tests/std_atomic: Add

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

12 years agoAnnounce fix for BZ #328455.
Florian Krohm [Tue, 10 Dec 2013 16:53:59 +0000 (16:53 +0000)] 
Announce fix for BZ #328455.

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

12 years agoThe result of rounding a 128-bit BFP/DFP value to 32/64 bit needs to
Florian Krohm [Tue, 10 Dec 2013 16:51:15 +0000 (16:51 +0000)] 
The result of rounding a 128-bit BFP/DFP value to 32/64 bit needs to
be stored in a register pair. This constraint was not observed previously
and the result was stored in any FPR that happened to be chosen. If the
selected FPR was not identifying a proper FPR pair, a SIGILL was delivered.
Fixes BZ #328455.

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

12 years agoAdd testcase for bug 328100 XABORT not implemented (VEX r2800).
Mark Wielaard [Tue, 10 Dec 2013 09:31:18 +0000 (09:31 +0000)] 
Add testcase for bug 328100 XABORT not implemented (VEX r2800).

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

12 years agoNEWS entry for resolved bug 328100 XABORT not implemented (VEX r2800).
Mark Wielaard [Tue, 10 Dec 2013 09:14:52 +0000 (09:14 +0000)] 
NEWS entry for resolved bug 328100 XABORT not implemented (VEX r2800).

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

12 years agoBug 328100 - XABORT not implemented.
Mark Wielaard [Mon, 9 Dec 2013 12:54:06 +0000 (12:54 +0000)] 
Bug 328100 - XABORT not implemented.

XABORT can be called even when there is no current transaction.
In such a case XABORT acts as a NOP. Implement xabort as nop.

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

12 years agodrd: Follow-up for r13749
Bart Van Assche [Sat, 7 Dec 2013 09:16:02 +0000 (09:16 +0000)] 
drd: Follow-up for r13749

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

12 years agoBump the version number on the trunk.
Julian Seward [Fri, 6 Dec 2013 15:54:02 +0000 (15:54 +0000)] 
Bump the version number on the trunk.

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

12 years agomips32: update ignore list.
Dejan Jevtic [Fri, 6 Dec 2013 14:28:29 +0000 (14:28 +0000)] 
mips32: update ignore list.

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

12 years agomips32/mips64: Suppress race condition error.
Dejan Jevtic [Fri, 6 Dec 2013 14:21:44 +0000 (14:21 +0000)] 
mips32/mips64: Suppress race condition error.

On MIPS architecture helgrind is showing race condition error in printf if
the printf is first time called from the child thread. If we call printf
from the main for the first time we will suppress this error on mips.

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

12 years agoMinor tweak in the VG_(poll) syscall and callers: have a way to show
Philippe Waroquiers [Thu, 5 Dec 2013 22:10:55 +0000 (22:10 +0000)] 
Minor tweak in the VG_(poll) syscall and callers: have a way to show
the error in case the poll syscall unexpectedly fails.

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

12 years agoMinor tweak in the vgdb instructions output by valgrind:
Philippe Waroquiers [Thu, 5 Dec 2013 20:29:53 +0000 (20:29 +0000)] 
Minor tweak in the vgdb instructions output by valgrind:
to make copy/paste and then editing the command easier,
put the --pid=3393 at the end of the instruction output by valgrind.

So, in gdb command history, one can just recuperate the previous target
command in the history and more easily change the pid.
I.e. have:

target remote | /home/philippe/valgrind/refactor_vgdb/Inst/lib/valgrind/../../bin/vgdb --vgdb-prefix=truc --pid=3393

instead of

target remote | /home/philippe/valgrind/refactor_vgdb/Inst/lib/valgrind/../../bin/vgdb --pid=3393 --vgdb-prefix=truc

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

12 years agomips32: Fix typo.
Dejan Jevtic [Thu, 5 Dec 2013 14:05:25 +0000 (14:05 +0000)] 
mips32: Fix typo.

Fix some typo error and some errors in tests that was discovered while running Valgrind on MIPS/Android.
In some cases initial FCSR value wasn't being set properly.

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

12 years agoHelgrind: Suppress false positive reports on _dl_allocate_tls_init()
Bart Van Assche [Mon, 2 Dec 2013 15:13:05 +0000 (15:13 +0000)] 
Helgrind: Suppress false positive reports on _dl_allocate_tls_init()

Reported-by: Dejan Jevtic <dejan.jevtic@rt-rk.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13745

12 years agoDecrease helgrind memory use for applications allocating many blocks
Philippe Waroquiers [Sun, 1 Dec 2013 19:28:48 +0000 (19:28 +0000)] 
Decrease helgrind memory use for applications allocating many blocks

Use a pool allocator for the MallocMeta struct that helgrind maintains
for each client allocated block.

For perf/heap on x86, this decreases the max amount of mmap-ed memory
for the core area from 56Mb to 36Mb.
On amd64, decreases from 104Mb to 62Mb.

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

12 years agoFix 326462 Refactor vgdb to isolate invoker stuff into separate module
Philippe Waroquiers [Sun, 1 Dec 2013 14:56:28 +0000 (14:56 +0000)] 
Fix 326462 Refactor vgdb to isolate invoker stuff into separate module

vgdb.c contained (conditionally compiled) "invoker" code to have ptrace syscalls
used to allow gdb/vgdb to connect to a valgrind process blocked in a syscall.
This "invoker" code is ptrace based.
Not all platforms are using ptrace.
=> refactor vgdb so as allow invoker code to be added more cleanly
for non ptrace based platforms (e.g. Darwin, Solaris).

* add file vgdb.h for:
   - definition of the vgdb-invoker interface
   - common declarations between vgdb.c and vgdb-invoker implementations
* move ptrace related code from vgdb.c to new file vgdb-invoker-ptrace.c
* new file vgdb-invoker-none.c containing an empty invoker implementation
  used on platforms that do not (yet) have a invoker implementation
  (e.g. android and darwin).
* modified Makefile.am to use one of the vgdb-invoker-*.c file depending
  on the platform.
* small changes related to changing ptraceinvoker to invoker in various files:
  gdbserver_tests/make_local_links, gdbserver_tests/nlcontrolc.vgtest,
  gdbserver_tests/mcinvokeRU.vgtest, gdbserver_tests/nlsigvgdb.vgtest
  gdbserver_tests/mcinvokeWS.vgtest, coregrind/m_gdbserver/README_DEVELOPERS

Patch from Ivo Raisr, slightly modified

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

12 years agoMove bug fix announcement to the FIXED BUGS section
Philippe Waroquiers [Sun, 1 Dec 2013 14:51:21 +0000 (14:51 +0000)] 
Move bug fix announcement to the FIXED BUGS section

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

12 years agoNEWS: Mark #328205 as fixed
Bart Van Assche [Sun, 1 Dec 2013 12:59:32 +0000 (12:59 +0000)] 
NEWS: Mark #328205 as fixed

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

12 years agoAnnounce bug fixed for several bugs in NEWS
Philippe Waroquiers [Sun, 1 Dec 2013 12:52:00 +0000 (12:52 +0000)] 
Announce bug fixed for several bugs in NEWS

fixed in r13709 326983  Clear direction flag after tests on amd64.
fixed in r13712 327238  Callgrind Assertion 'passed <= last_bb->cjmp_count' failed
fixed in r13715 327837  dwz compressed alternate .debug_info and .debug_str not read correctly
fixed in r13718 327916  DW_TAG_typedef may have no name

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

12 years agoCreate 3.10.0 section in NEWS, add (first draft of) README_DEVELOPERS_processes
Philippe Waroquiers [Sun, 1 Dec 2013 12:42:30 +0000 (12:42 +0000)] 
Create 3.10.0 section in NEWS, add (first draft of) README_DEVELOPERS_processes

* add the new sections for next 3.10.0 release in NEWS.
* add file README_DEVELOPERS_processes.

As discussed on valdev and documented in README_DEVELOPERS_processes,
the idea is to document fixed bugs or new features in NEWS together
with the commit fixing/implementing these.

Looking at SVN, the below bugs should be added in 3.10.0 fixed bugs.
I will add them in NEWS shortly.

Thanks

Philippe

r13709 | tom | 2013-11-01 11:46:28 +0100 (Fri, 01 Nov 2013) | 2 lines

Clear direction flag after tests on amd64. BZ#326983.

r13712 | weidendo | 2013-11-12 16:32:58 +0100 (Tue, 12 Nov 2013) | 17 lines

Fix bug 327238.

 assertion failure in Callgrind: bbcc.c:585 (vgCallgrind_setup_bbcc):
 Assertion 'passed <= last_bb->cjmp_count' failed

r13715 | mjw | 2013-11-20 12:54:38 +0100 (Wed, 20 Nov 2013) | 5 lines

dwz compressed alternate .debug_info and .debug_str not read correctly.

Bug #327837. The buildid from the .gnu_debugaltlink section was parsed
incorrectly (from the wrong offset). Causing the debug alt file not to
be found.

r13718 | mjw | 2013-11-24 18:19:35 +0100 (Sun, 24 Nov 2013) | 5 lines

Bug 327916 - DW_TAG_typedef may have no name

We already accepted DW_TAG_typedef without a name for Ada. But g++ for
OpenMP can also emit such nameless DW_TAG_typedefs. Just accept them.
Also fix up anonymous enum and typedef printing in tytypes.c.

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

12 years agoxen: Implement XEN_DOMCTL_set_max_evtchn
Bart Van Assche [Sun, 1 Dec 2013 10:59:07 +0000 (10:59 +0000)] 
xen: Implement XEN_DOMCTL_set_max_evtchn

This is new in Xen 4.4.

From: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13738

12 years agoxen: XEN_SYSCTL_debugkeys hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:58:38 +0000 (10:58 +0000)] 
xen: XEN_SYSCTL_debugkeys hypercall

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13737

12 years agoxen: XEN_SYSCTL_readconsole hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:58:11 +0000 (10:58 +0000)] 
xen: XEN_SYSCTL_readconsole hypercall

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13736

12 years agoxen: XEN_DOMCTL_shadow_op hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:57:43 +0000 (10:57 +0000)] 
xen: XEN_DOMCTL_shadow_op hypercall

And some of the sub-subops.  It is a little hacky given the legacy way of
having several methods of enabling/disbling LOG_DIRTY mode.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13735

12 years agoxen: XEN_DOMCTL_sethvmcontext hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:57:14 +0000 (10:57 +0000)] 
xen: XEN_DOMCTL_sethvmcontext hypercall

Xen reads 'num' and 'array' from the structure, and reads the entire buffer.
Nothing gets written back.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13734

12 years agoxen: XEN_DOMCTL_getpageframeinfo3 hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:56:28 +0000 (10:56 +0000)] 
xen: XEN_DOMCTL_getpageframeinfo3 hypercall

Xen reads 'num' and the 'array' pointer from ARG1, and proceeds to read and
modify-in-place the entire userspace array.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13733

12 years agoxen: XEN_DOMCTL_gethvmcontext hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:55:54 +0000 (10:55 +0000)] 
xen: XEN_DOMCTL_gethvmcontext hypercall

The semantics of XEN_DOMCTL_gethvmcontext are little interesting.

If the 'buffer' field of the structure is NULL, the hypercall is a request for
the required buffer size, which written into the 'size' paramater.

If 'buffer' is non NULL, Xen will write to the buffer, and update 'size' with
the amount of data written.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13732

12 years agoxen: XENMEM_remove_from_physmap hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:55:13 +0000 (10:55 +0000)] 
xen: XENMEM_remove_from_physmap hypercall

Xen reads the entire structure and writes nothing.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13731

12 years agoxen: XENMEM_add_to_physmap hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:54:42 +0000 (10:54 +0000)] 
xen: XENMEM_add_to_physmap hypercall

Xen reads the entire structure, and if the space is _gmfn, will write the
structure back

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13730

12 years agoxen: XENMEM_machphys_mfn_list hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:54:06 +0000 (10:54 +0000)] 
xen: XENMEM_machphys_mfn_list hypercall

The XENMEM_machphys_mfn_list implementation reads 'max_extents' and
'extents_start'.  It writes to the array at 'extents_start', and writes the
number of extents written into the 'nr_extents' field.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13729

12 years agoxen: XENMEM_maximum_gpfn hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:53:34 +0000 (10:53 +0000)] 
xen: XENMEM_maximum_gpfn hypercall

Xen reads a 16 bit domid from the pointer provided in ARG2, but does not write
anything back.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13728

12 years agoxen: XENMEM_maximum_ram_page hypercall
Bart Van Assche [Sun, 1 Dec 2013 10:53:05 +0000 (10:53 +0000)] 
xen: XENMEM_maximum_ram_page hypercall

Xen does not read or write any memory for this hypercall

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13727

12 years agoxen: Infratructure for XEN_TMEM_* hypercalls
Bart Van Assche [Sun, 1 Dec 2013 10:52:22 +0000 (10:52 +0000)] 
xen: Infratructure for XEN_TMEM_* hypercalls

and an implementation of XEN_TMEM_control save_begin.

Xen will read various fields at various time, but write nothing back for a
save_begin subop.

From: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13726

12 years agoxen: Fix XEN_SYSCTL_getdomaininfolist for version 0xa
Bart Van Assche [Sun, 1 Dec 2013 10:51:19 +0000 (10:51 +0000)] 
xen: Fix XEN_SYSCTL_getdomaininfolist for version 0xa

From: Andrew Cooper <andrew.cooper3@citrix.com>

Also add a default case so future bumps of the sysctl interface version dont
result in spurious passes of the IOCTL handler.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13725