Commit Graph

9824 Commits

Author SHA1 Message Date
Julian Seward
701d76bca9 Teach Helgrind about IRLoadG and IRStoreG.
git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13207
2012-12-27 13:37:36 +00:00
Julian Seward
c8f2fb5b51 Teach Callgrind about IRLoadG and IRStoreG.
git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13206
2012-12-27 12:02:15 +00:00
Julian Seward
d8f44a112c Teach Cachegrind about IRLoadG and IRStoreG.
git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13194
2012-12-21 10:34:08 +00:00
Julian Seward
77113fe633 Handle IRLoadG and IRStoreG.
git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13189
2012-12-19 23:56:46 +00:00
Julian Seward
eab3c85005 Instrumentation of guarded loads and stores: annotate helper calls
with the required IRDefault (guarded-dirty-call default return result
specifications).



git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13187
2012-12-17 21:56:58 +00:00
Julian Seward
287e6326c8 Mostly complete code for instrumentation of origin tracking for
guarded loads and stores.  Still lacks proper setting of defaults in
the helper calls.


git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13183
2012-12-16 13:21:17 +00:00
Julian Seward
be59e93fc8 Add a detailed comment re the situation with checking definedness of
addresses in guarded loads, stores and dirty helpers that access
memory.  Fall back to a simpler situation as documented in the
comment, possibly on a temporary basis.



git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13181
2012-12-14 12:51:08 +00:00
Julian Seward
07172defd4 Initial Memcheck support for instrumenting guarded loads and stores.
Still to do:

* origin tracking

* reinstate the two NULLed-out 3rd args to complainIfUndefined,
  once the complication pertaining to setting the shadow tmp to
  'defined' is resolved



git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13142
2012-11-25 15:33:42 +00:00
Julian Seward
a3deb5ced6 Swizzle external.
git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13141
2012-11-25 12:56:10 +00:00
Julian Seward
0822371e4d Move this directory to the right place. Duh.
git-svn-id: svn://svn.valgrind.org/valgrind/branches/COMEM@13140
2012-11-25 12:51:04 +00:00
Julian Seward
543f7090cd Create a copy of trunk r13138 to hold work on adding direct support
for conditional loads and stores to IR ("COnditional MEMory")



git-svn-id: svn://svn.valgrind.org/valgrind/COMEM@13139
2012-11-25 12:42:27 +00:00
Florian Krohm
e7f4d4f57f Fix some casts that removed const-ness as pointed out by
GCC's -Wcast-qual.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13138
2012-11-24 19:41:54 +00:00
Florian Krohm
af66466ce4 Changes to allow compilation with -Wwrite-strings. That compiler option
is not used for testcases, just for valgrind proper.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13137
2012-11-23 16:17:43 +00:00
Petar Jovanovic
e2110c0f00 Flush events in Callgrind before enering a RMW region.
On some MIPS platforms, we had an issue in which SC would fail each time
due to some memory access occuring in the RMW region.
If code for simulator events is called before LL, it can help SC to pass.

This change fixes a few LL/SC issues on MIPS arch.

The patch by Josef Weidendorfer.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13136
2012-11-23 00:01:36 +00:00
Florian Krohm
392c9a9492 Update list of ignored files.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13135
2012-11-22 18:57:29 +00:00
Julian Seward
8f2861e59b Another signedness fix.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13134
2012-11-22 11:07:04 +00:00
Julian Seward
831cf1f43b Fix up another char-signedness straggler.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13133
2012-11-22 10:48:20 +00:00
Julian Seward
f971b6f346 Add test cases for definedness propagation through PCMPISTRI $0x3A.
#309921, comment 7.  (Patrick J. LoPresti, lopresti@gmail.com)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13132
2012-11-20 15:25:32 +00:00
Josef Weidendorfer
635fe22514 Remove not-used typedef
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13131
2012-11-19 22:05:08 +00:00
Josef Weidendorfer
39cea8c6da Callgrind: fix Ir cost update for ignored functions
Also without cache simulation, Callgrind maintains Ir cost.
This is done in setup_bbcc by incrementing an execution counter
for last_bbcc (the cost center for the previously executed BB
in current context) and the global cost counter.

