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
(20) |
2
(19) |
3
(7) |
|
4
(13) |
5
(24) |
6
(9) |
7
(12) |
8
(8) |
9
(34) |
10
(28) |
|
11
(20) |
12
(23) |
13
(12) |
14
(10) |
15
(15) |
16
(24) |
17
(26) |
|
18
(17) |
19
(14) |
20
(14) |
21
(8) |
22
(12) |
23
(22) |
24
(10) |
|
25
(21) |
26
(21) |
27
(18) |
28
(8) |
29
(13) |
30
(15) |
|
|
From: <sv...@va...> - 2007-11-25 23:56:12
|
Author: sewardj Date: 2007-11-25 23:56:12 +0000 (Sun, 25 Nov 2007) New Revision: 7220 Log: Get rid of stuff which should not have been committed. Urrr. Removed: trunk/exp-drd/tests/fp_race.stderr.diff trunk/exp-drd/tests/fp_race.stderr.diff2 trunk/exp-drd/tests/fp_race.stderr.out trunk/exp-drd/tests/fp_race2.stderr.diff trunk/exp-drd/tests/fp_race2.stderr.out trunk/exp-drd/tests/pth_broadcast.stderr.diff trunk/exp-drd/tests/pth_broadcast.stderr.out trunk/exp-drd/tests/pth_cond_race.stderr.diff trunk/exp-drd/tests/pth_cond_race.stderr.out trunk/exp-drd/tests/pth_cond_race2.stderr.diff trunk/exp-drd/tests/pth_cond_race2.stderr.out trunk/exp-drd/tests/pth_create_chain.stderr.diff trunk/exp-drd/tests/pth_create_chain.stderr.out trunk/exp-drd/tests/pth_detached.stderr.diff trunk/exp-drd/tests/pth_detached.stderr.out trunk/exp-drd/tests/pth_detached2.stderr.diff trunk/exp-drd/tests/pth_detached2.stderr.out trunk/exp-drd/tests/sigalrm.stderr.diff trunk/exp-drd/tests/sigalrm.stderr.out Deleted: trunk/exp-drd/tests/fp_race.stderr.diff =================================================================== --- trunk/exp-drd/tests/fp_race.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/fp_race.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,10 +0,0 @@ -0a1 -> exp-drd, a data race detector. -4c5 -< Allocation context: s_d3 (offset 0, size 8) in fp_race, NONE:BSS ---- -> Allocation context: unknown -12c13 -< Allocation context: s_d3 (offset 0, size 8) in fp_race, NONE:BSS ---- -> Allocation context: unknown Deleted: trunk/exp-drd/tests/fp_race.stderr.diff2 =================================================================== --- trunk/exp-drd/tests/fp_race.stderr.diff2 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/fp_race.stderr.diff2 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,2 +0,0 @@ -0a1 -> exp-drd, a data race detector. Deleted: trunk/exp-drd/tests/fp_race.stderr.out =================================================================== --- trunk/exp-drd/tests/fp_race.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/fp_race.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,19 +0,0 @@ -exp-drd, a data race detector. - -Conflicting load by main at 0x........ size 8 - at 0x........: main (fp_race.cpp:?) -Allocation context: unknown -Other segment start (thread_func) - (thread finished, call stack no longer available) -Other segment end (thread_func) - (thread finished, call stack no longer available) - -Conflicting store by main at 0x........ size 8 - at 0x........: main (fp_race.cpp:?) -Allocation context: unknown -Other segment start (thread_func) - (thread finished, call stack no longer available) -Other segment end (thread_func) - (thread finished, call stack no longer available) - -ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/fp_race2.stderr.diff =================================================================== --- trunk/exp-drd/tests/fp_race2.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/fp_race2.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,22 +0,0 @@ -0a1 -> exp-drd, a data race detector. -1a3,17 -> Conflicting load by main at 0x........ size 8 -> at 0x........: (within /home/sewardj/VgTRUNK/trunk/exp-drd/tests/fp_race) -> by 0x........: main (fp_race.cpp:?) -> Allocation context: unknown -> Other segment start (thread_func) -> at 0x........: clone (in /...libc...) -> by 0x........: (within libpthread-?.?.so) -> by 0x........: ??? -> Other segment end (thread_func) -> at 0x........: (within libpthread-?.?.so) -> by 0x........: pthread_mutex_lock (drd_preloaded.c:?) -> by 0x........: thread_func(void*) (fp_race.cpp:?) -> by 0x........: vg_thread_wrapper (drd_preloaded.c:?) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -3c19 -< ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) ---- -> ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/fp_race2.stderr.out =================================================================== --- trunk/exp-drd/tests/fp_race2.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/fp_race2.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,19 +0,0 @@ -exp-drd, a data race detector. - -Conflicting load by main at 0x........ size 8 - at 0x........: (within /home/sewardj/VgTRUNK/trunk/exp-drd/tests/fp_race) - by 0x........: main (fp_race.cpp:?) -Allocation context: unknown -Other segment start (thread_func) - at 0x........: clone (in /...libc...) - by 0x........: (within libpthread-?.?.so) - by 0x........: ??? -Other segment end (thread_func) - at 0x........: (within libpthread-?.?.so) - by 0x........: pthread_mutex_lock (drd_preloaded.c:?) - by 0x........: thread_func(void*) (fp_race.cpp:?) - by 0x........: vg_thread_wrapper (drd_preloaded.c:?) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) - -ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_broadcast.stderr.diff =================================================================== --- trunk/exp-drd/tests/pth_broadcast.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_broadcast.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,105 +0,0 @@ -0a1 -> exp-drd, a data race detector. -1a3,12 -> Thread 9: -> Conflicting load by thread 9 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -3c14,102 -< ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) ---- -> Thread 10: -> Conflicting load by thread 10 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 11: -> Conflicting load by thread 11 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 2: -> Conflicting load by thread 2 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 3: -> Conflicting load by thread 3 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 5: -> Conflicting load by thread 5 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 4: -> Conflicting load by thread 4 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 6: -> Conflicting load by thread 6 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> Thread 7: -> Conflicting load by thread 7 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 8) -> (thread finished, call stack no longer available) -> Other segment end (thread 8) -> (thread finished, call stack no longer available) -> -> ERROR SUMMARY: 9 errors from 9 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_broadcast.stderr.out =================================================================== --- trunk/exp-drd/tests/pth_broadcast.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_broadcast.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,102 +0,0 @@ -exp-drd, a data race detector. - -Thread 9: -Conflicting load by thread 9 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 10: -Conflicting load by thread 10 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 11: -Conflicting load by thread 11 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 2: -Conflicting load by thread 2 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 3: -Conflicting load by thread 3 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 5: -Conflicting load by thread 5 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 4: -Conflicting load by thread 4 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 6: -Conflicting load by thread 6 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -Thread 7: -Conflicting load by thread 7 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 8) - (thread finished, call stack no longer available) -Other segment end (thread 8) - (thread finished, call stack no longer available) - -ERROR SUMMARY: 9 errors from 9 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_cond_race.stderr.diff =================================================================== --- trunk/exp-drd/tests/pth_cond_race.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_cond_race.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,2 +0,0 @@ -0a1 -> exp-drd, a data race detector. Deleted: trunk/exp-drd/tests/pth_cond_race.stderr.out =================================================================== --- trunk/exp-drd/tests/pth_cond_race.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_cond_race.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,11 +0,0 @@ -exp-drd, a data race detector. - -Thread 2: -Race condition: condition variable 0x........ has been signalled but the associated mutex 0x........ is not locked by the signalling thread - at 0x........: pthread_cond_signal@* (drd_preloaded.c:?) - by 0x........: thread_func(void*) (pth_cond_race.cpp:?) - by 0x........: vg_thread_wrapper (drd_preloaded.c:?) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) - -ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_cond_race2.stderr.diff =================================================================== --- trunk/exp-drd/tests/pth_cond_race2.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_cond_race2.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,2 +0,0 @@ -0a1 -> exp-drd, a data race detector. Deleted: trunk/exp-drd/tests/pth_cond_race2.stderr.out =================================================================== --- trunk/exp-drd/tests/pth_cond_race2.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_cond_race2.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,4 +0,0 @@ -exp-drd, a data race detector. - - -ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_create_chain.stderr.diff =================================================================== --- trunk/exp-drd/tests/pth_create_chain.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_create_chain.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,62 +0,0 @@ -0a1 -> exp-drd, a data race detector. -1a3,12 -> Thread 2: -> Conflicting load by thread 2 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 3) -> (thread finished, call stack no longer available) -> Other segment end (thread 3) -> (thread finished, call stack no longer available) -3c14,59 -< ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) ---- -> Thread 4: -> Conflicting load by thread 4 at 0x........ size 8 -> at 0x........: (within /home/sewardj/VgTRUNK/trunk/exp-drd/vgpreload_exp-drd-amd64-linux.so) -> by 0x........: thread_func(void*) (pth_create_chain.cpp:?) -> by 0x........: vg_thread_wrapper (drd_preloaded.c:?) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /home/sewardj/VgTRUNK/trunk/exp-drd/vgpreload_exp-drd-amd64-linux.so, NONE:Text -> Other segment start (thread 2) -> (thread finished, call stack no longer available) -> Other segment end (thread 2) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread 4 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 3) -> (thread finished, call stack no longer available) -> Other segment end (thread 3) -> (thread finished, call stack no longer available) -> -> Thread 5: -> Conflicting load by thread 5 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 3) -> (thread finished, call stack no longer available) -> Other segment end (thread 3) -> (thread finished, call stack no longer available) -> -> Thread 2: -> Conflicting load by thread 2 at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread 3) -> (thread finished, call stack no longer available) -> Other segment end (thread 3) -> (thread finished, call stack no longer available) -> -> ERROR SUMMARY: 5 errors from 5 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_create_chain.stderr.out =================================================================== --- trunk/exp-drd/tests/pth_create_chain.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_create_chain.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,59 +0,0 @@ -exp-drd, a data race detector. - -Thread 2: -Conflicting load by thread 2 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 3) - (thread finished, call stack no longer available) -Other segment end (thread 3) - (thread finished, call stack no longer available) - -Thread 4: -Conflicting load by thread 4 at 0x........ size 8 - at 0x........: (within /home/sewardj/VgTRUNK/trunk/exp-drd/vgpreload_exp-drd-amd64-linux.so) - by 0x........: thread_func(void*) (pth_create_chain.cpp:?) - by 0x........: vg_thread_wrapper (drd_preloaded.c:?) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /home/sewardj/VgTRUNK/trunk/exp-drd/vgpreload_exp-drd-amd64-linux.so, NONE:Text -Other segment start (thread 2) - (thread finished, call stack no longer available) -Other segment end (thread 2) - (thread finished, call stack no longer available) - -Conflicting load by thread 4 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 3) - (thread finished, call stack no longer available) -Other segment end (thread 3) - (thread finished, call stack no longer available) - -Thread 5: -Conflicting load by thread 5 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 3) - (thread finished, call stack no longer available) -Other segment end (thread 3) - (thread finished, call stack no longer available) - -Thread 2: -Conflicting load by thread 2 at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread 3) - (thread finished, call stack no longer available) -Other segment end (thread 3) - (thread finished, call stack no longer available) - -ERROR SUMMARY: 5 errors from 5 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_detached.stderr.diff =================================================================== --- trunk/exp-drd/tests/pth_detached.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_detached.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,17 +0,0 @@ -0a1 -> exp-drd, a data race detector. -1a3,12 -> Thread 3: -> Conflicting load by thread_func2[0] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -3c14 -< ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) ---- -> ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_detached.stderr.out =================================================================== --- trunk/exp-drd/tests/pth_detached.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_detached.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,14 +0,0 @@ -exp-drd, a data race detector. - -Thread 3: -Conflicting load by thread_func2[0] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_detached2.stderr.diff =================================================================== --- trunk/exp-drd/tests/pth_detached2.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_detached2.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,202 +0,0 @@ -0a1 -> exp-drd, a data race detector. -1a3,12 -> Thread 3: -> Conflicting load by thread_func1[1] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -3c14,199 -< ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) ---- -> Thread 2: -> Conflicting load by thread_func1[2] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func1[3] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func1[4] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func1[5] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func1[6] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func1[7] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func1[8] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Thread 3: -> Conflicting load by thread_func1[9] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Thread 2: -> Conflicting load by thread_func2[0] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Thread 3: -> Conflicting load by thread_func2[1] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Thread 2: -> Conflicting load by thread_func2[2] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[3] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[4] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[5] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[6] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[7] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[8] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> Conflicting load by thread_func2[9] at 0x........ size 8 -> at 0x........: (within libpthread-?.?.so) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -> Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -> Other segment start (thread_func1[0]) -> (thread finished, call stack no longer available) -> Other segment end (thread_func1[0]) -> (thread finished, call stack no longer available) -> -> ERROR SUMMARY: 19 errors from 19 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/pth_detached2.stderr.out =================================================================== --- trunk/exp-drd/tests/pth_detached2.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/pth_detached2.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,199 +0,0 @@ -exp-drd, a data race detector. - -Thread 3: -Conflicting load by thread_func1[1] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Thread 2: -Conflicting load by thread_func1[2] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func1[3] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func1[4] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func1[5] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func1[6] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func1[7] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func1[8] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Thread 3: -Conflicting load by thread_func1[9] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Thread 2: -Conflicting load by thread_func2[0] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Thread 3: -Conflicting load by thread_func2[1] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Thread 2: -Conflicting load by thread_func2[2] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[3] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[4] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[5] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[6] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[7] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[8] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -Conflicting load by thread_func2[9] at 0x........ size 8 - at 0x........: (within libpthread-?.?.so) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) -Allocation context: /lib64/libpthread-2.5.so, libpthread.so.0:Text -Other segment start (thread_func1[0]) - (thread finished, call stack no longer available) -Other segment end (thread_func1[0]) - (thread finished, call stack no longer available) - -ERROR SUMMARY: 19 errors from 19 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/sigalrm.stderr.diff =================================================================== --- trunk/exp-drd/tests/sigalrm.stderr.diff 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/sigalrm.stderr.diff 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,36 +0,0 @@ -0a1 -> exp-drd, a data race detector. -1a3,16 -> Conflicting load by thread 1 at 0x........ size 8 -> at 0x........: (within /home/sewardj/VgTRUNK/trunk/exp-drd/tests/sigalrm) -> by 0x........: main (sigalrm.cpp:?) -> Allocation context: unknown -> Other segment start (thread 2) -> at 0x........: clone (in /...libc...) -> by 0x........: (within libpthread-?.?.so) -> by 0x........: ??? -> Other segment end (thread 2) -> at 0x........: clock_nanosleep (in /lib64/librt-2.5.so) -> by 0x........: thread_func(void*) (sigalrm.cpp:?) -> by 0x........: vg_thread_wrapper (drd_preloaded.c:?) -> by 0x........: start_thread (in libpthread-?.?.so) -> by 0x........: clone (in /...libc...) -3c18,33 -< ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) ---- -> Thread 2: -> Conflicting load by thread 2 at 0x........ size 8 -> at 0x........: SignalHandler(int) (sigalrm.cpp:?) -> Allocation context: stack of thread 2, offset -6320 -> Other segment start (thread 1) -> at 0x........: clone (in /...libc...) -> by 0x........: do_clone (in libpthread-?.?.so) -> by 0x........: pthread_create@@GLIBC_2.2.5 (in libpthread-?.?.so) -> by 0x........: pthread_create@* (drd_preloaded.c:?) -> by 0x........: main (sigalrm.cpp:?) -> Other segment end (thread 1) -> at 0x........: pthread_join (in libpthread-?.?.so) -> by 0x........: pthread_join (drd_preloaded.c:?) -> by 0x........: main (sigalrm.cpp:?) -> -> ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0) Deleted: trunk/exp-drd/tests/sigalrm.stderr.out =================================================================== --- trunk/exp-drd/tests/sigalrm.stderr.out 2007-11-25 23:15:44 UTC (rev 7219) +++ trunk/exp-drd/tests/sigalrm.stderr.out 2007-11-25 23:56:12 UTC (rev 7220) @@ -1,33 +0,0 @@ -exp-drd, a data race detector. - -Conflicting load by thread 1 at 0x........ size 8 - at 0x........: (within /home/sewardj/VgTRUNK/trunk/exp-drd/tests/sigalrm) - by 0x........: main (sigalrm.cpp:?) -Allocation context: unknown -Other segment start (thread 2) - at 0x........: clone (in /...libc...) - by 0x........: (within libpthread-?.?.so) - by 0x........: ??? -Other segment end (thread 2) - at 0x........: clock_nanosleep (in /lib64/librt-2.5.so) - by 0x........: thread_func(void*) (sigalrm.cpp:?) - by 0x........: vg_thread_wrapper (drd_preloaded.c:?) - by 0x........: start_thread (in libpthread-?.?.so) - by 0x........: clone (in /...libc...) - -Thread 2: -Conflicting load by thread 2 at 0x........ size 8 - at 0x........: SignalHandler(int) (sigalrm.cpp:?) -Allocation context: stack of thread 2, offset -6320 -Other segment start (thread 1) - at 0x........: clone (in /...libc...) - by 0x........: do_clone (in libpthread-?.?.so) - by 0x........: pthread_create@@GLIBC_2.2.5 (in libpthread-?.?.so) - by 0x........: pthread_create@* (drd_preloaded.c:?) - by 0x........: main (sigalrm.cpp:?) -Other segment end (thread 1) - at 0x........: pthread_join (in libpthread-?.?.so) - by 0x........: pthread_join (drd_preloaded.c:?) - by 0x........: main (sigalrm.cpp:?) - -ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0) |
|
From: <sv...@va...> - 2007-11-25 23:15:42
|
Author: sewardj Date: 2007-11-25 23:15:44 +0000 (Sun, 25 Nov 2007) New Revision: 7219 Log: Fix g++-2.96 build breakage. Modified: trunk/exp-drd/tests/abort.cpp trunk/exp-drd/tests/pth_broadcast.cpp Modified: trunk/exp-drd/tests/abort.cpp =================================================================== --- trunk/exp-drd/tests/abort.cpp 2007-11-25 20:20:49 UTC (rev 7218) +++ trunk/exp-drd/tests/abort.cpp 2007-11-25 23:15:44 UTC (rev 7219) @@ -8,7 +8,7 @@ #include <fstream> #include <cassert> #include <pthread.h> - +#include <stdio.h>. static pthread_mutex_t s_mutex; void* thread_func(void*) Modified: trunk/exp-drd/tests/pth_broadcast.cpp =================================================================== --- trunk/exp-drd/tests/pth_broadcast.cpp 2007-11-25 20:20:49 UTC (rev 7218) +++ trunk/exp-drd/tests/pth_broadcast.cpp 2007-11-25 23:15:44 UTC (rev 7219) @@ -9,8 +9,8 @@ #include <iostream> #include <vector> #include <pthread.h> +#include <unistd.h> - // Class definitions. // Counting semaphore. |
|
From: Bart V. A. <bar...@gm...> - 2007-11-25 20:33:35
|
The following patch compensates recent changes in Valgrind -- please
apply this patch to the trunk. Result on openSUSE 10.3 after applying
the patch (revision 7218):
$ perl tests/vg_regtest exp-drd
-- Running tests in exp-drd/tests -------------------------------------
fp_race: valgrind ./fp_race
fp_race2: valgrind ./fp_race -m
pth_broadcast: valgrind ./pth_broadcast
pth_cond_race: valgrind ./pth_cond_race
pth_cond_race2: valgrind ./pth_cond_race -m
pth_create_chain: valgrind ./pth_create_chain 10
pth_detached: valgrind ./pth_detached 1 1
pth_detached2: valgrind ./pth_detached 10 10
sigalrm: valgrind ./sigalrm
*** sigalrm failed (stderr) ***
-- Finished tests in exp-drd/tests -------------------------------------
Index: exp-drd/tests/filter_stderr
===================================================================
--- exp-drd/tests/filter_stderr (revision 7218)
+++ exp-drd/tests/filter_stderr (working copy)
@@ -9,7 +9,7 @@
# Remove libpthread's version number.
# Remove line numbers from stack traces.
sed \
--e "/^drd, a data race detector\.$/d" \
+-e "/^exp-drd, a data race detector\.$/d" \
-e "/^NOTE: This is an Experimental-Class Valgrind Tool.$/d" \
-e "/^Copyright (C) 2006-200., and GNU GPL'd, by Bart Van Assche.$/d" \
-e "s/in [^ ]*libpthread-[0-9]*\.[0-9]*\.so/in libpthread-?.?.so/" \
Index: glibc-2.X-drd.supp
===================================================================
--- glibc-2.X-drd.supp (revision 7218)
+++ glibc-2.X-drd.supp (working copy)
@@ -78,6 +78,30 @@
{
pthread
exp-drd:ConflictingAccess
+ obj:/lib64/libpthread-2.6.1.so
+ fun:start_thread
+ fun:clone
+}
+{
+ pthread
+ exp-drd:ConflictingAccess
+ obj:/lib64/libc-2.6.1.so
+ fun:__libc_thread_freeres
+ fun:start_thread
+ fun:clone
+}
+{
+ pthread
+ exp-drd:ConflictingAccess
+ obj:/lib64/libc-2.6.1.so
+ obj:/lib64/libc-2.6.1.so
+ fun:__libc_thread_freeres
+ fun:start_thread
+ fun:clone
+}
+{
+ pthread
+ exp-drd:ConflictingAccess
fun:__nptl_deallocate_tsd
fun:start_thread
fun:clone
|
|
From: <sv...@va...> - 2007-11-25 20:20:49
|
Author: sewardj
Date: 2007-11-25 20:20:49 +0000 (Sun, 25 Nov 2007)
New Revision: 7218
Log:
Un-break 'make distdir'. Either by removing from EXTRA_DIST, file
names pertaining to tests which cannot be run (no associated .vgtest),
or by adding missing .stdout.exp files for tests which are to be run
(there is an associated .vgtest).
Added:
trunk/exp-drd/tests/fp_race.stdout.exp
trunk/exp-drd/tests/fp_race2.stdout.exp
trunk/exp-drd/tests/pth_broadcast.stdout.exp
trunk/exp-drd/tests/pth_cond_race.stdout.exp
trunk/exp-drd/tests/pth_cond_race2.stdout.exp
trunk/exp-drd/tests/pth_create_chain.stdout.exp
trunk/exp-drd/tests/sigalrm.stdout.exp
Modified:
trunk/exp-drd/docs/Makefile.am
trunk/exp-drd/tests/Makefile.am
Modified: trunk/exp-drd/docs/Makefile.am
===================================================================
--- trunk/exp-drd/docs/Makefile.am 2007-11-25 15:40:17 UTC (rev 7217)
+++ trunk/exp-drd/docs/Makefile.am 2007-11-25 20:20:49 UTC (rev 7218)
@@ -1 +1 @@
-EXTRA_DIST = drd-manual.xml
+#EXTRA_DIST = drd-manual.xml
Modified: trunk/exp-drd/tests/Makefile.am
===================================================================
--- trunk/exp-drd/tests/Makefile.am 2007-11-25 15:40:17 UTC (rev 7217)
+++ trunk/exp-drd/tests/Makefile.am 2007-11-25 20:20:49 UTC (rev 7218)
@@ -10,14 +10,10 @@
filter_fdleak filter_none_discards filter_stderr
EXTRA_DIST = $(noinst_SCRIPTS) \
- abort.vgtest \
- abort.stdout.exp abort.stderr.exp \
fp_race.vgtest \
fp_race.stdout.exp fp_race.stderr.exp \
fp_race2.vgtest \
fp_race2.stdout.exp fp_race2.stderr.exp \
- new_delete.vgtest \
- new_delete.stdout.exp new_delete.stderr.exp \
pth_broadcast.vgtest \
pth_broadcast.stdout.exp pth_broadcast.stderr.exp \
pth_cond_race.vgtest \
@@ -31,9 +27,7 @@
pth_detached2.vgtest \
pth_detached2.stdout.exp pth_detached2.stderr.exp \
sigalrm.vgtest \
- sigalrm.stdout.exp sigalrm.stderr.exp \
- std-string.vgtest \
- std-string.stdout.exp std-string.stderr.exp
+ sigalrm.stdout.exp sigalrm.stderr.exp
AM_CFLAGS = $(WERROR) -Winline -Wall -Wshadow -g $(AM_FLAG_M3264_PRI)
AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/include -I$(top_builddir)/include
Added: trunk/exp-drd/tests/fp_race.stdout.exp
===================================================================
Added: trunk/exp-drd/tests/fp_race2.stdout.exp
===================================================================
Added: trunk/exp-drd/tests/pth_broadcast.stdout.exp
===================================================================
Added: trunk/exp-drd/tests/pth_cond_race.stdout.exp
===================================================================
Added: trunk/exp-drd/tests/pth_cond_race2.stdout.exp
===================================================================
Added: trunk/exp-drd/tests/pth_create_chain.stdout.exp
===================================================================
Added: trunk/exp-drd/tests/sigalrm.stdout.exp
===================================================================
|
|
From: Bart V. A. <bar...@gm...> - 2007-11-25 19:46:18
|
On Nov 25, 2007 3:06 PM, <sv...@va...> wrote: > Author: sewardj > Date: 2007-11-25 14:06:06 +0000 (Sun, 25 Nov 2007) > New Revision: 7212 > > Log: > Core-tool iface changes needed to support exp-drd (Bart Van Assche). > > Modified: > trunk/coregrind/m_syswrap/syswrap-linux.c > trunk/coregrind/m_tooliface.c > trunk/coregrind/pub_core_tooliface.h > trunk/include/pub_tool_tooliface.h > ... Hello Julian, Thanks for merging this. I tried to figure out where to add a call to VG_TRACK(pre_thread_first_insn)() for AIX, but it was not clear to me where exactly this call should be inserted for AIX ? Bart. |
|
From: <sv...@va...> - 2007-11-25 15:40:14
|
Author: sewardj
Date: 2007-11-25 15:40:17 +0000 (Sun, 25 Nov 2007)
New Revision: 7217
Log:
Get rid of compiler warnings.
Modified:
trunk/exp-omega/tests/scope3.c
trunk/none/tests/amd64/rcl-amd64.c
trunk/none/tests/amd64/redundantRexW.c
Modified: trunk/exp-omega/tests/scope3.c
===================================================================
--- trunk/exp-omega/tests/scope3.c 2007-11-25 14:11:38 UTC (rev 7216)
+++ trunk/exp-omega/tests/scope3.c 2007-11-25 15:40:17 UTC (rev 7217)
@@ -2,7 +2,7 @@
static void func1(char *pointer)
{
- int dummy = 0;
+ __attribute__((unused)) int dummy = 0;
return;
} /* Line 7 x86-64*/
Modified: trunk/none/tests/amd64/rcl-amd64.c
===================================================================
--- trunk/none/tests/amd64/rcl-amd64.c 2007-11-25 14:11:38 UTC (rev 7216)
+++ trunk/none/tests/amd64/rcl-amd64.c 2007-11-25 15:40:17 UTC (rev 7217)
@@ -29,9 +29,8 @@
int main(int argc, char * argv[])
{
- register unsigned long a, b, c;
+ register unsigned long a, b;
int i;
- int sc;
if (argc == 2)
a = atol(argv[1]);
else
Modified: trunk/none/tests/amd64/redundantRexW.c
===================================================================
--- trunk/none/tests/amd64/redundantRexW.c 2007-11-25 14:11:38 UTC (rev 7216)
+++ trunk/none/tests/amd64/redundantRexW.c 2007-11-25 15:40:17 UTC (rev 7217)
@@ -95,10 +95,10 @@
void after_test ( char* who, XMMRegs* regs, Mem* mem ) {
XMMRegs rdiff;
Mem mdiff;
+ char s[128];
setup_regs_mem( &rdiff, &mdiff );
xor_XMMRegs( regs, &rdiff );
xor_Mem( mem, &mdiff );
- char s[128];
sprintf(s, "after \"%s\"", who );
pp_Mem( s, &mdiff );
pp_XMMRegs( s, &rdiff );
|
|
From: <sv...@va...> - 2007-11-25 14:11:36
|
Author: sewardj Date: 2007-11-25 14:11:38 +0000 (Sun, 25 Nov 2007) New Revision: 7216 Log: Remove from the active tree; this is of historical interest only now. Of course this remains in the repo forever. Removed: trunk/old-helgrind/ |
|
From: <sv...@va...> - 2007-11-25 14:09:42
|
Author: sewardj
Date: 2007-11-25 14:09:45 +0000 (Sun, 25 Nov 2007)
New Revision: 7215
Log:
Update.
Modified:
trunk/docs/internals/3_2_BUGSTATUS.txt
Modified: trunk/docs/internals/3_2_BUGSTATUS.txt
===================================================================
--- trunk/docs/internals/3_2_BUGSTATUS.txt 2007-11-25 14:09:26 UTC (rev 7214)
+++ trunk/docs/internals/3_2_BUGSTATUS.txt 2007-11-25 14:09:45 UTC (rev 7215)
@@ -20,8 +20,7 @@
n-i-bz vx1786,r6791 x86 INT insn (29 June) (INT (0xCD) 0x40 - 0x43)
-n-i-bz [patch] Add sys_utimensat system call for Linux x86
- platform (Oct 25)
+n-i-bz r7195 Add sys_utimensat system call for Linux x86 platform
79844 fixed Helgrind complains about race condition which does not exist
@@ -36,6 +35,8 @@
128359 glibc-fix Please suppress the uninitialized bytes report
on getifaddrs() (glibc 2.3.3)
+129937 fixed ==150380
+
133962 vx1792 unhandled instruction bytes: 0xF2 0x4C 0xF 0x10
134990 fixed use -fno-stack-protector if possible
@@ -48,8 +49,8 @@
145559 r7168 valgrind aborts when malloc_stats is called
145609 r7191 valgrind aborts all runs with 'repeated section!'
145622 r7183 --db-attach broken again on x86-64
-145837 ==149519
-145887 PPC32: getitimer() system call is not supported (patch)
+145837 fixed ==149519
+145887 r7193 PPC32: getitimer() system call is not supported (patch)
146252 fixed ==150678
146701 fixed ==134990
@@ -63,7 +64,7 @@
148096 VALGRIND_MALLOCLIKE_BLOCK not working correctly?
148174 r6855 Incorrect type of freed_list_volume causes
assertion with large memory allocations
-148254 crash writing global var on ppc64 from instrumentation fn
+148254 marginal crash writing global var on ppc64 from instrumentation fn
148363 marginal amd64->IR: 0x65 0x4C 0x8B 0x1C (mov %gs:0x10,%r11)
148447 vx1776 x86_64 : new NOP codes: 66 66 66 66 2e 0f 1f
148742 cantrepro Leak-check fails assert on exit
@@ -78,23 +79,23 @@
150044 r7171 SEGV during stack deregister
150045 fixable?? Valgrind doesn't recognize pthread stack as a stack
when context switching
-150380 PRIO dwarf/gcc interoperation (dwarf3 read problems)
- (related to 129937 ?)
-150408 ==148447
-150678 vx1798d priv/guest-amd64/toIR.c:3741 (dis_Grp5): Assertion
+150380 r7191 dwarf/gcc interoperation (dwarf3 read problems)
+150408 fixed ==148447
+150678 vx1798 priv/guest-amd64/toIR.c:3741 (dis_Grp5): Assertion
`sz == 4' failed when running Mono on x86_64
150681 Check definedness of client request arguments
151209 r7028 V unable to execute programs for users with UID > 2^16
151570 cantrepro Bogus "Conditional jump ..." error with bit field (3.1.1)
151886 PRIO Suppression entry Memcheck:Param ignored
-151908 inprogress --db-attach unimplemented on ppc64
-151935 --db-command= not parsed properly in .valgrindrc
-151938 help on --db-command= misleading
+151908 stalled --db-attach unimplemented on ppc64
+151935 bogus --db-command= not parsed properly in .valgrindrc
+151938 r7192 help on --db-command= misleading
152022 r7147 subw $0x28, %%sp causes assertion failure in memcheck
-152357 inb and outb not recognized in 64-bit mode
-152501 vex x86->IR: 0x27 0x66 0x89 0x45 (daa)
+152357 vx1799 inb and outb not recognized in 64-bit mode
+152501 vx1800 vex x86->IR: 0x27 0x66 0x89 0x45 (daa)
+152818 vx1801 vex x86->IR: 0xF3 0xAC 0xFC 0x9C (rep lodsb)
---------- Bugs reported after (in) 3.2.3 --------------------------
|
|
From: <sv...@va...> - 2007-11-25 14:09:24
|
Author: sewardj
Date: 2007-11-25 14:09:26 +0000 (Sun, 25 Nov 2007)
New Revision: 7214
Log:
Fix broken link.
Modified:
trunk/docs/xml/manual-core.xml
Modified: trunk/docs/xml/manual-core.xml
===================================================================
--- trunk/docs/xml/manual-core.xml 2007-11-25 14:08:53 UTC (rev 7213)
+++ trunk/docs/xml/manual-core.xml 2007-11-25 14:09:26 UTC (rev 7214)
@@ -1501,7 +1501,7 @@
using malloc/new/free/delete, it should still work, but Memcheck's
error checking won't be so effective. If you describe your program's
memory management scheme using "client requests"
- (see <xref linkend="manual-core.clientreq"/>), Memcheck can do
+ (see <xref linkend="manual-core-adv.clientreq"/>), Memcheck can do
better. Nevertheless, using malloc/new and free/delete is still the
best approach.</para>
</listitem>
|
|
From: <sv...@va...> - 2007-11-25 14:08:51
|
Author: sewardj
Date: 2007-11-25 14:08:53 +0000 (Sun, 25 Nov 2007)
New Revision: 7213
Log:
Misc changes needed to support exp-drd (Bart Van Assche).
Modified:
trunk/Makefile.am
trunk/configure.in
trunk/coregrind/m_debuginfo/debuginfo.c
trunk/coregrind/m_libcbase.c
trunk/coregrind/m_machine.c
trunk/include/pub_tool_debuginfo.h
trunk/include/pub_tool_libcbase.h
trunk/include/pub_tool_machine.h
Modified: trunk/Makefile.am
===================================================================
--- trunk/Makefile.am 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/Makefile.am 2007-11-25 14:08:53 UTC (rev 7213)
@@ -9,19 +9,22 @@
massif \
lackey \
none \
- helgrind \
- exp-omega
+ helgrind
+EXP_TOOLS = exp-omega \
+ exp-drd
+
# Put docs last because building the HTML is slow and we want to get
# everything else working before we try it.
-SUBDIRS = include coregrind . tests perf auxprogs $(TOOLS) docs
+SUBDIRS = include coregrind . tests perf auxprogs $(TOOLS) $(EXP_TOOLS) docs
DIST_SUBDIRS = $(SUBDIRS)
SUPP_FILES = \
glibc-2.2.supp glibc-2.3.supp glibc-2.4.supp glibc-2.5.supp \
glibc-2.6.supp aix5libc.supp xfree-3.supp xfree-4.supp \
glibc-2.34567-NPTL-helgrind.supp \
- glibc-2.2-LinuxThreads-helgrind.supp
+ glibc-2.2-LinuxThreads-helgrind.supp \
+ glibc-2.X-drd.supp
dist_val_DATA = $(SUPP_FILES) default.supp
@@ -65,6 +68,8 @@
## Preprend @PERL@ because tests/vg_regtest isn't executable
regtest: check
@PERL@ tests/vg_regtest $(TOOLS)
+exp-regtest: check
+ @PERL@ tests/vg_regtest $(EXP_TOOLS)
## Preprend @PERL@ because tests/vg_per isn't executable
perf: check
Modified: trunk/configure.in
===================================================================
--- trunk/configure.in 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/configure.in 2007-11-25 14:08:53 UTC (rev 7213)
@@ -1018,6 +1018,9 @@
exp-omega/Makefile
exp-omega/tests/Makefile
exp-omega/docs/Makefile
+ exp-drd/Makefile
+ exp-drd/docs/Makefile
+ exp-drd/tests/Makefile
)
cat<<EOF
Modified: trunk/coregrind/m_debuginfo/debuginfo.c
===================================================================
--- trunk/coregrind/m_debuginfo/debuginfo.c 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/coregrind/m_debuginfo/debuginfo.c 2007-11-25 14:08:53 UTC (rev 7213)
@@ -1290,7 +1290,7 @@
}
if (si != NULL)
- vg_assert(ret != VgSectUnknown);
+ vg_assert(ret != Vg_SectUnknown);
if (0 && si) {
VG_(printf)(
@@ -1305,6 +1305,33 @@
return ret;
}
+Char* VG_(seginfo_sect_kind_name)(Addr a, Char* buf, UInt n_buf)
+{
+ switch (VG_(seginfo_sect_kind)(a)) {
+ case Vg_SectUnknown:
+ VG_(snprintf)(buf, n_buf, "Unknown");
+ break;
+ case Vg_SectText:
+ VG_(snprintf)(buf, n_buf, "Text");
+ break;
+ case Vg_SectData:
+ VG_(snprintf)(buf, n_buf, "Data");
+ break;
+ case Vg_SectBSS:
+ VG_(snprintf)(buf, n_buf, "BSS");
+ break;
+ case Vg_SectGOT:
+ VG_(snprintf)(buf, n_buf, "GOT");
+ break;
+ case Vg_SectPLT:
+ VG_(snprintf)(buf, n_buf, "PLT");
+ break;
+ default:
+ vg_assert(0);
+ }
+ return buf;
+}
+
Int VG_(seginfo_syms_howmany) ( const SegInfo *si )
{
return si->symtab_used;
Modified: trunk/coregrind/m_libcbase.c
===================================================================
--- trunk/coregrind/m_libcbase.c 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/coregrind/m_libcbase.c 2007-11-25 14:08:53 UTC (rev 7213)
@@ -501,6 +501,24 @@
return dest;
}
+void* VG_(memmove)(void *dest, const void *src, SizeT sz)
+{
+ SizeT i;
+ if (sz == 0)
+ return dest;
+ if (dest < src) {
+ for (i = 0; i < sz; i++) {
+ ((UChar*)dest)[i] = ((UChar*)src)[i];
+ }
+ }
+ else if (dest > src) {
+ for (i = sz - 1; i >= 0; i--) {
+ ((UChar*)dest)[i] = ((UChar*)src)[i];
+ }
+ }
+ return dest;
+}
+
void* VG_(memset) ( void *dest, Int c, SizeT sz )
{
Char *d = (Char *)dest;
Modified: trunk/coregrind/m_machine.c
===================================================================
--- trunk/coregrind/m_machine.c 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/coregrind/m_machine.c 2007-11-25 14:08:53 UTC (rev 7213)
@@ -215,6 +215,13 @@
return False;
}
+Addr VG_(thread_get_stack_max)(ThreadId tid)
+{
+ vg_assert(0 <= tid && tid < VG_N_THREADS && tid != VG_INVALID_THREADID);
+ vg_assert(VG_(threads)[tid].status != VgTs_Empty);
+ return VG_(threads)[tid].client_stack_highest_word;
+}
+
//-------------------------------------------------------------
/* Details about the capabilities of the underlying (host) CPU. These
details are acquired by (1) enquiring with the CPU at startup, or
Modified: trunk/include/pub_tool_debuginfo.h
===================================================================
--- trunk/include/pub_tool_debuginfo.h 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/include/pub_tool_debuginfo.h 2007-11-25 14:08:53 UTC (rev 7213)
@@ -136,6 +136,9 @@
extern VgSectKind VG_(seginfo_sect_kind)(Addr);
+extern Char* VG_(seginfo_sect_kind_name)(Addr a, Char* buf, UInt n_buf);
+
+
#endif // __PUB_TOOL_DEBUGINFO_H
/*--------------------------------------------------------------------*/
Modified: trunk/include/pub_tool_libcbase.h
===================================================================
--- trunk/include/pub_tool_libcbase.h 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/include/pub_tool_libcbase.h 2007-11-25 14:08:53 UTC (rev 7213)
@@ -104,6 +104,7 @@
------------------------------------------------------------------ */
extern void* VG_(memcpy) ( void *d, const void *s, SizeT sz );
+extern void* VG_(memmove)( void *d, const void *s, SizeT sz );
extern void* VG_(memset) ( void *s, Int c, SizeT sz );
extern Int VG_(memcmp) ( const void* s1, const void* s2, SizeT n );
Modified: trunk/include/pub_tool_machine.h
===================================================================
--- trunk/include/pub_tool_machine.h 2007-11-25 14:06:06 UTC (rev 7212)
+++ trunk/include/pub_tool_machine.h 2007-11-25 14:08:53 UTC (rev 7213)
@@ -100,6 +100,9 @@
extern Bool VG_(thread_stack_next) ( ThreadId* tid, Addr* stack_min,
Addr* stack_max );
+// Returns .client_stack_highest_word for the given thread
+extern Addr VG_(thread_get_stack_max) ( ThreadId tid );
+
// Given a pointer to a function as obtained by "& functionname" in C,
// produce a pointer to the actual entry point for the function. For
// most platforms it's the identity function. Unfortunately, on
|
|
From: <sv...@va...> - 2007-11-25 14:06:06
|
Author: sewardj
Date: 2007-11-25 14:06:06 +0000 (Sun, 25 Nov 2007)
New Revision: 7212
Log:
Core-tool iface changes needed to support exp-drd (Bart Van Assche).
Modified:
trunk/coregrind/m_syswrap/syswrap-linux.c
trunk/coregrind/m_tooliface.c
trunk/coregrind/pub_core_tooliface.h
trunk/include/pub_tool_tooliface.h
Modified: trunk/coregrind/m_syswrap/syswrap-linux.c
===================================================================
--- trunk/coregrind/m_syswrap/syswrap-linux.c 2007-11-25 14:01:38 UTC (rev 7211)
+++ trunk/coregrind/m_syswrap/syswrap-linux.c 2007-11-25 14:06:06 UTC (rev 7212)
@@ -78,6 +78,8 @@
VG_(printf)("thread tid %d started: stack = %p\n",
tid, &tid);
+ VG_TRACK(pre_thread_first_insn, tid);
+
tst->os_state.lwpid = VG_(gettid)();
tst->os_state.threadgroup = VG_(getpid)();
Modified: trunk/coregrind/m_tooliface.c
===================================================================
--- trunk/coregrind/m_tooliface.c 2007-11-25 14:01:38 UTC (rev 7211)
+++ trunk/coregrind/m_tooliface.c 2007-11-25 14:06:06 UTC (rev 7212)
@@ -335,6 +335,7 @@
DEF(track_stop_client_code, ThreadId, ULong)
DEF(track_pre_thread_ll_create, ThreadId, ThreadId)
+DEF(track_pre_thread_first_insn, ThreadId)
DEF(track_pre_thread_ll_exit, ThreadId)
DEF(track_pre_deliver_signal, ThreadId, Int sigNo, Bool)
Modified: trunk/coregrind/pub_core_tooliface.h
===================================================================
--- trunk/coregrind/pub_core_tooliface.h 2007-11-25 14:01:38 UTC (rev 7211)
+++ trunk/coregrind/pub_core_tooliface.h 2007-11-25 14:06:06 UTC (rev 7212)
@@ -209,6 +209,7 @@
void (*track_stop_client_code) (ThreadId, ULong);
void (*track_pre_thread_ll_create)(ThreadId, ThreadId);
+ void (*track_pre_thread_first_insn)(ThreadId);
void (*track_pre_thread_ll_exit) (ThreadId);
void (*track_pre_deliver_signal) (ThreadId, Int sigNo, Bool);
Modified: trunk/include/pub_tool_tooliface.h
===================================================================
--- trunk/include/pub_tool_tooliface.h 2007-11-25 14:01:38 UTC (rev 7211)
+++ trunk/include/pub_tool_tooliface.h 2007-11-25 14:06:06 UTC (rev 7212)
@@ -588,9 +588,21 @@
low-level thread create/quit event. In general a few hundred
instructions; hence a few hundred(ish) memory references could get
misclassified each time.
+
+ pre_thread_first_insn: is called when the thread is all set up and
+ ready to go (stack in place, etc) but has not executed its first
+ instruction yet. Gives threading tools a chance to ask questions
+ about the thread (eg, what is its initial client stack pointer)
+ that are not easily answered at pre_thread_ll_create time.
+
+ For a given thread, the call sequence is:
+ ll_create (in the parent's context)
+ first_insn (in the child's context)
+ ll_exit (in the child's context)
*/
-void VG_(track_pre_thread_ll_create)(void(*f)(ThreadId tid, ThreadId child));
-void VG_(track_pre_thread_ll_exit) (void(*f)(ThreadId tid));
+void VG_(track_pre_thread_ll_create) (void(*f)(ThreadId tid, ThreadId child));
+void VG_(track_pre_thread_first_insn)(void(*f)(ThreadId tid));
+void VG_(track_pre_thread_ll_exit) (void(*f)(ThreadId tid));
/* Signal events (not exhaustive)
|
|
From: <sv...@va...> - 2007-11-25 14:01:37
|
Author: sewardj Date: 2007-11-25 14:01:38 +0000 (Sun, 25 Nov 2007) New Revision: 7211 Log: Add DRD as an experimental tool. Bart Van Assche is the maintainer. Added: trunk/exp-drd/ trunk/exp-drd/Makefile.am trunk/exp-drd/TODO.txt trunk/exp-drd/docs/ trunk/exp-drd/docs/Makefile.am trunk/exp-drd/drd_bitmap.c trunk/exp-drd/drd_bitmap.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_error.h trunk/exp-drd/drd_main.c trunk/exp-drd/drd_malloc_wrappers.c trunk/exp-drd/drd_malloc_wrappers.h trunk/exp-drd/drd_mutex.c trunk/exp-drd/drd_mutex.h trunk/exp-drd/drd_preloaded.c trunk/exp-drd/drd_segment.c trunk/exp-drd/drd_segment.h trunk/exp-drd/drd_suppression.c trunk/exp-drd/drd_suppression.h trunk/exp-drd/drd_thread.c trunk/exp-drd/drd_thread.h trunk/exp-drd/drd_track.h trunk/exp-drd/drd_vc.c trunk/exp-drd/drd_vc.h trunk/exp-drd/pthread_object_size.h trunk/exp-drd/pub_drd_bitmap.h trunk/exp-drd/tests/ trunk/exp-drd/tests/Makefile.am trunk/exp-drd/tests/abort.cpp trunk/exp-drd/tests/filter_cmdline0 trunk/exp-drd/tests/filter_fdleak trunk/exp-drd/tests/filter_linenos trunk/exp-drd/tests/filter_none_discards trunk/exp-drd/tests/filter_stderr trunk/exp-drd/tests/fp_race.cpp trunk/exp-drd/tests/fp_race.stderr.diff trunk/exp-drd/tests/fp_race.stderr.diff2 trunk/exp-drd/tests/fp_race.stderr.exp trunk/exp-drd/tests/fp_race.stderr.exp2 trunk/exp-drd/tests/fp_race.stderr.out trunk/exp-drd/tests/fp_race.vgtest trunk/exp-drd/tests/fp_race2.stderr.diff trunk/exp-drd/tests/fp_race2.stderr.exp trunk/exp-drd/tests/fp_race2.stderr.out trunk/exp-drd/tests/fp_race2.vgtest trunk/exp-drd/tests/new_delete.cpp trunk/exp-drd/tests/pth_broadcast.cpp trunk/exp-drd/tests/pth_broadcast.stderr.diff trunk/exp-drd/tests/pth_broadcast.stderr.exp trunk/exp-drd/tests/pth_broadcast.stderr.out trunk/exp-drd/tests/pth_broadcast.vgtest trunk/exp-drd/tests/pth_cond_race.cpp trunk/exp-drd/tests/pth_cond_race.stderr.diff trunk/exp-drd/tests/pth_cond_race.stderr.exp trunk/exp-drd/tests/pth_cond_race.stderr.out trunk/exp-drd/tests/pth_cond_race.vgtest trunk/exp-drd/tests/pth_cond_race2.stderr.diff trunk/exp-drd/tests/pth_cond_race2.stderr.exp trunk/exp-drd/tests/pth_cond_race2.stderr.out trunk/exp-drd/tests/pth_cond_race2.vgtest trunk/exp-drd/tests/pth_create_chain.cpp trunk/exp-drd/tests/pth_create_chain.stderr.diff trunk/exp-drd/tests/pth_create_chain.stderr.exp trunk/exp-drd/tests/pth_create_chain.stderr.out trunk/exp-drd/tests/pth_create_chain.vgtest trunk/exp-drd/tests/pth_detached.c trunk/exp-drd/tests/pth_detached.stderr.diff trunk/exp-drd/tests/pth_detached.stderr.exp trunk/exp-drd/tests/pth_detached.stderr.out trunk/exp-drd/tests/pth_detached.stdout.exp trunk/exp-drd/tests/pth_detached.vgtest trunk/exp-drd/tests/pth_detached2.stderr.diff trunk/exp-drd/tests/pth_detached2.stderr.exp trunk/exp-drd/tests/pth_detached2.stderr.out trunk/exp-drd/tests/pth_detached2.stdout.exp trunk/exp-drd/tests/pth_detached2.vgtest trunk/exp-drd/tests/sigalrm.cpp trunk/exp-drd/tests/sigalrm.stderr.diff trunk/exp-drd/tests/sigalrm.stderr.exp trunk/exp-drd/tests/sigalrm.stderr.out trunk/exp-drd/tests/sigalrm.vgtest trunk/exp-drd/tests/std-string.cpp trunk/glibc-2.X-drd.supp [... diff too large to include ...] |
|
From: <sv...@va...> - 2007-11-25 12:30:34
|
Author: sewardj
Date: 2007-11-25 12:30:36 +0000 (Sun, 25 Nov 2007)
New Revision: 7210
Log:
Fix completely bogus implementation of VG_(seginfo_sect_kind). This
was reported a very long time ago (2 years?) but was not fixed until
now.
Modified:
trunk/coregrind/m_debuginfo/debuginfo.c
Modified: trunk/coregrind/m_debuginfo/debuginfo.c
===================================================================
--- trunk/coregrind/m_debuginfo/debuginfo.c 2007-11-25 00:56:51 UTC (rev 7209)
+++ trunk/coregrind/m_debuginfo/debuginfo.c 2007-11-25 12:30:36 UTC (rev 7210)
@@ -1263,36 +1263,43 @@
VgSectKind VG_(seginfo_sect_kind)(Addr a)
{
- SegInfo* si;
+ SegInfo* si;
VgSectKind ret = Vg_SectUnknown;
- for(si = segInfo_list; si != NULL; si = si->next) {
- if (a >= si->text_start_avma
- && a < si->text_start_avma + si->text_size) {
+ for (si = segInfo_list; si != NULL; si = si->next) {
+ if (a >= si->text_start_avma && a < si->text_start_avma + si->text_size) {
+ ret = Vg_SectText;
+ break;
+ }
+ if (a >= si->data_start_avma && a < si->data_start_avma + si->data_size) {
+ ret = Vg_SectData;
+ break;
+ }
+ if (a >= si->bss_start_avma && a < si->bss_start_avma + si->bss_size) {
+ ret = Vg_SectBSS;
+ break;
+ }
+ if (a >= si->plt_start_avma && a < si->plt_start_avma + si->plt_size) {
+ ret = Vg_SectPLT;
+ break;
+ }
+ if (a >= si->got_start_avma && a < si->got_start_avma + si->got_size) {
+ ret = Vg_SectGOT;
+ break;
+ }
+ }
- if (0)
- VG_(printf)(
- "addr=%p si=%p %s got=%p %d plt=%p %d data=%p %d bss=%p %d\n",
- a, si, si->filename,
- si->got_start_avma, si->got_size,
- si->plt_start_avma, si->plt_size,
- si->data_start_avma, si->data_size,
- si->bss_start_avma, si->bss_size);
+ if (si != NULL)
+ vg_assert(ret != VgSectUnknown);
- ret = Vg_SectText;
-
- if (a >= si->data_start_avma && a < si->data_start_avma + si->data_size)
- ret = Vg_SectData;
- else
- if (a >= si->bss_start_avma && a < si->bss_start_avma + si->bss_size)
- ret = Vg_SectBSS;
- else
- if (a >= si->plt_start_avma && a < si->plt_start_avma + si->plt_size)
- ret = Vg_SectPLT;
- else
- if (a >= si->got_start_avma && a < si->got_start_avma + si->got_size)
- ret = Vg_SectGOT;
- }
+ if (0 && si) {
+ VG_(printf)(
+ "addr=%p si=%p %s got=%p %d plt=%p %d data=%p %d bss=%p %d\n",
+ a, si, si->filename,
+ si->got_start_avma, si->got_size,
+ si->plt_start_avma, si->plt_size,
+ si->data_start_avma, si->data_size,
+ si->bss_start_avma, si->bss_size);
}
return ret;
|
|
From: Tom H. <th...@cy...> - 2007-11-25 04:03:58
|
Nightly build on alvis ( i686, Red Hat 7.3 ) started at 2007-11-25 03:15:02 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 == 318 tests, 60 stderr failures, 1 stdout failure, 27 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/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/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/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-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/mremap (stderr) none/tests/mremap2 (stdout) 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) ================================================= == 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 == 318 tests, 60 stderr failures, 3 stdout failures, 27 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/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/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/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-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/cmdline1 (stdout) none/tests/cmdline2 (stdout) none/tests/mremap (stderr) none/tests/mremap2 (stdout) 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) ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Sun Nov 25 03:47:10 2007 --- new.short Sun Nov 25 04:03:58 2007 *************** *** 8,10 **** ! == 318 tests, 60 stderr failures, 3 stdout failures, 27 post failures == memcheck/tests/addressable (stderr) --- 8,10 ---- ! == 318 tests, 60 stderr failures, 1 stdout failure, 27 post failures == memcheck/tests/addressable (stderr) *************** *** 70,73 **** massif/tests/zero2 (post) - none/tests/cmdline1 (stdout) - none/tests/cmdline2 (stdout) none/tests/mremap (stderr) --- 70,71 ---- |
|
From: Tom H. <th...@cy...> - 2007-11-25 03:34:51
|
Nightly build on lloyd ( x86_64, Fedora 7 ) started at 2007-11-25 03:05:05 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 == 352 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) memcheck/tests/xml1 (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc22_exit_w_lock (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 == 352 tests, 6 stderr failures, 4 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) memcheck/tests/xml1 (stderr) none/tests/cmdline1 (stdout) none/tests/cmdline2 (stdout) 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 Sun Nov 25 03:14:39 2007 --- new.short Sun Nov 25 03:34:23 2007 *************** *** 8,10 **** ! == 352 tests, 6 stderr failures, 4 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) --- 8,10 ---- ! == 352 tests, 6 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) *************** *** 13,16 **** memcheck/tests/xml1 (stderr) - none/tests/cmdline1 (stdout) - none/tests/cmdline2 (stdout) none/tests/mremap (stderr) --- 13,14 ---- |
|
From: Tom H. <th...@cy...> - 2007-11-25 03:26:05
|
Nightly build on dellow ( x86_64, Fedora 8 ) started at 2007-11-25 03:10:03 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 == 352 tests, 9 stderr failures, 4 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) memcheck/tests/xml1 (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) none/tests/pth_cvsimple (stdout) none/tests/pth_detached (stdout) helgrind/tests/tc17_sembar (stderr) helgrind/tests/tc18_semabuse (stderr) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc22_exit_w_lock (stderr) helgrind/tests/tc23_bogus_condwait (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 == 352 tests, 9 stderr failures, 5 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/vcpu_fnfns (stdout) memcheck/tests/x86/scalar (stderr) memcheck/tests/xml1 (stderr) none/tests/cmdline1 (stdout) none/tests/cmdline2 (stdout) none/tests/mremap (stderr) none/tests/mremap2 (stdout) none/tests/pth_detached (stdout) helgrind/tests/tc17_sembar (stderr) helgrind/tests/tc18_semabuse (stderr) helgrind/tests/tc20_verifywrap (stderr) helgrind/tests/tc22_exit_w_lock (stderr) helgrind/tests/tc23_bogus_condwait (stderr) ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Sun Nov 25 03:18:10 2007 --- new.short Sun Nov 25 03:26:07 2007 *************** *** 8,10 **** ! == 352 tests, 9 stderr failures, 5 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) --- 8,10 ---- ! == 352 tests, 9 stderr failures, 4 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) *************** *** 13,18 **** memcheck/tests/xml1 (stderr) - none/tests/cmdline1 (stdout) - none/tests/cmdline2 (stdout) none/tests/mremap (stderr) none/tests/mremap2 (stdout) none/tests/pth_detached (stdout) --- 13,17 ---- memcheck/tests/xml1 (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) + none/tests/pth_cvsimple (stdout) none/tests/pth_detached (stdout) |
|
From: Tom H. <th...@cy...> - 2007-11-25 03:13:33
|
Nightly build on gill ( x86_64, Fedora Core 2 ) started at 2007-11-25 03:00:02 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 == 354 tests, 24 stderr failures, 1 stdout failure, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/stack_switch (stderr) memcheck/tests/x86/scalar (stderr) memcheck/tests/x86/scalar_supp (stderr) none/tests/fdleak_fcntl (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) 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/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) ================================================= == 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 == 354 tests, 24 stderr failures, 3 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) memcheck/tests/stack_switch (stderr) memcheck/tests/x86/scalar (stderr) memcheck/tests/x86/scalar_supp (stderr) none/tests/cmdline1 (stdout) none/tests/cmdline2 (stdout) none/tests/fdleak_fcntl (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) 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/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) ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Sun Nov 25 03:06:44 2007 --- new.short Sun Nov 25 03:13:33 2007 *************** *** 8,10 **** ! == 354 tests, 24 stderr failures, 3 stdout failures, 0 post failures == memcheck/tests/pointer-trace (stderr) --- 8,10 ---- ! == 354 tests, 24 stderr failures, 1 stdout failure, 0 post failures == memcheck/tests/pointer-trace (stderr) *************** *** 13,16 **** memcheck/tests/x86/scalar_supp (stderr) - none/tests/cmdline1 (stdout) - none/tests/cmdline2 (stdout) none/tests/fdleak_fcntl (stderr) --- 13,14 ---- |
|
From: <sv...@va...> - 2007-11-25 01:34:01
|
Author: sewardj
Date: 2007-11-25 01:34:03 +0000 (Sun, 25 Nov 2007)
New Revision: 1801
Log:
Implement lods{b,w,l}. Fixes #152818.
Modified:
trunk/priv/guest-x86/toIR.c
Modified: trunk/priv/guest-x86/toIR.c
===================================================================
--- trunk/priv/guest-x86/toIR.c 2007-11-23 02:46:29 UTC (rev 1800)
+++ trunk/priv/guest-x86/toIR.c 2007-11-25 01:34:03 UTC (rev 1801)
@@ -12308,6 +12308,12 @@
guest_EIP_bbstart+delta, "rep stos" );
break;
+ case 0xAC: sz = 1; /* REP LODS<sz> */
+ case 0xAD:
+ dis_REP_op ( X86CondAlways, dis_LODS, sz, eip_orig,
+ guest_EIP_bbstart+delta, "rep lods" );
+ break;
+
case 0xAE: sz = 1; /* REPE SCAS<sz> */
case 0xAF:
dis_REP_op ( X86CondZ, dis_SCAS, sz, eip_orig,
|
|
From: <js...@ac...> - 2007-11-25 01:21:39
|
Nightly build on g5 ( SuSE 10.1, ppc970 ) started at 2007-11-25 02:00:01 CET 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 == 285 tests, 25 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/deep_templates (stdout) memcheck/tests/leak-cycle (stderr) memcheck/tests/leak-tree (stderr) memcheck/tests/pointer-trace (stderr) none/tests/faultstatus (stderr) none/tests/fdleak_cmsg (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) 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/tc07_hbl1 (stderr) helgrind/tests/tc08_hbl2 (stderr) helgrind/tests/tc09_bad_unlock (stderr) helgrind/tests/tc11_XCHG (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) ================================================= == 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 == 285 tests, 25 stderr failures, 4 stdout failures, 0 post failures == memcheck/tests/deep_templates (stdout) memcheck/tests/leak-cycle (stderr) memcheck/tests/leak-tree (stderr) memcheck/tests/pointer-trace (stderr) none/tests/cmdline1 (stdout) none/tests/cmdline2 (stdout) none/tests/faultstatus (stderr) none/tests/fdleak_cmsg (stderr) none/tests/mremap (stderr) none/tests/mremap2 (stdout) 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/tc07_hbl1 (stderr) helgrind/tests/tc08_hbl2 (stderr) helgrind/tests/tc09_bad_unlock (stderr) helgrind/tests/tc11_XCHG (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) ================================================= == Difference between 24 hours ago and now == ================================================= *** old.short Sun Nov 25 02:11:04 2007 --- new.short Sun Nov 25 02:21:41 2007 *************** *** 8,10 **** ! == 285 tests, 25 stderr failures, 4 stdout failures, 0 post failures == memcheck/tests/deep_templates (stdout) --- 8,10 ---- ! == 285 tests, 25 stderr failures, 2 stdout failures, 0 post failures == memcheck/tests/deep_templates (stdout) *************** *** 13,16 **** memcheck/tests/pointer-trace (stderr) - none/tests/cmdline1 (stdout) - none/tests/cmdline2 (stdout) none/tests/faultstatus (stderr) --- 13,14 ---- |
|
From: <sv...@va...> - 2007-11-25 00:56:48
|
Author: sewardj
Date: 2007-11-25 00:56:51 +0000 (Sun, 25 Nov 2007)
New Revision: 7209
Log:
Very minor changes.
Modified:
trunk/docs/README
trunk/docs/xml/index.xml
trunk/docs/xml/quick-start-guide.xml
Modified: trunk/docs/README
===================================================================
--- trunk/docs/README 2007-11-25 00:55:11 UTC (rev 7208)
+++ trunk/docs/README 2007-11-25 00:56:51 UTC (rev 7209)
@@ -148,7 +148,9 @@
pool_size.pdfxmltex = 1500000
and that fixes it.
+It is also reported that the print docs build OK on Fedora Core 5.
+
Notes [Nov. 2005]
-----------------
After upgrading to Suse 10, found a (known) bug in PassiveTex which
Modified: trunk/docs/xml/index.xml
===================================================================
--- trunk/docs/xml/index.xml 2007-11-25 00:55:11 UTC (rev 7208)
+++ trunk/docs/xml/index.xml 2007-11-25 00:56:51 UTC (rev 7209)
@@ -17,12 +17,21 @@
</copyright>
<legalnotice>
- <para>Permission is granted to copy, distribute and/or
- modify this document under the terms of the GNU Free Documentation License,
- Version 1.2 or any later version published by the Free Software Foundation;
- with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
- Texts. A copy of the license is included in the section entitled
- <xref linkend="license.gfdl"/>.</para>
+ <para>Permission is granted to copy, distribute and/or modify
+ this document under the terms of the GNU Free Documentation
+ License, Version 1.2 or any later version published by the
+ Free Software Foundation; with no Invariant Sections, with no
+ Front-Cover Texts, and with no Back-Cover Texts. A copy of
+ the license is included in the section entitled
+ <xref linkend="license.gfdl"/>.
+ </para>
+ <para>This is the top level of Valgrind's documentation tree.
+ The documentation is contained in six logically separate
+ documents, as listed in the following Table of Contents. To
+ get started quickly, read the Valgrind Quick Start Guide. For
+ full documentation on Valgrind, read the Valgrind User Manual.
+ </para>
+
</legalnotice>
</setinfo>
Modified: trunk/docs/xml/quick-start-guide.xml
===================================================================
--- trunk/docs/xml/quick-start-guide.xml 2007-11-25 00:55:11 UTC (rev 7208)
+++ trunk/docs/xml/quick-start-guide.xml 2007-11-25 00:56:51 UTC (rev 7209)
@@ -54,16 +54,16 @@
<listitem>
<para>Cachegrind: a profiling tool which produces detailed data on
cache (miss) and branch (misprediction) events. Statistics are
- gathered for the entire program, for each function, for each line
- of code, and even for each instruction, if you need that level of
- detail.</para>
+ gathered for the entire program, for each function, and for each
+ line of code, if you need that level of detail.</para>
</listitem>
<listitem>
- <para>Callgrind: a heavyweight profiling tool similar to
- Cachegrind, but which also shows cost relationships across
- function calls. Information gathered by Callgrind can be viewed
- using the KCachegrind GUI. KCachegrind is not part of the
- Valgrind suite - it is part of the KDE Desktop Environment.</para>
+ <para>Callgrind: a profiling tool that shows cost relationships
+ across function calls, optionally with cache simulation similar to
+ Cachegrind. Information gathered by Callgrind can be viewed
+ either with an included command line tool, or by using the
+ KCachegrind GUI. KCachegrind is not part of the Valgrind suite
+ -- it is part of the KDE Desktop Environment.</para>
</listitem>
<listitem>
<para>Massif: a space profiling tool. It allows you to explore
@@ -84,8 +84,8 @@
</itemizedlist>
<para>The rest of this guide discusses only the Memcheck tool. For
-full documentation on the other tools, see the Valgrind User
-Manual.</para>
+full documentation on the other tools, and for Memcheck, see the
+Valgrind User Manual.</para>
<para>What follows is the minimum information you need to start
detecting memory errors in your program with Memcheck. Note that this
|
|
From: <sv...@va...> - 2007-11-25 00:55:09
|
Author: sewardj Date: 2007-11-25 00:55:11 +0000 (Sun, 25 Nov 2007) New Revision: 7208 Log: Create a new chapter in the Valgrind Manual: a chapter containing info on some advanced aspects of the core (client requests, function wrapping) and move stuff from the main core manual into it. Added: trunk/docs/xml/manual-core-adv.xml Modified: trunk/docs/xml/manual-core.xml trunk/docs/xml/manual.xml Added: trunk/docs/xml/manual-core-adv.xml =================================================================== --- trunk/docs/xml/manual-core-adv.xml (rev 0) +++ trunk/docs/xml/manual-core-adv.xml 2007-11-25 00:55:11 UTC (rev 7208) @@ -0,0 +1,667 @@ +<?xml version="1.0"?> <!-- -*- sgml -*- --> +<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" + "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" +[ <!ENTITY % vg-entities SYSTEM "vg-entities.xml"> %vg-entities; ]> + + +<chapter id="manual-core-adv" xreflabel="Valgrind's core: advanced topics"> +<title>Using and understanding the Valgrind core: Advanced Topics</title> + +<para>This chapter describes advanced aspects of the Valgrind core +services, which are mostly of interest to power users who wish to +customise and modify Valgrind's default behaviours in certain useful +ways. The subjects covered are:</para> + +<itemizedlist> + <listitem><para>The "Client Request" mechanism</para></listitem> + <listitem><para>Function Wrapping</para></listitem> +</itemizedlist> + + + +<sect1 id="manual-core-adv.clientreq" + xreflabel="The Client Request mechanism"> +<title>The Client Request mechanism</title> + +<para>Valgrind has a trapdoor mechanism via which the client +program can pass all manner of requests and queries to Valgrind +and the current tool. Internally, this is used extensively to +make malloc, free, etc, work, although you don't see that.</para> + +<para>For your convenience, a subset of these so-called client +requests is provided to allow you to tell Valgrind facts about +the behaviour of your program, and also to make queries. +In particular, your program can tell Valgrind about changes in +memory range permissions that Valgrind would not otherwise know +about, and so allows clients to get Valgrind to do arbitrary +custom checks.</para> + +<para>Clients need to include a header file to make this work. +Which header file depends on which client requests you use. Some +client requests are handled by the core, and are defined in the +header file <filename>valgrind/valgrind.h</filename>. Tool-specific +header files are named after the tool, e.g. +<filename>valgrind/memcheck.h</filename>. All header files can be found +in the <literal>include/valgrind</literal> directory of wherever Valgrind +was installed.</para> + +<para>The macros in these header files have the magical property +that they generate code in-line which Valgrind can spot. +However, the code does nothing when not run on Valgrind, so you +are not forced to run your program under Valgrind just because you +use the macros in this file. Also, you are not required to link your +program with any extra supporting libraries.</para> + +<para>The code added to your binary has negligible performance impact: +on x86, amd64, ppc32 and ppc64, the overhead is 6 simple integer instructions +and is probably undetectable except in tight loops. +However, if you really wish to compile out the client requests, you can +compile with <computeroutput>-DNVALGRIND</computeroutput> (analogous to +<computeroutput>-DNDEBUG</computeroutput>'s effect on +<computeroutput>assert()</computeroutput>). +</para> + +<para>You are encouraged to copy the <filename>valgrind/*.h</filename> headers +into your project's include directory, so your program doesn't have a +compile-time dependency on Valgrind being installed. The Valgrind headers, +unlike most of the rest of the code, are under a BSD-style license so you may +include them without worrying about license incompatibility.</para> + +<para>Here is a brief description of the macros available in +<filename>valgrind.h</filename>, which work with more than one +tool (see the tool-specific documentation for explanations of the +tool-specific macros).</para> + + <variablelist> + + <varlistentry> + <term><command><computeroutput>RUNNING_ON_VALGRIND</computeroutput></command>:</term> + <listitem> + <para>Returns 1 if running on Valgrind, 0 if running on the + real CPU. If you are running Valgrind on itself, returns the + number of layers of Valgrind emulation you're running on. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_DISCARD_TRANSLATIONS</computeroutput>:</command></term> + <listitem> + <para>Discards translations of code in the specified address + range. Useful if you are debugging a JIT compiler or some other + dynamic code generation system. After this call, attempts to + execute code in the invalidated address range will cause + Valgrind to make new translations of that code, which is + probably the semantics you want. Note that code invalidations + are expensive because finding all the relevant translations + quickly is very difficult. So try not to call it often. + Note that you can be clever about + this: you only need to call it when an area which previously + contained code is overwritten with new code. You can choose + to write code into fresh memory, and just call this + occasionally to discard large chunks of old code all at + once.</para> + <para> + Alternatively, for transparent self-modifying-code support, + use<computeroutput>--smc-check=all</computeroutput>, or run + on ppc32/Linux or ppc64/Linux. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_COUNT_ERRORS</computeroutput>:</command></term> + <listitem> + <para>Returns the number of errors found so far by Valgrind. Can be + useful in test harness code when combined with the + <option>--log-fd=-1</option> option; this runs Valgrind silently, + but the client program can detect when errors occur. Only useful + for tools that report errors, e.g. it's useful for Memcheck, but for + Cachegrind it will always return zero because Cachegrind doesn't + report errors.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_MALLOCLIKE_BLOCK</computeroutput>:</command></term> + <listitem> + <para>If your program manages its own memory instead of using + the standard <computeroutput>malloc()</computeroutput> / + <computeroutput>new</computeroutput> / + <computeroutput>new[]</computeroutput>, tools that track + information about heap blocks will not do nearly as good a + job. For example, Memcheck won't detect nearly as many + errors, and the error messages won't be as informative. To + improve this situation, use this macro just after your custom + allocator allocates some new memory. See the comments in + <filename>valgrind.h</filename> for information on how to use + it.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_FREELIKE_BLOCK</computeroutput>:</command></term> + <listitem> + <para>This should be used in conjunction with + <computeroutput>VALGRIND_MALLOCLIKE_BLOCK</computeroutput>. + Again, see <filename>memcheck/memcheck.h</filename> for + information on how to use it.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>:</command></term> + <listitem> + <para>This is similar to + <computeroutput>VALGRIND_MALLOCLIKE_BLOCK</computeroutput>, + but is tailored towards code that uses memory pools. See the + comments in <filename>valgrind.h</filename> for information + on how to use it.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_DESTROY_MEMPOOL</computeroutput>:</command></term> + <listitem> + <para>This should be used in conjunction with + <computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>. + Again, see the comments in <filename>valgrind.h</filename> for + information on how to use it.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_MEMPOOL_ALLOC</computeroutput>:</command></term> + <listitem> + <para>This should be used in conjunction with + <computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>. + Again, see the comments in <filename>valgrind.h</filename> for + information on how to use it.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_MEMPOOL_FREE</computeroutput>:</command></term> + <listitem> + <para>This should be used in conjunction with + <computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>. + Again, see the comments in <filename>valgrind.h</filename> for + information on how to use it.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_NON_SIMD_CALL[0123]</computeroutput>:</command></term> + <listitem> + <para>Executes a function of 0, 1, 2 or 3 args in the client + program on the <emphasis>real</emphasis> CPU, not the virtual + CPU that Valgrind normally runs code on. These are used in + various ways internally to Valgrind. They might be useful to + client programs.</para> + + <para><command>Warning:</command> Only use these if you + <emphasis>really</emphasis> know what you are doing.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_PRINTF(format, ...)</computeroutput>:</command></term> + <listitem> + <para>printf a message to the log file when running under + Valgrind. Nothing is output if not running under Valgrind. + Returns the number of characters output.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_PRINTF_BACKTRACE(format, ...)</computeroutput>:</command></term> + <listitem> + <para>printf a message to the log file along with a stack + backtrace when running under Valgrind. Nothing is output if + not running under Valgrind. Returns the number of characters + output.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_STACK_REGISTER(start, end)</computeroutput>:</command></term> + <listitem> + <para>Registers a new stack. Informs Valgrind that the memory range + between start and end is a unique stack. Returns a stack identifier + that can be used with other + <computeroutput>VALGRIND_STACK_*</computeroutput> calls.</para> + <para>Valgrind will use this information to determine if a change to + the stack pointer is an item pushed onto the stack or a change over + to a new stack. Use this if you're using a user-level thread package + and are noticing spurious errors from Valgrind about uninitialized + memory reads.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_STACK_DEREGISTER(id)</computeroutput>:</command></term> + <listitem> + <para>Deregisters a previously registered stack. Informs + Valgrind that previously registered memory range with stack id + <computeroutput>id</computeroutput> is no longer a stack.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><command><computeroutput>VALGRIND_STACK_CHANGE(id, start, end)</computeroutput>:</command></term> + <listitem> + <para>Changes a previously registered stack. Informs + Valgrind that the previously registered stack with stack id + <computeroutput>id</computeroutput> has changed its start and end + values. Use this if your user-level thread package implements + stack growth.</para> + </listitem> + </varlistentry> + + </variablelist> + +<para>Note that <filename>valgrind.h</filename> is included by +all the tool-specific header files (such as +<filename>memcheck.h</filename>), so you don't need to include it +in your client if you include a tool-specific header.</para> + +</sect1> + + + + + +<sect1 id="manual-core-adv.wrapping" xreflabel="Function Wrapping"> +<title>Function wrapping</title> + +<para> +Valgrind versions 3.2.0 and above can do function wrapping on all +supported targets. In function wrapping, calls to some specified +function are intercepted and rerouted to a different, user-supplied +function. This can do whatever it likes, typically examining the +arguments, calling onwards to the original, and possibly examining the +result. Any number of functions may be wrapped.</para> + +<para> +Function wrapping is useful for instrumenting an API in some way. For +example, wrapping functions in the POSIX pthreads API makes it +possible to notify Valgrind of thread status changes, and wrapping +functions in the MPI (message-passing) API allows notifying Valgrind +of memory status changes associated with message arrival/departure. +Such information is usually passed to Valgrind by using client +requests in the wrapper functions, although that is not of relevance +here.</para> + +<sect2 id="manual-core-adv.wrapping.example" xreflabel="A Simple Example"> +<title>A Simple Example</title> + +<para>Supposing we want to wrap some function</para> + +<programlisting><![CDATA[ +int foo ( int x, int y ) { return x + y; }]]></programlisting> + +<para>A wrapper is a function of identical type, but with a special name +which identifies it as the wrapper for <computeroutput>foo</computeroutput>. +Wrappers need to include +supporting macros from <computeroutput>valgrind.h</computeroutput>. +Here is a simple wrapper which prints the arguments and return value:</para> + +<programlisting><![CDATA[ +#include <stdio.h> +#include "valgrind.h" +int I_WRAP_SONAME_FNNAME_ZU(NONE,foo)( int x, int y ) +{ + int result; + OrigFn fn; + VALGRIND_GET_ORIG_FN(fn); + printf("foo's wrapper: args %d %d\n", x, y); + CALL_FN_W_WW(result, fn, x,y); + printf("foo's wrapper: result %d\n", result); + return result; +} +]]></programlisting> + +<para>To become active, the wrapper merely needs to be present in a text +section somewhere in the same process' address space as the function +it wraps, and for its ELF symbol name to be visible to Valgrind. In +practice, this means either compiling to a +<computeroutput>.o</computeroutput> and linking it in, or +compiling to a <computeroutput>.so</computeroutput> and +<computeroutput>LD_PRELOAD</computeroutput>ing it in. The latter is more +convenient in that it doesn't require relinking.</para> + +<para>All wrappers have approximately the above form. There are three +crucial macros:</para> + +<para><computeroutput>I_WRAP_SONAME_FNNAME_ZU</computeroutput>: +this generates the real name of the wrapper. +This is an encoded name which Valgrind notices when reading symbol +table information. What it says is: I am the wrapper for any function +named <computeroutput>foo</computeroutput> which is found in +an ELF shared object with an empty +("<computeroutput>NONE</computeroutput>") soname field. The specification +mechanism is powerful in +that wildcards are allowed for both sonames and function names. +The details are discussed below.</para> + +<para><computeroutput>VALGRIND_GET_ORIG_FN</computeroutput>: +once in the the wrapper, the first priority is +to get hold of the address of the original (and any other supporting +information needed). This is stored in a value of opaque +type <computeroutput>OrigFn</computeroutput>. +The information is acquired using +<computeroutput>VALGRIND_GET_ORIG_FN</computeroutput>. It is crucial +to make this macro call before calling any other wrapped function +in the same thread.</para> + +<para><computeroutput>CALL_FN_W_WW</computeroutput>: eventually we will +want to call the function being +wrapped. Calling it directly does not work, since that just gets us +back to the wrapper and tends to kill the program in short order by +stack overflow. Instead, the result lvalue, +<computeroutput>OrigFn</computeroutput> and arguments are +handed to one of a family of macros of the form +<computeroutput>CALL_FN_*</computeroutput>. These +cause Valgrind to call the original and avoid recursion back to the +wrapper.</para> +</sect2> + +<sect2 id="manual-core-adv.wrapping.specs" xreflabel="Wrapping Specifications"> +<title>Wrapping Specifications</title> + +<para>This scheme has the advantage of being self-contained. A library of +wrappers can be compiled to object code in the normal way, and does +not rely on an external script telling Valgrind which wrappers pertain +to which originals.</para> + +<para>Each wrapper has a name which, in the most general case says: I am the +wrapper for any function whose name matches FNPATT and whose ELF +"soname" matches SOPATT. Both FNPATT and SOPATT may contain wildcards +(asterisks) and other characters (spaces, dots, @, etc) which are not +generally regarded as valid C identifier names.</para> + +<para>This flexibility is needed to write robust wrappers for POSIX pthread +functions, where typically we are not completely sure of either the +function name or the soname, or alternatively we want to wrap a whole +set of functions at once.</para> + +<para>For example, <computeroutput>pthread_create</computeroutput> +in GNU libpthread is usually a +versioned symbol - one whose name ends in, eg, +<computeroutput>@GLIBC_2.3</computeroutput>. Hence we +are not sure what its real name is. We also want to cover any soname +of the form <computeroutput>libpthread.so*</computeroutput>. +So the header of the wrapper will be</para> + +<programlisting><![CDATA[ +int I_WRAP_SONAME_FNNAME_ZZ(libpthreadZdsoZd0,pthreadZucreateZAZa) + ( ... formals ... ) + { ... body ... } +]]></programlisting> + +<para>In order to write unusual characters as valid C function names, a +Z-encoding scheme is used. Names are written literally, except that +a capital Z acts as an escape character, with the following encoding:</para> + +<programlisting><![CDATA[ + Za encodes * + Zp + + Zc : + Zd . + Zu _ + Zh - + Zs (space) + ZA @ + ZZ Z + ZL ( # only in valgrind 3.3.0 and later + ZR ) # only in valgrind 3.3.0 and later +]]></programlisting> + +<para>Hence <computeroutput>libpthreadZdsoZd0</computeroutput> is an +encoding of the soname <computeroutput>libpthread.so.0</computeroutput> +and <computeroutput>pthreadZucreateZAZa</computeroutput> is an encoding +of the function name <computeroutput>pthread_create@*</computeroutput>. +</para> + +<para>The macro <computeroutput>I_WRAP_SONAME_FNNAME_ZZ</computeroutput> +constructs a wrapper name in which +both the soname (first component) and function name (second component) +are Z-encoded. Encoding the function name can be tiresome and is +often unnecessary, so a second macro, +<computeroutput>I_WRAP_SONAME_FNNAME_ZU</computeroutput>, can be +used instead. The <computeroutput>_ZU</computeroutput> variant is +also useful for writing wrappers for +C++ functions, in which the function name is usually already mangled +using some other convention in which Z plays an important role. Having +to encode a second time quickly becomes confusing.</para> + +<para>Since the function name field may contain wildcards, it can be +anything, including just <computeroutput>*</computeroutput>. +The same is true for the soname. +However, some ELF objects - specifically, main executables - do not +have sonames. Any object lacking a soname is treated as if its soname +was <computeroutput>NONE</computeroutput>, which is why the original +example above had a name +<computeroutput>I_WRAP_SONAME_FNNAME_ZU(NONE,foo)</computeroutput>.</para> + +<para>Note that the soname of an ELF object is not the same as its +file name, although it is often similar. You can find the soname of +an object <computeroutput>libfoo.so</computeroutput> using the command +<computeroutput>readelf -a libfoo.so | grep soname</computeroutput>.</para> +</sect2> + +<sect2 id="manual-core-adv.wrapping.semantics" xreflabel="Wrapping Semantics"> +<title>Wrapping Semantics</title> + +<para>The ability for a wrapper to replace an infinite family of functions +is powerful but brings complications in situations where ELF objects +appear and disappear (are dlopen'd and dlclose'd) on the fly. +Valgrind tries to maintain sensible behaviour in such situations.</para> + +<para>For example, suppose a process has dlopened (an ELF object with +soname) <computeroutput>object1.so</computeroutput>, which contains +<computeroutput>function1</computeroutput>. It starts to use +<computeroutput>function1</computeroutput> immediately.</para> + +<para>After a while it dlopens <computeroutput>wrappers.so</computeroutput>, +which contains a wrapper +for <computeroutput>function1</computeroutput> in (soname) +<computeroutput>object1.so</computeroutput>. All subsequent calls to +<computeroutput>function1</computeroutput> are rerouted to the wrapper.</para> + +<para>If <computeroutput>wrappers.so</computeroutput> is +later dlclose'd, calls to <computeroutput>function1</computeroutput> are +naturally routed back to the original.</para> + +<para>Alternatively, if <computeroutput>object1.so</computeroutput> +is dlclose'd but wrappers.so remains, +then the wrapper exported by <computeroutput>wrapper.so</computeroutput> +becomes inactive, since there +is no way to get to it - there is no original to call any more. However, +Valgrind remembers that the wrapper is still present. If +<computeroutput>object1.so</computeroutput> is +eventually dlopen'd again, the wrapper will become active again.</para> + +<para>In short, valgrind inspects all code loading/unloading events to +ensure that the set of currently active wrappers remains consistent.</para> + +<para>A second possible problem is that of conflicting wrappers. It is +easily possible to load two or more wrappers, both of which claim +to be wrappers for some third function. In such cases Valgrind will +complain about conflicting wrappers when the second one appears, and +will honour only the first one.</para> +</sect2> + +<sect2 id="manual-core-adv.wrapping.debugging" xreflabel="Debugging"> +<title>Debugging</title> + +<para>Figuring out what's going on given the dynamic nature of wrapping +can be difficult. The +<computeroutput>--trace-redir=yes</computeroutput> flag makes +this possible +by showing the complete state of the redirection subsystem after +every +<computeroutput>mmap</computeroutput>/<computeroutput>munmap</computeroutput> +event affecting code (text).</para> + +<para>There are two central concepts:</para> + +<itemizedlist> + + <listitem><para>A "redirection specification" is a binding of + a (soname pattern, fnname pattern) pair to a code address. + These bindings are created by writing functions with names + made with the + <computeroutput>I_WRAP_SONAME_FNNAME_{ZZ,_ZU}</computeroutput> + macros.</para></listitem> + + <listitem><para>An "active redirection" is code-address to + code-address binding currently in effect.</para></listitem> + +</itemizedlist> + +<para>The state of the wrapping-and-redirection subsystem comprises a set of +specifications and a set of active bindings. The specifications are +acquired/discarded by watching all +<computeroutput>mmap</computeroutput>/<computeroutput>munmap</computeroutput> +events on code (text) +sections. The active binding set is (conceptually) recomputed from +the specifications, and all known symbol names, following any change +to the specification set.</para> + +<para><computeroutput>--trace-redir=yes</computeroutput> shows the contents +of both sets following any such event.</para> + +<para><computeroutput>-v</computeroutput> prints a line of text each +time an active specification is used for the first time.</para> + +<para>Hence for maximum debugging effectiveness you will need to use both +flags.</para> + +<para>One final comment. The function-wrapping facility is closely +tied to Valgrind's ability to replace (redirect) specified +functions, for example to redirect calls to +<computeroutput>malloc</computeroutput> to its +own implementation. Indeed, a replacement function can be +regarded as a wrapper function which does not call the original. +However, to make the implementation more robust, the two kinds +of interception (wrapping vs replacement) are treated differently. +</para> + +<para><computeroutput>--trace-redir=yes</computeroutput> shows +specifications and bindings for both +replacement and wrapper functions. To differentiate the +two, replacement bindings are printed using +<computeroutput>R-></computeroutput> whereas +wraps are printed using <computeroutput>W-></computeroutput>. +</para> +</sect2> + + +<sect2 id="manual-core-adv.wrapping.limitations-cf" + xreflabel="Limitations - control flow"> +<title>Limitations - control flow</title> + +<para>For the most part, the function wrapping implementation is robust. +The only important caveat is: in a wrapper, get hold of +the <computeroutput>OrigFn</computeroutput> information using +<computeroutput>VALGRIND_GET_ORIG_FN</computeroutput> before calling any +other wrapped function. Once you have the +<computeroutput>OrigFn</computeroutput>, arbitrary +calls between, recursion between, and longjumps out of wrappers +should work correctly. There is never any interaction between wrapped +functions and merely replaced functions +(eg <computeroutput>malloc</computeroutput>), so you can call +<computeroutput>malloc</computeroutput> etc safely from within wrappers. +</para> + +<para>The above comments are true for {x86,amd64,ppc32}-linux. On +ppc64-linux function wrapping is more fragile due to the (arguably +poorly designed) ppc64-linux ABI. This mandates the use of a shadow +stack which tracks entries/exits of both wrapper and replacement +functions. This gives two limitations: firstly, longjumping out of +wrappers will rapidly lead to disaster, since the shadow stack will +not get correctly cleared. Secondly, since the shadow stack has +finite size, recursion between wrapper/replacement functions is only +possible to a limited depth, beyond which Valgrind has to abort the +run. This depth is currently 16 calls.</para> + +<para>For all platforms ({x86,amd64,ppc32,ppc64}-linux) all the above +comments apply on a per-thread basis. In other words, wrapping is +thread-safe: each thread must individually observe the above +restrictions, but there is no need for any kind of inter-thread +cooperation.</para> +</sect2> + + +<sect2 id="manual-core-adv.wrapping.limitations-sigs" + xreflabel="Limitations - original function signatures"> +<title>Limitations - original function signatures</title> + +<para>As shown in the above example, to call the original you must use a +macro of the form <computeroutput>CALL_FN_*</computeroutput>. +For technical reasons it is impossible +to create a single macro to deal with all argument types and numbers, +so a family of macros covering the most common cases is supplied. In +what follows, 'W' denotes a machine-word-typed value (a pointer or a +C <computeroutput>long</computeroutput>), +and 'v' denotes C's <computeroutput>void</computeroutput> type. +The currently available macros are:</para> + +<programlisting><![CDATA[ +CALL_FN_v_v -- call an original of type void fn ( void ) +CALL_FN_W_v -- call an original of type long fn ( void ) + +CALL_FN_v_W -- void fn ( long ) +CALL_FN_W_W -- long fn ( long ) + +CALL_FN_v_WW -- void fn ( long, long ) +CALL_FN_W_WW -- long fn ( long, long ) + +CALL_FN_v_WWW -- void fn ( long, long, long ) +CALL_FN_W_WWW -- long fn ( long, long, long ) + +CALL_FN_W_WWWW -- long fn ( long, long, long, long ) +CALL_FN_W_5W -- long fn ( long, long, long, long, long ) +CALL_FN_W_6W -- long fn ( long, long, long, long, long, long ) +and so on, up to +CALL_FN_W_12W +]]></programlisting> + +<para>The set of supported types can be expanded as needed. It is +regrettable that this limitation exists. Function wrapping has proven +difficult to implement, with a certain apparently unavoidable level of +ickyness. After several implementation attempts, the present +arrangement appears to be the least-worst tradeoff. At least it works +reliably in the presence of dynamic linking and dynamic code +loading/unloading.</para> + +<para>You should not attempt to wrap a function of one type signature with a +wrapper of a different type signature. Such trickery will surely lead +to crashes or strange behaviour. This is not of course a limitation +of the function wrapping implementation, merely a reflection of the +fact that it gives you sweeping powers to shoot yourself in the foot +if you are not careful. Imagine the instant havoc you could wreak by +writing a wrapper which matched any function name in any soname - in +effect, one which claimed to be a wrapper for all functions in the +process.</para> +</sect2> + +<sect2 id="manual-core-adv.wrapping.examples" xreflabel="Examples"> +<title>Examples</title> + +<para>In the source tree, +<computeroutput>memcheck/tests/wrap[1-8].c</computeroutput> provide a series of +examples, ranging from very simple to quite advanced.</para> + +<para><computeroutput>auxprogs/libmpiwrap.c</computeroutput> is an example +of wrapping a big, complex API (the MPI-2 interface). This file defines +almost 300 different wrappers.</para> +</sect2> + +</sect1> + + + + +</chapter> Modified: trunk/docs/xml/manual-core.xml =================================================================== --- trunk/docs/xml/manual-core.xml 2007-11-24 23:37:07 UTC (rev 7207) +++ trunk/docs/xml/manual-core.xml 2007-11-25 00:55:11 UTC (rev 7208) @@ -7,12 +7,19 @@ <chapter id="manual-core" xreflabel="Valgrind's core"> <title>Using and understanding the Valgrind core</title> -<para>This section describes the Valgrind core services, flags and +<para>This chapter describes the Valgrind core services, flags and behaviours. That means it is relevant regardless of what particular -tool you are using. A point of terminology: most references to -"Valgrind" in the rest of this section refer to the Valgrind -core services.</para> +tool you are using. The information should be sufficient for you to +make effective day-to-day use of Valgrind. Advanced topics related to +the Valgrind core are described in <xref linkend="manual-core-adv"/>. +</para> +<para> +A point of terminology: most references to "Valgrind" in this chapter +refer to the Valgrind core services. </para> + + + <sect1 id="manual-core.whatdoes" xreflabel="What Valgrind does with your program"> <title>What Valgrind does with your program</title> @@ -1781,649 +1788,7 @@ -<sect1 id="manual-core.clientreq" - xreflabel="The Client Request mechanism"> -<title>The Client Request mechanism</title> -<para>Valgrind has a trapdoor mechanism via which the client -program can pass all manner of requests and queries to Valgrind -and the current tool. Internally, this is used extensively to -make malloc, free, etc, work, although you don't see that.</para> -<para>For your convenience, a subset of these so-called client -requests is provided to allow you to tell Valgrind facts about -the behaviour of your program, and also to make queries. -In particular, your program can tell Valgrind about changes in -memory range permissions that Valgrind would not otherwise know -about, and so allows clients to get Valgrind to do arbitrary -custom checks.</para> -<para>Clients need to include a header file to make this work. -Which header file depends on which client requests you use. Some -client requests are handled by the core, and are defined in the -header file <filename>valgrind/valgrind.h</filename>. Tool-specific -header files are named after the tool, e.g. -<filename>valgrind/memcheck.h</filename>. All header files can be found -in the <literal>include/valgrind</literal> directory of wherever Valgrind -was installed.</para> - -<para>The macros in these header files have the magical property -that they generate code in-line which Valgrind can spot. -However, the code does nothing when not run on Valgrind, so you -are not forced to run your program under Valgrind just because you -use the macros in this file. Also, you are not required to link your -program with any extra supporting libraries.</para> - -<para>The code added to your binary has negligible performance impact: -on x86, amd64, ppc32 and ppc64, the overhead is 6 simple integer instructions -and is probably undetectable except in tight loops. -However, if you really wish to compile out the client requests, you can -compile with <computeroutput>-DNVALGRIND</computeroutput> (analogous to -<computeroutput>-DNDEBUG</computeroutput>'s effect on -<computeroutput>assert()</computeroutput>). -</para> - -<para>You are encouraged to copy the <filename>valgrind/*.h</filename> headers -into your project's include directory, so your program doesn't have a -compile-time dependency on Valgrind being installed. The Valgrind headers, -unlike most of the rest of the code, are under a BSD-style license so you may -include them without worrying about license incompatibility.</para> - -<para>Here is a brief description of the macros available in -<filename>valgrind.h</filename>, which work with more than one -tool (see the tool-specific documentation for explanations of the -tool-specific macros).</para> - - <variablelist> - - <varlistentry> - <term><command><computeroutput>RUNNING_ON_VALGRIND</computeroutput></command>:</term> - <listitem> - <para>Returns 1 if running on Valgrind, 0 if running on the - real CPU. If you are running Valgrind on itself, returns the - number of layers of Valgrind emulation you're running on. - </para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_DISCARD_TRANSLATIONS</computeroutput>:</command></term> - <listitem> - <para>Discards translations of code in the specified address - range. Useful if you are debugging a JIT compiler or some other - dynamic code generation system. After this call, attempts to - execute code in the invalidated address range will cause - Valgrind to make new translations of that code, which is - probably the semantics you want. Note that code invalidations - are expensive because finding all the relevant translations - quickly is very difficult. So try not to call it often. - Note that you can be clever about - this: you only need to call it when an area which previously - contained code is overwritten with new code. You can choose - to write code into fresh memory, and just call this - occasionally to discard large chunks of old code all at - once.</para> - <para> - Alternatively, for transparent self-modifying-code support, - use<computeroutput>--smc-check=all</computeroutput>, or run - on ppc32/Linux or ppc64/Linux. - </para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_COUNT_ERRORS</computeroutput>:</command></term> - <listitem> - <para>Returns the number of errors found so far by Valgrind. Can be - useful in test harness code when combined with the - <option>--log-fd=-1</option> option; this runs Valgrind silently, - but the client program can detect when errors occur. Only useful - for tools that report errors, e.g. it's useful for Memcheck, but for - Cachegrind it will always return zero because Cachegrind doesn't - report errors.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_MALLOCLIKE_BLOCK</computeroutput>:</command></term> - <listitem> - <para>If your program manages its own memory instead of using - the standard <computeroutput>malloc()</computeroutput> / - <computeroutput>new</computeroutput> / - <computeroutput>new[]</computeroutput>, tools that track - information about heap blocks will not do nearly as good a - job. For example, Memcheck won't detect nearly as many - errors, and the error messages won't be as informative. To - improve this situation, use this macro just after your custom - allocator allocates some new memory. See the comments in - <filename>valgrind.h</filename> for information on how to use - it.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_FREELIKE_BLOCK</computeroutput>:</command></term> - <listitem> - <para>This should be used in conjunction with - <computeroutput>VALGRIND_MALLOCLIKE_BLOCK</computeroutput>. - Again, see <filename>memcheck/memcheck.h</filename> for - information on how to use it.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>:</command></term> - <listitem> - <para>This is similar to - <computeroutput>VALGRIND_MALLOCLIKE_BLOCK</computeroutput>, - but is tailored towards code that uses memory pools. See the - comments in <filename>valgrind.h</filename> for information - on how to use it.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_DESTROY_MEMPOOL</computeroutput>:</command></term> - <listitem> - <para>This should be used in conjunction with - <computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>. - Again, see the comments in <filename>valgrind.h</filename> for - information on how to use it.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_MEMPOOL_ALLOC</computeroutput>:</command></term> - <listitem> - <para>This should be used in conjunction with - <computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>. - Again, see the comments in <filename>valgrind.h</filename> for - information on how to use it.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_MEMPOOL_FREE</computeroutput>:</command></term> - <listitem> - <para>This should be used in conjunction with - <computeroutput>VALGRIND_CREATE_MEMPOOL</computeroutput>. - Again, see the comments in <filename>valgrind.h</filename> for - information on how to use it.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_NON_SIMD_CALL[0123]</computeroutput>:</command></term> - <listitem> - <para>Executes a function of 0, 1, 2 or 3 args in the client - program on the <emphasis>real</emphasis> CPU, not the virtual - CPU that Valgrind normally runs code on. These are used in - various ways internally to Valgrind. They might be useful to - client programs.</para> - - <para><command>Warning:</command> Only use these if you - <emphasis>really</emphasis> know what you are doing.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_PRINTF(format, ...)</computeroutput>:</command></term> - <listitem> - <para>printf a message to the log file when running under - Valgrind. Nothing is output if not running under Valgrind. - Returns the number of characters output.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_PRINTF_BACKTRACE(format, ...)</computeroutput>:</command></term> - <listitem> - <para>printf a message to the log file along with a stack - backtrace when running under Valgrind. Nothing is output if - not running under Valgrind. Returns the number of characters - output.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_STACK_REGISTER(start, end)</computeroutput>:</command></term> - <listitem> - <para>Registers a new stack. Informs Valgrind that the memory range - between start and end is a unique stack. Returns a stack identifier - that can be used with other - <computeroutput>VALGRIND_STACK_*</computeroutput> calls.</para> - <para>Valgrind will use this information to determine if a change to - the stack pointer is an item pushed onto the stack or a change over - to a new stack. Use this if you're using a user-level thread package - and are noticing spurious errors from Valgrind about uninitialized - memory reads.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_STACK_DEREGISTER(id)</computeroutput>:</command></term> - <listitem> - <para>Deregisters a previously registered stack. Informs - Valgrind that previously registered memory range with stack id - <computeroutput>id</computeroutput> is no longer a stack.</para> - </listitem> - </varlistentry> - - <varlistentry> - <term><command><computeroutput>VALGRIND_STACK_CHANGE(id, start, end)</computeroutput>:</command></term> - <listitem> - <para>Changes a previously registered stack. Informs - Valgrind that the previously registered stack with stack id - <computeroutput>id</computeroutput> has changed its start and end - values. Use this if your user-level thread package implements - stack growth.</para> - </listitem> - </varlistentry> - - </variablelist> - -<para>Note that <filename>valgrind.h</filename> is included by -all the tool-specific header files (such as -<filename>memcheck.h</filename>), so you don't need to include it -in your client if you include a tool-specific header.</para> - -</sect1> - - - - - -<sect1 id="manual-core.wrapping" xreflabel="Function Wrapping"> -<title>Function wrapping</title> - -<para> -Valgrind versions 3.2.0 and above can do function wrapping on all -supported targets. In function wrapping, calls to some specified -function are intercepted and rerouted to a different, user-supplied -function. This can do whatever it likes, typically examining the -arguments, calling onwards to the original, and possibly examining the -result. Any number of functions may be wrapped.</para> - -<para> -Function wrapping is useful for instrumenting an API in some way. For -example, wrapping functions in the POSIX pthreads API makes it -possible to notify Valgrind of thread status changes, and wrapping -functions in the MPI (message-passing) API allows notifying Valgrind -of memory status changes associated with message arrival/departure. -Such information is usually passed to Valgrind by using client -requests in the wrapper functions, although that is not of relevance -here.</para> - -<sect2 id="manual-core.wrapping.example" xreflabel="A Simple Example"> -<title>A Simple Example</title> - -<para>Supposing we want to wrap some function</para> - -<programlisting><![CDATA[ -int foo ( int x, int y ) { return x + y; }]]></programlisting> - -<para>A wrapper is a function of identical type, but with a special name -which identifies it as the wrapper for <computeroutput>foo</computeroutput>. -Wrappers need to include -supporting macros from <computeroutput>valgrind.h</computeroutput>. -Here is a simple wrapper which prints the arguments and return value:</para> - -<programlisting><![CDATA[ -#include <stdio.h> -#include "valgrind.h" -int I_WRAP_SONAME_FNNAME_ZU(NONE,foo)( int x, int y ) -{ - int result; - OrigFn fn; - VALGRIND_GET_ORIG_FN(fn); - printf("foo's wrapper: args %d %d\n", x, y); - CALL_FN_W_WW(result, fn, x,y); - printf("foo's wrapper: result %d\n", result); - return result; -} -]]></programlisting> - -<para>To become active, the wrapper merely needs to be present in a text -section somewhere in the same process' address space as the function -it wraps, and for its ELF symbol name to be visible to Valgrind. In -practice, this means either compiling to a -<computeroutput>.o</computeroutput> and linking it in, or -compiling to a <computeroutput>.so</computeroutput> and -<computeroutput>LD_PRELOAD</computeroutput>ing it in. The latter is more -convenient in that it doesn't require relinking.</para> - -<para>All wrappers have approximately the above form. There are three -crucial macros:</para> - -<para><computeroutput>I_WRAP_SONAME_FNNAME_ZU</computeroutput>: -this generates the real name of the wrapper. -This is an encoded name which Valgrind notices when reading symbol -table information. What it says is: I am the wrapper for any function -named <computeroutput>foo</computeroutput> which is found in -an ELF shared object with an empty -("<computeroutput>NONE</computeroutput>") soname field. The specification -mechanism is powerful in -that wildcards are allowed for both sonames and function names. -The details are discussed below.</para> - -<para><computeroutput>VALGRIND_GET_ORIG_FN</computeroutput>: -once in the the wrapper, the first priority is -to get hold of the address of the original (and any other supporting -information needed). This is stored in a value of opaque -type <computeroutput>OrigFn</computeroutput>. -The information is acquired using -<computeroutput>VALGRIND_GET_ORIG_FN</computeroutput>. It is crucial -to make this macro call before calling any other wrapped function -in the same thread.</para> - -<para><computeroutput>CALL_FN_W_WW</computeroutput>: eventually we will -want to call the function being -wrapped. Calling it directly does not work, since that just gets us -back to the wrapper and tends to kill the program in short order by -stack overflow. Instead, the result lvalue, -<computeroutput>OrigFn</computeroutput> and arguments are -handed to one of a family of macros of the form -<computeroutput>CALL_FN_*</computeroutput>. These -cause Valgrind to call the original and avoid recursion back to the -wrapper.</para> -</sect2> - -<sect2 id="manual-core.wrapping.specs" xreflabel="Wrapping Specifications"> -<title>Wrapping Specifications</title> - -<para>This scheme has the advantage of being self-contained. A library of -wrappers can be compiled to object code in the normal way, and does -not rely on an external script telling Valgrind which wrappers pertain -to which originals.</para> - -<para>Each wrapper has a name which, in the most general case says: I am the -wrapper for any function whose name matches FNPATT and whose ELF -"soname" matches SOPATT. Both FNPATT and SOPATT may contain wildcards -(asterisks) and other characters (spaces, dots, @, etc) which are not -generally regarded as valid C identifier names.</para> - -<para>This flexibility is needed to write robust wrappers for POSIX pthread -functions, where typically we are not completely sure of either the -function name or the soname, or alternatively we want to wrap a whole -set of functions at once.</para> - -<para>For example, <computeroutput>pthread_create</computeroutput> -in GNU libpthread is usually a -versioned symbol - one whose name ends in, eg, -<computeroutput>@GLIBC_2.3</computeroutput>. Hence we -are not sure what its real name is. We also want to cover any soname -of the form <computeroutput>libpthread.so*</computeroutput>. -So the header of the wrapper will be</para> - -<programlisting><![CDATA[ -int I_WRAP_SONAME_FNNAME_ZZ(libpthreadZdsoZd0,pthreadZucreateZAZa) - ( ... formals ... ) - { ... body ... } -]]></programlisting> - -<para>In order to write unusual characters as valid C function names, a -Z-encoding scheme is used. Names are written literally, except that -a capital Z acts as an escape character, with the following encoding:</para> - -<programlisting><![CDATA[ - Za encodes * - Zp + - Zc : - Zd . - Zu _ - Zh - - Zs (space) - ZA @ - ZZ Z - ZL ( # only in valgrind 3.3.0 and later - ZR ) # only in valgrind 3.3.0 and later -]]></programlisting> - -<para>Hence <computeroutput>libpthreadZdsoZd0</computeroutput> is an -encoding of the soname <computeroutput>libpthread.so.0</computeroutput> -and <computeroutput>pthreadZucreateZAZa</computeroutput> is an encoding -of the function name <computeroutput>pthread_create@*</computeroutput>. -</para> - -<para>The macro <computeroutput>I_WRAP_SONAME_FNNAME_ZZ</computeroutput> -constructs a wrapper name in which -both the soname (first component) and function name (second component) -are Z-encoded. Encoding the function name can be tiresome and is -often unnecessary, so a second macro, -<computeroutput>I_WRAP_SONAME_FNNAME_ZU</computeroutput>, can be -used instead. The <computeroutput>_ZU</computeroutput> variant is -also useful for writing wrappers for -C++ functions, in which the function name is usually already mangled -using some other convention in which Z plays an important role. Having -to encode a second time quickly becomes confusing.</para> - -<para>Since the function name field may contain wildcards, it can be -anything, including just <computeroutput>*</computeroutput>. -The same is true for the soname. -However, some ELF objects - specifically, main executables - do not -have sonames. Any object lacking a soname is treated as if its soname -was <computeroutput>NONE</computeroutput>, which is why the original -example above had a name -<computeroutput>I_WRAP_SONAME_FNNAME_ZU(NONE,foo)</computeroutput>.</para> - -<para>Note that the soname of an ELF object is not the same as its -file name, although it is often similar. You can find the soname of -an object <computeroutput>libfoo.so</computeroutput> using the command -<computeroutput>readelf -a libfoo.so | grep soname</computeroutput>.</para> -</sect2> - -<sect2 id="manual-core.wrapping.semantics" xreflabel="Wrapping Semantics"> -<title>Wrapping Semantics</title> - -<para>The ability for a wrapper to replace an infinite family of functions -is powerful but brings complications in situations where ELF objects -appear and disappear (are dlopen'd and dlclose'd) on the fly. -Valgrind tries to maintain sensible behaviour in such situations.</para> - -<para>For example, suppose a process has dlopened (an ELF object with -soname) <computeroutput>object1.so</computeroutput>, which contains -<computeroutput>function1</computeroutput>. It starts to use -<computeroutput>function1</computeroutput> immediately.</para> - -<para>After a while it dlopens <computeroutput>wrappers.so</computeroutput>, -which contains a wrapper -for <computeroutput>function1</computeroutput> in (soname) -<computeroutput>object1.so</computeroutput>. All subsequent calls to -<computeroutput>function1</computeroutput> are rerouted to the wrapper.</para> - -<para>If <computeroutput>wrappers.so</computeroutput> is -later dlclose'd, calls to <computeroutput>function1</computeroutput> are -naturally routed back to the original.</para> - -<para>Alternatively, if <computeroutput>object1.so</computeroutput> -is dlclose'd but wrappers.so remains, -then the wrapper exported by <computeroutput>wrapper.so</computeroutput> -becomes inactive, since there -is no way to get to it - there is no original to call any more. However, -Valgrind remembers that the wrapper is still present. If -<computeroutput>object1.so</computeroutput> is -eventually dlopen'd again, the wrapper will become active again.</para> - -<para>In short, valgrind inspects all code loading/unloading events to -ensure that the set of currently active wrappers remains consistent.</para> - -<para>A second possible problem is that of conflicting wrappers. It is -easily possible to load two or more wrappers, both of which claim -to be wrappers for some third function. In such cases Valgrind will -complain about conflicting wrappers when the second one appears, and -will honour only the first one.</para> -</sect2> - -<sect2 id="manual-core.wrapping.debugging" xreflabel="Debugging"> -<title>Debugging</title> - -<para>Figuring out what's going on given the dynamic nature of wrapping -can be difficult. The -<computeroutput>--trace-redir=yes</computeroutput> flag makes -this possible -by showing the complete state of the redirection subsystem after -every -<computeroutput>mmap</computeroutput>/<computeroutput>munmap</computeroutput> -event affecting code (text).</para> - -<para>There are two central concepts:</para> - -<itemizedlist> - - <listitem><para>A "redirection specification" is a binding of - a (soname pattern, fnname pattern) pair to a code address. - These bindings are created by writing functions with names - made with the - <computeroutput>I_WRAP_SONAME_FNNAME_{ZZ,_ZU}</computeroutput> - macros.</para></listitem> - - <listitem><para>An "active redirection" is code-address to - code-address binding currently in effect.</para></listitem> - -</itemizedlist> - -<para>The state of the wrapping-and-redirection subsystem comprises a set of -specifications and a set of active bindings. The specifications are -acquired/discarded by watching all -<computeroutput>mmap</computeroutput>/<computeroutput>munmap</computeroutput> -events on code (text) -sections. The active binding set is (conceptually) recomputed from -the specifications, and all known symbol names, following any change -to the specification set.</para> - -<para><computeroutput>--trace-redir=yes</computeroutput> shows the contents -of both sets following any such event.</para> - -<para><computeroutput>-v</computeroutput> prints a line of text each -time an active specification is used for the first time.</para> - -<para>Hence for maximum debugging effectiveness you will need to use both -flags.</para> - -<para>One final comment. The function-wrapping facility is closely -tied to Valgrind's ability to replace (redirect) specified -functions, for example to redirect calls to -<computeroutput>malloc</computeroutput> to its -own implementation. Indeed, a replacement function can be -regarded as a wrapper function which does not call the original. -However, to make the implementation more robust, the two kinds -of interception (wrapping vs replacement) are treated differently. -</para> - -<para><computeroutput>--trace-redir=yes</computeroutput> shows -specifications and bindings for both -replacement and wrapper functions. To differentiate the -two, replacement bindings are printed using -<computeroutput>R-></computeroutput> whereas -wraps are printed using <computeroutput>W-></computeroutput>. -</para> -</sect2> - - -<sect2 id="manual-core.wrapping.limitations-cf" - xreflabel="Limitations - control flow"> -<title>Limitations - control flow</title> - -<para>For the most part, the function wrapping implementation is robust. -The only important caveat is: in a wrapper, get hold of -the <computeroutput>OrigFn</computeroutput> information using -<computeroutput>VALGRIND_GET_ORIG_FN</computeroutput> before calling any -other wrapped function. Once you have the -<computeroutput>OrigFn</computeroutput>, arbitrary -calls between, recursion between, and longjumps out of wrappers -should work correctly. There is never any interaction between wrapped -functions and merely replaced functions -(eg <computeroutput>malloc</computeroutput>), so you can call -<computeroutput>malloc</computeroutput> etc safely from within wrappers. -</para> - -<para>The above comments are true for {x86,amd64,ppc32}-linux. On -ppc64-linux function wrapping is more fragile due to the (arguably -poorly designed) ppc64-linux ABI. This mandates the use of a shadow -stack which tracks entries/exits of both wrapper and replacement -functions. This gives two limitations: firstly, longjumping out of -wrappers will rapidly lead to disaster, since the shadow stack will -not get correctly cleared. Secondly, since the shadow stack has -finite size, recursion between wrapper/replacement functions is only -possible to a limited depth, beyond which Valgrind has to abort the -run. This depth is currently 16 calls.</para> - -<para>For all platforms ({x86,amd64,ppc32,ppc64}-linux) all the above -comments apply on a per-thread basis. In other words, wrapping is -thread-safe: each thread must individually observe the above -restrictions, but there is no need for any kind of inter-thread -cooperation.</para> -</sect2> - - -<sect2 id="manual-core.wrapping.limitations-sigs" - xreflabel="Limitations - original function signatures"> -<title>Limitations - original function signatures</title> - -<para>As shown in the above example, to call the original you must use a -macro of the form <computeroutput>CALL_FN_*</computeroutput>. -For technical reasons it is impossible -to create a single macro to deal with all argument types and numbers, -so a family of macros covering the most common cases is supplied. In -what follows, 'W' denotes a machine-word-typed value (a pointer or a -C <computeroutput>long</computeroutput>), -and 'v' denotes C's <computeroutput>void</computeroutput> type. -The currently available macros are:</para> - -<programlisting><![CDATA[ -CALL_FN_v_v -- call an original of type void fn ( void ) -CALL_FN_W_v -- call an original of type long fn ( void ) - -CALL_FN_v_W -- void fn ( long ) -CALL_FN_W_W -- long fn ( long ) - -CALL_FN_v_WW -- void fn ( long, long ) -CALL_FN_W_WW -- long fn ( long, long ) - -CALL_FN_v_WWW -- void fn ( long, long, long ) -CALL_FN_W_WWW -- long fn ( long, long, long ) - -CALL_FN_W_WWWW -- long fn ( long, long, long, long ) -CALL_FN_W_5W -- long fn ( long, long, long, long, long ) -CALL_FN_W_6W -- long fn ( long, long, long, long, long, long ) -and so on, up to -CALL_FN_W_12W -]]></programlisting> - -<para>The set of supported types can be expanded as needed. It is -regrettable that this limitation exists. Function wrapping has proven -difficult to implement, with a certain apparently unavoidable level of -ickyness. After several implementation attempts, the present -arrangement appears to be the least-worst tradeoff. At least it works -reliably in the presence of dynamic linking and dynamic code -loading/unloading.</para> - -<para>You should not attempt to wrap a function of one type signature with a -wrapper of a different type signature. Such trickery will surely lead -to crashes or strange behaviour. This is not of course a limitation -of the function wrapping implementation, merely a reflection of the -fact that it gives you sweeping powers to shoot yourself in the foot -if you are not careful. Imagine the instant havoc you could wreak by -writing a wrapper which matched any function name in any soname - in -effect, one which claimed to be a wrapper for all functions in the -process.</para> -</sect2> - -<sect2 id="manual-core.wrapping.examples" xreflabel="Examples"> -<title>Examples</title> - -<para>In the source tree, -<computeroutput>memcheck/tests/wrap[1-8].c</computeroutput> provide a series of -examples, ranging from very simple to quite advanced.</para> - -<para><computeroutput>auxprogs/libmpiwrap.c</computeroutput> is an example -of wrapping a big, complex API (the MPI-2 interface). This file defines -almost 300 different wrappers.</para> -</sect2> - -</sect1> - - - - </chapter> Modified: trunk/docs/xml/manual.xml =================================================================== --- trunk/docs/xml/manual.xml 2007-11-24 23:37:07 UTC (rev 7207) +++ trunk/docs/xml/manual.xml 2007-11-25 00:55:11 UTC (rev 7208) @@ -22,6 +22,8 @@ xmlns:xi="http://www.w3.org/2001/XInclude" /> <xi:include href="manual-core.xml" parse="xml" xmlns:xi="http://www.w3.org/2001/XInclude" /> + <xi:include href="manual-core-adv.xml" parse="xml" + xmlns:xi="http://www.w3.org/2001/XInclude" /> <xi:include href="../../memcheck/docs/mc-manual.xml" parse="xml" xmlns:xi="http://www.w3.org/2001/XInclude" /> <xi:include href="../../cachegrind/docs/cg-manual.xml" parse="xml" |