[Lldb-commits] [PATCH] D13859: [LLDB][LLGS Test] Check length of register, only when its available

Greg Clayton via lldb-commits lldb-commits at lists.llvm.org
Tue Oct 20 10:16:45 PDT 2015


clayborg requested changes to this revision.
clayborg added a comment.
This revision now requires changes to proceed.

Is there a list of error codes and what they mean for the GDB remote protocol? debugserver returns random errors and doesn't abide by any specific error codes. Quote from some GDB remote protocol docs I found:

  The error response returned for some packets includes a two character error number. That number is not well defined.

So we can't rely on specific responses unless you verify that the error is coming from a specific GDB server. In order to do this, we would need to add a qGDBServerInfo packet that could return a name, version info, etc:

  $qGDBServerInfo#00
  $name:debugserver;version:123.2.3;

The real fix is to fix the GDB server to not have it return this register if it is not available.


Repository:
  rL LLVM

http://reviews.llvm.org/D13859





More information about the lldb-commits mailing list