I'm not too familiar with the GDB remote plugin, but it looks like ProcessGDBRemote::Resume() is being called, which is somewhat surprising because at first glance it doesn't look like anything in UpdateThreadList() should be calling that.
If you can, I'd recommend making a debug build of lldb and starting it with another debugger (gdb) attached and set a breakpoint in ProcessGDBRemote::DoResume() to see who calls it and why. If you find out more information, feel free to log a defect at http://llvm.org/bugs/enter_bug.cgi?product=lldb Cheers, Dan From: [email protected] [mailto:[email protected]] On Behalf Of Benjamin Kemper Sent: Tuesday, January 22, 2013 9:56 AM To: [email protected] Subject: [lldb-dev] LLDB sends continue right after connection (gdb-remote) Hi, I've implemented a debugger backend that implements the gdb remote protocol, and I've noticed that while communication seems OK, right after the connection from LLDB to my implementation the process resumes automatically. I'm guessing that this is not the expected behaviour, but when looking at the logs I did see LLDB sending the "$vCont" packet without any user interaction. I used the following command to connect: process connect -p gdb-remote connect://localhost:52168 And this is an excerpt from the logs: ProcessGDBRemote::UpdateThreadList (pid = 1799) 0x7fe2aa2268b0: ThreadGDBRemote::ThreadGDBRemote (pid = 1799, tid = 0x0707) < 22> send packet: $qThreadStopInfo707#99 size_t GDBRemoteCommunication::WaitForPacketWithTimeoutMicroSecondsNoLock(StringExtractorGDBRemote &, uint32_t): Read (buffer, (sizeof(buffer), timeout_usec = 0xf4240, status = success, error = (null)) => bytes_read = 1 < 1> read packet: + size_t GDBRemoteCommunication::WaitForPacketWithTimeoutMicroSecondsNoLock(StringExtractorGDBRemote &, uint32_t): Read (buffer, (sizeof(buffer), timeout_usec = 0xf4240, status = success, error = (null)) => bytes_read = 4 < 4> read packet: $#00 < 1> send packet: + error: failed to get response for 'qThreadStopInfo707' ProcessGDBRemote::Resume() ProcessGDBRemote::AsyncThread (arg = 0x7fe2ab00d000, pid = 1799) Got an event of type: 1... ProcessGDBRemote::AsyncThread (arg = 0x7fe2ab00d000, pid = 1799) got eBroadcastBitAsyncContinue: vCont;c:0707 GDBRemoteCommunicationClient::SendContinuePacketAndWaitForResponse () GDBRemoteCommunicationClient::SendContinuePacketAndWaitForResponse () sending continue packet: vCont;c:0707 < 16> send packet: $vCont;c:0707#b0 size_t GDBRemoteCommunication::WaitForPacketWithTimeoutMicroSecondsNoLock(StringExtractorGDBRemote &, uint32_t): Read (buffer, (sizeof(buffer), timeout_usec = 0xf4240, status = success, error = (null)) => bytes_read = 1 < 1> read packet: + GDBRemoteCommunicationClient::SendContinuePacketAndWaitForResponse () WaitForPacket(vCont;c:0707) size_t GDBRemoteCommunication::WaitForPacketWithTimeoutMicroSecondsNoLock(StringExtractorGDBRemote &, uint32_t): Read (buffer, (sizeof(buffer), timeout_usec = 0xffffffff, status = success, error = (null)) => bytes_read = 7 < 7> read packet: $W00#b7 < 1> send packet: + GDBRemoteCommunicationClient::SendContinuePacketAndWaitForResponse () got packet: W00 GDBRemoteCommunicationClient::SendContinuePacketAndWaitForResponse () => exited ProcessGDBRemote::AsyncThread (arg = 0x7fe2ab00d000, pid = 1799) thread exiting... Any ideas why this is happening? Thanks, Benjamin.
_______________________________________________ lldb-dev mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev
