Skip to content

dr.memory 在window10上运行,应用程序创建新线程std::thread后,应用程序异常退出 #2550

@sammy2025-spring

Description

@sammy2025-spring

Describe the bug
win10上用vs编译的程序,用Dr.memory启动dr.memory -ignore_kernel -ignore_assert -verbose 2 -debug -dr_debug -log_dir .\log -- .\DemoTest.exe
,DemoTest.exe 中途退出

To Reproduce
Steps to reproduce the behavior:

  1. 程序中调用std::thread创建线程,线程返回主线程时退出来了
  2. dr.memory -ignore_kernel -ignore_assert -verbose 2 -debug -dr_debug -log_dir .\log -- .\DemoTest.exe
    ,DemoTest.exe

Dr . Memory version 2.6.0 build 0 built on Sep 21 2023 17:44:51
Windows version : WinVer =105; Rel -2009; Build -19043; Edition - Professional
Dr . Memory results for pid 14628:" DemoTest . exe "
Application cmdline :". DemoTest . exe "
Recorded 124 suppression ( s ) from default D :001 tools MemoryCheckTools DrMemory - Windows -2.6.0- NB \ DrMemory - Windows -2.6.0bin64\ suppress - default . txt
Recorded 29 suppression ( s ) from user E :001 code bp master3.5\ Code SelfDev bin x64 Debug suppress - bp new .txt3
System call information is missing for this operating system : WinVer -105; Rel -2009; Build -19043; Edition - Professional .
Error #1: UNINITIALIZED READ : reading 0x000000319f2e2920-0x000000319f2e298096 byte ( s ) within 0x0000003f912e2780-0x000000#0 ntdll . dll !RtICaptureContext2+0x2f0(0x00007ffac71312a0< ntdll . dll -0xa12a0>)
#1 ntdll . dll ! RtlUnwindEx
+0x565(0x00007ffac70c0b66< ntdll . dil +0x30b66>)
#2 ntdil . dil ! RtIUserThreadStart +0x20(0x0000/ffac70e2651 entdll . dil +0x52651s)
Note :@0:10:56.364 in thread 29300
Note : instruction : fxrstor 0x00000100(% rcx )
Error #2: UNINITIALIZED READ : reading 0x0000003f9f2e25ea-0x0000003f912e25f06 byte ( s ) within 0x0000003f9f2e25e0-0x0000003f9f2e2608#0 ntdll . dll !RtICaptureContext2+0x409(0x00007ffac71313b9< ntdll . dll +Oxa13b9>
#1 ntdll . dll ! RtlUnwindEx
+0x565(0x00007ffac70c0b66 ntdll . dll +0x30b66*)
#2 ntdll . dll ! RtlUserThreadStart +0x20(0x00007ffac70e2651< ntdll . dll +0x52651>)
Note :@0:10:56.373 in thread 29300
Note : instruction : iret % rsp (% rsp )->% rsp

Please also answer these questions drawn from https://drmemory.org/page_help.html#sec_narrow :

  • Does the problem go away when running in light mode (pass -light to Dr. Memory)? Yes
  • Does the problem go away when running with the options -leaks_only -no_count_leaks -no_track_allocs? Yes

Expected behavior
application not exit

Versions

  • What version of Dr. Memory are you using? 2.6.0
  • Does the latest build from
    https://drmemory.org/page_download.html#sec_latest_build solve the problem? not try it
  • What operating system version are you running on? ("Windows 10" is not sufficient: give the release number.) Windows 10 19043.1288
  • Is your application 32-bit or 64-bit? 64-bit

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions