-
Notifications
You must be signed in to change notification settings - Fork 597
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add "b" prefix when using DREQ_GET_MEM_BINARY #3902
base: master
Are you sure you want to change the base?
Conversation
It appears older LLDB is unhappy with this. |
Hmmm, the failing tests also break on latest LLDB too. It seems like LLDB doesn't skip the first character even though the protocol specification says it's required. Not really sure what to do about that other than disabling binary memory read/write command support, since LLDB appears to have a fallback path for when that isn't supported. |
So GDB implemented this in a completely incompatible way to LLDB? |
Yes, OK, that's what they did. @khang06 can you contact the GDB people or file a GDB bug and tell them that they've implemented this incompatibly with LLDB and now all third-party gdbservers that implemented this in an LLDB-compatible way are broken? It would be nice if they could fix this by accepting output either with or without the 'b', but that doesn't really work because 'b' could be legitimate data :-(. If we have to we can work around this in rr by having an "LLDB mode" flag and setting that flag automatically by detecting use of LLDB-specific extensions, but it would really suck for all already-installed versions of rr to not work with gdb 16.1. Seems better to issue a gdb 16.1 point release as soon as possible. |
Yeah so I think we should ask the GDB folks if they are willing to change to be LLDB compatible here. |
I'm doing this. |
I think that's there to differentiate successful cases from the "E" prefix error cases according to the protocol page. |
Good point, that makes sense. |
Fixes #3901.
GDB errors out if the response doesn't start with "b" (see https://github.com/bminor/binutils-gdb/blob/master/gdb/remote.c#L9739). This works on GDB 16.1 and LLDB 19.1.7, but I haven't tested anything else.