I am able to make debugserver return "$#00" to the QStartNoAckMode and get it 
to work:

% ll a.out
Current executable set to 'a.out' (x86_64).
(lldb) log enable gdb-remote packets
(lldb) b main
Breakpoint 1: where = a.out`main + 64 at main.c:11, address = 0x0000000100000aa0
(lldb) r
<lldb.driver.main-thread> <   1> send packet: +
<lldb.driver.main-thread> <  19> send packet: $QStartNoAckMode#b0
<lldb.driver.main-thread> <   1> read packet: +
<lldb.driver.main-thread> <   4> read packet: $#00
<lldb.driver.main-thread> <   1> send packet: +
<lldb.driver.main-thread> <  26> send packet: $QThreadSuffixSupported#e4
<lldb.driver.main-thread> <   1> read packet: +
<lldb.driver.main-thread> <   6> read packet: $OK#9a
<lldb.driver.main-thread> <   1> send packet: +
<lldb.driver.main-thread> <  27> send packet: $QListThreadsInStopReply#21
<lldb.driver.main-thread> <   1> read packet: +
<lldb.driver.main-thread> <   6> read packet: $OK#9a
<lldb.driver.main-thread> <   1> send packet: +
<lldb.driver.main-thread> <  13> send packet: $qHostInfo#9b
<lldb.driver.main-thread> <   1> read packet: +
<lldb.driver.main-thread> < 122> read packet: 
$cputype:16777223;cpusubtype:3;ostype:macosx;watchpoint_exceptions_received:after;vendor:apple;endian:little;ptrsize:8;#16
<lldb.driver.main-thread> <   1> send packet: +


Not sure what it going on, but the current GDBRemoteCommunicationClient works 
for me. You will need to trace through to see what is else is failing.

On Dec 10, 2013, at 11:21 AM, Ed Maste <[email protected]> wrote:

>> This actually does fix attaching to GDB servers that don't support 
>> QStartNoAckMode and was the main reason for making this fix!
> 
> Ok.  I'm trying to use lldb against QEMU's GDB server, and fail while
> trying the initial handshake.
> 
> Debug log shows:
> 
> (lldb) log enable gdb-remote packets
> (lldb) gdb-remote localhost:1234
> <   1> send packet: +
> history[1] tid=0x18a33 <   1> send packet: +
> <  19> send packet: $QStartNoAckMode#b0
> <   1> read packet: +
> <   4> read packet: $#00
> <   1> send packet: +
> error: failed to get reply to handshake packet
> 
> As far as I can tell the packet exchange looks like what I'd expect.

_______________________________________________
lldb-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits

Reply via email to