我试图找出我们使用的旧版 Windows 脚本组件的问题。查看 WinDbg 中的几个内存转储,我发现很多线程,实际上看起来 50% 的应用程序线程都在等待另一个线程完成。该线程有一个长堆栈,位于下方。这个线程正在使用 RegExp 对象做一些工作,所以我现在的问题是 RegExp 线程安全吗?
看起来它肯定不是来自等待它的所有其他线程,但我想在我下结论之前确定并努力在网上找到任何真实信息。
vbscript!RegExpExec::PopGreedyStar+3a
vbscript!RegExpExec::FExecAux+639
vbscript!RegExpExec::FExec+1f
vbscript!RegExpExec::Exec+5a0
vbscript!RegExpExec::ReplaceUsingString+2d
vbscript!CRegExp::OrigReplace+14e
vbscript!CRegExp::Replace+80
oleaut32!DispCallFunc+16a
oleaut32!CTypeInfo2::Invoke+234
vbscript!CRegExp::Invoke+24
vbscript!IDispatchInvoke2+b2
vbscript!IDispatchInvoke+59
vbscript!InvokeDispatch+13a
vbscript!InvokeByName+42
vbscript!CScriptRuntime::RunNoEH+22b2
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CScriptRuntime::RunNoEH+1e02
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CSession::Execute+c8
vbscript!NameTbl::InvokeEx+516
scrobj!DoInvoke+2c
scrobj!NameTable::InvokeEx+e6
scrobj!ComDispatchEx::InvokeEx+25
scrobj!DoInvoke+2c
scrobj!InvokeMember+a3
scrobj!NameTable::InvokeEx+aa
scrobj!ComDexHandler::Inner::InvokeEx+25
vbscript!IDispatchExInvokeEx2+a9
vbscript!IDispatchExInvokeEx+56
vbscript!InvokeDispatch+101
vbscript!InvokeByName+42
vbscript!CScriptRuntime::RunNoEH+234c
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CScriptRuntime::RunNoEH+1bbd
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CSession::Execute+c8
vbscript!NameTbl::InvokeEx+516
vbscript!IDispatchExInvokeEx2+a9
vbscript!IDispatchExInvokeEx+56
vbscript!InvokeDispatch+101
vbscript!InvokeByName+42
vbscript!CScriptRuntime::RunNoEH+234c
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CScriptRuntime::RunNoEH+1bbd
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CScriptRuntime::RunNoEH+1bbd
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CScriptRuntime::RunNoEH+1bbd
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CSession::Execute+c8
vbscript!NameTbl::InvokeEx+516
vbscript!IDispatchExInvokeEx2+a9
vbscript!IDispatchExInvokeEx+56
vbscript!InvokeDispatch+101
vbscript!InvokeByName+42
vbscript!CScriptRuntime::RunNoEH+234c
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CScriptRuntime::RunNoEH+1beb
vbscript!CScriptRuntime::Run+62
vbscript!CScriptEntryPoint::Call+51
vbscript!CSession::Execute+c8
vbscript!COleScript::ExecutePendingScripts+144
vbscript!COleScript::SetScriptState+14d