However, we forgot to increment any counter if the currently
executing function should be ignored. We need to still update
costs, add attribute this to a not-ignored call site (as
given in CLG_(current_state).nonskipped).

Before this fix, there was a difference in Ir cost with vs. without
cache simulation. This was because ignored functions (e.g. PLT code)
contributed no cost when not doing cache simulation.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13130
2012-11-19 22:05:06 +00:00
Julian Seward
0395372b49 Add test cases for dependency tracking through pmovmskb and bsfl.
Part of #308627.  (Patrick J. LoPresti, lopresti@gmail.com)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13129
2012-11-19 15:12:07 +00:00
Julian Seward
6f44cae342 Fix a couple of x86 char-signedness stragglers
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13128
2012-11-19 14:55:15 +00:00
Florian Krohm
c42327c171 One more Char/HChar mixup in conditional code. Reported by Bart.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13127
2012-11-18 22:15:22 +00:00
Florian Krohm
4a60891892 Re-establich configury checking for -Wno-pointer-sign. We need that
flag to compile pref/tinycc.c. Sigh.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13126
2012-11-18 14:39:11 +00:00
Florian Krohm
b87aa67392 Final patch for Char/HChar mixups.
Remove -Wno-pointer-sign from configure.in.
Fixes 273227.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13125
2012-11-18 00:36:15 +00:00
Carl Love
59fc40a7f3 vbit-tester, add counts for the number of 1, 2, 3 and 4 operand tests.
This patch adds code to count the number of each type of test.  The
number of 1, 2, 3 and 4 operand tests that are generated by the vbit-tester
are counted and printed by the vbit-tester.  The user should refer to the
Valgrind output to see if any of the tests failed.

The existing two verbose levels was increased by one level and the the
new output giving the number of tests was inserted as the first verbose
level.  The verbose levels are now:

-v        shows the number of 1, 2, 3 and 4 operand tests that are generated
-v -v     shows IROps being tested
-v -v -v  extreme edition, shows input values

This patch is for bugzilla 309229

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13124
2012-11-16 19:41:21 +00:00
Carl Love
adfd3e03b1 Valgrind, V-bit tester: Add support for Iop_CmpORD class iops
The Iop_CmpORD class of iops  support the POWER specific comparison
instructions.  The instructions take two 32-bit or 64-bit operands
and produce a result of the same size.  However, only the lower bits
of the result are set by the instruction.  The bits are set by the instruction
to indicate if the comparison is "less then", "greater then", or "equal".

This patch adds support to the V-bit tester to verify the propagation
of the undefined bits in the inputs to the output for the Iop_CmpORd iops.
The output bits are always set to undefined if any of the input bits are not
defined.

This patch is for bugzilla 310169 

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13123
2012-11-16 18:58:08 +00:00
Florian Krohm
117196ac6d Char/HChar fixups for m_debuginfo and m_gdbserver.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13122
2012-11-15 04:27:04 +00:00
Florian Krohm
12fec34e2f Add missing files. They should have been added in r13120.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13121
2012-11-11 13:59:54 +00:00
Florian Krohm
78ec60e0e7 Update s390_features.c for DFP.
Add a testcase.
Patch by Maran (maranp@linux.vnet.ibm.com).
Part of fixing BZ 307113.
See also VEX r2560.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13120
2012-11-10 22:35:24 +00:00
Florian Krohm
d0aa69c331 Fix more Char/HChar mixups. Closing in...
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13119
2012-11-10 22:29:54 +00:00
Florian Krohm
d29742d1f8 Update list of ignored files.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13118
2012-11-10 20:11:14 +00:00
Christian Borntraeger
bf1836a5d9 add BLKPBSZGET ioctl
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13117
2012-11-09 16:01:38 +00:00
Christian Borntraeger
d0b18e8cf4 Add missing EXTRA DIST statement
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13116
2012-11-09 08:35:50 +00:00
Christian Borntraeger
73744bb25f GETREGSET was introduced with 2.6.33.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13115
2012-11-09 08:06:14 +00:00
Florian Krohm
5dc9f96b48 Announce fix for BZ 308886.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13114
2012-11-08 23:04:16 +00:00
Christian Borntraeger
a4b734a6ac also wire up arm, x86 and amd64 regarding ptrace regsets
original patch from 
Andreas Arnez <arnez AT  linux DOT vnet DOT ibm DOT com>

