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
(26) |
2
(35) |
3
(18) |
4
(14) |
|
5
(12) |
6
(13) |
7
(11) |
8
(15) |
9
(8) |
10
(13) |
11
(25) |
|
12
(13) |
13
(24) |
14
(7) |
15
(6) |
16
(8) |
17
(6) |
18
(7) |
|
19
(8) |
20
(7) |
21
(5) |
22
(7) |
23
(6) |
24
(7) |
25
(6) |
|
26
(7) |
27
(7) |
28
(5) |
29
(5) |
30
(5) |
|
|
|
From: Nicholas N. <nj...@ca...> - 2004-09-05 22:25:21
|
CVS commit by nethercote: Remove unnecessary #includes. M +0 -2 stage1.c 1.20 M +0 -4 ume.c 1.23 --- valgrind/coregrind/stage1.c #1.19:1.20 @@ -32,5 +32,4 @@ #include <stdio.h> -#include <elf.h> #include <string.h> #include <stdlib.h> @@ -38,5 +37,4 @@ #include <signal.h> #include <fcntl.h> -#include <errno.h> #include <sys/resource.h> --- valgrind/coregrind/ume.c #1.22:1.23 @@ -35,15 +35,11 @@ #include "core.h" -#include <stddef.h> #include <sys/mman.h> #include <fcntl.h> #include <errno.h> -#include <elf.h> #include <stdio.h> #include <string.h> #include <stdlib.h> #include <unistd.h> -#include <sys/stat.h> -#include <dlfcn.h> #include <assert.h> |
|
From: Nicholas N. <nj...@ca...> - 2004-09-05 22:02:52
|
CVS commit by nethercote:
Arch-abstraction:
- replaced some x86-specific register mentions with arch-neutral ones.
M +23 -17 vg_scheduler.c 1.176
--- valgrind/coregrind/vg_scheduler.c #1.175:1.176
@@ -153,5 +153,5 @@ ThreadId VG_(first_matching_thread_stack
if (vg_tid_currently_in_baseBlock != VG_INVALID_THREADID) {
tid = vg_tid_currently_in_baseBlock;
- if ( p ( VG_(baseBlock)[VGOFF_(m_esp)],
+ if ( p ( VG_(baseBlock)[VGOFF_STACK_PTR],
VG_(threads)[tid].stack_highest_word, d ) )
return tid;
@@ -163,5 +163,5 @@ ThreadId VG_(first_matching_thread_stack
if (VG_(threads)[tid].status == VgTs_Empty) continue;
if (tid == tid_to_skip) continue;
- if ( p ( VG_(threads)[tid].arch.m_esp,
+ if ( p ( ARCH_STACK_PTR(VG_(threads)[tid].arch),
VG_(threads)[tid].stack_highest_word, d ) )
return tid;
@@ -195,6 +195,7 @@ void VG_(pp_sched_status) ( void )
VG_(threads)[i].associated_cv );
VG_(pp_ExeContext)(
- VG_(get_ExeContext2)( VG_(threads)[i].arch.m_eip, VG_(threads)[i].arch.m_ebp,
- VG_(threads)[i].arch.m_esp,
+ VG_(get_ExeContext2)( ARCH_INSTR_PTR(VG_(threads)[i].arch),
+ ARCH_FRAME_PTR(VG_(threads)[i].arch),
+ ARCH_STACK_PTR(VG_(threads)[i].arch),
VG_(threads)[i].stack_highest_word)
);
@@ -837,8 +838,9 @@ VgSchedReturnCode do_scheduler ( Int* ex
if (VG_(bbs_done) > 31700000 + 0) {
dispatch_ctr_SAVED = VG_(dispatch_ctr) = 2;
- VG_(translate)(&VG_(threads)[tid], VG_(threads)[tid].arch.m_eip,
+ VG_(translate)(&VG_(threads)[tid],
+ ARCH_INSTR_PTR(VG_(threads)[tid].arch),
/*debugging*/True);
}
- vg_assert(VG_(threads)[tid].arch.m_eip != 0);
+ vg_assert(ARCH_INSTR_PTR(VG_(threads)[tid].arch) != 0);
# endif
@@ -846,7 +848,7 @@ VgSchedReturnCode do_scheduler ( Int* ex
# if 0
- if (0 == VG_(threads)[tid].arch.m_eip) {
+ if (0 == ARCH_INSTR_PTR(VG_(threads)[tid].arch)) {
VG_(printf)("tid = %d, dc = %llu\n", tid, VG_(bbs_done));
- vg_assert(0 != VG_(threads)[tid].arch.m_eip);
+ vg_assert(0 != ARCH_INSTR_PTR(VG_(threads)[tid].arch));
}
# endif
@@ -860,9 +862,12 @@ VgSchedReturnCode do_scheduler ( Int* ex
/* Trivial event. Miss in the fast-cache. Do a full
lookup for it. */
- trans_addr = VG_(search_transtab) ( VG_(threads)[tid].arch.m_eip );
+ trans_addr = VG_(search_transtab)
+ ( ARCH_INSTR_PTR(VG_(threads)[tid].arch) );
if (trans_addr == (Addr)0) {
/* Not found; we need to request a translation. */
- VG_(translate)( tid, VG_(threads)[tid].arch.m_eip, /*debug*/False );
- trans_addr = VG_(search_transtab) ( VG_(threads)[tid].arch.m_eip );
+ VG_(translate)( tid, ARCH_INSTR_PTR(VG_(threads)[tid].arch),
+ /*debug*/False );
+ trans_addr = VG_(search_transtab)
+ ( ARCH_INSTR_PTR(VG_(threads)[tid].arch) );
if (trans_addr == (Addr)0)
VG_(core_panic)("VG_TRC_INNER_FASTMISS: missing tt_fast entry");
@@ -902,5 +907,5 @@ VgSchedReturnCode do_scheduler ( Int* ex
# if 0
{ UInt* esp; Int i;
- esp=(UInt*)VG_(threads)[tid].arch.m_esp;
+ esp=(UInt*)ARCH_STACK_PTR(VG_(threads)[tid].arch);
VG_(printf)("\nBEFORE\n");
for (i = 10; i >= -10; i--)
@@ -940,5 +945,6 @@ VgSchedReturnCode do_scheduler ( Int* ex
}
VG_(nuke_all_threads_except) ( tid );
- VG_(threads)[tid].arch.m_eip = (UInt)__libc_freeres_wrapper;
+ ARCH_INSTR_PTR(VG_(threads)[tid].arch) =
+ (UInt)__libc_freeres_wrapper;
vg_assert(VG_(threads)[tid].status == VgTs_Runnable);
goto stage1; /* party on, dudes (but not for much longer :) */
@@ -972,5 +978,5 @@ VgSchedReturnCode do_scheduler ( Int* ex
# if 0
{ UInt* esp; Int i;
- esp=(UInt*)VG_(threads)[tid].arch.m_esp;
+ esp=(UInt*)ARCH_STACK_PTR(VG_(threads)[tid].arch);
VG_(printf)("AFTER\n");
for (i = 10; i >= -10; i--)
@@ -1166,5 +1172,5 @@ void make_thread_jump_to_cancelhdlr ( Th
/* .cancel_pend will hold &thread_exit_wrapper */
- VG_(threads)[tid].arch.m_eip = (UInt)VG_(threads)[tid].cancel_pend;
+ ARCH_INSTR_PTR(VG_(threads)[tid].arch) = (UInt)VG_(threads)[tid].cancel_pend;
VG_(proxy_abort_syscall)(tid);
@@ -1833,5 +1839,5 @@ void do__apply_in_new_thread ( ThreadId
/* this is where we start */
- VG_(threads)[tid].arch.m_eip = (UInt)fn;
+ ARCH_INSTR_PTR(VG_(threads)[tid].arch) = (UInt)fn;
if (VG_(clo_trace_sched)) {
@@ -3265,5 +3271,5 @@ void scheduler_sanity ( void )
Int
stack_used = (Addr)VG_(threads)[i].stack_highest_word
- - (Addr)VG_(threads)[i].arch.m_esp;
+ - (Addr)ARCH_STACK_PTR(VG_(threads)[i].arch);
Int
stack_avail = VG_(threads)[i].stack_size
|
|
From: Nicholas N. <nj...@ca...> - 2004-09-05 21:32:51
|
CVS commit by nethercote:
Arch-abstraction: made vg_execontext.c arch-independent, based on Paul
Mackerras's work.
- introduced arch-neutral macros for getting the instruction/frame/stack
pointers.
- renamed ExeContext.eips as ExeContext.ips
- renamed esp/ebp/eip to sp/fp/ip in several related files and arch-neutralised
various comments
- introduced arch-neutral macros for walking the stack
M +2 -2 coregrind/core.h 1.11
M +5 -5 coregrind/vg_errcontext.c 1.62
M +71 -71 coregrind/vg_execontext.c 1.19
M +2 -2 coregrind/vg_scheduler.c 1.175
M +26 -0 coregrind/x86/core_arch.h 1.4
M +7 -7 include/tool.h.base 1.5
--- valgrind/coregrind/core.h #1.10:1.11
@@ -1150,7 +1150,7 @@ struct _ExeContext {
struct _ExeContext * next;
/* Variable-length array. The size is VG_(clo_backtrace_size); at
- least 1, at most VG_DEEPEST_BACKTRACE. [0] is the current %eip,
+ least 1, at most VG_DEEPEST_BACKTRACE. [0] is the current IP,
[1] is its caller, [2] is the caller of [1], etc. */
- Addr eips[0];
+ Addr ips[0];
};
--- valgrind/coregrind/vg_errcontext.c #1.61:1.62
@@ -361,5 +361,5 @@ static void gen_suppression(Error* err)
i = 0;
do {
- Addr eip = ec->eips[i];
+ Addr eip = ec->ips[i];
if (i > 0)
eip -= MIN_INSTR_SIZE; // point to calling line
@@ -381,5 +381,5 @@ static void gen_suppression(Error* err)
}
i++;
- } while (i < stop_at && ec->eips[i] != 0);
+ } while (i < stop_at && ec->ips[i] != 0);
VG_(printf)("}\n");
@@ -668,5 +668,5 @@ void VG_(show_all_errors) ( void )
if ((i+1 == VG_(clo_dump_error))) {
VG_(translate) ( 0 /* dummy ThreadId; irrelevant due to debugging*/,
- p_min->where->eips[0], /*debugging*/True);
+ p_min->where->ips[0], /*debugging*/True);
}
@@ -1003,5 +1003,5 @@ static Supp* is_suppressible_error ( Err
for (i = 0; i < VG_N_SUPP_CALLERS && i < VG_(clo_backtrace_size); i++) {
- get_objname_fnname ( err->where->eips[i], caller_obj[i], M_VG_ERRTXT,
+ get_objname_fnname ( err->where->ips[i], caller_obj[i], M_VG_ERRTXT,
caller_fun[i], M_VG_ERRTXT );
}
--- valgrind/coregrind/vg_execontext.c #1.18:1.19
@@ -110,5 +110,5 @@ void VG_(pp_ExeContext) ( ExeContext* e
{
init_ExeContext_storage();
- VG_(mini_stack_dump) ( e->eips, VG_(clo_backtrace_size) );
+ VG_(mini_stack_dump) ( e->ips, VG_(clo_backtrace_size) );
}
@@ -123,6 +123,6 @@ Bool VG_(eq_ExeContext) ( VgRes res, Exe
/* Just compare the top two callers. */
vg_ec_cmp2s++;
- if (e1->eips[0] != e2->eips[0]
- || e1->eips[1] != e2->eips[1]) return False;
+ if (e1->ips[0] != e2->ips[0]
+ || e1->ips[1] != e2->ips[1]) return False;
return True;
@@ -130,14 +130,14 @@ Bool VG_(eq_ExeContext) ( VgRes res, Exe
/* Just compare the top four callers. */
vg_ec_cmp4s++;
- if (e1->eips[0] != e2->eips[0]) return False;
+ if (e1->ips[0] != e2->ips[0]) return False;
if (VG_(clo_backtrace_size) < 2) return True;
- if (e1->eips[1] != e2->eips[1]) return False;
+ if (e1->ips[1] != e2->ips[1]) return False;
if (VG_(clo_backtrace_size) < 3) return True;
- if (e1->eips[2] != e2->eips[2]) return False;
+ if (e1->ips[2] != e2->ips[2]) return False;
if (VG_(clo_backtrace_size) < 4) return True;
- if (e1->eips[3] != e2->eips[3]) return False;
+ if (e1->ips[3] != e2->ips[3]) return False;
return True;
@@ -154,19 +154,19 @@ Bool VG_(eq_ExeContext) ( VgRes res, Exe
-/* Take a snapshot of the client's stack, putting the up to 'n_eips' %eips
- into 'eips'. In order to be thread-safe, we pass in the thread's %EIP
- and %EBP. Returns number of %eips put in 'eips'. */
-static UInt stack_snapshot2 ( Addr* eips, UInt n_eips, Addr eip, Addr ebp,
- Addr ebp_min, Addr ebp_max_orig )
+/* Take a snapshot of the client's stack, putting the up to 'n_ips' IPs
+ into 'ips'. In order to be thread-safe, we pass in the thread's IP
+ and FP. Returns number of IPs put in 'ips'. */
+static UInt stack_snapshot2 ( Addr* ips, UInt n_ips, Addr ip, Addr fp,
+ Addr fp_min, Addr fp_max_orig )
{
Int i;
- Addr ebp_max;
+ Addr fp_max;
UInt n_found = 0;
VGP_PUSHCC(VgpExeContext);
- /* First snaffle %EIPs from the client's stack into eips[0 .. n_eips-1],
+ /* First snaffle IPs from the client's stack into ips[0 .. n_ips-1],
putting zeroes in when the trail goes cold, which we guess to be when
- %ebp is not a reasonable stack location. We also assert that %ebp
+ FP is not a reasonable stack location. We also assert that FP
increases down the chain. */
@@ -176,37 +176,38 @@ static UInt stack_snapshot2 ( Addr* eips
// NJN 2002-sep-05: traces for pthreaded programs are particularly bad.
- // JRS 2002-sep-17: hack, to round up ebp_max to the end of the
+ // JRS 2002-sep-17: hack, to round up fp_max to the end of the
// current page, at least. Dunno if it helps.
// NJN 2002-sep-17: seems to -- stack traces look like 1.0.X again
- ebp_max = (ebp_max_orig + VKI_BYTES_PER_PAGE - 1)
+ fp_max = (fp_max_orig + VKI_BYTES_PER_PAGE - 1)
& ~(VKI_BYTES_PER_PAGE - 1);
- ebp_max -= sizeof(Addr);
+ fp_max -= sizeof(Addr);
/* Assertion broken before main() is reached in pthreaded programs; the
* offending stack traces only have one item. --njn, 2002-aug-16 */
- /* vg_assert(ebp_min <= ebp_max);*/
+ /* vg_assert(fp_min <= fp_max);*/
- if (ebp_min + 4000000 <= ebp_max) {
+ if (fp_min + 4000000 <= fp_max) {
/* If the stack is ridiculously big, don't poke around ... but
don't bomb out either. Needed to make John Regehr's
user-space threads package work. JRS 20021001 */
- eips[0] = eip;
+ ips[0] = ip;
i = 1;
} else {
/* Get whatever we safely can ... */
- eips[0] = eip;
- for (i = 1; i < n_eips; i++) {
- if (!(ebp_min <= ebp && ebp <= ebp_max)) {
- //VG_(printf)("... out of range %p\n", ebp);
- break; /* ebp gone baaaad */
+ ips[0] = ip;
+ fp = FIRST_STACK_FRAME(fp);
+ for (i = 1; i < n_ips; i++) {
+ if (!(fp_min <= fp && fp <= fp_max)) {
+ //VG_(printf)("... out of range %p\n", fp);
+ break; /* fp gone baaaad */
}
// NJN 2002-sep-17: monotonicity doesn't work -- gives wrong traces...
- // if (ebp >= ((UInt*)ebp)[0]) {
+ // if (fp >= ((UInt*)fp)[0]) {
// VG_(printf)("nonmonotonic\n");
- // break; /* ebp gone nonmonotonic */
+ // break; /* fp gone nonmonotonic */
// }
- eips[i] = ((UInt*)ebp)[1]; /* ret addr */
- ebp = ((UInt*)ebp)[0]; /* old ebp */
- //VG_(printf)(" %p\n", eips[i]);
+ ips[i] = STACK_FRAME_RET(fp); /* ret addr */
+ fp = STACK_FRAME_NEXT(fp); /* old fp */
+ //VG_(printf)(" %p\n", ips[i]);
}
}
@@ -214,6 +215,6 @@ static UInt stack_snapshot2 ( Addr* eips
/* Put zeroes in the rest. */
- for (; i < n_eips; i++) {
- eips[i] = 0;
+ for (; i < n_ips; i++) {
+ ips[i] = 0;
}
VGP_POPCC(VgpExeContext);
@@ -231,9 +232,9 @@ static UInt stack_snapshot2 ( Addr* eips
Text type.
*/
-ExeContext* VG_(get_ExeContext2) ( Addr eip, Addr ebp,
- Addr ebp_min, Addr ebp_max_orig )
+ExeContext* VG_(get_ExeContext2) ( Addr ip, Addr fp,
+ Addr fp_min, Addr fp_max_orig )
{
Int i;
- Addr eips[VG_DEEPEST_BACKTRACE];
+ Addr ips[VG_DEEPEST_BACKTRACE];
Bool same;
UInt hash;
@@ -247,6 +248,6 @@ ExeContext* VG_(get_ExeContext2) ( Addr
&& VG_(clo_backtrace_size) <= VG_DEEPEST_BACKTRACE);
- stack_snapshot2( eips, VG_(clo_backtrace_size),
- eip, ebp, ebp_min, ebp_max_orig );
+ stack_snapshot2( ips, VG_(clo_backtrace_size),
+ ip, fp, fp_min, fp_max_orig );
/* Now figure out if we've seen this one before. First hash it so
@@ -255,5 +256,5 @@ ExeContext* VG_(get_ExeContext2) ( Addr
hash = 0;
for (i = 0; i < VG_(clo_backtrace_size); i++) {
- hash ^= (UInt)eips[i];
+ hash ^= (UInt)ips[i];
hash = (hash << 29) | (hash >> 3);
}
@@ -271,5 +272,5 @@ ExeContext* VG_(get_ExeContext2) ( Addr
same = True;
for (i = 0; i < VG_(clo_backtrace_size); i++) {
- if (list->eips[i] != eips[i]) {
+ if (list->ips[i] != ips[i]) {
same = False;
break;
@@ -294,5 +295,5 @@ ExeContext* VG_(get_ExeContext2) ( Addr
for (i = 0; i < VG_(clo_backtrace_size); i++)
- new_ec->eips[i] = eips[i];
+ new_ec->ips[i] = ips[i];
new_ec->next = vg_ec_list[hash];
@@ -303,19 +304,19 @@ ExeContext* VG_(get_ExeContext2) ( Addr
}
-void get_needed_regs(ThreadId tid, Addr* eip, Addr* ebp, Addr* esp,
+void get_needed_regs(ThreadId tid, Addr* ip, Addr* fp, Addr* sp,
Addr* stack_highest_word)
{
if (VG_(is_running_thread)(tid)) {
/* thread currently in baseblock */
- *eip = VG_(baseBlock)[VGOFF_(m_eip)];
- *ebp = VG_(baseBlock)[VGOFF_(m_ebp)];
- *esp = VG_(baseBlock)[VGOFF_(m_esp)];
+ *ip = VG_(baseBlock)[VGOFF_INSTR_PTR];
+ *fp = VG_(baseBlock)[VGOFF_FRAME_PTR];
+ *sp = VG_(baseBlock)[VGOFF_STACK_PTR];
*stack_highest_word = VG_(threads)[tid].stack_highest_word;
} else {
/* thread in thread table */
ThreadState* tst = & VG_(threads)[ tid ];
- *eip = tst->arch.m_eip;
- *ebp = tst->arch.m_ebp;
- *esp = tst->arch.m_esp;
+ *ip = ARCH_INSTR_PTR(tst->arch);
+ *fp = ARCH_FRAME_PTR(tst->arch);
+ *sp = ARCH_STACK_PTR(tst->arch);
*stack_highest_word = tst->stack_highest_word;
}
@@ -323,15 +324,15 @@ void get_needed_regs(ThreadId tid, Addr*
/* Nasty little hack to deal with sysinfo syscalls - if libc is
using the sysinfo page for syscalls (the TLS version does), then
- eip will always appear to be in that page when doing a syscall,
+ ip will always appear to be in that page when doing a syscall,
not the actual libc function doing the syscall. This check sees
- if EIP is within the syscall code, and pops the return address
- off the stack so that eip is placed within the library function
+ if IP is within the syscall code, and pops the return address
+ off the stack so that ip is placed within the library function
calling the syscall. This makes stack backtraces much more
useful. */
- if (*eip >= VG_(client_trampoline_code)+VG_(tramp_syscall_offset) &&
- *eip < VG_(client_trampoline_code)+VG_(trampoline_code_length) &&
- VG_(is_addressable)(*esp, sizeof(Addr))) {
- *eip = *(Addr *)*esp;
- *esp += sizeof(Addr);
+ if (*ip >= VG_(client_trampoline_code)+VG_(tramp_syscall_offset) &&
+ *ip < VG_(client_trampoline_code)+VG_(trampoline_code_length) &&
+ VG_(is_addressable)(*sp, sizeof(Addr))) {
+ *ip = *(Addr *)*sp;
+ *sp += sizeof(Addr);
}
}
@@ -339,20 +340,19 @@ void get_needed_regs(ThreadId tid, Addr*
ExeContext* VG_(get_ExeContext) ( ThreadId tid )
{
- Addr eip, ebp, esp, stack_highest_word;
+ Addr ip, fp, sp, stack_highest_word;
- get_needed_regs(tid, &eip, &ebp, &esp, &stack_highest_word);
- return VG_(get_ExeContext2)(eip, ebp, esp, stack_highest_word);
+ get_needed_regs(tid, &ip, &fp, &sp, &stack_highest_word);
+ return VG_(get_ExeContext2)(ip, fp, sp, stack_highest_word);
}
-/* Take a snapshot of the client's stack, putting the up to 'n_eips' %eips
- into 'eips'. In order to be thread-safe, we pass in the thread's %EIP
- and %EBP. Returns number of %eips put in 'eips'. */
-UInt VG_(stack_snapshot) ( ThreadId tid, Addr* eips, UInt n_eips )
+/* Take a snapshot of the client's stack, putting the up to 'n_ips'
+ instruction pointers into 'ips'. In order to be thread-safe, we pass in
+ the thread's IP and FP. Returns number of IPs put in 'ips'. */
+UInt VG_(stack_snapshot) ( ThreadId tid, Addr* ips, UInt n_ips )
{
- Addr eip, ebp, esp, stack_highest_word;
+ Addr ip, fp, sp, stack_highest_word;
- get_needed_regs(tid, &eip, &ebp, &esp, &stack_highest_word);
- return stack_snapshot2(eips, n_eips,
- eip, ebp, esp, stack_highest_word);
+ get_needed_regs(tid, &ip, &fp, &sp, &stack_highest_word);
+ return stack_snapshot2(ips, n_ips, ip, fp, sp, stack_highest_word);
}
@@ -361,5 +361,5 @@ Addr VG_(get_EIP_from_ExeContext) ( ExeC
{
if (n > VG_(clo_backtrace_size)) return 0;
- return e->eips[n];
+ return e->ips[n];
}
@@ -369,7 +369,7 @@ Addr VG_(get_EIP) ( ThreadId tid )
if (VG_(is_running_thread)(tid))
- ret = VG_(baseBlock)[VGOFF_(m_eip)];
+ ret = VG_(baseBlock)[VGOFF_INSTR_PTR];
else
- ret = VG_(threads)[ tid ].arch.m_eip;
+ ret = ARCH_INSTR_PTR(VG_(threads)[ tid ].arch);
return ret;
@@ -377,4 +377,4 @@ Addr VG_(get_EIP) ( ThreadId tid )
/*--------------------------------------------------------------------*/
-/*--- end vg_execontext.c ---*/
+/*--- end ---*/
/*--------------------------------------------------------------------*/
--- valgrind/coregrind/vg_scheduler.c #1.174:1.175
@@ -3116,5 +3116,5 @@ void do_client_request ( ThreadId tid )
int count =
VG_(vmessage)( Vg_ClientMsg, (char *)arg[1], (va_list)arg[2] );
- VG_(mini_stack_dump)(e->eips, VG_(clo_backtrace_size));
+ VG_(mini_stack_dump)(e->ips, VG_(clo_backtrace_size));
SET_CLREQ_RETVAL( tid, count );
break; }
@@ -3124,5 +3124,5 @@ void do_client_request ( ThreadId tid )
int count =
VG_(vmessage)( Vg_UserMsg, (char *)arg[1], (va_list)arg[2] );
- VG_(mini_stack_dump)(e->eips, VG_(clo_backtrace_size));
+ VG_(mini_stack_dump)(e->ips, VG_(clo_backtrace_size));
SET_CLREQ_RETVAL( tid, count );
break; }
--- valgrind/coregrind/x86/core_arch.h #1.3:1.4
@@ -36,4 +36,30 @@
/* ---------------------------------------------------------------------
+ Interesting registers
+ ------------------------------------------------------------------ */
+
+// Accessors for the arch_thread_t
+#define ARCH_INSTR_PTR(regs) ((regs).m_eip)
+#define ARCH_STACK_PTR(regs) ((regs).m_esp)
+#define ARCH_FRAME_PTR(regs) ((regs).m_ebp)
+
+#define ARCH_CLREQ_ARGS(regs) ((regs).m_eax)
+
+// Interesting register numbers
+#define R_STACK_PTR R_ESP
+#define R_FRAME_PTR R_EBP
+
+// Stack frame layout and linkage
+#define FIRST_STACK_FRAME(ebp) (ebp)
+#define STACK_FRAME_RET(ebp) (((UInt*)ebp)[1])
+#define STACK_FRAME_NEXT(ebp) (((UInt*)ebp)[0])
+
+// Offsets of interesting registers
+#define VGOFF_INSTR_PTR VGOFF_(m_eip)
+#define VGOFF_STACK_PTR VGOFF_(m_esp)
+#define VGOFF_FRAME_PTR VGOFF_(m_ebp)
+
+
+/* ---------------------------------------------------------------------
Exports of vg_ldt.c
------------------------------------------------------------------ */
--- valgrind/include/tool.h.base #1.4:1.5
@@ -1484,10 +1484,10 @@
extern ExeContext* VG_(get_ExeContext) ( ThreadId tid );
-/* Get the nth EIP from the ExeContext. 0 is the EIP of the top function, 1
+/* Get the nth IP from the ExeContext. 0 is the IP of the top function, 1
is its caller, etc. Returns 0 if there isn't one, or if n is greater
than VG_(clo_backtrace_size), set by the --num-callers option. */
extern Addr VG_(get_EIP_from_ExeContext) ( ExeContext* e, UInt n );
-/* Just grab the client's EIP, as a much smaller and cheaper
+/* Just grab the client's IP, as a much smaller and cheaper
indication of where they are. Use is basically same as for
VG_(get_ExeContext)() above.
@@ -1496,12 +1496,12 @@
/* For tools needing more control over stack traces: walks the stack to get
- %eips from the top stack frames for thread 'tid'. Maximum of 'n_eips'
- addresses put into 'eips'; 0 is the top of the stack, 1 is its caller,
- etc. */
-extern UInt VG_(stack_snapshot) ( ThreadId tid, Addr* eips, UInt n_eips );
+ instruction pointers from the top stack frames for thread 'tid'. Maximum of
+ 'n_ips' addresses put into 'ips'; 0 is the top of the stack, 1 is its
+ caller, etc. */
+extern UInt VG_(stack_snapshot) ( ThreadId tid, Addr* ips, UInt n_ips );
/* Does the same thing as VG_(pp_ExeContext)(), just with slightly
different input. */
-extern void VG_(mini_stack_dump) ( Addr eips[], UInt n_eips );
+extern void VG_(mini_stack_dump) ( Addr ips[], UInt n_ips );
|
|
From: Nicholas N. <nj...@ca...> - 2004-09-05 20:40:10
|
CVS commit by nethercote: Move env variables out of core_asm.h into core.h, where they should be. M +25 -0 core.h 1.10 M +0 -23 core_asm.h 1.3 --- valgrind/coregrind/core.h #1.9:1.10 @@ -182,4 +182,29 @@ #define PGROUNDUP(p) ROUNDUP(p, VKI_BYTES_PER_PAGE) +/* --------------------------------------------------------------------- + Environment variables + ------------------------------------------------------------------ */ + +/* The directory we look for all our auxillary files in */ +#define VALGRINDLIB "VALGRINDLIB" + +/* Additional command-line arguments; they are overridden by actual + command-line option. Each argument is separated by spaces. There + is no quoting mechanism. + */ +#define VALGRINDOPTS "VALGRIND_OPTS" + +/* If this variable is present in the environment, then valgrind will + not parse the command line for options at all; all options come + from this variable. Arguments are terminated by ^A (\001). There + is no quoting mechanism. + + This variable is not expected to be set by anything other than + Valgrind itself, as part of its handling of execve with + --trace-children=yes. This variable should not be present in the + client environment. + */ +#define VALGRINDCLO "_VALGRIND_CLO" + /* --------------------------------------------------------------------- --- valgrind/coregrind/core_asm.h #1.2:1.3 @@ -153,27 +153,4 @@ #define VG_AMD_FEAT_3DNOW (VG_AMD_FEAT*32 + 31) -/* Various environment variables we pay attention to */ - -/* The directory we look for all our auxillary files in */ -#define VALGRINDLIB "VALGRINDLIB" - -/* Additional command-line arguments; they are overridden by actual - command-line option. Each argument is separated by spaces. There - is no quoting mechanism. - */ -#define VALGRINDOPTS "VALGRIND_OPTS" - -/* If this variable is present in the environment, then valgrind will - not parse the command line for options at all; all options come - from this variable. Arguments are terminated by ^A (\001). There - is no quoting mechanism. - - This variable is not expected to be set by anything other than - Valgrind itself, as part of its handling of execve with - --trace-children=yes. This variable should not be present in the - client environment. - */ -#define VALGRINDCLO "_VALGRIND_CLO" - #endif /* ndef __CORE_ASM_H */ |
|
From: Nicholas N. <nj...@ca...> - 2004-09-05 19:55:10
|
On Sun, 5 Sep 2004, Chris January wrote: >> I'd rather see the whole proposed change working before committing >> pieces of it. > > I understand. I thought it might be easier for people to check smaller > patches. I'm reluctant to work on one large single patch that never gets > accepted because of peoples' objections - submitting smaller patches would > help me know I'm on the right track. Yeah, that's understandable. I think committing changes in pieces is fine so long as the end goal is clear, which is why seeing the whole thing helps. N |
|
From: Chris J. <ch...@at...> - 2004-09-05 16:48:46
|
> On Sat, 4 Sep 2004, Chris January wrote: >=20 > > The end result of these changes is to make it easy to add debugging=20 > > support at a later stage because support for breakpoints and single=20 > > stepping is already in the Valgrind core. No further changes would=20 > > (hopefully) be required. >=20 > I'd rather see the whole proposed change working before=20 > committing pieces=20 > of it. I understand. I thought it might be easier for people to check smaller patches. I'm reluctant to work on one large single patch that never gets accepted because of peoples' objections - submitting smaller patches = would help me know I'm on the right track. You can look at the patch I pointed = you to on my website to see how this smaller patch might be used by a = debugging stub/server. Chris January |
|
From: Tom H. <th...@cy...> - 2004-09-05 03:07:09
|
Nightly build on standard ( Red Hat 7.2 ) started at 2004-09-05 02:00:02 BST Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow fork: valgrind -q ./fork fpu_lazy_eflags: valgrind ./fpu_lazy_eflags fucomip: valgrind ./fucomip gxx304: valgrind ./gxx304 insn_basic: valgrind ./insn_basic insn_cmov: valgrind ./insn_cmov insn_fpu: valgrind ./insn_fpu insn_mmx: valgrind ./insn_mmx insn_mmxext: valgrind ./insn_mmxext insn_sse: valgrind ./insn_sse int: valgrind ./int map_unmap: valgrind ./map_unmap mq: valgrind ./mq mremap: valgrind ./mremap munmap_exe: valgrind ./munmap_exe pth_blockedsig: valgrind ./pth_blockedsig pushpopseg: valgrind ./pushpopseg rcl_assert: valgrind ./rcl_assert Could not read `rcl_assert.stderr.exp' make: *** [regtest] Error 2 |
|
From: <js...@ac...> - 2004-09-05 02:55:23
|
Nightly build on phoenix ( SuSE 9.1 ) started at 2004-09-05 03:50:00 BST Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow sem: valgrind ./sem semlimit: valgrind ./semlimit sha1_test: valgrind ./sha1_test shortpush: valgrind ./shortpush shorts: valgrind ./shorts smc1: valgrind ./smc1 susphello: valgrind ./susphello syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 174 tests, 4 stderr failures, 0 stdout failures ================= corecheck/tests/as_mmap (stderr) corecheck/tests/fdleak_fcntl (stderr) memcheck/tests/writev (stderr) memcheck/tests/zeropage (stderr) make: *** [regtest] Error 1 |
|
From: Tom H. <to...@co...> - 2004-09-05 02:26:15
|
Nightly build on dunsmere ( Fedora Core 2 ) started at 2004-09-05 03:20:02 BST Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow smc1: valgrind ./smc1 susphello: valgrind ./susphello syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 179 tests, 8 stderr failures, 1 stdout failure ================= corecheck/tests/fdleak_cmsg (stderr) corecheck/tests/fdleak_fcntl (stderr) corecheck/tests/fdleak_ipv4 (stderr) corecheck/tests/fdleak_socketpair (stderr) memcheck/tests/buflen_check (stderr) memcheck/tests/execve (stderr) memcheck/tests/execve2 (stderr) memcheck/tests/writev (stderr) none/tests/exec-sigmask (stdout) make: *** [regtest] Error 1 |
|
From: Tom H. <th...@cy...> - 2004-09-05 02:19:41
|
Nightly build on audi ( Red Hat 9 ) started at 2004-09-05 03:15:02 BST Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow shorts: valgrind ./shorts smc1: valgrind ./smc1 susphello: valgrind ./susphello syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 179 tests, 8 stderr failures, 0 stdout failures ================= corecheck/tests/fdleak_cmsg (stderr) corecheck/tests/fdleak_fcntl (stderr) corecheck/tests/fdleak_ipv4 (stderr) corecheck/tests/fdleak_socketpair (stderr) memcheck/tests/buflen_check (stderr) memcheck/tests/execve (stderr) memcheck/tests/execve2 (stderr) memcheck/tests/writev (stderr) make: *** [regtest] Error 1 |
|
From: Tom H. <th...@cy...> - 2004-09-05 02:13:17
|
Nightly build on ginetta ( Red Hat 8.0 ) started at 2004-09-05 03:10:01 BST Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow seg_override: valgrind ./seg_override sem: valgrind ./sem semlimit: valgrind ./semlimit sha1_test: valgrind ./sha1_test shortpush: valgrind ./shortpush shorts: valgrind ./shorts smc1: valgrind ./smc1 susphello: valgrind ./susphello syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 179 tests, 3 stderr failures, 0 stdout failures ================= helgrind/tests/race (stderr) helgrind/tests/race2 (stderr) memcheck/tests/writev (stderr) make: *** [regtest] Error 1 |
|
From: Tom H. <th...@cy...> - 2004-09-05 02:08:26
|
Nightly build on alvis ( Red Hat 7.3 ) started at 2004-09-05 03:05:02 BST Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow -- Finished tests in none/tests ---------------------------------------- == 179 tests, 14 stderr failures, 1 stdout failure ================= addrcheck/tests/toobig-allocs (stderr) helgrind/tests/deadlock (stderr) helgrind/tests/race (stderr) helgrind/tests/race2 (stderr) memcheck/tests/badjump (stderr) memcheck/tests/brk (stderr) memcheck/tests/brk2 (stderr) memcheck/tests/error_counts (stdout) memcheck/tests/mismatches (stderr) memcheck/tests/new_nothrow (stderr) memcheck/tests/new_override (stderr) memcheck/tests/toobig-allocs (stderr) memcheck/tests/writev (stderr) none/tests/coolo_sigaction (stderr) none/tests/gxx304 (stderr) make: *** [regtest] Error 1 |