First pass at mach-o core file support is in. It currently works for x86_64 
user space programs. The core file support is implemented by making a process
plug-in that will dress up the threads and stack frames by using the core file
memory. 

Added many default implementations for the lldb_private::Process functions so
that plug-ins like the ProcessMachCore don't need to override many many 
functions only to have to return an error.

Added new virtual functions to the ObjectFile class for extracting the frozen
thread states that might be stored in object files. The default implementations
return no thread information, but any platforms that support core files that
contain frozen thread states (like mach-o) can make a module using the core
file and then extract the information. The object files can enumerate the 
threads and also provide the register state for each thread. Since each object
file knows how the thread registers are stored, they are responsible for 
creating a suitable register context that can be used by the core file threads.

Changed the process CreateInstace callbacks to return a shared pointer and
to also take an "const FileSpec *core_file" parameter to allow for core file
support. This will also allow for lldb_private::Process subclasses to be made
that could load crash logs. This should be possible on darwin where the crash
logs contain all of the stack frames for all of the threads, yet the crash
logs only contain the registers for the crashed thrad. It should also allow
some variables to be viewed for the thread that crashed.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@150154 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/lldb.cpp b/source/lldb.cpp
index 18c9c19..6ee3e1c 100644
--- a/source/lldb.cpp
+++ b/source/lldb.cpp
@@ -51,6 +51,8 @@
 #include "Plugins/Platform/MacOSX/PlatformRemoteiOS.h"
 #endif
 
+#include "Plugins/Process/mach-core/ProcessMachCore.h"
+
 #if defined (__linux__)
 #include "Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.h"
 #include "Plugins/Platform/Linux/PlatformLinux.h"
@@ -113,6 +115,7 @@
         ObjectFileMachO::Initialize();
         ProcessKDP::Initialize();
         ProcessGDBRemote::Initialize();
+        ProcessMachCore::Initialize();
         SymbolVendorMacOSX::Initialize();
         PlatformMacOSX::Initialize();
         PlatformRemoteiOS::Initialize();
@@ -183,6 +186,7 @@
     AppleObjCRuntimeV1::Terminate();
     ObjectContainerUniversalMachO::Terminate();
     ObjectFileMachO::Terminate();
+    ProcessMachCore::Terminate();
     ProcessKDP::Terminate();
     ProcessGDBRemote::Terminate();
     SymbolVendorMacOSX::Terminate();