Seems that ppc and mips dont have ptrace support....



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13113
2012-11-08 20:27:05 +00:00
Christian Borntraeger
4155f1b382 add s390 specific fix for getregset
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13112
2012-11-08 20:10:10 +00:00
Christian Borntraeger
b5bb5fa736 wire up testcase
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13111
2012-11-08 19:46:29 +00:00
Christian Borntraeger
6c0b993485 Add ptrace getreset testcase from Andreas Arnez
arnez AT  linux DOT vnet DOT ibm DOT com



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13110
2012-11-08 19:42:00 +00:00
Julian Seward
5bbaebd031 Ignore ELF sections that have zero size. Fixes #309600.
(Dragos Tatulea, dragos.tatulea@gmail.com)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13109
2012-11-08 15:45:16 +00:00
Julian Seward
1ef2516cd3 Improve accuracy of definedness tracking through the x86 PMOVMSKB and
BSF instructions, as the lack of it causes false positives (Valgrind
side).  Fixes #308627.  (Patrick J. LoPresti <lopresti@gmail.com>)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13108
2012-11-08 10:58:16 +00:00
Christian Borntraeger
797e1fd67d Same idea as for mips. sem_post does not fail on s390
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13107
2012-11-07 13:42:36 +00:00
Christian Borntraeger
ad1814e451 s390x machines z196 and zec12 have 4 levels of caches. Adopt the test suite
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13106
2012-11-07 07:57:01 +00:00
Philippe Waroquiers
d7eae8afe5 fix n-i-bz same as 303624 (fixed in 3.8.0), but for x86 android
(note: this might be a candidate if a 3.8.2 is done).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13105
2012-11-06 22:47:00 +00:00
Philippe Waroquiers
88d11f08b4 factorise sys_socketcall
sys_socketcall was duplicated in syswrap-{ppc64|ppc32|arm|mips32|s390x}-linux.c
=>
* Similarly for what was done for sys_ipc, factorise the code in syswrap-linux.c
* re-enabled PRE_MEM_READ for VKI_SYS_SENDMSG and VKI_SYS_RECVMSG 
  (PRE_MEM_READ calls were commented out around 2003, for what
   was supposed a glibc bug.
   The PRE_MEM_READ calls were already re-enabled in s390x)
* s390x also had some more checking to verify the addressibility of
  the args and fail the syscall with EFAULT if not addressable
  => same checks are now done for all platforms.

(tested on x86/amd64/mips32/s390x/ppc32/ppc64, 
 compiled for arm-android-emulator)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13104
2012-11-04 20:40:33 +00:00
Florian Krohm
5de39dd72a Fix Char/HChar mixups and constness in m_scheduler.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13103
2012-11-03 19:32:28 +00:00
Florian Krohm
b906e8df12 Fix Char/HChar mixups and constness in m_initimg.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13102
2012-11-03 19:18:10 +00:00
Florian Krohm
eec3191320 Char/HChar and constness fixes in m_ume
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13101
2012-11-03 18:28:20 +00:00
Florian Krohm
5a27187a2a s390: Autodetect cache info. These are the final bits to fix BZ 275800.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13100
2012-11-02 22:00:59 +00:00