qtc-sourcetrail
qtc-sourcetrail copied to clipboard
"Send Location to Sourctrail" is slow, hangs Qt Creator IDE for 3 seconds
In Qt Creator, if I trigger "Send Location to Sourctrail", Qt Creator freezes for 3 seconds, before Qt Creator unfreezes and Sourcetrail loads to the correct path (if the window is open).
I debugged Qt Creator in Visual Studio, paused it during the freeze, and got the following stack:
ntdll.dll!_NtWaitForSingleObject@12() Unknown
mswsock.dll!SockWaitForSingleObject() Unknown
mswsock.dll!_WSPSelect@24() Unknown
ws2_32.dll!select() Unknown
> Qt5Network.dll!QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) Line 1558 C++
Qt5Network.dll!QNativeSocketEngine::waitForWrite(int msecs, bool * timedOut) Line 1070 C++
Qt5Network.dll!QAbstractSocket::waitForConnected(int msecs) Line 2187 C++
Sourcetrail4.dll!61bf36d0() Unknown
Sourcetrail4.dll![Frames below may be incorrect and/or missing, no symbols loaded for Sourcetrail4.dll] Unknown
Sourcetrail4.dll!61bf3953() Unknown
msecs is 30000 (30 seconds) in waitForConnected, and 29993 (just below 30 seconds) in waitForWrite. I suspect that msecs was actually decremented within waitForConnected before it was passed into waitForWrite, but the debugger doesn't see the modified value because it was only modified in a register and not the argument stack, or something.
I took a minidump: qtcreator sourcetrail freeze.mini.dmp.zip. Contact me if you need the full 650MB heap dump.
Versions
- Windows 10 x64
- Qt Creator 4.12.1 (32-bit)
- Sourcetrail plugin 0.8.3
- Sourcetrail Version 2020.1.117 - 64 bit.
I tried poking at Port 6667 (sourcetrail server) using netcat in WSL. It connects or fails immediately, depending on if Sourcetrail is open or not.
nyanpasu@win /mnt/c/Users/nyanpasu/src/qt-everywhere-src-5.14.2> nc -zv localhost 6667
Connection to localhost 6667 port [tcp/ircd] succeeded!
(close sourcetrail)
nyanpasu@win /mnt/c/Users/nyanpasu/src/qt-everywhere-src-5.14.2> nc -zv localhost 6667
nc: connect to localhost port 6667 (tcp) failed: Connection refused
However, either way, Qt Creator freezes for almost exactly 3 seconds.