You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(122) |
Nov
(152) |
Dec
(69) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(6) |
Feb
(25) |
Mar
(73) |
Apr
(82) |
May
(24) |
Jun
(25) |
Jul
(10) |
Aug
(11) |
Sep
(10) |
Oct
(54) |
Nov
(203) |
Dec
(182) |
| 2004 |
Jan
(307) |
Feb
(305) |
Mar
(430) |
Apr
(312) |
May
(187) |
Jun
(342) |
Jul
(487) |
Aug
(637) |
Sep
(336) |
Oct
(373) |
Nov
(441) |
Dec
(210) |
| 2005 |
Jan
(385) |
Feb
(480) |
Mar
(636) |
Apr
(544) |
May
(679) |
Jun
(625) |
Jul
(810) |
Aug
(838) |
Sep
(634) |
Oct
(521) |
Nov
(965) |
Dec
(543) |
| 2006 |
Jan
(494) |
Feb
(431) |
Mar
(546) |
Apr
(411) |
May
(406) |
Jun
(322) |
Jul
(256) |
Aug
(401) |
Sep
(345) |
Oct
(542) |
Nov
(308) |
Dec
(481) |
| 2007 |
Jan
(427) |
Feb
(326) |
Mar
(367) |
Apr
(255) |
May
(244) |
Jun
(204) |
Jul
(223) |
Aug
(231) |
Sep
(354) |
Oct
(374) |
Nov
(497) |
Dec
(362) |
| 2008 |
Jan
(322) |
Feb
(482) |
Mar
(658) |
Apr
(422) |
May
(476) |
Jun
(396) |
Jul
(455) |
Aug
(267) |
Sep
(280) |
Oct
(253) |
Nov
(232) |
Dec
(304) |
| 2009 |
Jan
(486) |
Feb
(470) |
Mar
(458) |
Apr
(423) |
May
(696) |
Jun
(461) |
Jul
(551) |
Aug
(575) |
Sep
(134) |
Oct
(110) |
Nov
(157) |
Dec
(102) |
| 2010 |
Jan
(226) |
Feb
(86) |
Mar
(147) |
Apr
(117) |
May
(107) |
Jun
(203) |
Jul
(193) |
Aug
(238) |
Sep
(300) |
Oct
(246) |
Nov
(23) |
Dec
(75) |
| 2011 |
Jan
(133) |
Feb
(195) |
Mar
(315) |
Apr
(200) |
May
(267) |
Jun
(293) |
Jul
(353) |
Aug
(237) |
Sep
(278) |
Oct
(611) |
Nov
(274) |
Dec
(260) |
| 2012 |
Jan
(303) |
Feb
(391) |
Mar
(417) |
Apr
(441) |
May
(488) |
Jun
(655) |
Jul
(590) |
Aug
(610) |
Sep
(526) |
Oct
(478) |
Nov
(359) |
Dec
(372) |
| 2013 |
Jan
(467) |
Feb
(226) |
Mar
(391) |
Apr
(281) |
May
(299) |
Jun
(252) |
Jul
(311) |
Aug
(352) |
Sep
(481) |
Oct
(571) |
Nov
(222) |
Dec
(231) |
| 2014 |
Jan
(185) |
Feb
(329) |
Mar
(245) |
Apr
(238) |
May
(281) |
Jun
(399) |
Jul
(382) |
Aug
(500) |
Sep
(579) |
Oct
(435) |
Nov
(487) |
Dec
(256) |
| 2015 |
Jan
(338) |
Feb
(357) |
Mar
(330) |
Apr
(294) |
May
(191) |
Jun
(108) |
Jul
(142) |
Aug
(261) |
Sep
(190) |
Oct
(54) |
Nov
(83) |
Dec
(22) |
| 2016 |
Jan
(49) |
Feb
(89) |
Mar
(33) |
Apr
(50) |
May
(27) |
Jun
(34) |
Jul
(53) |
Aug
(53) |
Sep
(98) |
Oct
(206) |
Nov
(93) |
Dec
(53) |
| 2017 |
Jan
(65) |
Feb
(82) |
Mar
(102) |
Apr
(86) |
May
(187) |
Jun
(67) |
Jul
(23) |
Aug
(93) |
Sep
(65) |
Oct
(45) |
Nov
(35) |
Dec
(17) |
| 2018 |
Jan
(26) |
Feb
(35) |
Mar
(38) |
Apr
(32) |
May
(8) |
Jun
(43) |
Jul
(27) |
Aug
(30) |
Sep
(43) |
Oct
(42) |
Nov
(38) |
Dec
(67) |
| 2019 |
Jan
(32) |
Feb
(37) |
Mar
(53) |
Apr
(64) |
May
(49) |
Jun
(18) |
Jul
(14) |
Aug
(53) |
Sep
(25) |
Oct
(30) |
Nov
(49) |
Dec
(31) |
| 2020 |
Jan
(87) |
Feb
(45) |
Mar
(37) |
Apr
(51) |
May
(99) |
Jun
(36) |
Jul
(11) |
Aug
(14) |
Sep
(20) |
Oct
(24) |
Nov
(40) |
Dec
(23) |
| 2021 |
Jan
(14) |
Feb
(53) |
Mar
(85) |
Apr
(15) |
May
(19) |
Jun
(3) |
Jul
(14) |
Aug
(1) |
Sep
(57) |
Oct
(73) |
Nov
(56) |
Dec
(22) |
| 2022 |
Jan
(3) |
Feb
(22) |
Mar
(6) |
Apr
(55) |
May
(46) |
Jun
(39) |
Jul
(15) |
Aug
(9) |
Sep
(11) |
Oct
(34) |
Nov
(20) |
Dec
(36) |
| 2023 |
Jan
(79) |
Feb
(41) |
Mar
(99) |
Apr
(169) |
May
(48) |
Jun
(16) |
Jul
(16) |
Aug
(57) |
Sep
(19) |
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
|
|
1
(21) |
|
2
(19) |
3
(33) |
4
(24) |
5
(18) |
6
(13) |
7
(22) |
8
(21) |
|
9
(38) |
10
(25) |
11
(20) |
12
(27) |
13
(43) |
14
(9) |
15
(19) |
|
16
(37) |
17
(19) |
18
(13) |
19
(11) |
20
(8) |
21
(11) |
22
(25) |
|
23
(21) |
24
(30) |
25
(18) |
26
(11) |
27
(10) |
28
(14) |
29
(40) |
|
30
(24) |
31
(14) |
|
|
|
|
|
|
From: Nuno L. <nun...@sa...> - 2008-03-11 23:41:45
|
> http://www.valgrind.org/docs/valgrind2007.pdf has some info on > optimisations performed in section 3.7. Note especially that there are > two optimisation phases. You'll want to read the surrounding sections > (and probably the whole paper) to make sense of it. > > VEX/priv/ir/iropt.c is the main file controlling Vex optimisation, I > believe. It has this comment near the top: > > The comments in VEX/pub/libvex_ir.h is the best documentation for Vex. > > As the Valgrind paper says, these are fairly heavyweight optimisations for > a binary translation system. You could try to do some more compiler-style > optimisations, but I think the scope for improvement there is not so > great. But I could be wrong -- Julian, what do you think? Uhm, it seems that most easy optimizations are already implemented, as I would expect. Anyway I'll take a closer look (maybe next week) to what is implemented to see if we have any chance do improve anything at all. Inter-block optimizations (e.g. inlining, GCSE, ...) would be really cool, but I'm not sure how Vex is suited for that. > A very interesting project you could be try would be to implement chaining > for Vex -- the Valgrind paper (above) talks about this. (Section 2.3.6 of > http://www.valgrind.org/docs/phd2004.pdf discusses the old implementation > of chaining that was in pre-Vex Valgrind -- you can see the actual > implementation in Valgrind 2.4.1 at > http://www.valgrind.org/downloads/old.html.) Sounds interesting, but maybe this requires too much valgrind internals knowledge, but I'll take a look into this as well. > An important question you should consider early is what your goals are. > More specifically, are you trying to speed up Valgrind's code when no > instrumentation is present? In one way, that's the obvious thing to do, > but it's also the least interesting thing to do (the paper talks about > this in section 5.4). A more interesting thing is to speed up any of the > real existing tools, especially Memcheck, since that's the most widely > used. Yes, but I'm not sure I can justify such a project about dynamic program analysis in a virtual execution class. The class is targeted at dynamic binary translation, binary interpretation, intra-block optimizations, virtualization, and so on. > As for giving the code you develop back, there's a complication -- Julian > is the sole author and thus owns the copyright for the Vex part of > Valgrind. This means that accepting external contributions for Vex is more > complicated than the rest of Valgrind. He might have more to add. OK, we can take care of the copyright stuff later if we come up with something useful. Thanks, Nuno |
|
From: <sv...@va...> - 2008-03-11 20:38:58
|
Author: bart
Date: 2008-03-11 20:39:01 +0000 (Tue, 11 Mar 2008)
New Revision: 7644
Log:
Reverted last commit.
Modified:
trunk/exp-drd/drd_pthread_intercepts.c
trunk/exp-drd/tests/tc18_semabuse.stderr.exp
trunk/exp-drd/tests/tc20_verifywrap.stderr.exp
trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp
Modified: trunk/exp-drd/drd_pthread_intercepts.c
===================================================================
--- trunk/exp-drd/drd_pthread_intercepts.c 2008-03-11 20:28:51 UTC (rev 7643)
+++ trunk/exp-drd/drd_pthread_intercepts.c 2008-03-11 20:39:01 UTC (rev 7644)
@@ -656,7 +656,7 @@
return ret;
}
-PTH_FUNC(int, semZuinitZAZAZa, // sem_init@@*
+PTH_FUNC(int, semZuinitZa, // sem_init*
sem_t *sem,
int pshared,
unsigned int value)
@@ -721,7 +721,7 @@
}
// sem_wait
-PTH_FUNC(int, semZuwaitZAZAZa, // sem_wait@@*
+PTH_FUNC(int, semZuwaitZa, // sem_wait*
sem_t *sem)
{
int ret;
@@ -800,7 +800,7 @@
}
// sem_post
-PTH_FUNC(int, semZupostZAZAZa, // sem_post@@*
+PTH_FUNC(int, semZupostZa, // sem_post*
sem_t *sem)
{
int ret;
Modified: trunk/exp-drd/tests/tc18_semabuse.stderr.exp
===================================================================
--- trunk/exp-drd/tests/tc18_semabuse.stderr.exp 2008-03-11 20:28:51 UTC (rev 7643)
+++ trunk/exp-drd/tests/tc18_semabuse.stderr.exp 2008-03-11 20:39:01 UTC (rev 7644)
@@ -1,6 +1,6 @@
Invalid semaphore: semaphore 0x........
- at 0x........: sem_wait@@* (drd_pthread_intercepts.c:?)
+ at 0x........: sem_wait* (drd_pthread_intercepts.c:?)
by 0x........: main (tc18_semabuse.c:34)
ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0)
Modified: trunk/exp-drd/tests/tc20_verifywrap.stderr.exp
===================================================================
--- trunk/exp-drd/tests/tc20_verifywrap.stderr.exp 2008-03-11 20:28:51 UTC (rev 7643)
+++ trunk/exp-drd/tests/tc20_verifywrap.stderr.exp 2008-03-11 20:39:01 UTC (rev 7644)
@@ -92,7 +92,7 @@
Invalid semaphore: semaphore 0x........
- at 0x........: sem_wait@@* (drd_pthread_intercepts.c:?)
+ at 0x........: sem_wait* (drd_pthread_intercepts.c:?)
by 0x........: main (tc20_verifywrap.c:242)
FIXME: can't figure out how to verify wrap of sem_post
Modified: trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp
===================================================================
--- trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp 2008-03-11 20:28:51 UTC (rev 7643)
+++ trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp 2008-03-11 20:39:01 UTC (rev 7644)
@@ -120,7 +120,7 @@
[1/1] semaphore_post_wait 0x........
Invalid semaphore: semaphore 0x........
- at 0x........: sem_wait@@* (drd_pthread_intercepts.c:?)
+ at 0x........: sem_wait* (drd_pthread_intercepts.c:?)
by 0x........: main (tc20_verifywrap.c:242)
[1/1] semaphore_post 0x........
|
|
From: Bart V. A. <bar...@gm...> - 2008-03-11 20:36:42
|
On Tue, Mar 11, 2008 at 12:59 PM, Julian Seward <js...@ac...> wrote: > > > view of Helgrind and DRD. Can you explain the purpose of the libgomp > > patch ? > > Without that patch, the libgomp barrier routine has inter thread > dependencies controlled by the value of a shared variable. Neither > drd nor helgrind will see those. The patch adds an extra semaphore > which generates just enough new inter-thread dependencies via > post/wait events, that the overall hb graph for the barrier as a > whole has correct dependencies. I investigated this by dumping the hb > graph to a file and using xvcg to look at it. I found another way to handle libgomp barriers: by intercepting them. Unfortunately this only works when libgomp.so contains debug information. Bart. |
|
From: Bart V. A. <bar...@gm...> - 2008-03-11 20:32:01
|
On Tue, Mar 11, 2008 at 12:44 PM, <sv...@va...> wrote: > Log: > More crude experimentation: ignore references in the lowest page of a > thread's stack. There is a good reason for doing so -- NPTL reserves the first 3KB (about) of the stack for private data associated with the thread. LinuxThreads did not do this. I found this out by reverse engineering the NPTL source code. Bart. |
|
From: <sv...@va...> - 2008-03-11 20:28:48
|
Author: bart
Date: 2008-03-11 20:28:51 +0000 (Tue, 11 Mar 2008)
New Revision: 7643
Log:
Resolved function redirection conflict.
Modified:
trunk/exp-drd/drd_pthread_intercepts.c
trunk/exp-drd/tests/tc18_semabuse.stderr.exp
trunk/exp-drd/tests/tc20_verifywrap.stderr.exp
trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp
Modified: trunk/exp-drd/drd_pthread_intercepts.c
===================================================================
--- trunk/exp-drd/drd_pthread_intercepts.c 2008-03-11 20:10:21 UTC (rev 7642)
+++ trunk/exp-drd/drd_pthread_intercepts.c 2008-03-11 20:28:51 UTC (rev 7643)
@@ -656,7 +656,7 @@
return ret;
}
-PTH_FUNC(int, semZuinitZa, // sem_init*
+PTH_FUNC(int, semZuinitZAZAZa, // sem_init@@*
sem_t *sem,
int pshared,
unsigned int value)
@@ -721,7 +721,7 @@
}
// sem_wait
-PTH_FUNC(int, semZuwaitZa, // sem_wait*
+PTH_FUNC(int, semZuwaitZAZAZa, // sem_wait@@*
sem_t *sem)
{
int ret;
@@ -800,7 +800,7 @@
}
// sem_post
-PTH_FUNC(int, semZupostZa, // sem_post*
+PTH_FUNC(int, semZupostZAZAZa, // sem_post@@*
sem_t *sem)
{
int ret;
Modified: trunk/exp-drd/tests/tc18_semabuse.stderr.exp
===================================================================
--- trunk/exp-drd/tests/tc18_semabuse.stderr.exp 2008-03-11 20:10:21 UTC (rev 7642)
+++ trunk/exp-drd/tests/tc18_semabuse.stderr.exp 2008-03-11 20:28:51 UTC (rev 7643)
@@ -1,6 +1,6 @@
Invalid semaphore: semaphore 0x........
- at 0x........: sem_wait* (drd_pthread_intercepts.c:?)
+ at 0x........: sem_wait@@* (drd_pthread_intercepts.c:?)
by 0x........: main (tc18_semabuse.c:34)
ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0)
Modified: trunk/exp-drd/tests/tc20_verifywrap.stderr.exp
===================================================================
--- trunk/exp-drd/tests/tc20_verifywrap.stderr.exp 2008-03-11 20:10:21 UTC (rev 7642)
+++ trunk/exp-drd/tests/tc20_verifywrap.stderr.exp 2008-03-11 20:28:51 UTC (rev 7643)
@@ -92,7 +92,7 @@
Invalid semaphore: semaphore 0x........
- at 0x........: sem_wait* (drd_pthread_intercepts.c:?)
+ at 0x........: sem_wait@@* (drd_pthread_intercepts.c:?)
by 0x........: main (tc20_verifywrap.c:242)
FIXME: can't figure out how to verify wrap of sem_post
Modified: trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp
===================================================================
--- trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp 2008-03-11 20:10:21 UTC (rev 7642)
+++ trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp 2008-03-11 20:28:51 UTC (rev 7643)
@@ -120,7 +120,7 @@
[1/1] semaphore_post_wait 0x........
Invalid semaphore: semaphore 0x........
- at 0x........: sem_wait* (drd_pthread_intercepts.c:?)
+ at 0x........: sem_wait@@* (drd_pthread_intercepts.c:?)
by 0x........: main (tc20_verifywrap.c:242)
[1/1] semaphore_post 0x........
|
|
From: <sv...@va...> - 2008-03-11 20:10:17
|
Author: bart
Date: 2008-03-11 20:10:21 +0000 (Tue, 11 Mar 2008)
New Revision: 7642
Log:
Added support for OpenMP barriers -- if libgomp.so has been built with debug information. More in general, added support for nested synchronization constructs.
Added:
trunk/exp-drd/drd_gomp_intercepts.c
Modified:
trunk/exp-drd/Makefile.am
trunk/exp-drd/TODO.txt
trunk/exp-drd/drd_barrier.c
trunk/exp-drd/drd_barrier.h
trunk/exp-drd/drd_bitmap.c
trunk/exp-drd/drd_bitmap.h
trunk/exp-drd/drd_clientobj.c
trunk/exp-drd/drd_clientobj.h
trunk/exp-drd/drd_clientreq.c
trunk/exp-drd/drd_clientreq.h
trunk/exp-drd/drd_cond.c
trunk/exp-drd/drd_cond.h
trunk/exp-drd/drd_error.c
trunk/exp-drd/drd_main.c
trunk/exp-drd/drd_mutex.c
trunk/exp-drd/drd_mutex.h
trunk/exp-drd/drd_pthread_intercepts.c
trunk/exp-drd/drd_rwlock.c
trunk/exp-drd/drd_rwlock.h
trunk/exp-drd/drd_semaphore.c
trunk/exp-drd/drd_semaphore.h
trunk/exp-drd/drd_thread.c
trunk/exp-drd/drd_thread.h
trunk/exp-drd/drd_track.h
trunk/exp-drd/pub_drd_bitmap.h
trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp
trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp-glibc2.3
trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp-glibc2.3-b
Modified: trunk/exp-drd/Makefile.am
===================================================================
--- trunk/exp-drd/Makefile.am 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/Makefile.am 2008-03-11 20:10:21 UTC (rev 7642)
@@ -20,7 +20,11 @@
noinst_PROGRAMS += exp-drd-ppc64-aix5 vgpreload_exp-drd-ppc64-aix5.so
endif
+if HAVE_GCC_FOPENMP
+VGPRELOAD_DRD_SOURCES_COMMON = drd_pthread_intercepts.c drd_gomp_intercepts.c
+else
VGPRELOAD_DRD_SOURCES_COMMON = drd_pthread_intercepts.c
+endif
vgpreload_exp_drd_x86_linux_so_SOURCES = $(VGPRELOAD_DRD_SOURCES_COMMON)
vgpreload_exp_drd_x86_linux_so_CPPFLAGS = $(AM_CPPFLAGS_X86_LINUX)
Modified: trunk/exp-drd/TODO.txt
===================================================================
--- trunk/exp-drd/TODO.txt 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/TODO.txt 2008-03-11 20:10:21 UTC (rev 7642)
@@ -30,15 +30,17 @@
- Add test programs for destroying a condition variable / semaphore / barrier
being waited upon.
- Add OpenMP examples to the regression tests.
+- Make sure an error message is printed if no debug information is found in
+ libopenmp.so.1.
- Make sure tc14_laog_dinphils is run during exp-drd regression tests.
- Find a way for suppressing races reported on _IO_2_1_stdout. This race is
triggered by calling printf() from more than one thread. Examples (AMD64):
./vg-in-place --tool=exp-drd exp-drd/tests/tc21_pthonce
./vg-in-place --tool=exp-drd exp-drd/tests/pth_detached 10 10 1
-- Performance testing and tuning.
- testing on PPC and AIX (current implementation is only tested on X86 and
AMD64).
- Convert the array in drd_thread.c with thread information into an OSet.
+- Performance testing and tuning.
- Optimize run time of the following test case:
./vg-in-place --tool=exp-drd exp-drd/tests/matinv 100
Modified: trunk/exp-drd/drd_barrier.c
===================================================================
--- trunk/exp-drd/drd_barrier.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_barrier.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -91,14 +91,13 @@
static
void barrier_initialize(struct barrier_info* const p,
const Addr barrier,
- const SizeT size,
+ const BarrierT barrier_type,
const Word count)
{
tl_assert(barrier != 0);
- tl_assert(size > 0);
+ tl_assert(barrier_type == pthread_barrier || barrier_type == gomp_barrier);
tl_assert(count > 0);
tl_assert(p->a1 == barrier);
- tl_assert(p->a2 - p->a1 == size);
p->cleanup = (void(*)(DrdClientobj*))barrier_cleanup;
p->count = count;
@@ -146,16 +145,19 @@
* found, add it. */
static
struct barrier_info*
-barrier_get_or_allocate(const Addr barrier, const SizeT size, const Word count)
+barrier_get_or_allocate(const Addr barrier,
+ const BarrierT barrier_type, const Word count)
{
struct barrier_info *p;
+ tl_assert(barrier_type == pthread_barrier || barrier_type == gomp_barrier);
+
tl_assert(offsetof(DrdClientobj, barrier) == 0);
p = &clientobj_get(barrier, ClientBarrier)->barrier;
if (p == 0)
{
- p = &clientobj_add(barrier, barrier + size, ClientBarrier)->barrier;
- barrier_initialize(p, barrier, size, count);
+ p = &clientobj_add(barrier, ClientBarrier)->barrier;
+ barrier_initialize(p, barrier, barrier_type, count);
}
return p;
}
@@ -172,8 +174,9 @@
* where count threads participate in each barrier.
* Called before pthread_barrier_init().
*/
-struct barrier_info*
-barrier_init(const Addr barrier, const SizeT size, const Word count)
+void barrier_init(const Addr barrier,
+ const BarrierT barrier_type, const Word count,
+ const Bool reinitialization)
{
if (s_trace_barrier)
{
@@ -184,11 +187,12 @@
barrier);
}
tl_assert(barrier_get(barrier) == 0);
- return barrier_get_or_allocate(barrier, size, count);
+ tl_assert(barrier_type == pthread_barrier || barrier_type == gomp_barrier);
+ barrier_get_or_allocate(barrier, barrier_type, count);
}
/** Called after pthread_barrier_destroy(). */
-void barrier_destroy(const Addr barrier)
+void barrier_destroy(const Addr barrier, const BarrierT barrier_type)
{
struct barrier_info* p;
@@ -217,7 +221,8 @@
}
/** Called before pthread_barrier_wait(). */
-void barrier_pre_wait(const DrdThreadId tid, const Addr barrier)
+void barrier_pre_wait(const DrdThreadId tid, const Addr barrier,
+ const BarrierT barrier_type)
{
struct barrier_info* p;
struct barrier_thread_info* q;
@@ -256,7 +261,7 @@
/** Called after pthread_barrier_wait(). */
void barrier_post_wait(const DrdThreadId tid, const Addr barrier,
- const Bool waited)
+ const BarrierT barrier_type, const Bool waited)
{
struct barrier_info* p;
Modified: trunk/exp-drd/drd_barrier.h
===================================================================
--- trunk/exp-drd/drd_barrier.h 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_barrier.h 2008-03-11 20:10:21 UTC (rev 7642)
@@ -30,21 +30,24 @@
#define __DRD_BARRIER_H
-#include "drd_thread.h" // DrdThreadId
+#include "drd_clientreq.h" // BarrierT
+#include "drd_thread.h" // DrdThreadId
#include "drd_vc.h"
-#include "pub_tool_basics.h" // Addr, SizeT
+#include "pub_tool_basics.h" // Addr
struct barrier_info;
void barrier_set_trace(const Bool trace_barrier);
-struct barrier_info* barrier_init(const Addr barrier, const SizeT size,
- const Word count);
-void barrier_destroy(const Addr barrier);
-void barrier_pre_wait(const DrdThreadId tid, const Addr barrier);
+void barrier_init(const Addr barrier,
+ const BarrierT barrier_type, const Word count,
+ const Bool reinitialization);
+void barrier_destroy(const Addr barrier, const BarrierT barrier_type);
+void barrier_pre_wait(const DrdThreadId tid, const Addr barrier,
+ const BarrierT barrier_type);
void barrier_post_wait(const DrdThreadId tid, const Addr barrier,
- const Bool waited);
+ const BarrierT barrier_type, const Bool waited);
void barrier_thread_delete(const DrdThreadId threadid);
void barrier_stop_using_mem(const Addr a1, const Addr a2);
Modified: trunk/exp-drd/drd_bitmap.c
===================================================================
--- trunk/exp-drd/drd_bitmap.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_bitmap.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -151,9 +151,9 @@
* bitmap bm.
*/
void bm_access_range(struct bitmap* const bm,
- const Addr a,
- const SizeT size,
- const BmAccessTypeT access_type)
+ const Addr a,
+ const SizeT size,
+ const BmAccessTypeT access_type)
{
tl_assert(bm);
tl_assert(size > 0);
Modified: trunk/exp-drd/drd_bitmap.h
===================================================================
--- trunk/exp-drd/drd_bitmap.h 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_bitmap.h 2008-03-11 20:10:21 UTC (rev 7642)
@@ -46,12 +46,12 @@
#define ADDR0_MASK (ADDR0_COUNT - 1)
-#define SPLIT_ADDRESS(a) \
- UWord a##0 = ((a) & ADDR0_MASK); \
+#define SPLIT_ADDRESS(a) \
+ UWord a##0 = ((a) & ADDR0_MASK); \
UWord a##1 = ((a) >> ADDR0_BITS);
// Assumption: sizeof(Addr) == sizeof(UWord).
-#define MAKE_ADDRESS(a1, a0) \
+#define MAKE_ADDRESS(a1, a0) \
(Addr)(((UWord)(a1) << (ADDR0_BITS)) | ((UWord)(a0)))
#define BITS_PER_UWORD (8UL*sizeof(UWord))
Modified: trunk/exp-drd/drd_clientobj.c
===================================================================
--- trunk/exp-drd/drd_clientobj.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_clientobj.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -92,8 +92,7 @@
VG_(OSetGen_ResetIter)(s_clientobj);
for ( ; (p = VG_(OSetGen_Next)(s_clientobj)) != 0; )
{
- if ((a1 <= p->any.a1 && p->any.a1 < a2)
- || (a1 < p->any.a2 && p->any.a2 <= a2))
+ if (a1 <= p->any.a1 && p->any.a1 < a2)
{
return True;
}
@@ -106,12 +105,11 @@
* @pre No other client object is present in the address range [addr,addr+size[.
*/
DrdClientobj*
-clientobj_add(const Addr a1, const Addr a2, const ObjType t)
+clientobj_add(const Addr a1, const ObjType t)
{
DrdClientobj* p;
- tl_assert(a1 < a2 && a1 + 4096 > a2);
- tl_assert(! clientobj_present(a1, a2));
+ tl_assert(! clientobj_present(a1, a1 + 1));
tl_assert(VG_(OSetGen_Lookup)(s_clientobj, &a1) == 0);
if (s_trace_clientobj)
@@ -122,11 +120,9 @@
p = VG_(OSetGen_AllocNode)(s_clientobj, sizeof(*p));
VG_(memset)(p, 0, sizeof(*p));
p->any.a1 = a1;
- p->any.a2 = a2;
p->any.type = t;
VG_(OSetGen_Insert)(s_clientobj, p);
tl_assert(VG_(OSetGen_Lookup)(s_clientobj, &a1) == p);
- drd_start_suppression(p->any.a1, p->any.a2, "client object");
return p;
}
@@ -150,7 +146,6 @@
if (p)
{
tl_assert(VG_(OSetGen_Lookup)(s_clientobj, &addr) == 0);
- drd_finish_suppression(p->any.a1, p->any.a2);
tl_assert(p->any.cleanup);
(*p->any.cleanup)(p);
VG_(OSetGen_FreeNode)(s_clientobj, p);
@@ -169,8 +164,7 @@
p = VG_(OSetGen_Next)(s_clientobj);
for ( ; p != 0; )
{
- if ((a1 <= p->any.a1 && p->any.a1 < a2)
- || (a1 < p->any.a2 && p->any.a2 <= a2))
+ if (a1 <= p->any.a1 && p->any.a1 < a2)
{
removed_at = p->any.a1;
clientobj_remove(p->any.a1, p->any.type);
Modified: trunk/exp-drd/drd_clientobj.h
===================================================================
--- trunk/exp-drd/drd_clientobj.h 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_clientobj.h 2008-03-11 20:10:21 UTC (rev 7642)
@@ -51,7 +51,6 @@
struct any
{
Addr a1;
- Addr a2;
ObjType type;
void (*cleanup)(union drd_clientobj*);
};
@@ -59,7 +58,6 @@
struct mutex_info
{
Addr a1;
- Addr a2;
ObjType type;
void (*cleanup)(union drd_clientobj*);
MutexT mutex_type; // pthread_mutex_t or pthread_spinlock_t.
@@ -71,7 +69,6 @@
struct cond_info
{
Addr a1;
- Addr a2;
ObjType type;
void (*cleanup)(union drd_clientobj*);
int waiter_count;
@@ -82,7 +79,6 @@
struct semaphore_info
{
Addr a1;
- Addr a2;
ObjType type;
void (*cleanup)(union drd_clientobj*);
UWord value; // Semaphore value.
@@ -94,7 +90,6 @@
struct barrier_info
{
Addr a1;
- Addr a2;
ObjType type;
void (*cleanup)(union drd_clientobj*);
Word count; // Participant count in a barrier wait.
@@ -109,7 +104,6 @@
struct rwlock_info
{
Addr a1;
- Addr a2;
ObjType type;
void (*cleanup)(union drd_clientobj*);
OSet* thread_info;
@@ -133,7 +127,7 @@
void clientobj_cleanup(void);
DrdClientobj* clientobj_get(const Addr addr, const ObjType t);
Bool clientobj_present(const Addr a1, const Addr a2);
-DrdClientobj* clientobj_add(const Addr a1, const Addr a2, const ObjType t);
+DrdClientobj* clientobj_add(const Addr a1, const ObjType t);
Bool clientobj_remove(const Addr addr, const ObjType t);
void clientobj_stop_using_mem(const Addr a1, const Addr a2);
void clientobj_resetiter(void);
Modified: trunk/exp-drd/drd_clientreq.c
===================================================================
--- trunk/exp-drd/drd_clientreq.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_clientreq.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -41,7 +41,7 @@
#include "pub_tool_tooliface.h" // VG_(needs_...)()
-static void drd_spin_init_or_unlock(const Addr spinlock, const SizeT size)
+static void drd_spin_init_or_unlock(const Addr spinlock)
{
struct mutex_info* mutex_p = mutex_get(spinlock);
if (mutex_p)
@@ -50,15 +50,15 @@
}
else
{
- mutex_init(spinlock, size, mutex_type_spinlock);
+ mutex_init(spinlock, mutex_type_spinlock);
}
}
-static void drd_pre_cond_wait(const Addr cond, const SizeT cond_size,
+static void drd_pre_cond_wait(const Addr cond,
const Addr mutex, const MutexT mutex_type)
{
mutex_unlock(mutex, mutex_type);
- cond_pre_wait(cond, cond_size, mutex);
+ cond_pre_wait(cond, mutex);
}
static void drd_post_cond_wait(const Addr cond,
@@ -79,19 +79,22 @@
cond_pre_broadcast(cond);
}
-static Bool drd_handle_client_request(ThreadId tid, UWord* arg, UWord* ret)
+static Bool drd_handle_client_request(ThreadId vg_tid, UWord* arg, UWord* ret)
{
UWord result = 0;
+ const DrdThreadId drd_tid = thread_get_running_tid();
+ tl_assert(vg_tid == VG_(get_running_tid()));
+ tl_assert(VgThreadIdToDrdThreadId(vg_tid) == drd_tid);
+
switch (arg[0])
{
case VG_USERREQ__GET_THREAD_SELF:
- result = tid;
+ result = vg_tid;
break;
case VG_USERREQ__SET_THREAD_NAME:
- thread_set_name_fmt(VgThreadIdToDrdThreadId(VG_(get_running_tid)()),
- (char*)arg[1], arg[2]);
+ thread_set_name_fmt(drd_tid, (char*)arg[1], arg[2]);
break;
case VG_USERREQ__DRD_START_SUPPRESSION:
@@ -103,8 +106,7 @@
break;
case VG_USERREQ__DRD_SUPPRESS_CURRENT_STACK:
- thread_set_stack_startup(thread_get_running_tid(),
- VG_(get_SP)(VG_(get_running_tid)()));
+ thread_set_stack_startup(drd_tid, VG_(get_SP)(vg_tid));
break;
case VG_USERREQ__DRD_START_NEW_SEGMENT:
@@ -116,7 +118,7 @@
break;
case VG_USERREQ__SET_PTHREADID:
- thread_set_pthreadid(thread_get_running_tid(), arg[1]);
+ thread_set_pthreadid(drd_tid, arg[1]);
break;
case VG_USERREQ__SET_JOINABLE:
@@ -125,101 +127,150 @@
case VG_USERREQ__POST_THREAD_JOIN:
tl_assert(arg[1]);
- drd_post_thread_join(thread_get_running_tid(),
+ drd_post_thread_join(drd_tid,
PtThreadIdToDrdThreadId(arg[1]));
break;
case VG_USERREQ__PRE_MUTEX_INIT:
- drd_pre_mutex_init(arg[1], arg[2], arg[3]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_pre_mutex_init(arg[1], arg[2]);
break;
+ case VG_USERREQ__POST_MUTEX_INIT:
+ thread_leave_synchr(drd_tid);
+ break;
+
+ case VG_USERREQ__PRE_MUTEX_DESTROY:
+ thread_enter_synchr(drd_tid);
+ break;
+
case VG_USERREQ__POST_MUTEX_DESTROY:
- drd_post_mutex_destroy(arg[1], arg[2]);
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_post_mutex_destroy(arg[1], arg[2]);
break;
- case VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK:
- drd_pre_mutex_lock(arg[1], arg[2], arg[3]);
+ case VG_USERREQ__PRE_MUTEX_LOCK:
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_pre_mutex_lock(arg[1], arg[2]);
break;
- case VG_USERREQ__POST_PTHREAD_MUTEX_LOCK:
- drd_post_mutex_lock(arg[1], arg[2]);
+ case VG_USERREQ__POST_MUTEX_LOCK:
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_post_mutex_lock(arg[1], arg[2]);
break;
- case VG_USERREQ__PRE_PTHREAD_MUTEX_UNLOCK:
- drd_pre_mutex_unlock(arg[1], arg[3]);
+ case VG_USERREQ__PRE_MUTEX_UNLOCK:
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_pre_mutex_unlock(arg[1], arg[2]);
break;
+ case VG_USERREQ__POST_MUTEX_UNLOCK:
+ thread_leave_synchr(drd_tid);
+ break;
+
case VG_USERREQ__SPIN_INIT_OR_UNLOCK:
- drd_spin_init_or_unlock(arg[1], arg[2]);
+ tl_assert(thread_get_synchr_nesting_count(drd_tid) == 0);
+ drd_spin_init_or_unlock(arg[1]);
break;
- case VG_USERREQ__PRE_PTHREAD_COND_INIT:
- drd_pre_cond_init(arg[1], arg[2]);
+ case VG_USERREQ__PRE_COND_INIT:
+ tl_assert(thread_get_synchr_nesting_count(drd_tid) == 0);
+ drd_pre_cond_init(arg[1]);
break;
- case VG_USERREQ__POST_PTHREAD_COND_DESTROY:
+ case VG_USERREQ__POST_COND_DESTROY:
+ tl_assert(thread_get_synchr_nesting_count(drd_tid) == 0);
drd_post_cond_destroy(arg[1]);
break;
- case VG_USERREQ__PRE_PTHREAD_COND_WAIT:
- drd_pre_cond_wait(arg[1]/*cond*/, arg[2]/*cond_size*/,
- arg[3]/*mutex*/, arg[4]/*mutex_type*/);
+ case VG_USERREQ__PRE_COND_WAIT:
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_pre_cond_wait(arg[1], arg[2], arg[3]);
break;
- case VG_USERREQ__POST_PTHREAD_COND_WAIT:
- drd_post_cond_wait(arg[1]/*cond*/, arg[2]/*mutex*/, arg[3]/*took_lock*/);
+ case VG_USERREQ__POST_COND_WAIT:
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_post_cond_wait(arg[1], arg[2], arg[3]);
break;
- case VG_USERREQ__PRE_PTHREAD_COND_SIGNAL:
+ case VG_USERREQ__PRE_COND_SIGNAL:
+ tl_assert(thread_get_synchr_nesting_count(drd_tid) == 0);
drd_pre_cond_signal(arg[1]);
break;
- case VG_USERREQ__PRE_PTHREAD_COND_BROADCAST:
+ case VG_USERREQ__PRE_COND_BROADCAST:
+ tl_assert(thread_get_synchr_nesting_count(drd_tid) == 0);
drd_pre_cond_broadcast(arg[1]);
break;
- case VG_USERREQ__SEM_INIT:
- drd_semaphore_init(arg[1], arg[2], arg[3], arg[4]);
+ case VG_USERREQ__PRE_SEM_INIT:
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_semaphore_init(arg[1], arg[2], arg[3]);
break;
- case VG_USERREQ__SEM_DESTROY:
- drd_semaphore_destroy(arg[1]);
+ case VG_USERREQ__POST_SEM_INIT:
+ thread_leave_synchr(drd_tid);
break;
+ case VG_USERREQ__PRE_SEM_DESTROY:
+ thread_enter_synchr(drd_tid);
+ break;
+
+ case VG_USERREQ__POST_SEM_DESTROY:
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_semaphore_destroy(arg[1]);
+ break;
+
case VG_USERREQ__PRE_SEM_WAIT:
- drd_semaphore_pre_wait(thread_get_running_tid(), arg[1], arg[2]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_semaphore_pre_wait(drd_tid, arg[1]);
break;
case VG_USERREQ__POST_SEM_WAIT:
- drd_semaphore_post_wait(thread_get_running_tid(), arg[1], arg[2]);
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_semaphore_post_wait(drd_tid, arg[1], arg[2]);
break;
case VG_USERREQ__PRE_SEM_POST:
- drd_semaphore_pre_post(thread_get_running_tid(), arg[1], arg[2]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_semaphore_pre_post(drd_tid, arg[1]);
break;
case VG_USERREQ__POST_SEM_POST:
- drd_semaphore_post_post(thread_get_running_tid(), arg[1], arg[2], arg[3]);
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_semaphore_post_post(drd_tid, arg[1], arg[2]);
break;
- case VG_USERREQ__BARRIER_INIT:
- drd_barrier_init(arg[1], arg[2], arg[3]);
+ case VG_USERREQ__PRE_BARRIER_INIT:
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_barrier_init(arg[1], arg[2], arg[3], arg[4]);
break;
- case VG_USERREQ__BARRIER_DESTROY:
- drd_barrier_destroy(arg[1]);
+ case VG_USERREQ__POST_BARRIER_INIT:
+ thread_leave_synchr(drd_tid);
break;
+ case VG_USERREQ__PRE_BARRIER_DESTROY:
+ thread_enter_synchr(drd_tid);
+ break;
+
+ case VG_USERREQ__POST_BARRIER_DESTROY:
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_barrier_destroy(arg[1], arg[2]);
+ break;
+
case VG_USERREQ__PRE_BARRIER_WAIT:
- drd_barrier_pre_wait(thread_get_running_tid(), arg[1]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ drd_barrier_pre_wait(drd_tid, arg[1], arg[2]);
break;
case VG_USERREQ__POST_BARRIER_WAIT:
- drd_barrier_post_wait(thread_get_running_tid(), arg[1], arg[2]);
+ if (thread_leave_synchr(drd_tid) == 0)
+ drd_barrier_post_wait(drd_tid, arg[1], arg[2], arg[3]);
break;
case VG_USERREQ__PRE_RWLOCK_INIT:
- rwlock_pre_init(arg[1], arg[2]);
+ rwlock_pre_init(arg[1]);
break;
case VG_USERREQ__POST_RWLOCK_DESTROY:
@@ -227,24 +278,33 @@
break;
case VG_USERREQ__PRE_RWLOCK_RDLOCK:
- rwlock_pre_rdlock(arg[1], arg[2]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ rwlock_pre_rdlock(arg[1]);
break;
case VG_USERREQ__POST_RWLOCK_RDLOCK:
- rwlock_post_rdlock(arg[1], arg[2]);
+ if (thread_leave_synchr(drd_tid) == 0)
+ rwlock_post_rdlock(arg[1], arg[2]);
break;
case VG_USERREQ__PRE_RWLOCK_WRLOCK:
- rwlock_pre_wrlock(arg[1], arg[2]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ rwlock_pre_wrlock(arg[1]);
break;
case VG_USERREQ__POST_RWLOCK_WRLOCK:
- rwlock_post_wrlock(arg[1], arg[2]);
+ if (thread_leave_synchr(drd_tid) == 0)
+ rwlock_post_wrlock(arg[1], arg[2]);
break;
case VG_USERREQ__PRE_RWLOCK_UNLOCK:
- rwlock_pre_unlock(arg[1]);
+ if (thread_enter_synchr(drd_tid) == 0)
+ rwlock_pre_unlock(arg[1]);
break;
+
+ case VG_USERREQ__POST_RWLOCK_UNLOCK:
+ thread_leave_synchr(drd_tid);
+ break;
default:
VG_(message)(Vg_DebugMsg, "Unrecognized client request 0x%lx 0x%lx",
Modified: trunk/exp-drd/drd_clientreq.h
===================================================================
--- trunk/exp-drd/drd_clientreq.h 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_clientreq.h 2008-03-11 20:10:21 UTC (rev 7642)
@@ -49,89 +49,113 @@
/* to notify the drd tool of a pthread_mutex_init call. */
VG_USERREQ__PRE_MUTEX_INIT,
/* args: Addr, MutexT */
+ /* to notify the drd tool of a pthread_mutex_init call. */
+ VG_USERREQ__POST_MUTEX_INIT,
+ /* args: Addr */
/* to notify the drd tool of a pthread_mutex_destroy call. */
+ VG_USERREQ__PRE_MUTEX_DESTROY,
+ /* args: Addr */
+ /* to notify the drd tool of a pthread_mutex_destroy call. */
VG_USERREQ__POST_MUTEX_DESTROY,
- /* args: Addr, SizeT, MutexT */
+ /* args: Addr, MutexT */
/* to notify the drd tool of pthread_mutex_lock calls */
- VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK,
- /* args: Addr, SizeT, MutexT */
+ VG_USERREQ__PRE_MUTEX_LOCK,
+ /* args: Addr, MutexT */
/* to notify the drd tool of pthread_mutex_lock calls */
- VG_USERREQ__POST_PTHREAD_MUTEX_LOCK,
+ VG_USERREQ__POST_MUTEX_LOCK,
/* args: Addr, Bool */
/* to notify the drd tool of pthread_mutex_unlock calls */
- VG_USERREQ__PRE_PTHREAD_MUTEX_UNLOCK,
+ VG_USERREQ__PRE_MUTEX_UNLOCK,
/* args: Addr */
+ /* to notify the drd tool of pthread_mutex_unlock calls */
+ VG_USERREQ__POST_MUTEX_UNLOCK,
+ /* args: Addr */
VG_USERREQ__SPIN_INIT_OR_UNLOCK,
- /* args: Addr spinlock, SizeT size */
+ /* args: Addr spinlock */
/* to notify the drd tool of a pthread_cond_init call. */
- VG_USERREQ__PRE_PTHREAD_COND_INIT,
+ VG_USERREQ__PRE_COND_INIT,
/* args: Addr */
/* to notify the drd tool of a pthread_cond_destroy call. */
- VG_USERREQ__POST_PTHREAD_COND_DESTROY,
- /* args: Addr cond, SizeT cond_size, Addr mutex, SizeT mutex_size,MutexT mt*/
- VG_USERREQ__PRE_PTHREAD_COND_WAIT,
- /* args: Addr cond, SizeT cond_size, Addr mutex, MutexT mt */
- VG_USERREQ__POST_PTHREAD_COND_WAIT,
+ VG_USERREQ__POST_COND_DESTROY,
+ /* args: Addr cond */
+ VG_USERREQ__PRE_COND_WAIT,
+ /* args: Addr cond, Addr mutex, MutexT mt */
+ VG_USERREQ__POST_COND_WAIT,
/* args: Addr cond, Addr mutex, Bool took_lock*/
- VG_USERREQ__PRE_PTHREAD_COND_SIGNAL,
+ VG_USERREQ__PRE_COND_SIGNAL,
/* args: Addr cond */
- VG_USERREQ__PRE_PTHREAD_COND_BROADCAST,
+ VG_USERREQ__PRE_COND_BROADCAST,
/* args: Addr cond */
/* To notify the drd tool of a sem_init call. */
- VG_USERREQ__SEM_INIT,
- /* args: Addr sem, SizeT sem_size, Word pshared, Word value */
+ VG_USERREQ__PRE_SEM_INIT,
+ /* args: Addr sem, Word pshared, Word value */
+ /* To notify the drd tool of a sem_init call. */
+ VG_USERREQ__POST_SEM_INIT,
+ /* args: Addr sem */
/* To notify the drd tool of a sem_destroy call. */
- VG_USERREQ__SEM_DESTROY,
+ VG_USERREQ__PRE_SEM_DESTROY,
/* args: Addr sem */
+ /* To notify the drd tool of a sem_destroy call. */
+ VG_USERREQ__POST_SEM_DESTROY,
+ /* args: Addr sem */
/* To notify the drd tool of a sem_wait call. */
VG_USERREQ__PRE_SEM_WAIT,
- /* args: Addr sem, SizeT sem_size */
+ /* args: Addr sem */
/* To notify the drd tool of a sem_wait call. */
VG_USERREQ__POST_SEM_WAIT,
/* args: Addr sem, Bool waited */
/* To notify the drd tool before a sem_post call. */
VG_USERREQ__PRE_SEM_POST,
- /* args: Addr sem, SizeT sem_size */
+ /* args: Addr sem */
/* To notify the drd tool after a sem_post call. */
VG_USERREQ__POST_SEM_POST,
- /* args: Addr sem, SizeT sem_size, Bool waited */
+ /* args: Addr sem, Bool waited */
/* To notify the drd tool of a pthread_barrier_init call. */
- VG_USERREQ__BARRIER_INIT,
- /* args: Addr barrier, SizeT barrier_size, Word count */
+ VG_USERREQ__PRE_BARRIER_INIT,
+ /* args: Addr barrier, BarrierT type, Word count, Bool reinit */
+ /* To notify the drd tool of a pthread_barrier_init call. */
+ VG_USERREQ__POST_BARRIER_INIT,
+ /* args: Addr barrier, BarrierT type */
/* To notify the drd tool of a pthread_barrier_destroy call. */
- VG_USERREQ__BARRIER_DESTROY,
- /* args: Addr barrier */
+ VG_USERREQ__PRE_BARRIER_DESTROY,
+ /* args: Addr barrier, BarrierT type. */
+ /* To notify the drd tool of a pthread_barrier_destroy call. */
+ VG_USERREQ__POST_BARRIER_DESTROY,
+ /* args: Addr barrier, BarrierT type. */
/* To notify the drd tool of a pthread_barrier_wait call. */
VG_USERREQ__PRE_BARRIER_WAIT,
- /* args: Addr barrier */
+ /* args: Addr barrier, BarrierT type. */
/* To notify the drd tool of a pthread_barrier_wait call. */
VG_USERREQ__POST_BARRIER_WAIT,
- /* args: Addr barrier, Word has_waited */
+ /* args: Addr barrier, BarrierT type, Word has_waited */
/* To notify the drd tool of a pthread_rwlock_init call. */
VG_USERREQ__PRE_RWLOCK_INIT,
- /* args: Addr rwlock, SizeT size */
+ /* args: Addr rwlock */
/* To notify the drd tool of a pthread_rwlock_destroy call. */
VG_USERREQ__POST_RWLOCK_DESTROY,
- /* args: Addr rwlock, SizeT size */
+ /* args: Addr rwlock */
/* To notify the drd tool of a pthread_rwlock_rdlock call. */
VG_USERREQ__PRE_RWLOCK_RDLOCK,
- /* args: Addr rwlock, SizeT size */
+ /* args: Addr rwlock */
/* To notify the drd tool of a pthread_rwlock_rdlock call. */
VG_USERREQ__POST_RWLOCK_RDLOCK,
/* args: Addr rwlock, Bool took_lock */
/* To notify the drd tool of a pthread_rwlock_wrlock call. */
VG_USERREQ__PRE_RWLOCK_WRLOCK,
- /* args: Addr rwlock, SizeT size */
+ /* args: Addr rwlock */
/* To notify the drd tool of a pthread_rwlock_wrlock call. */
VG_USERREQ__POST_RWLOCK_WRLOCK,
/* args: Addr rwlock, Bool took_lock */
/* To notify the drd tool of a pthread_rwlock_unlock call. */
VG_USERREQ__PRE_RWLOCK_UNLOCK,
+ /* args: Addr rwlock */
+ /* To notify the drd tool of a pthread_rwlock_unlock call. */
+ VG_USERREQ__POST_RWLOCK_UNLOCK,
/* args: Addr rwlock, Bool unlocked */
};
@@ -145,5 +169,10 @@
mutex_type_spinlock = 4,
} MutexT;
+typedef enum
+ {
+ pthread_barrier = 1,
+ gomp_barrier = 2,
+ } BarrierT;
#endif // __DRD_CLIENTREQ_H
Modified: trunk/exp-drd/drd_cond.c
===================================================================
--- trunk/exp-drd/drd_cond.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_cond.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -54,12 +54,10 @@
}
static
-void cond_initialize(struct cond_info* const p, const Addr cond,
- const SizeT size)
+void cond_initialize(struct cond_info* const p, const Addr cond)
{
tl_assert(cond != 0);
tl_assert(p->a1 == cond);
- tl_assert(p->a2 - p->a1 == size);
tl_assert(p->type == ClientCondvar);
p->cleanup = (void(*)(DrdClientobj*))cond_cleanup;
@@ -90,8 +88,7 @@
}
}
-static struct cond_info*
-cond_get_or_allocate(const Addr cond, const SizeT size)
+static struct cond_info* cond_get_or_allocate(const Addr cond)
{
struct cond_info *p;
@@ -99,8 +96,8 @@
p = &clientobj_get(cond, ClientCondvar)->cond;
if (p == 0)
{
- p = &clientobj_add(cond, cond + size, ClientCondvar)->cond;
- cond_initialize(p, cond, size);
+ p = &clientobj_add(cond, ClientCondvar)->cond;
+ cond_initialize(p, cond);
}
return p;
}
@@ -112,7 +109,7 @@
}
/** Called before pthread_cond_init(). */
-void cond_pre_init(const Addr cond, const SizeT size)
+void cond_pre_init(const Addr cond)
{
struct cond_info* p;
@@ -125,8 +122,6 @@
cond);
}
- tl_assert(size > 0);
-
p = cond_get(cond);
if (p)
@@ -139,7 +134,7 @@
&cei);
}
- p = cond_get_or_allocate(cond, size);
+ p = cond_get_or_allocate(cond);
}
/** Called after pthread_cond_destroy(). */
@@ -183,7 +178,7 @@
}
/** Called before pthread_cond_wait(). */
-int cond_pre_wait(const Addr cond, const SizeT cond_size, const Addr mutex)
+int cond_pre_wait(const Addr cond, const Addr mutex)
{
struct cond_info* p;
@@ -196,7 +191,7 @@
cond);
}
- p = cond_get_or_allocate(cond, cond_size);
+ p = cond_get_or_allocate(cond);
tl_assert(p);
if (p->waiter_count == 0)
Modified: trunk/exp-drd/drd_cond.h
===================================================================
--- trunk/exp-drd/drd_cond.h 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_cond.h 2008-03-11 20:10:21 UTC (rev 7642)
@@ -32,16 +32,16 @@
#include "drd_thread.h" // DrdThreadid
-#include "pub_tool_basics.h" // Addr, SizeT
+#include "pub_tool_basics.h" // Addr
struct cond_info;
void cond_set_trace(const Bool trace_cond);
-void cond_pre_init(const Addr cond, const SizeT size);
+void cond_pre_init(const Addr cond);
void cond_post_destroy(const Addr cond);
-int cond_pre_wait(const Addr cond, const SizeT cond_size, const Addr mutex);
+int cond_pre_wait(const Addr cond, const Addr mutex);
int cond_post_wait(const Addr cond);
void cond_pre_signal(const Addr cond);
void cond_pre_broadcast(const Addr cond);
Modified: trunk/exp-drd/drd_error.c
===================================================================
--- trunk/exp-drd/drd_error.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_error.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -249,8 +249,9 @@
else if (ai.akind == eMallocd && ai.lastchange)
{
VG_(message)(Vg_UserMsg,
- "Address 0x%08lx is at offset %ld. Allocation context:",
- dri->addr, ai.rwoffset);
+ "Address 0x%lx is at offset %ld from 0x%lx."
+ " Allocation context:",
+ dri->addr, ai.rwoffset, dri->addr - ai.rwoffset);
VG_(pp_ExeContext)(ai.lastchange);
}
else
Added: trunk/exp-drd/drd_gomp_intercepts.c
===================================================================
--- trunk/exp-drd/drd_gomp_intercepts.c (rev 0)
+++ trunk/exp-drd/drd_gomp_intercepts.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -0,0 +1,118 @@
+
+/*--------------------------------------------------------------------*/
+/*--- Client-space code for drd. drd_gomp_intercepts.c ---*/
+/*--------------------------------------------------------------------*/
+
+/*
+ This file is part of drd, a data race detector.
+
+ Copyright (C) 2006-2008 Bart Van Assche
+ bar...@gm...
+
+ This program is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License as
+ published by the Free Software Foundation; either version 2 of the
+ License, or (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307, USA.
+
+ The GNU General Public License is contained in the file COPYING.
+*/
+
+/* ---------------------------------------------------------------------
+ ALL THE CODE IN THIS FILE RUNS ON THE SIMULATED CPU.
+
+ These functions are not called directly - they're the targets of code
+ redirection or load notifications (see pub_core_redir.h for info).
+ They're named weirdly so that the intercept code can find them when the
+ shared object is initially loaded.
+
+ Note that this filename has the "drd_" prefix because it can appear
+ in stack traces, and the "drd_" makes it a little clearer that it
+ originates from Valgrind.
+ ------------------------------------------------------------------ */
+
+#include <assert.h>
+#include "drd_clientreq.h"
+#include "pub_tool_redir.h"
+
+
+// Defines.
+
+#define GOMP_FUNC(ret_ty, f, args...) \
+ ret_ty VG_WRAP_FUNCTION_ZZ(libgompZdsoZd1Za,f)(args); \
+ ret_ty VG_WRAP_FUNCTION_ZZ(libgompZdsoZd1Za,f)(args)
+
+
+// Type definitions
+
+typedef void* gomp_barrier_t;
+
+
+// Function definitions.
+
+GOMP_FUNC(void, gompZubarrierZuinit, // gomp_barrier_init
+ gomp_barrier_t* barrier, unsigned count)
+{
+ int ret;
+ int res;
+ OrigFn fn;
+
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_INIT,
+ barrier, gomp_barrier, count, 0, 0);
+ VALGRIND_GET_ORIG_FN(fn);
+ CALL_FN_W_WW(ret, fn, barrier, count);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_INIT,
+ barrier, gomp_barrier, 0, 0, 0);
+}
+
+GOMP_FUNC(void, gompZubarrierZureinit, // gomp_barrier_reinit
+ gomp_barrier_t* barrier, unsigned count)
+{
+ int ret;
+ int res;
+ OrigFn fn;
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_INIT,
+ barrier, gomp_barrier, count, 1, 0);
+ VALGRIND_GET_ORIG_FN(fn);
+ CALL_FN_W_WW(ret, fn, barrier, count);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_INIT,
+ barrier, gomp_barrier, 0, 0, 0);
+}
+
+GOMP_FUNC(void, gompZubarrierZudestroy, // gomp_barrier_destroy
+ gomp_barrier_t* barrier)
+{
+ int ret;
+ int res;
+ OrigFn fn;
+ VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_DESTROY,
+ barrier, gomp_barrier,
+ 0, 0, 0);
+ CALL_FN_W_W(ret, fn, barrier);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_DESTROY,
+ barrier, gomp_barrier, 0, 0, 0);
+}
+
+GOMP_FUNC(void, gompZubarrierZuwait, // gomp_barrier_wait
+ gomp_barrier_t* barrier)
+{
+ int ret;
+ int res;
+ OrigFn fn;
+ VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_WAIT,
+ barrier, gomp_barrier, 0, 0, 0);
+ CALL_FN_W_W(ret, fn, barrier);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_WAIT,
+ barrier, gomp_barrier, 1, 0, 0);
+}
Modified: trunk/exp-drd/drd_main.c
===================================================================
--- trunk/exp-drd/drd_main.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_main.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -156,6 +156,9 @@
tl_assert(thread_get_running_tid()
== VgThreadIdToDrdThreadId(VG_(get_running_tid())));
+ if (! thread_is_recording(thread_get_running_tid()))
+ return;
+
#if 1
if (drd_trace_mem || (addr == drd_trace_address))
{
@@ -199,6 +202,9 @@
tl_assert(thread_get_running_tid()
== VgThreadIdToDrdThreadId(VG_(get_running_tid())));
+ if (! thread_is_recording(thread_get_running_tid()))
+ return;
+
#if 1
if (drd_trace_mem || (addr == drd_trace_address))
{
@@ -230,7 +236,7 @@
VG_(maybe_record_error)(VG_(get_running_tid)(),
DataRaceErr,
VG_(get_IP)(VG_(get_running_tid)()),
- "Conflicting accesses",
+ "Conflicting accesses",
&drei);
}
}
@@ -452,10 +458,9 @@
thread_finished(drd_tid);
}
-void drd_pre_mutex_init(const Addr mutex, const SizeT size,
- const MutexT mutex_type)
+void drd_pre_mutex_init(const Addr mutex, const MutexT mutex_type)
{
- mutex_init(mutex, size, mutex_type);
+ mutex_init(mutex, mutex_type);
}
void drd_post_mutex_destroy(const Addr mutex, const MutexT mutex_type)
@@ -463,11 +468,9 @@
mutex_post_destroy(mutex);
}
-void drd_pre_mutex_lock(const Addr mutex,
- const SizeT size,
- const MutexT mutex_type)
+void drd_pre_mutex_lock(const Addr mutex, const MutexT mutex_type)
{
- mutex_pre_lock(mutex, size, mutex_type);
+ mutex_pre_lock(mutex, mutex_type);
}
void drd_post_mutex_lock(const Addr mutex, const Bool took_lock)
@@ -480,9 +483,9 @@
mutex_unlock(mutex, mutex_type);
}
-void drd_pre_cond_init(Addr cond, SizeT s)
+void drd_pre_cond_init(Addr cond)
{
- cond_pre_init(cond, s);
+ cond_pre_init(cond);
}
void drd_post_cond_destroy(Addr cond)
@@ -490,10 +493,10 @@
cond_post_destroy(cond);
}
-void drd_semaphore_init(const Addr semaphore, const SizeT size,
+void drd_semaphore_init(const Addr semaphore,
const Word pshared, const Word value)
{
- semaphore_init(semaphore, size, pshared, value);
+ semaphore_init(semaphore, pshared, value);
}
void drd_semaphore_destroy(const Addr semaphore)
@@ -501,10 +504,9 @@
semaphore_destroy(semaphore);
}
-void drd_semaphore_pre_wait(const DrdThreadId tid, const Addr semaphore,
- const SizeT size)
+void drd_semaphore_pre_wait(const DrdThreadId tid, const Addr semaphore)
{
- semaphore_pre_wait(semaphore, size);
+ semaphore_pre_wait(semaphore);
}
void drd_semaphore_post_wait(const DrdThreadId tid, const Addr semaphore,
@@ -513,38 +515,40 @@
semaphore_post_wait(tid, semaphore, waited);
}
-void drd_semaphore_pre_post(const DrdThreadId tid, const Addr semaphore,
- const SizeT size)
+void drd_semaphore_pre_post(const DrdThreadId tid, const Addr semaphore)
{
- semaphore_pre_post(tid, semaphore, size);
+ semaphore_pre_post(tid, semaphore);
}
void drd_semaphore_post_post(const DrdThreadId tid, const Addr semaphore,
- const SizeT size, const Bool waited)
+ const Bool waited)
{
- semaphore_post_post(tid, semaphore, size, waited);
+ semaphore_post_post(tid, semaphore, waited);
}
-void drd_barrier_init(const Addr barrier, const SizeT size, const Word count)
+void drd_barrier_init(const Addr barrier,
+ const BarrierT barrier_type, const Word count,
+ const Bool reinitialization)
{
- barrier_init(barrier, size, count);
+ barrier_init(barrier, barrier_type, count, reinitialization);
}
-void drd_barrier_destroy(const Addr barrier)
+void drd_barrier_destroy(const Addr barrier, const BarrierT barrier_type)
{
- barrier_destroy(barrier);
+ barrier_destroy(barrier, barrier_type);
}
-void drd_barrier_pre_wait(const DrdThreadId tid, const Addr barrier)
+void drd_barrier_pre_wait(const DrdThreadId tid, const Addr barrier,
+ const BarrierT barrier_type)
{
- barrier_pre_wait(tid, barrier);
+ barrier_pre_wait(tid, barrier, barrier_type);
}
void drd_barrier_post_wait(const DrdThreadId tid, const Addr barrier,
- const Bool waited)
+ const BarrierT barrier_type, const Bool waited)
{
- barrier_post_wait(tid, barrier, waited);
+ barrier_post_wait(tid, barrier, barrier_type, waited);
}
@@ -596,7 +600,7 @@
{
case Ist_IMark:
instrument = VG_(seginfo_sect_kind)(NULL, 0, st->Ist.IMark.addr)
- != Vg_SectPLT;
+ != Vg_SectPLT;
break;
case Ist_MBE:
@@ -623,7 +627,7 @@
{
addr_expr = st->Ist.Store.addr;
size_expr = mkIRExpr_HWord(
- sizeofIRType(typeOfIRExpr(bb->tyenv, st->Ist.Store.data)));
+ sizeofIRType(typeOfIRExpr(bb->tyenv, st->Ist.Store.data)));
argv = mkIRExprVec_2(addr_expr, size_expr);
di = unsafeIRDirty_0_N(/*regparms*/2,
"drd_trace_store",
Modified: trunk/exp-drd/drd_mutex.c
===================================================================
--- trunk/exp-drd/drd_mutex.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_mutex.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -57,15 +57,11 @@
static
void mutex_initialize(struct mutex_info* const p,
- const Addr mutex,
- const SizeT size,
- const MutexT mutex_type)
+ const Addr mutex, const MutexT mutex_type)
{
tl_assert(mutex != 0);
- tl_assert(size > 0);
tl_assert(p->a1 == mutex);
- tl_assert(p->a2 == mutex + size);
p->cleanup = (void(*)(DrdClientobj*))&mutex_cleanup;
p->mutex_type = mutex_type;
p->recursion_count = 0;
@@ -101,9 +97,7 @@
static
struct mutex_info*
-mutex_get_or_allocate(const Addr mutex,
- const SizeT size,
- const MutexT mutex_type)
+mutex_get_or_allocate(const Addr mutex, const MutexT mutex_type)
{
struct mutex_info* p;
@@ -111,12 +105,10 @@
p = &clientobj_get(mutex, ClientMutex)->mutex;
if (p)
{
- tl_assert(p->mutex_type == mutex_type);
- tl_assert(p->a2 - p->a1 == size);
return p;
}
- if (clientobj_present(mutex, mutex + size))
+ if (clientobj_present(mutex, mutex + 1))
{
GenericErrInfo GEI;
VG_(maybe_record_error)(VG_(get_running_tid)(),
@@ -127,8 +119,8 @@
return 0;
}
- p = &clientobj_add(mutex, mutex + size, ClientMutex)->mutex;
- mutex_initialize(p, mutex, size, mutex_type);
+ p = &clientobj_add(mutex, ClientMutex)->mutex;
+ mutex_initialize(p, mutex, mutex_type);
return p;
}
@@ -140,7 +132,7 @@
/** Called before pthread_mutex_init(). */
struct mutex_info*
-mutex_init(const Addr mutex, const SizeT size, const MutexT mutex_type)
+mutex_init(const Addr mutex, const MutexT mutex_type)
{
struct mutex_info* p;
@@ -178,7 +170,7 @@
&MEI);
return p;
}
- p = mutex_get_or_allocate(mutex, size, mutex_type);
+ p = mutex_get_or_allocate(mutex, mutex_type);
return p;
}
@@ -208,22 +200,24 @@
* an attempt is made to lock recursively a synchronization object that must
* not be locked recursively.
*/
-void mutex_pre_lock(const Addr mutex, const SizeT size, MutexT mutex_type)
+void mutex_pre_lock(const Addr mutex, MutexT mutex_type)
{
struct mutex_info* p;
- p = mutex_get(mutex);
+ p = mutex_get_or_allocate(mutex, mutex_type);
+ tl_assert(p);
+
if (s_trace_mutex)
{
VG_(message)(Vg_UserMsg,
"[%d/%d] pre_mutex_lock %s 0x%lx rc %d owner %d",
VG_(get_running_tid)(),
thread_get_running_tid(),
- p ? mutex_get_typename(p) : "(?)",
+ mutex_get_typename(p),
mutex,
- p ? p->recursion_count : 0,
- p ? p->owner : VG_INVALID_THREADID);
+ p->recursion_count,
+ p->owner);
}
if (mutex_type == mutex_type_invalid_mutex)
@@ -237,13 +231,6 @@
return;
}
- if (p == 0)
- {
- p = mutex_init(mutex, size, mutex_type);
- }
-
- tl_assert(p);
-
if (p->owner == thread_get_running_tid()
&& p->recursion_count >= 1
&& mutex_type != mutex_type_recursive_mutex)
Modified: trunk/exp-drd/drd_mutex.h
===================================================================
--- trunk/exp-drd/drd_mutex.h 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_mutex.h 2008-03-11 20:10:21 UTC (rev 7642)
@@ -33,18 +33,18 @@
#include "drd_clientreq.h" // MutexT
#include "drd_thread.h" // DrdThreadId
#include "drd_vc.h"
-#include "pub_tool_basics.h" // Addr, SizeT
+#include "pub_tool_basics.h" // Addr
struct mutex_info;
void mutex_set_trace(const Bool trace_mutex);
-struct mutex_info* mutex_init(const Addr mutex, const SizeT size,
+struct mutex_info* mutex_init(const Addr mutex,
const MutexT mutex_type);
void mutex_post_destroy(const Addr mutex);
struct mutex_info* mutex_get(const Addr mutex);
-void mutex_pre_lock(const Addr mutex, const SizeT size,
+void mutex_pre_lock(const Addr mutex,
const MutexT mutex_type);
void mutex_post_lock(const Addr mutex, const Bool took_lock);
void mutex_unlock(const Addr mutex, const MutexT mutex_type);
Modified: trunk/exp-drd/drd_pthread_intercepts.c
===================================================================
--- trunk/exp-drd/drd_pthread_intercepts.c 2008-03-11 20:06:50 UTC (rev 7641)
+++ trunk/exp-drd/drd_pthread_intercepts.c 2008-03-11 20:10:21 UTC (rev 7642)
@@ -321,14 +321,16 @@
int ret;
int res;
OrigFn fn;
- int mt = PTHREAD_MUTEX_DEFAULT;
+ int mt;
VALGRIND_GET_ORIG_FN(fn);
+ mt = PTHREAD_MUTEX_DEFAULT;
if (attr)
pthread_mutexattr_gettype(attr, &mt);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_MUTEX_INIT,
- mutex, sizeof(*mutex),
- pthread_to_drd_mutex_type(mt), 0, 0);
+ mutex, pthread_to_drd_mutex_type(mt), 0, 0, 0);
CALL_FN_W_WW(ret, fn, mutex, attr);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_MUTEX_INIT,
+ mutex, 0, 0, 0, 0);
return ret;
}
@@ -340,6 +342,8 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_MUTEX_DESTROY,
+ mutex, 0, 0, 0, 0);
CALL_FN_W_W(ret, fn, mutex);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_MUTEX_DESTROY,
mutex, mutex_type(mutex), 0, 0, 0);
@@ -354,10 +358,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK,
- mutex, sizeof(*mutex), mutex_type(mutex), 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_MUTEX_LOCK,
+ mutex, mutex_type(mutex), 0, 0, 0);
CALL_FN_W_W(ret, fn, mutex);
- VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__POST_PTHREAD_MUTEX_LOCK,
+ VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__POST_MUTEX_LOCK,
mutex, ret == 0, 0, 0, 0);
return ret;
}
@@ -370,10 +374,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK,
- mutex, sizeof(*mutex), mutex_type(mutex), 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_MUTEX_LOCK,
+ mutex, mutex_type(mutex), 0, 0, 0);
CALL_FN_W_W(ret, fn, mutex);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_MUTEX_LOCK,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_MUTEX_LOCK,
mutex, ret == 0, 0, 0, 0);
return ret;
}
@@ -387,10 +391,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK,
- mutex, sizeof(*mutex), mutex_type(mutex), 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_MUTEX_LOCK,
+ mutex, mutex_type(mutex), 0, 0, 0);
CALL_FN_W_WW(ret, fn, mutex, abs_timeout);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_MUTEX_LOCK,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_MUTEX_LOCK,
mutex, ret == 0, 0, 0, 0);
return ret;
}
@@ -404,9 +408,12 @@
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
VALGRIND_DO_CLIENT_REQUEST(res, -1,
- VG_USERREQ__PRE_PTHREAD_MUTEX_UNLOCK,
- mutex, sizeof(*mutex), mutex_type(mutex), 0, 0);
+ VG_USERREQ__PRE_MUTEX_UNLOCK,
+ mutex, mutex_type(mutex), 0, 0, 0);
CALL_FN_W_W(ret, fn, mutex);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1,
+ VG_USERREQ__POST_MUTEX_UNLOCK,
+ mutex, 0, 0, 0, 0);
return ret;
}
@@ -419,8 +426,8 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_PTHREAD_COND_INIT,
- cond, sizeof(*cond), 0, 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_COND_INIT,
+ cond, 0, 0, 0, 0);
CALL_FN_W_WW(ret, fn, cond, attr);
return ret;
}
@@ -434,7 +441,7 @@
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
CALL_FN_W_W(ret, fn, cond);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_COND_DESTROY,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_COND_DESTROY,
cond, 0, 0, 0, 0);
return ret;
}
@@ -448,11 +455,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_PTHREAD_COND_WAIT,
- cond, sizeof(*cond), mutex, mutex_type(mutex),
- 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_COND_WAIT,
+ cond, mutex, mutex_type(mutex), 0, 0);
CALL_FN_W_WW(ret, fn, cond, mutex);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_COND_WAIT,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_COND_WAIT,
cond, mutex, ret == 0, 0, 0);
return ret;
}
@@ -467,11 +473,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_PTHREAD_COND_WAIT,
- cond, sizeof(*cond), mutex, mutex_type(mutex),
- 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_COND_WAIT,
+ cond, mutex, mutex_type(mutex), 0, 0);
CALL_FN_W_WWW(ret, fn, cond, mutex, abstime);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_COND_WAIT,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_COND_WAIT,
cond, mutex, ret == 0, 0, 0);
return ret;
}
@@ -484,7 +489,7 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_PTHREAD_COND_SIGNAL,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_COND_SIGNAL,
cond, 0, 0, 0, 0);
CALL_FN_W_W(ret, fn, cond);
return ret;
@@ -498,7 +503,7 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_PTHREAD_COND_BROADCAST,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_COND_BROADCAST,
cond, 0, 0, 0, 0);
CALL_FN_W_W(ret, fn, cond);
return ret;
@@ -515,8 +520,7 @@
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SPIN_INIT_OR_UNLOCK,
- spinlock, sizeof(*spinlock),
- mutex_type_spinlock, 0, 0);
+ spinlock, mutex_type_spinlock, 0, 0, 0);
CALL_FN_W_WW(ret, fn, spinlock, pshared);
return ret;
}
@@ -543,11 +547,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK,
- spinlock, sizeof(*spinlock), mutex_type_spinlock,
- 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_MUTEX_LOCK,
+ spinlock, mutex_type_spinlock, 0, 0, 0);
CALL_FN_W_W(ret, fn, spinlock);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_MUTEX_LOCK,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_MUTEX_LOCK,
spinlock, ret == 0, 0, 0, 0);
return ret;
}
@@ -560,11 +563,10 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_PTHREAD_MUTEX_LOCK,
- spinlock, sizeof(*spinlock), mutex_type_spinlock,
- 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, 0, VG_USERREQ__PRE_MUTEX_LOCK,
+ spinlock, mutex_type_spinlock, 0, 0, 0);
CALL_FN_W_W(ret, fn, spinlock);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_PTHREAD_MUTEX_LOCK,
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_MUTEX_LOCK,
spinlock, ret == 0, 0, 0, 0);
return ret;
}
@@ -578,8 +580,7 @@
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SPIN_INIT_OR_UNLOCK,
- spinlock, sizeof(*spinlock),
- mutex_type_spinlock, 0, 0);
+ spinlock, mutex_type_spinlock, 0, 0, 0);
CALL_FN_W_W(ret, fn, spinlock);
return ret;
}
@@ -594,10 +595,11 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__BARRIER_INIT,
- barrier, sizeof(*barrier),
- count, 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_INIT,
+ barrier, pthread_barrier, count, 0, 0);
CALL_FN_W_WWW(ret, fn, barrier, attr, count);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_INIT,
+ barrier, pthread_barrier, 0, 0, 0);
return ret;
}
@@ -609,9 +611,11 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_DESTROY,
+ barrier, pthread_barrier, 0, 0, 0);
CALL_FN_W_W(ret, fn, barrier);
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__BARRIER_DESTROY,
- barrier, 0, 0, 0, 0);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_DESTROY,
+ barrier, pthread_barrier, 0, 0, 0);
return ret;
}
@@ -624,22 +628,19 @@
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_BARRIER_WAIT,
- barrier, 0, 0, 0, 0);
+ barrier, pthread_barrier, 0, 0, 0);
CALL_FN_W_W(ret, fn, barrier);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_BARRIER_WAIT,
- barrier,
+ barrier, pthread_barrier,
ret == 0 || ret == PTHREAD_BARRIER_SERIAL_THREAD,
- 0, 0, 0);
+ 0, 0);
return ret;
}
-// From glibc 2.0 linuxthreads/sysdeps/pthread/cmpxchg/semaphorebits.h
-typedef struct { long int sem_status; } sem_t_glibc_2_0;
-
// sem_init
PTH_FUNC(int, semZuinitZAGLIBCZu2Zd0, // sem_init@GLIBC_2.0
- sem_t_glibc_2_0 *sem,
+ sem_t *sem,
int pshared,
unsigned int value)
{
@@ -647,13 +648,11 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_SEM_INIT,
+ sem, pshared, value, 0, 0);
CALL_FN_W_WWW(ret, fn, sem, pshared, value);
- if (ret == 0)
- {
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SEM_INIT,
- sem, sizeof(*sem),
- pshared, value, 0);
- }
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_SEM_INIT,
+ sem, 0, 0, 0, 0);
return ret;
}
@@ -666,30 +665,27 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_SEM_INIT,
+ sem, pshared, value, 0, 0);
CALL_FN_W_WWW(ret, fn, sem, pshared, value);
- if (ret == 0)
- {
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SEM_INIT,
- sem, sizeof(*sem),
- pshared, value, 0);
- }
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_SEM_INIT,
+ sem, 0, 0, 0, 0);
return ret;
}
// sem_destroy
PTH_FUNC(int, semZudestroyZAGLIBCZu2Zd0, // sem_destroy@GLIBC_2.0
- sem_t_glibc_2_0 *sem)
+ sem_t *sem)
{
int ret;
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_SEM_DESTROY,
+ sem, 0, 0, 0, 0);
CALL_FN_W_W(ret, fn, sem);
- if (ret == 0)
- {
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SEM_DESTROY,
- sem, 0, 0, 0, 0);
- }
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_SEM_DESTROY,
+ sem, 0, 0, 0, 0);
return ret;
}
@@ -700,18 +696,17 @@
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_SEM_DESTROY,
+ sem, 0, 0, 0, 0);
CALL_FN_W_W(ret, fn, sem);
- if (ret == 0)
- {
- VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__SEM_DESTROY,
- sem, 0, 0, 0, 0);
- }
+ VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_SEM_DESTROY,
+ sem, 0, 0, 0, 0);
return ret;
}
// sem_wait
PTH_FUNC(int, semZuwaitZAGLIBCZu2Zd0, // sem_wait@GLIBC_2.0
- sem_t_glibc_2_0 *sem)
+ sem_t *sem)
{
int ret;
int res;
@@ -743,7 +738,7 @@
// sem_trywait
PTH_FUNC(int, semZutrywaitZAGLIBCZu2Zd0, // sem_trywait@GLIBC_2.0
- sem_t_glibc_2_0 *sem)
+ sem_t *sem)
{
int ret;
int res;
@@ -790,17 +785,17 @@
// sem_post
PTH_FUNC(int, semZupostZAGLIBCZu2Zd0, // sem_post@GLIBC_2.0
- sem_t_glibc_2_0 *sem)
+ sem_t *sem)
{
int ret;
int res;
OrigFn fn;
VALGRIND_GET_ORIG_FN(fn);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__PRE_SEM_POST,
- sem, sizeof(*sem), 0, 0, 0);
+ sem, 0, 0, 0, 0);
CALL_FN_W_W(ret, fn, sem);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__POST_SEM_POST,
- sem, sizeof(*sem), ret == 0, 0, 0);
+ sem, ret == 0, 0, 0, 0);
return ret;
}
@@ -813,10 +808,10 @@
OrigF...
[truncated message content] |
|
From: <sv...@va...> - 2008-03-11 20:06:45
|
Author: bart
Date: 2008-03-11 20:06:50 +0000 (Tue, 11 Mar 2008)
New Revision: 7641
Log:
Converted tabs into spaces.
Modified:
trunk/exp-drd/tests/pth_create_chain.c
Modified: trunk/exp-drd/tests/pth_create_chain.c
===================================================================
--- trunk/exp-drd/tests/pth_create_chain.c 2008-03-11 20:06:04 UTC (rev 7640)
+++ trunk/exp-drd/tests/pth_create_chain.c 2008-03-11 20:06:50 UTC (rev 7641)
@@ -20,10 +20,10 @@
// std::cout << "create " << thread_count << std::endl;
s_arg[thread_count] = thread_count;
pthread_create(&s_thread[thread_count], 0, thread_func,
- &s_arg[thread_count]);
+ &s_arg[thread_count]);
#if 0
std::cout << "created " << thread_count << "(" << s_thread[thread_count]
- << ")" << std::endl;
+ << ")" << std::endl;
#endif
}
return 0;
@@ -40,10 +40,10 @@
thread_count--;
// std::cout << "create " << thread_count << std::endl;
pthread_create(&s_thread[thread_count], 0, thread_func,
- &thread_count);
+ &thread_count);
#if 0
std::cout << "created " << thread_count << "(" << s_thread[thread_count]
- << ")" << std::endl;
+ << ")" << std::endl;
#endif
for (i = thread_count; i >= 0; i--)
{
|
|
From: <sv...@va...> - 2008-03-11 20:06:03
|
Author: bart
Date: 2008-03-11 20:06:04 +0000 (Tue, 11 Mar 2008)
New Revision: 7640
Log:
Depending on the fourth command line argument, a racy or non-racy run is started.
Modified:
trunk/exp-drd/tests/matinv_openmp.c
Modified: trunk/exp-drd/tests/matinv_openmp.c
===================================================================
--- trunk/exp-drd/tests/matinv_openmp.c 2008-03-11 19:46:45 UTC (rev 7639)
+++ trunk/exp-drd/tests/matinv_openmp.c 2008-03-11 20:06:04 UTC (rev 7640)
@@ -26,6 +26,13 @@
typedef double elem_t;
+/********************/
+/* Local variables. */
+/********************/
+
+static int s_trigger_race;
+
+
/*************************/
/* Function definitions. */
/*************************/
@@ -186,18 +193,37 @@
}
// Reduce all rows j != i.
-#pragma omp parallel for private(j, k)
- for (j = 0; j < rows; j++)
+
+ if (s_trigger_race)
{
- if (i != j)
+# pragma omp parallel for
+ for (j = 0; j < rows; j++)
{
- const elem_t factor = a[j * cols + i];
- for (k = 0; k < cols; k++)
+ if (i != j)
{
- a[j * cols + k] -= a[i * cols + k] * factor;
+ const elem_t factor = a[j * cols + i];
+ for (k = 0; k < cols; k++)
+ {
+ a[j * cols + k] -= a[i * cols + k] * factor;
+ }
}
}
}
+ else
+ {
+# pragma omp parallel for private(j, k)
+ for (j = 0; j < rows; j++)
+ {
+ if (i != j)
+ {
+ const elem_t factor = a[j * cols + i];
+ for (k = 0; k < cols; k++)
+ {
+ a[j * cols + k] -= a[i * cols + k] * factor;
+ }
+ }
+ }
+ }
}
}
@@ -258,9 +284,10 @@
double error;
double ratio;
- matrix_size = (argc > 1) ? atoi(argv[1]) : 3;
- nthread = (argc > 2) ? atoi(argv[2]) : 3;
- silent = (argc > 3) ? atoi(argv[3]) : 0;
+ matrix_size = (argc > 1) ? atoi(argv[1]) : 3;
+ nthread = (argc > 2) ? atoi(argv[2]) : 3;
+ silent = (argc > 3) ? atoi(argv[3]) : 0;
+ s_trigger_race = (argc > 4) ? atoi(argv[4]) : 0;
omp_set_num_threads(nthread);
omp_set_dynamic(0);
|
|
From: <sv...@va...> - 2008-03-11 19:46:47
|
Author: bart
Date: 2008-03-11 19:46:45 +0000 (Tue, 11 Mar 2008)
New Revision: 7639
Log:
Added an OpenMP suppression pattern.
Modified:
trunk/glibc-2.X-drd.supp
Modified: trunk/glibc-2.X-drd.supp
===================================================================
--- trunk/glibc-2.X-drd.supp 2008-03-11 18:29:35 UTC (rev 7638)
+++ trunk/glibc-2.X-drd.supp 2008-03-11 19:46:45 UTC (rev 7639)
@@ -334,3 +334,9 @@
exp-drd:ConflictingAccess
fun:_pthread_cleanup_push_defer
}
+{
+ gomp
+ exp-drd:ConflictingAccess
+ obj:/usr/lib*/libgomp.so*
+ obj:/usr/lib*/libgomp.so*
+}
|
|
From: <sv...@va...> - 2008-03-11 18:29:32
|
Author: bart Date: 2008-03-11 18:29:35 +0000 (Tue, 11 Mar 2008) New Revision: 7638 Log: Renamed drd_intercepts.c into drd_pthread_intercepts.c. Added: trunk/exp-drd/drd_pthread_intercepts.c Removed: trunk/exp-drd/drd_intercepts.c Modified: trunk/exp-drd/Makefile.am trunk/exp-drd/tests/hg03_inherit.stderr.exp trunk/exp-drd/tests/hg03_inherit.stderr.exp2 trunk/exp-drd/tests/hg04_race.stderr.exp trunk/exp-drd/tests/hg05_race2.stderr.exp trunk/exp-drd/tests/omp_prime.c trunk/exp-drd/tests/pth_cond_race.stderr.exp trunk/exp-drd/tests/recursive_mutex.stderr.exp trunk/exp-drd/tests/rwlock_race.stderr.exp trunk/exp-drd/tests/tc09_bad_unlock.stderr.exp trunk/exp-drd/tests/tc09_bad_unlock.stderr.exp-linuxthreads trunk/exp-drd/tests/tc10_rec_lock.stderr.exp trunk/exp-drd/tests/tc10_rec_lock.stderr.exp-linuxthreads trunk/exp-drd/tests/tc12_rwl_trivial.stderr.exp trunk/exp-drd/tests/tc12_rwl_trivial.stderr.exp-linuxthreads trunk/exp-drd/tests/tc18_semabuse.stderr.exp trunk/exp-drd/tests/tc20_verifywrap.stderr.exp trunk/exp-drd/tests/tc20_verifywrap.stderr.exp-glibc2.3 trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp-glibc2.3 trunk/exp-drd/tests/tc20_verifywrap2.stderr.exp-glibc2.3-b trunk/exp-drd/tests/tc22_exit_w_lock.stderr.exp-32bit trunk/exp-drd/tests/tc22_exit_w_lock.stderr.exp-64bit trunk/exp-drd/tests/tc23_bogus_condwait.stderr.exp trunk/exp-drd/tests/trylock.stderr.exp [... diff too large to include ...] |
|
From: <sv...@va...> - 2008-03-11 18:15:46
|
Author: bart
Date: 2008-03-11 18:15:49 +0000 (Tue, 11 Mar 2008)
New Revision: 7637
Log:
Third attempt to get the OpenMP configure test right.
Modified:
trunk/configure.in
Modified: trunk/configure.in
===================================================================
--- trunk/configure.in 2008-03-11 11:44:53 UTC (rev 7636)
+++ trunk/configure.in 2008-03-11 18:15:49 UTC (rev 7637)
@@ -552,15 +552,11 @@
# does this compiler support -fopenmp, does it have the include file
# <omp.h> and does it have libgomp ?
-AC_MSG_CHECKING([if gcc supports OpenMP])
safe_CFLAGS=$CFLAGS
CFLAGS="-fopenmp"
-AC_TRY_COMPILE(, [
-#include <omp.h>
-int main () { omp_set_dynamic(0); return 0; }
-],
+AC_COMPILE_CHECK([OpenMP], [#include <omp.h>], [ omp_set_dynamic(0); ],
[
ac_have_gcc_fopenmp=yes
AC_MSG_RESULT([yes])
|
|
From: <sv...@va...> - 2008-03-11 11:44:50
|
Author: sewardj
Date: 2008-03-11 11:44:53 +0000 (Tue, 11 Mar 2008)
New Revision: 7636
Log:
More crude experimentation: ignore references in the lowest page of a
thread's stack.
Modified:
branches/HGDEV/helgrind/hg_main.c
Modified: branches/HGDEV/helgrind/hg_main.c
===================================================================
--- branches/HGDEV/helgrind/hg_main.c 2008-03-10 20:05:57 UTC (rev 7635)
+++ branches/HGDEV/helgrind/hg_main.c 2008-03-11 11:44:53 UTC (rev 7636)
@@ -469,7 +469,7 @@
typedef
struct {
Bool inUse;
- SVal w32s[N_LINE_ARANGE];
+ SVal w64s[N_LINE_ARANGE];
}
CacheLineF; /* full rep for a cache line */
@@ -549,7 +549,7 @@
lineF = &sm->linesF[ lineZ->dict[1] ];
tl_assert(lineF->inUse);
tl_assert(itr->word_no >= 0 && itr->word_no < N_LINE_ARANGE);
- *pVal = &lineF->w32s[itr->word_no];
+ *pVal = &lineF->w64s[itr->word_no];
itr->word_no++;
if (itr->word_no == N_LINE_ARANGE)
itr->word_no = 0;
@@ -4291,7 +4291,7 @@
if (SCE_SVALS)
tl_assert(is_SHVAL_valid(sv));
for (m = csvals[k].count; m > 0; m--) {
- lineF->w32s[i] = sv;
+ lineF->w64s[i] = sv;
i++;
}
}
@@ -4338,7 +4338,7 @@
if (lineF) {
tl_assert(lineF->inUse);
for (i = 0; i < N_LINE_ARANGE; i++) {
- cl->svals[i] = lineF->w32s[i];
+ cl->svals[i] = lineF->w64s[i];
}
stats__cache_F_fetches++;
} else {
@@ -5819,7 +5819,47 @@
all__sanity_check("evh__new_mem-post");
}
+// Hacky stack filter; ignore references in the lowest page of
+// a thread's stack. This picks up basically all stack references
+// that threads ever make (iow, ignoring the lowest 2, 3, .. pages
+// hardly succeeds in filtering out any more than just the first
+// page)
+#define HACKY_FILTER 1
+#define HACKY_FILTER_SIZE (1*4096)
+// skip ref at 'a' if
+// (a - sp + VG_STACK_REDZONE_SZB) <=u HACKY_FILTER_SIZE
+
static
+void evh__new_mem_stack ( Addr a, SizeT len ) {
+ if (SHOW_EVENTS >= 2)
+ VG_(printf)("evh__new_mem_stack(%p, %lu)\n", (void*)a, len );
+#if 0
+ // This is simply wrong
+ ThreadId coretid = VG_(get_running_tid)();
+ if (coretid != VG_INVALID_THREADID) {
+ Addr sp_min1 = VG_(get_SP)(coretid) - VG_STACK_REDZONE_SZB;
+ VG_(printf)("QQQ %p\n", sp_min1);
+ if (a > sp_min1 && a+len <= sp_min1 + HACKY_FILTER_SIZE) {
+ VG_(printf)("XXX skip %p %lu\n", a, len);
+ return;
+ }
+ }
+#endif
+#if 0
+ // This isn't right either
+ if (len <= HACKY_FILTER_SIZE) {
+ //VG_(printf)("XXX skip %p %lu\n", a, len);
+ return;
+ }
+ a += HACKY_FILTER_SIZE;
+ len -= HACKY_FILTER_SIZE;
+#endif
+ shadow_mem_make_New( get_current_Thread(), a, len );
+ if (len >= SCE_BIGRANGE_T && (clo_sanity_flags & SCE_BIGRANGE))
+ all__sanity_check("evh__new_mem_stack-post");
+}
+
+static
void evh__new_mem_w_perms ( Addr a, SizeT len,
Bool rr, Bool ww, Bool xx ) {
if (SHOW_EVENTS >= 1)
@@ -6087,45 +6127,78 @@
// thread async exit?
-static VG_REGPARM(1)
-void evh__mem_help_read_1(Addr a) {
+// skip ref at 'a' if
+// (a - sp + VG_STACK_REDZONE_SZB) <=u HACKY_FILTER_SIZE
+
+static VG_REGPARM(2)
+void evh__mem_help_read_1(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_read8( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(1)
-void evh__mem_help_read_2(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_read_2(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_read16( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(1)
-void evh__mem_help_read_4(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_read_4(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_read32( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(1)
-void evh__mem_help_read_8(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_read_8(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_read64( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(2)
-void evh__mem_help_read_N(Addr a, SizeT size) {
+static VG_REGPARM(3)
+void evh__mem_help_read_N(Addr a, SizeT size, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_read_range( get_current_Thread_in_C_C(), a, size );
}
-static VG_REGPARM(1)
-void evh__mem_help_write_1(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_write_1(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_write8( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(1)
-void evh__mem_help_write_2(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_write_2(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_write16( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(1)
-void evh__mem_help_write_4(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_write_4(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_write32( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(1)
-void evh__mem_help_write_8(Addr a) {
+static VG_REGPARM(2)
+void evh__mem_help_write_8(Addr a, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_write64( get_current_Thread_in_C_C(), a, 0/*unused*/ );
}
-static VG_REGPARM(2)
-void evh__mem_help_write_N(Addr a, SizeT size) {
+static VG_REGPARM(3)
+void evh__mem_help_write_N(Addr a, SizeT size, Addr sp) {
+ if (HACKY_FILTER
+ && ((UWord)(a - sp + VG_STACK_REDZONE_SZB)) <= HACKY_FILTER_SIZE)
+ return;
shadow_mem_write_range( get_current_Thread_in_C_C(), a, size );
}
@@ -7597,7 +7670,8 @@
IRExpr* addr,
Int szB,
Bool isStore,
- Int hWordTy_szB )
+ Int hWordTy_szB,
+ VexGuestLayout* layout )
{
IRType tyAddr = Ity_INVALID;
HChar* hName = NULL;
@@ -7605,6 +7679,8 @@
Int regparms = 0;
IRExpr** argv = NULL;
IRDirty* di = NULL;
+ IRTemp sp;
+ IRExpr* spE;
tl_assert(isIRAtom(addr));
tl_assert(hWordTy_szB == 4 || hWordTy_szB == 8);
@@ -7612,36 +7688,57 @@
tyAddr = typeOfIRExpr( bbOut->tyenv, addr );
tl_assert(tyAddr == Ity_I32 || tyAddr == Ity_I64);
+ /* Get the guest's stack pointer, so we can pass it to the helper.
+ How do we know this is up to date? Presumably because SP is
+ flushed to guest state before every memory reference. */
+ tl_assert(sizeof(void*) == layout->sizeof_SP);
+ tl_assert(sizeof(void*) == hWordTy_szB);
+ if (layout->sizeof_SP == 4) {
+ sp = newIRTemp(bbOut->tyenv, Ity_I32);
+ addStmtToIRSB(
+ bbOut,
+ IRStmt_WrTmp( sp, IRExpr_Get( layout->offset_SP, Ity_I32 ) )
+ );
+ } else {
+ tl_assert(layout->sizeof_SP == 8);
+ sp = newIRTemp(bbOut->tyenv, Ity_I64);
+ addStmtToIRSB(
+ bbOut,
+ IRStmt_WrTmp( sp, IRExpr_Get( layout->offset_SP, Ity_I64 ) )
+ );
+ }
+ spE = IRExpr_RdTmp( sp );
+
/* So the effective address is in 'addr' now. */
- regparms = 1; // unless stated otherwise
+ regparms = 2; // unless stated otherwise
if (isStore) {
switch (szB) {
case 1:
hName = "evh__mem_help_write_1";
hAddr = &evh__mem_help_write_1;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
case 2:
hName = "evh__mem_help_write_2";
hAddr = &evh__mem_help_write_2;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
case 4:
hName = "evh__mem_help_write_4";
hAddr = &evh__mem_help_write_4;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
case 8:
hName = "evh__mem_help_write_8";
hAddr = &evh__mem_help_write_8;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
default:
tl_assert(szB > 8 && szB <= 512); /* stay sane */
- regparms = 2;
+ regparms = 3;
hName = "evh__mem_help_write_N";
hAddr = &evh__mem_help_write_N;
- argv = mkIRExprVec_2( addr, mkIRExpr_HWord( szB ));
+ argv = mkIRExprVec_3( addr, mkIRExpr_HWord( szB ), spE);
break;
}
} else {
@@ -7649,29 +7746,29 @@
case 1:
hName = "evh__mem_help_read_1";
hAddr = &evh__mem_help_read_1;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
case 2:
hName = "evh__mem_help_read_2";
hAddr = &evh__mem_help_read_2;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
case 4:
hName = "evh__mem_help_read_4";
hAddr = &evh__mem_help_read_4;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
case 8:
hName = "evh__mem_help_read_8";
hAddr = &evh__mem_help_read_8;
- argv = mkIRExprVec_1( addr );
+ argv = mkIRExprVec_2( addr, spE );
break;
default:
tl_assert(szB > 8 && szB <= 512); /* stay sane */
- regparms = 2;
+ regparms = 3;
hName = "evh__mem_help_read_N";
hAddr = &evh__mem_help_read_N;
- argv = mkIRExprVec_2( addr, mkIRExpr_HWord( szB ));
+ argv = mkIRExprVec_3( addr, mkIRExpr_HWord( szB ), spE);
break;
}
}
@@ -7768,7 +7865,8 @@
st->Ist.Store.addr,
sizeofIRType(typeOfIRExpr(bbIn->tyenv, st->Ist.Store.data)),
True/*isStore*/,
- sizeofIRType(hWordTy)
+ sizeofIRType(hWordTy),
+ layout
);
break;
@@ -7780,7 +7878,8 @@
data->Iex.Load.addr,
sizeofIRType(data->Iex.Load.ty),
False/*!isStore*/,
- sizeofIRType(hWordTy)
+ sizeofIRType(hWordTy),
+ layout
);
}
break;
@@ -7798,13 +7897,13 @@
if (d->mFx == Ifx_Read || d->mFx == Ifx_Modify) {
instrument_mem_access(
bbOut, d->mAddr, dataSize, False/*!isStore*/,
- sizeofIRType(hWordTy)
+ sizeofIRType(hWordTy), layout
);
}
if (d->mFx == Ifx_Write || d->mFx == Ifx_Modify) {
instrument_mem_access(
bbOut, d->mAddr, dataSize, True/*isStore*/,
- sizeofIRType(hWordTy)
+ sizeofIRType(hWordTy), layout
);
}
} else {
@@ -9226,6 +9325,9 @@
stats__cline_64to32pulldown,
stats__cline_32to16pulldown,
stats__cline_16to8pulldown );
+ if (0)
+ VG_(printf)(" cline: sizeof(CacheLineZ) %ld, covers %ld bytes of arange\n",
+ (Word)sizeof(CacheLineZ), (Word)N_LINE_ARANGE);
VG_(printf)("\n");
}
@@ -9284,7 +9386,7 @@
VG_(track_new_mem_stack_signal)( evh__die_mem );
VG_(track_new_mem_brk) ( evh__new_mem );
VG_(track_new_mem_mmap) ( evh__new_mem_w_perms );
- VG_(track_new_mem_stack) ( evh__new_mem );
+ VG_(track_new_mem_stack) ( evh__new_mem_stack );
// FIXME: surely this isn't thread-aware
VG_(track_copy_mem_remap) ( shadow_mem_copy_range );
|
|
From: Julian S. <js...@ac...> - 2008-03-11 11:05:04
|
On Tuesday 11 March 2008 07:19, Brad Hards wrote:
> On Tuesday 11 March 2008 08:02:01 am Nicholas Nethercote wrote:
> > On Mon, 10 Mar 2008, Brad Hards wrote:
> > > It appears to be working for me, although some of the output looks a
> > > bit strange:
> > > 5: 12:void TestQEmf::check()
> > > -: 13:{
> > > 9: 14: QVERIFY( true );
> > > 2: 15: QWinMetaFile wmf;
> > > 5: 16: QImage pic(1000, 800,
> > > QImage::Format_ARGB32_Premultiplied); 20: 17: QVERIFY( wmf.load(
> > > "1.emf" ) );
> > > -: 18:
> > > 14: 19: wmf.paint( &pic );
> > > 4: 20:}
> > >
> > > I'm not too worried - all I really care about is executed-or-not, but
> > > it does make the output look unreliable.
> >
> > Why is it strange? I've seen cases where compiler optimisations make
> > lines that you think should be executable become non-executable, but this
> > doesn't seem to be one of them. Well, whether the function name line and
> > the '{' and '}' lines are executable depends on what the compiler does.
>
> I assumed that it was "number of times this line gets executed", rather
> than "number of times a code block from this line gets executed", so all
> the lines (in the absence of a conditional statement or loop) should have
> the same number.
At a guess and knowing nothing about how VCov works, I'd say it's the
number of executed instructions for each line. (Unless it's not :-)
J
|
|
From: Brad H. <br...@fr...> - 2008-03-11 06:20:04
|
On Tuesday 11 March 2008 08:02:01 am Nicholas Nethercote wrote:
> On Mon, 10 Mar 2008, Brad Hards wrote:
> > It appears to be working for me, although some of the output looks a bit
> > strange:
> > 5: 12:void TestQEmf::check()
> > -: 13:{
> > 9: 14: QVERIFY( true );
> > 2: 15: QWinMetaFile wmf;
> > 5: 16: QImage pic(1000, 800,
> > QImage::Format_ARGB32_Premultiplied); 20: 17: QVERIFY( wmf.load(
> > "1.emf" ) );
> > -: 18:
> > 14: 19: wmf.paint( &pic );
> > 4: 20:}
> >
> > I'm not too worried - all I really care about is executed-or-not, but it
> > does make the output look unreliable.
>
> Why is it strange? I've seen cases where compiler optimisations make lines
> that you think should be executable become non-executable, but this doesn't
> seem to be one of them. Well, whether the function name line and the '{'
> and '}' lines are executable depends on what the compiler does.
I assumed that it was "number of times this line gets executed", rather
than "number of times a code block from this line gets executed", so all the
lines (in the absence of a conditional statement or loop) should have the
same number.
Brad
|
|
From: Tom H. <th...@cy...> - 2008-03-11 06:16:58
|
Nightly build on alvis ( i686, Red Hat 7.3 ) started at 2008-03-11 03:15:05 GMT Results unchanged from 24 hours ago Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Regression test results follow == 378 tests, 78 stderr failures, 1 stdout failure, 29 post failures == memcheck/tests/addressable (stderr) memcheck/tests/badjump (stderr) memcheck/tests/describe-block (stderr) memcheck/tests/erringfds (stderr) memcheck/tests/leak-0 (stderr) memcheck/tests/leak-cycle (stderr) memcheck/tests/leak-pool-0 (stderr) memcheck/tests/leak-pool-1 (stderr) memcheck/tests/leak-pool-2 (stderr) memcheck/tests/leak-pool-3 (stderr) memcheck/tests/leak-pool-4 (stderr) memcheck/tests/leak-pool-5 (stderr) memcheck/tests/leak-regroot (stderr) memcheck/tests/leak-tree (stderr) memcheck/tests/long_namespace_xml (stderr) memcheck/tests/lsframe1 (stderr) memcheck/tests/lsframe2 (stderr) memcheck/tests/malloc_free_fill (stderr) memcheck/tests/match-overrun (stderr) memcheck/tests/noisy_child (stderr) memcheck/tests/partial_load_dflt (stderr) memcheck/tests/partial_load_ok (stderr) memcheck/tests/partiallydefinedeq (stderr) memcheck/tests/pointer-trace (stderr) memcheck/tests/sigkill (stderr) memcheck/tests/stack_changes (stderr) memcheck/tests/varinfo1 (stderr) memcheck/tests/varinfo2 (stderr) memcheck/tests/varinfo3 (stderr) memcheck/tests/varinfo4 (stderr) memcheck/tests/varinfo5 (stderr) memcheck/tests/varinfo6 (stderr) memcheck/tests/x86/bug152022 (stderr) memcheck/tests/x86/scalar (stderr) memcheck/tests/x86/scalar_supp (stderr) memcheck/tests/x86/xor-undef-x86 (stderr) memcheck/tests/xml1 (stderr) massif/tests/alloc-fns-A (post) massif/tests/alloc-fns-B (post) massif/tests/basic (post) massif/tests/basic2 (post) massif/tests/big-alloc (post) massif/tests/culling1 (stderr) massif/tests/culling2 (stderr) massif/tests/custom_alloc (post) massif/tests/deep-A (post) massif/tests/deep-B (stderr) massif/tests/deep-B (post) massif/tests/deep-C (stderr) massif/tests/deep-C (post) massif/tests/deep-D (post) massif/tests/ignoring (post) massif/tests/insig (post) massif/tests/long-names (post) massif/tests/long-time (post) massif/tests/new-cpp (post) massif/tests/null (post) massif/tests/one (post) massif/tests/overloaded-new (post) massif/tests/peak (post) massif/tests/peak2 (stderr) massif/tests/peak2 (post) massif/tests/realloc (stderr) massif/tests/realloc (post) massif/tests/thresholds_0_0 (post) massif/tests/thresholds_0_10 (post) massif/tests/thresholds_10_0 (post) massif/tests/thresholds_10_10 (post) massif/tests/thresholds_5_0 (post) massif/tests/thresholds_5_10 (post) massif/tests/zero1 (post) massif/tests/zero2 (post) none/tests/blockfault (stderr) none/tests/faultstatus (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) none/tests/shell (stderr) none/tests/shell_valid1 (stderr) none/tests/shell_valid2 (stderr) none/tests/shell_valid3 (stderr) helgrind/tests/hg01_all_ok (stderr) helgrind/tests/hg02_deadlock (stderr) helgrind/tests/hg03_inherit (stderr) helgrind/tests/hg04_race (stderr) helgrind/tests/hg05_race2 (stderr) helgrind/tests/hg06_readshared (stderr) helgrind/tests/tc01_simple_race (stderr) helgrind/tests/tc02_simple_tls (stderr) helgrind/tests/tc03_re_excl (stderr) helgrind/tests/tc05_simple_race (stderr) helgrind/tests/tc06_two_races (stderr) helgrind/tests/tc07_hbl1 (stderr) helgrind/tests/tc08_hbl2 (stderr) helgrind/tests/tc09_bad_unlock (stderr) helgrind/tests/tc11_XCHG (stderr) helgrind/tests/tc12_rwl_trivial (stderr) helgrind/tests/tc14_laog_dinphils (stderr) helgrind/tests/tc16_byterace (stderr) helgrind/tests/tc17_sembar (stderr) helgrind/tests/tc18_semabuse (stderr) helgrind/tests/tc19_shadowmem (stderr) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc21_pthonce (stderr) helgrind/tests/tc22_exit_w_lock (stderr) helgrind/tests/tc23_bogus_condwait (stderr) helgrind/tests/tc24_nonzero_sem (stderr) exp-drd/tests/tc09_bad_unlock (stderr) exp-drd/tests/tc12_rwl_trivial (stderr) |
|
From: Tom H. <th...@cy...> - 2008-03-11 04:32:08
|
Nightly build on lloyd ( x86_64, Fedora 7 ) started at 2008-03-11 03:05:04 GMT Results differ from 24 hours ago Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Regression test results follow == 413 tests, 7 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) none/tests/faultstatus (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc22_exit_w_lock (stderr) exp-drd/tests/matinv_openmp (stderr) ================================================= == Results from 24 hours ago == ================================================= Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Regression test results follow == 412 tests, 6 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) none/tests/faultstatus (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc22_exit_w_lock (stderr) ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Tue Mar 11 03:45:58 2008 --- new.short Tue Mar 11 04:32:09 2008 *************** *** 8,10 **** ! == 412 tests, 6 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) --- 8,10 ---- ! == 413 tests, 7 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) *************** *** 17,18 **** --- 17,19 ---- helgrind/tests/tc22_exit_w_lock (stderr) + exp-drd/tests/matinv_openmp (stderr) |
|
From: Tom H. <th...@cy...> - 2008-03-11 03:37:44
|
Nightly build on aston ( x86_64, Fedora Core 5 ) started at 2008-03-11 03:20:07 GMT Results differ from 24 hours ago Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Last 20 lines of verbose log follow echo omp_prime-omp_prime.o: In function `main': omp_prime.c:(.text+0x1a4): undefined reference to `omp_set_num_threads' omp_prime.c:(.text+0x1ae): undefined reference to `omp_set_dynamic' omp_prime.c:(.text+0x205): undefined reference to `GOMP_parallel_start' omp_prime.c:(.text+0x213): undefined reference to `GOMP_parallel_end' omp_prime-omp_prime.o: In function `main.omp_fn.0': omp_prime.c:(.text+0x2ac): undefined reference to `omp_get_num_threads' omp_prime.c:(.text+0x2b3): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status make[5]: *** [omp_prime] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[4]: *** [check-am] Error 2 make[4]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[3]: *** [check-recursive] Error 1 make[3]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[2]: *** [check-recursive] Error 1 make[2]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd' make[1]: *** [check-recursive] Error 1 make[1]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind' make: *** [check] Error 2 ================================================= == Results from 24 hours ago == ================================================= Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Last 20 lines of verbose log follow echo then mv -f ".deps/matinv_openmp-matinv_openmp.Tpo" ".deps/matinv_openmp-matinv_openmp.Po"; else rm -f ".deps/matinv_openmp-matinv_openmp.Tpo"; exit 1; fi gcc -Winline -Wall -Wshadow -g -m64 -Wno-long-long -Wno-pointer-sign -Wdeclaration-after-statement -fno-stack-protector -o matinv_openmp matinv_openmp-matinv_openmp.o -lm matinv_openmp-matinv_openmp.o: In function `gj': matinv_openmp.c:(.text+0x5fe): undefined reference to `GOMP_parallel_start' matinv_openmp.c:(.text+0x60c): undefined reference to `GOMP_parallel_end' matinv_openmp-matinv_openmp.o: In function `gj.omp_fn.0': matinv_openmp.c:(.text+0x661): undefined reference to `omp_get_num_threads' matinv_openmp.c:(.text+0x668): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status make[5]: *** [matinv_openmp] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[4]: *** [check-am] Error 2 make[4]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[3]: *** [check-recursive] Error 1 make[3]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[2]: *** [check-recursive] Error 1 make[2]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd' make[1]: *** [check-recursive] Error 1 make[1]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind' make: *** [check] Error 2 ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Tue Mar 11 03:28:55 2008 --- new.short Tue Mar 11 03:37:46 2008 *************** *** 7,18 **** Last 20 lines of verbose log follow echo ! then mv -f ".deps/matinv_openmp-matinv_openmp.Tpo" ".deps/matinv_openmp-matinv_openmp.Po"; else rm -f ".deps/matinv_openmp-matinv_openmp.Tpo"; exit 1; fi ! gcc -Winline -Wall -Wshadow -g -m64 -Wno-long-long -Wno-pointer-sign -Wdeclaration-after-statement -fno-stack-protector -o matinv_openmp matinv_openmp-matinv_openmp.o -lm ! matinv_openmp-matinv_openmp.o: In function `gj': ! matinv_openmp.c:(.text+0x5fe): undefined reference to `GOMP_parallel_start' ! matinv_openmp.c:(.text+0x60c): undefined reference to `GOMP_parallel_end' ! matinv_openmp-matinv_openmp.o: In function `gj.omp_fn.0': ! matinv_openmp.c:(.text+0x661): undefined reference to `omp_get_num_threads' ! matinv_openmp.c:(.text+0x668): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status ! make[5]: *** [matinv_openmp] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' --- 7,18 ---- Last 20 lines of verbose log follow echo ! omp_prime-omp_prime.o: In function `main': ! omp_prime.c:(.text+0x1a4): undefined reference to `omp_set_num_threads' ! omp_prime.c:(.text+0x1ae): undefined reference to `omp_set_dynamic' ! omp_prime.c:(.text+0x205): undefined reference to `GOMP_parallel_start' ! omp_prime.c:(.text+0x213): undefined reference to `GOMP_parallel_end' ! omp_prime-omp_prime.o: In function `main.omp_fn.0': ! omp_prime.c:(.text+0x2ac): undefined reference to `omp_get_num_threads' ! omp_prime.c:(.text+0x2b3): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status ! make[5]: *** [omp_prime] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' |
|
From: Tom H. <th...@cy...> - 2008-03-11 03:33:56
|
Nightly build on dellow ( x86_64, Fedora 8 ) started at 2008-03-11 03:10:04 GMT Results differ from 24 hours ago Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Regression test results follow == 413 tests, 9 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) none/tests/faultstatus (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) helgrind/tests/tc18_semabuse (stderr) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc21_pthonce (stderr) helgrind/tests/tc22_exit_w_lock (stderr) exp-drd/tests/matinv_openmp (stderr) ================================================= == Results from 24 hours ago == ================================================= Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Regression test results follow == 412 tests, 8 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) none/tests/faultstatus (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) helgrind/tests/tc18_semabuse (stderr) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc21_pthonce (stderr) helgrind/tests/tc22_exit_w_lock (stderr) ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Tue Mar 11 03:22:03 2008 --- new.short Tue Mar 11 03:33:59 2008 *************** *** 8,10 **** ! == 412 tests, 8 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) --- 8,10 ---- ! == 413 tests, 9 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) *************** *** 19,20 **** --- 19,21 ---- helgrind/tests/tc22_exit_w_lock (stderr) + exp-drd/tests/matinv_openmp (stderr) |
|
From: Tom H. <th...@cy...> - 2008-03-11 03:31:54
|
Nightly build on trojan ( x86_64, Fedora Core 6 ) started at 2008-03-11 03:25:05 GMT Results differ from 24 hours ago Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Last 20 lines of verbose log follow echo omp_prime-omp_prime.o: In function `main': omp_prime.c:(.text+0x1a4): undefined reference to `omp_set_num_threads' omp_prime.c:(.text+0x1ae): undefined reference to `omp_set_dynamic' omp_prime.c:(.text+0x205): undefined reference to `GOMP_parallel_start' omp_prime.c:(.text+0x213): undefined reference to `GOMP_parallel_end' omp_prime-omp_prime.o: In function `main.omp_fn.0': omp_prime.c:(.text+0x2ac): undefined reference to `omp_get_num_threads' omp_prime.c:(.text+0x2b3): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status make[5]: *** [omp_prime] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[4]: *** [check-am] Error 2 make[4]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[3]: *** [check-recursive] Error 1 make[3]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[2]: *** [check-recursive] Error 1 make[2]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd' make[1]: *** [check-recursive] Error 1 make[1]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind' make: *** [check] Error 2 ================================================= == Results from 24 hours ago == ================================================= Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Last 20 lines of verbose log follow echo then mv -f ".deps/matinv_openmp-matinv_openmp.Tpo" ".deps/matinv_openmp-matinv_openmp.Po"; else rm -f ".deps/matinv_openmp-matinv_openmp.Tpo"; exit 1; fi gcc -Winline -Wall -Wshadow -g -m64 -Wno-long-long -Wno-pointer-sign -Wdeclaration-after-statement -fno-stack-protector -o matinv_openmp matinv_openmp-matinv_openmp.o -lm matinv_openmp-matinv_openmp.o: In function `gj': matinv_openmp.c:(.text+0x5fe): undefined reference to `GOMP_parallel_start' matinv_openmp.c:(.text+0x60c): undefined reference to `GOMP_parallel_end' matinv_openmp-matinv_openmp.o: In function `gj.omp_fn.0': matinv_openmp.c:(.text+0x661): undefined reference to `omp_get_num_threads' matinv_openmp.c:(.text+0x668): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status make[5]: *** [matinv_openmp] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[4]: *** [check-am] Error 2 make[4]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[3]: *** [check-recursive] Error 1 make[3]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' make[2]: *** [check-recursive] Error 1 make[2]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd' make[1]: *** [check-recursive] Error 1 make[1]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind' make: *** [check] Error 2 ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Tue Mar 11 03:28:33 2008 --- new.short Tue Mar 11 03:31:57 2008 *************** *** 7,18 **** Last 20 lines of verbose log follow echo ! then mv -f ".deps/matinv_openmp-matinv_openmp.Tpo" ".deps/matinv_openmp-matinv_openmp.Po"; else rm -f ".deps/matinv_openmp-matinv_openmp.Tpo"; exit 1; fi ! gcc -Winline -Wall -Wshadow -g -m64 -Wno-long-long -Wno-pointer-sign -Wdeclaration-after-statement -fno-stack-protector -o matinv_openmp matinv_openmp-matinv_openmp.o -lm ! matinv_openmp-matinv_openmp.o: In function `gj': ! matinv_openmp.c:(.text+0x5fe): undefined reference to `GOMP_parallel_start' ! matinv_openmp.c:(.text+0x60c): undefined reference to `GOMP_parallel_end' ! matinv_openmp-matinv_openmp.o: In function `gj.omp_fn.0': ! matinv_openmp.c:(.text+0x661): undefined reference to `omp_get_num_threads' ! matinv_openmp.c:(.text+0x668): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status ! make[5]: *** [matinv_openmp] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' --- 7,18 ---- Last 20 lines of verbose log follow echo ! omp_prime-omp_prime.o: In function `main': ! omp_prime.c:(.text+0x1a4): undefined reference to `omp_set_num_threads' ! omp_prime.c:(.text+0x1ae): undefined reference to `omp_set_dynamic' ! omp_prime.c:(.text+0x205): undefined reference to `GOMP_parallel_start' ! omp_prime.c:(.text+0x213): undefined reference to `GOMP_parallel_end' ! omp_prime-omp_prime.o: In function `main.omp_fn.0': ! omp_prime.c:(.text+0x2ac): undefined reference to `omp_get_num_threads' ! omp_prime.c:(.text+0x2b3): undefined reference to `omp_get_thread_num' collect2: ld returned 1 exit status ! make[5]: *** [omp_prime] Error 1 make[5]: Leaving directory `/tmp/vgtest/2008-03-11/valgrind/exp-drd/tests' |
|
From: Tom H. <th...@cy...> - 2008-03-11 03:17:23
|
Nightly build on gill ( x86_64, Fedora Core 2 ) started at 2008-03-11 03:00:02 GMT Results unchanged from 24 hours ago Checking out valgrind source tree ... done Configuring valgrind ... done Building valgrind ... done Running regression tests ... failed Regression test results follow == 418 tests, 32 stderr failures, 3 stdout failures, 0 post failures == memcheck/tests/malloc_free_fill (stderr) memcheck/tests/pointer-trace (stderr) memcheck/tests/stack_switch (stderr) memcheck/tests/varinfo6 (stderr) memcheck/tests/x86/scalar (stderr) memcheck/tests/x86/scalar_supp (stderr) none/tests/amd64/insn_ssse3 (stdout) none/tests/amd64/insn_ssse3 (stderr) none/tests/amd64/ssse3_misaligned (stderr) none/tests/blockfault (stderr) none/tests/faultstatus (stderr) none/tests/fdleak_fcntl (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) none/tests/x86/insn_ssse3 (stdout) none/tests/x86/insn_ssse3 (stderr) none/tests/x86/ssse3_misaligned (stderr) helgrind/tests/hg01_all_ok (stderr) helgrind/tests/hg02_deadlock (stderr) helgrind/tests/hg03_inherit (stderr) helgrind/tests/hg04_race (stderr) helgrind/tests/hg05_race2 (stderr) helgrind/tests/tc01_simple_race (stderr) helgrind/tests/tc05_simple_race (stderr) helgrind/tests/tc06_two_races (stderr) helgrind/tests/tc09_bad_unlock (stderr) helgrind/tests/tc14_laog_dinphils (stderr) helgrind/tests/tc16_byterace (stderr) helgrind/tests/tc17_sembar (stderr) helgrind/tests/tc19_shadowmem (stderr) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc21_pthonce (stderr) helgrind/tests/tc22_exit_w_lock (stderr) helgrind/tests/tc23_bogus_condwait (stderr) exp-drd/tests/pth_create_chain (stderr) |