зеркало из https://github.com/github/ruby.git
* vm_dump.c (dump_thread): show the displacement from the beginning
of the symbol. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
b96d267c7e
Коммит
952a357274
|
@ -1,3 +1,8 @@
|
|||
Fri Nov 26 11:09:07 2010 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* vm_dump.c (dump_thread): show the displacement from the beginning
|
||||
of the symbol.
|
||||
|
||||
Fri Nov 26 10:48:23 2010 NAKAMURA Usaku <usa@ruby-lang.org>
|
||||
|
||||
* vm_dump.c (dump_thread): follow the output of glibc.
|
||||
|
|
|
@ -727,6 +727,7 @@ dump_thread(void *arg)
|
|||
NULL, NULL, NULL)) {
|
||||
DWORD64 addr = frame.AddrPC.Offset;
|
||||
IMAGEHLP_LINE64 line;
|
||||
DWORD64 displacement;
|
||||
DWORD tmp;
|
||||
|
||||
if (addr == frame.AddrReturn.Offset || addr == 0 ||
|
||||
|
@ -736,10 +737,11 @@ dump_thread(void *arg)
|
|||
memset(buf, 0, sizeof(buf));
|
||||
info->SizeOfStruct = sizeof(SYMBOL_INFO);
|
||||
info->MaxNameLen = MAX_SYM_NAME;
|
||||
if (pSymFromAddr(ph, addr, NULL, info)) {
|
||||
if (pSymFromAddr(ph, addr, &displacement, info)) {
|
||||
if (GetModuleFileName((HANDLE)(uintptr_t)pSymGetModuleBase64(ph, addr), libpath, sizeof(libpath)))
|
||||
fprintf(stderr, "%s", libpath);
|
||||
fprintf(stderr, "(%s)", info->Name);
|
||||
fprintf(stderr, "(%s+0x%I64x)",
|
||||
info->Name, displacement);
|
||||
}
|
||||
fprintf(stderr, " [0x%p]", (void *)(VALUE)addr);
|
||||
memset(&line, 0, sizeof(line));
|
||||
|
|
Загрузка…
Ссылка в новой задаче