Add lldb-gdbserver support for Linux x86_64.

This change brings in lldb-gdbserver (llgs) specifically for Linux x86_64.
(More architectures coming soon).

Not every debugserver option is covered yet.  Currently
the lldb-gdbserver command line can start unattached,
start attached to a pid (process-name attach not supported yet),
or accept lldb attaching and launching a process or connecting
by process id.

The history of this large change can be found here:
https://github.com/tfiala/lldb/tree/dev-tfiala-native-protocol-linux-x86_64

Until mid/late April, I was not sharing the work and continued
to rebase it off of head (developed via id tfiala@google.com).  I switched over to
user todd.fiala@gmail.com in the middle, and once I went to github, I did
merges rather than rebasing so I could share with others.

llvm-svn: 212069
This commit is contained in:
Todd Fiala
2014-06-30 21:05:18 +00:00
parent b201cf8883
commit af245d115b
85 changed files with 12074 additions and 617 deletions

View File

@@ -527,12 +527,10 @@ RecurseCopy_Callback (void *baton,
case FileSpec::eFileTypeInvalid:
case FileSpec::eFileTypeOther:
case FileSpec::eFileTypeUnknown:
default:
rc_baton->error.SetErrorStringWithFormat("invalid file detected during copy: %s", src.GetPath().c_str());
return FileSpec::eEnumerateDirectoryResultQuit; // got an error, bail out
break;
default:
return FileSpec::eEnumerateDirectoryResultQuit; // unsupported file type, bail out
break;
}
}
@@ -1189,6 +1187,27 @@ Platform::CalculateMD5 (const FileSpec& file_spec,
return false;
}
Error
Platform::LaunchNativeProcess (
ProcessLaunchInfo &launch_info,
lldb_private::NativeProcessProtocol::NativeDelegate &native_delegate,
NativeProcessProtocolSP &process_sp)
{
// Platforms should override this implementation if they want to
// support lldb-gdbserver.
return Error("unimplemented");
}
Error
Platform::AttachNativeProcess (lldb::pid_t pid,
lldb_private::NativeProcessProtocol::NativeDelegate &native_delegate,
NativeProcessProtocolSP &process_sp)
{
// Platforms should override this implementation if they want to
// support lldb-gdbserver.
return Error("unimplemented");
}
void
Platform::SetLocalCacheDirectory (const char* local)
{