Why does graphedt hang when I stop a graph using "Generate Still Video"?
-
Saturday, April 21, 2012 5:03 PM
I have created this graph in graphedt:
If I start it, then stop it a few seconds later, it often (about half the time) gives me this:
I am running 64-bit Windows 7. Graphedt does not hang if I use a different camera, nor does it hang if I use something other than the "Generate Still Video" filter to feed Input 0 on the VMR9.
I would be very grateful if anyone would tell me if they can repeat this behavior. (Also, if anyone knows what "Hang Signature: 9bc9" means, please pass that along; can't find any reference to it online.)
UPDATE: Turns out that I can get this behavior with a Microsoft camera (a LifeCam HD-5001) and a Chicony camera, and I can get it on 32-bit Windows 7 as well as 64-bit. The key is to stop the graph with the red "stop" button. If I just close the display window (with the "X" button), the graph stops without error and can be restarted. But if I stop it with the stop button, it almost always causes graphedt to hang. Is this just some inherent flaw in the "Generate Still Video" code? I've read a lot about it online, but much of what I've read can't be verified (that it departs from COM standards, isn't really implemented as a filter, and so on).
Stevens Miller
- Edited by Stevens Miller Sunday, April 22, 2012 6:45 PM
All Replies
-
Tuesday, April 24, 2012 1:15 PMWhen/if it freezes, you can take a snapshot with debugger and check threads to see what exactly is locked. The same applies to access violation (crashes) - you can set debugger to break on exception and call stack will give you an idea about faulty module.
-
Tuesday, April 24, 2012 1:48 PM
Great idea! Thanks. If I can make it work, I'll post here.
Stevens Miller
-
Wednesday, April 25, 2012 4:41 PM
Roman, I think I am not following your advice correctly. I started graphedt, then used "Debug/Attach to Process" in VS2010-Express. I checked all exceptions under "Debug/Exceptions" and then ran my graph, which hung graphedt as usual. There is a long list of modules shown under "Debug/Windows/Modules," but nothing in the Breakpoints or Call Stack. The Output window shows this:
'graphedt.exe': Loaded 'C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\graphedt.exe', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ntdll.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\kernel32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\KernelBase.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\advapi32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\msvcrt.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\sechost.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\rpcrt4.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\sspicli.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\cryptbase.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\gdi32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\user32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\lpk.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\usp10.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\mfc42.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ole32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\oleaut32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\odbc32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\comdlg32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\shlwapi.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.windows.common-controls_6595b64144ccf1df_5.82.7601.17514_none_ec83dffa859149af\comctl32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\shell32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\version.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\quartz.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\winmm.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\imm32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\msctf.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\odbcint.dll', Binary was not built with debug information.
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\uxtheme.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Program Files (x86)\McAfee\SiteAdvisor\sahook.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\dwmapi.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\cryptsp.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\rsaenh.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\RpcRtRemote.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\clbcatq.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_41e6975e2bd6f2b2\comctl32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Program Files (x86)\Common Files\microsoft shared\ink\tiptsf.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\WindowsCodecs.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\apphelp.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\EhStorShell.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\setupapi.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\cfgmgr32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\devobj.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\propsys.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ntshrui.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\srvcli.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\cscapi.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\slc.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ntmarta.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\Wldap32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\SearchFolder.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\xmllite.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\linkinfo.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\profapi.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\StructuredQuery.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\secur32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\mssprxy.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\thumbcache.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\psapi.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\shdocvw.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ieframe.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\oleacc.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\iertutil.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ksproxy.ax', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\ksuser.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\d3d9.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\d3d8thk.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\wintrust.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\crypt32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\msasn1.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\devenum.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\vidcap.ax', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\Kswdmcap.ax', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\qedit.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\msvfw32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.windows.gdiplus_6595b64144ccf1df_1.1.7601.17514_none_72d18a4386696c80\GdiPlus.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\lvcodec2.dll', Binary was not built with debug information.
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\igdumd32.dll', Cannot find or open the PDB file
'graphedt.exe': Loaded 'C:\Windows\SysWOW64\dxva2.dll', Cannot find or open the PDB file
The thread 'Win32 Thread' (0x2728) has exited with code 0 (0x0).
'graphedt.exe': Unloaded 'C:\Program Files (x86)\Common Files\microsoft shared\ink\tiptsf.dll'
The thread 'Win32 Thread' (0x2038) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x26ac) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x1368) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x2d48) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x2aa4) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x680) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x2b54) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x1c60) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x1a20) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x214c) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x163c) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x8e0) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x22dc) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x1d28) has exited with code 0 (0x0).
The thread 'Win32 Thread' (0x2270) has exited with code 0 (0x0)
I suspect I am doing this wrong. Can you see where?Stevens Miller
-
Wednesday, April 25, 2012 4:54 PMHaving done this, the application should be still running. Now it is time to runs and stop the graph to eventually make it unresponsive. The application will either throw an exception and the debugger will break on it, or it will freeze and then it's your turn to pause it in debugger and check the state.
-
Wednesday, April 25, 2012 5:07 PMIt behaves exactly as you described. I run the graph, stop the graph, and graphedt becomes unresponsive. Nothing happens after that. Can you please tell me how to pause it in the debugger? That's a new operation for me.
Stevens Miller http://www.withoutsupervision.com
-
Wednesday, April 25, 2012 5:10 PM
Ah! "Debug/Break All" seems to pause it. Here's what I get in the Call Stack:
> user32.dll!772278d7()
[Frames below may be incorrect and/or missing, no symbols loaded for user32.dll]
user32.dll!772278d7()
user32.dll!7722790d()
shell32.dll!75709acf()
shlwapi.dll!766643c0()
kernel32.dll!7732339a()
ntdll.dll!77d89ef2()
ntdll.dll!77d89ec5()Stevens Miller http://www.withoutsupervision.com
-
Wednesday, April 25, 2012 5:16 PM
With exception debugger brings you exactly to the point of interest. However when you pause the process manually, it is different: it pops you up a random thread, such as with most recent activity (which might be a system background thread whatsoever). So you need to look around and check other threads too, which have possibly items on stack that indicate the freeze condition.
Keep in mind you can set debugger to download symbol information for Microsoft DLLs and have symbols on call stack, not just addresses.
http://alax.info/blog/tag/directshow
- Edited by Roman RyltsovMVP Wednesday, April 25, 2012 5:17 PM
-
Wednesday, April 25, 2012 5:40 PMRight again! I see one main thread and 17 worker threads. Nothing seems to stand out. The call stacks for all but two of those threads end in ntdll.dll. The other two end in user32.dll.
Stevens Miller http://www.withoutsupervision.com
-
Wednesday, April 25, 2012 5:58 PM
I downloaded the symbols. Here's the list of threads and where each one is after graphedt hangs and I pause the process:
Unflagged 10960 0 Main Thread Main Thread _NtWaitForSingleObject@12 Normal
Unflagged 848 0 Worker Thread _TppWaiterpThread@4 _ZwWaitForMultipleObjects@20 Normal
Unflagged 10464 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 9172 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 7928 0 RPC Thread RPC Callback Thread CROIDTable::WorkerThreadLoop Normal
Unflagged 12156 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 1520 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 7304 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 9292 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged > 5464 0 Worker Thread WrapperThreadProc _NtUserGetMessage@16 Normal
Unflagged 6872 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 2728 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 11076 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 11200 0 Worker Thread ObjectThread _NtUserGetMessage@16 Normal
Unflagged 6084 0 Worker Thread CBoxNetDoc::NotificationThread _ZwWaitForMultipleObjects@20 Normal
Unflagged 5240 0 Worker Thread DllRefCountSafeThreadThunk _ZwWaitForMultipleObjects@20 Normal
Unflagged 9200 0 Worker Thread VMR9::CVideoMixer::MixerThreadProc _ZwWaitForMultipleObjects@20 Normal
Unflagged 9796 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 11392 0 Worker Thread _TppWorkerThread@4 _NtWaitForWorkViaWorkerFactory@8 Normal
Unflagged 5964 0 Worker Thread CBatchFilterI::LHBatchWorkerThread _NtWaitForSingleObject@12 Normal
Unflagged 4944 0 Worker Thread wmt_CSSEShaderCode::ProcessPositionAndColors _NtWaitForSingleObject@12 Normal
Unflagged 9228 0 Worker Thread wmt_CSSEShaderCode::ProcessPositionAndColors _NtWaitForSingleObject@12 Normal
Unflagged 4412 0 Worker Thread wmt_CSSEShaderCode::ProcessPositionAndColors _NtWaitForSingleObject@12 Normal
Unflagged 2272 0 Worker Thread CBaseReferenceClock::AdviseThreadFunction _NtWaitForSingleObject@12 Time Critical
Unflagged 440 0 Worker Thread CKsClockF::ClockThread _NtWaitForSingleObject@12 Highest
Unflagged 11428 0 Worker Thread CAMThread::InitialThreadProc _NtWaitForSingleObject@12 Normal
Unflagged 4812 0 Worker Thread CAsyncItemHandler::AsyncItemProc _ZwWaitForMultipleObjects@20 NormalStevens Miller http://www.withoutsupervision.com


