<div>Hi,</div><div><br></div><div>I would like to ask you to review and land the following patch.</div><div>The patch contains fixes for Linux platform, it's somewhat huge, but all changes are merely adding missing arguments or changing parameter types. The list of affected files:</div>
<div>Index: source/Plugins/Platform/Linux/PlatformLinux.cpp</div><div><div>Index: source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.h</div><div>Index: source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp</div>
<div>Index: source/Plugins/Process/Linux/ProcessLinux.cpp</div><div>Index: source/Plugins/Process/Linux/ProcessLinux.h</div><div>Index: source/Plugins/Process/Linux/ProcessMonitor.cpp</div><div>Index: source/Plugins/Process/POSIX/POSIXThread.h</div>
<div>Index: source/Plugins/Process/POSIX/ProcessPOSIX.cpp</div><div>Index: source/Plugins/Process/POSIX/RegisterContext_i386.cpp</div><div>Index: source/Plugins/Process/POSIX/ProcessPOSIXLog.cpp</div><div>Index: source/Plugins/Process/POSIX/RegisterContext_x86_64.cpp</div>
<div>Index: source/Plugins/Process/POSIX/ProcessPOSIXLog.h</div><div>Index: source/Plugins/Process/POSIX/POSIXThread.cpp</div><div>Index: source/Plugins/Process/Utility/StopInfoMachException.cpp</div></div><div><br></div>
<div><br></div><div><br></div><div><br></div><div>Index: source/Plugins/Platform/Linux/PlatformLinux.cpp</div><div>===================================================================</div><div>--- source/Plugins/Platform/Linux/PlatformLinux.cpp<span class="Apple-tab-span" style="white-space:pre"> </span>(revision 151036)</div>
<div>+++ source/Plugins/Platform/Linux/PlatformLinux.cpp<span class="Apple-tab-span" style="white-space:pre">   </span>(working copy)</div><div>@@ -128,7 +128,8 @@</div><div>         {</div><div>             error = m_remote_platform_sp->ResolveExecutable (exe_file,</div>
<div>                                                              exe_arch,</div><div>-                                                             exe_module_sp);</div><div>+                                                             exe_module_sp,</div>
<div>+                                                             NULL);</div><div>         }</div><div>         else</div><div>         {</div><div>@@ -152,6 +153,7 @@</div><div>                                                  0, </div>
<div>                                                  exe_module_sp, </div><div>                                                  NULL, </div><div>+                                                 NULL,</div><div>                                                  NULL);</div>
<div>         </div><div>             if (exe_module_sp->GetObjectFile() == NULL)</div><div>@@ -180,6 +182,7 @@</div><div>                                                      0, </div><div>                                                      exe_module_sp, </div>
<div>                                                      NULL, </div><div>+                                                     NULL,</div><div>                                                      NULL);</div><div>                 // Did we find an executable using one of the </div>
<div>                 if (error.Success())</div><div>@@ -367,7 +370,9 @@</div><div>         {</div><div>             debugger.GetTargetList().SetSelectedTarget(target);</div><div> </div><div>-            process_sp = target->CreateProcess (listener, attach_info.GetProcessPluginName());</div>
<div>+            process_sp = target->CreateProcess (listener,</div><div>+                                                attach_info.GetProcessPluginName(),</div><div>+                                                NULL);</div>
<div> </div><div>             if (process_sp)</div><div>                 error = process_sp->Attach (attach_info);</div><div>Index: source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.h</div><div>===================================================================</div>
<div>--- source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.h<span class="Apple-tab-span" style="white-space:pre">       </span>(revision 151036)</div><div>+++ source/Plugins/DynamicLoader/POSIX-DYLD/AuxVector.h<span class="Apple-tab-span" style="white-space:pre">     </span>(working copy)</div>
<div>@@ -15,7 +15,7 @@</div><div> #include <vector></div><div> </div><div> // Other libraries and framework includes</div><div>-#include "lldb/lldb-forward-rtti.h"</div><div>+#include "lldb/lldb-forward.h"</div>
<div> </div><div> namespace lldb_private {</div><div> class DataExtractor;</div><div>Index: source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp</div><div>===================================================================</div>
<div>--- source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp<span class="Apple-tab-span" style="white-space:pre">        </span>(revision 151036)</div><div>+++ source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp<span class="Apple-tab-span" style="white-space:pre">      </span>(working copy)</div>
<div>@@ -307,7 +307,7 @@</div><div>         return thread_plan_sp;</div><div> </div><div>     SymbolContextList target_symbols;</div><div>-    Target &target = thread.GetProcess().GetTarget();</div><div>+    Target &target = thread.GetProcess()->GetTarget();</div>
<div>     ModuleList &images = target.GetImages();</div><div> </div><div>     images.FindSymbolsWithNameAndType(sym_name, eSymbolTypeCode, target_symbols);</div><div>Index: source/Plugins/Process/Linux/ProcessLinux.cpp</div>
<div>===================================================================</div><div>--- source/Plugins/Process/Linux/ProcessLinux.cpp<span class="Apple-tab-span" style="white-space:pre">   </span>(revision 151036)</div><div>
+++ source/Plugins/Process/Linux/ProcessLinux.cpp<span class="Apple-tab-span" style="white-space:pre">        </span>(working copy)</div><div>@@ -31,10 +31,10 @@</div><div> //------------------------------------------------------------------------------</div>
<div> // Static functions.</div><div> </div><div>-Process*</div><div>-ProcessLinux::CreateInstance(Target& target, Listener &listener)</div><div>+ProcessSP</div><div>+ProcessLinux::CreateInstance(Target &target, Listener &listener, const FileSpec *)</div>
<div> {</div><div>-    return new ProcessLinux(target, listener);</div><div>+    return ProcessSP(new ProcessLinux(target, listener));</div><div> }</div><div> </div><div> void</div><div>@@ -105,8 +105,10 @@</div><div>     // FIXME: We should be using tid, not pid.</div>
<div>     assert(m_monitor);</div><div>     ThreadSP thread_sp (old_thread_list.FindThreadByID (GetID(), false));</div><div>-    if (!thread_sp)</div><div>-        thread_sp.reset(new POSIXThread(*this, GetID()));</div><div>
+    if (!thread_sp) {</div><div>+        ProcessSP me = this->shared_from_this();</div><div>+        thread_sp.reset(new POSIXThread(me, GetID()));</div><div>+    }</div><div> </div><div>     if (log && log->GetMask().Test(POSIX_LOG_VERBOSE))</div>
<div>         log->Printf ("ProcessLinux::%s() updated pid = %i", __FUNCTION__, GetID());</div><div>Index: source/Plugins/Process/Linux/ProcessLinux.h</div><div>===================================================================</div>
<div>--- source/Plugins/Process/Linux/ProcessLinux.h<span class="Apple-tab-span" style="white-space:pre">       </span>(revision 151036)</div><div>+++ source/Plugins/Process/Linux/ProcessLinux.h<span class="Apple-tab-span" style="white-space:pre">     </span>(working copy)</div>
<div>@@ -30,9 +30,10 @@</div><div>     //------------------------------------------------------------------</div><div>     // Static functions.</div><div>     //------------------------------------------------------------------</div>
<div>-    static Process*</div><div>+    static lldb::ProcessSP</div><div>     CreateInstance(lldb_private::Target& target,</div><div>-                   lldb_private::Listener &listener);</div><div>+                   lldb_private::Listener &listener,</div>
<div>+                   const lldb_private::FileSpec *);</div><div> </div><div>     static void</div><div>     Initialize();</div><div>Index: source/Plugins/Process/Linux/ProcessMonitor.cpp</div><div>===================================================================</div>
<div>--- source/Plugins/Process/Linux/ProcessMonitor.cpp<span class="Apple-tab-span" style="white-space:pre">   </span>(revision 151036)</div><div>+++ source/Plugins/Process/Linux/ProcessMonitor.cpp<span class="Apple-tab-span" style="white-space:pre"> </span>(working copy)</div>
<div>@@ -966,6 +966,7 @@</div><div> {</div><div>     ProcessMonitor *monitor = args->m_monitor;</div><div>     ProcessLinux &process = monitor->GetProcess();</div><div>+    lldb::ProcessSP processSP = process.shared_from_this();</div>
<div>     const char **argv = args->m_argv;</div><div>     const char **envp = args->m_envp;</div><div>     const char *stdin_path = args->m_stdin_path;</div><div>@@ -1104,7 +1105,7 @@</div><div>     // Update the process thread list with this new thread.</div>
<div>     // FIXME: should we be letting UpdateThreadList handle this?</div><div>     // FIXME: by using pids instead of tids, we can only support one thread.</div><div>-    inferior.reset(new POSIXThread(process, pid));</div>
<div>+    inferior.reset(new POSIXThread(processSP, pid));</div><div>     if (log)</div><div>         log->Printf ("ProcessMonitor::%s() adding pid = %i", __FUNCTION__, pid);</div><div>     process.GetThreadList().AddThread(inferior);</div>
<div>@@ -1166,6 +1167,7 @@</div><div> </div><div>     ProcessMonitor *monitor = args->m_monitor;</div><div>     ProcessLinux &process = monitor->GetProcess();</div><div>+    lldb::ProcessSP processSP = process.shared_from_this();</div>
<div>     lldb::ThreadSP inferior;</div><div>     LogSP log (ProcessPOSIXLog::GetLogIfAllCategoriesSet (POSIX_LOG_PROCESS));</div><div> </div><div>@@ -1191,7 +1193,7 @@</div><div>     }</div><div> </div><div>     // Update the process thread list with the attached thread.</div>
<div>-    inferior.reset(new POSIXThread(process, pid));</div><div>+    inferior.reset(new POSIXThread(processSP, pid));</div><div>     if (log)</div><div>         log->Printf ("ProcessMonitor::%s() adding tid = %i", __FUNCTION__, pid);</div>
<div>     process.GetThreadList().AddThread(inferior);</div><div>Index: source/Plugins/Process/POSIX/POSIXThread.h</div><div>===================================================================</div><div>--- source/Plugins/Process/POSIX/POSIXThread.h<span class="Apple-tab-span" style="white-space:pre">      </span>(revision 151036)</div>
<div>+++ source/Plugins/Process/POSIX/POSIXThread.h<span class="Apple-tab-span" style="white-space:pre">        </span>(working copy)</div><div>@@ -29,7 +29,7 @@</div><div>     : public lldb_private::Thread</div><div> {</div><div>
 public:</div><div>-    POSIXThread(lldb_private::Process &process, lldb::tid_t tid);</div><div>+    POSIXThread(lldb::ProcessSP &process, lldb::tid_t tid);</div><div> </div><div>     virtual ~POSIXThread();</div>
<div> </div><div>Index: source/Plugins/Process/POSIX/ProcessPOSIX.cpp</div><div>===================================================================</div><div>--- source/Plugins/Process/POSIX/ProcessPOSIX.cpp<span class="Apple-tab-span" style="white-space:pre">        </span>(revision 151036)</div>
<div>+++ source/Plugins/Process/POSIX/ProcessPOSIX.cpp<span class="Apple-tab-span" style="white-space:pre">     </span>(working copy)</div><div>@@ -500,8 +500,10 @@</div><div>     // FIXME: We should be using tid, not pid.</div>
<div>     assert(m_monitor);</div><div>     ThreadSP thread_sp (old_thread_list.FindThreadByID (GetID(), false));</div><div>-    if (!thread_sp)</div><div>-        thread_sp.reset(new POSIXThread(*this, GetID()));</div><div>
+    if (!thread_sp) {</div><div>+        ProcessSP me = this->shared_from_this();</div><div>+        thread_sp.reset(new POSIXThread(me, GetID()));</div><div>+    }</div><div> </div><div>     if (log && log->GetMask().Test(POSIX_LOG_VERBOSE))</div>
<div>         log->Printf ("ProcessPOSIX::%s() updated pid = %i", __FUNCTION__, GetID());</div><div>Index: source/Plugins/Process/POSIX/RegisterContext_i386.cpp</div><div>===================================================================</div>
<div>--- source/Plugins/Process/POSIX/RegisterContext_i386.cpp<span class="Apple-tab-span" style="white-space:pre">     </span>(revision 151036)</div><div>+++ source/Plugins/Process/POSIX/RegisterContext_i386.cpp<span class="Apple-tab-span" style="white-space:pre">   </span>(working copy)</div>
<div>@@ -364,7 +364,8 @@</div><div> ProcessMonitor &</div><div> RegisterContext_i386::GetMonitor()</div><div> {</div><div>-    ProcessPOSIX *process = static_cast<ProcessPOSIX*>(CalculateProcess());</div><div>+    ProcessSP base = CalculateProcess();</div>
<div>+    ProcessPOSIX *process = static_cast<ProcessPOSIX*>(base.get());</div><div>     return process->GetMonitor();</div><div> }</div><div> </div><div>Index: source/Plugins/Process/POSIX/ProcessPOSIXLog.cpp</div>
<div>===================================================================</div><div>--- source/Plugins/Process/POSIX/ProcessPOSIXLog.cpp<span class="Apple-tab-span" style="white-space:pre">        </span>(revision 151036)</div><div>
+++ source/Plugins/Process/POSIX/ProcessPOSIXLog.cpp<span class="Apple-tab-span" style="white-space:pre">     </span>(working copy)</div><div>@@ -44,44 +44,38 @@</div><div> }</div><div> </div><div> void</div><div>-ProcessPOSIXLog::DisableLog (Args &args, Stream *feedback_strm)</div>
<div>+ProcessPOSIXLog::DisableLog (const char **args, Stream *feedback_strm)</div><div> {</div><div>     LogSP log (GetLog ());</div><div>     if (log)</div><div>     {</div><div>         uint32_t flag_bits = 0;</div><div>
         </div><div>-        const size_t argc = args.GetArgumentCount ();</div><div>-        if (argc > 0)</div><div>+        flag_bits = log->GetMask().Get();</div><div>+        for (; args[0]; args++)</div><div>         {</div>
<div>-            flag_bits = log->GetMask().Get();</div><div>-            for (size_t i = 0; i < argc; ++i)</div><div>-            {</div><div>-                const char *arg = args.GetArgumentAtIndex (i);</div><div>
-                </div><div>+            const char *arg = args[0];</div><div> </div><div>-                if      (::strcasecmp (arg, "all")        == 0 ) flag_bits &= ~POSIX_LOG_ALL;</div><div>-                else if (::strcasecmp (arg, "async")      == 0 ) flag_bits &= ~POSIX_LOG_ASYNC;</div>
<div>-                else if (::strncasecmp (arg, "break", 5)  == 0 ) flag_bits &= ~POSIX_LOG_BREAKPOINTS;</div><div>-                else if (::strncasecmp (arg, "comm", 4)   == 0 ) flag_bits &= ~POSIX_LOG_COMM;</div>
<div>-                else if (::strcasecmp (arg, "default")    == 0 ) flag_bits &= ~POSIX_LOG_DEFAULT;</div><div>-                else if (::strcasecmp (arg, "packets")    == 0 ) flag_bits &= ~POSIX_LOG_PACKETS;</div>
<div>-                else if (::strcasecmp (arg, "memory")     == 0 ) flag_bits &= ~POSIX_LOG_MEMORY;</div><div>-                else if (::strcasecmp (arg, "data-short") == 0 ) flag_bits &= ~POSIX_LOG_MEMORY_DATA_SHORT;</div>
<div>-                else if (::strcasecmp (arg, "data-long")  == 0 ) flag_bits &= ~POSIX_LOG_MEMORY_DATA_LONG;</div><div>-                else if (::strcasecmp (arg, "process")    == 0 ) flag_bits &= ~POSIX_LOG_PROCESS;</div>
<div>-                else if (::strcasecmp (arg, "ptrace")     == 0 ) flag_bits &= ~POSIX_LOG_PTRACE;</div><div>-                else if (::strcasecmp (arg, "registers")  == 0 ) flag_bits &= ~POSIX_LOG_REGISTERS;</div>
<div>-                else if (::strcasecmp (arg, "step")       == 0 ) flag_bits &= ~POSIX_LOG_STEP;</div><div>-                else if (::strcasecmp (arg, "thread")     == 0 ) flag_bits &= ~POSIX_LOG_THREAD;</div>
<div>-                else if (::strcasecmp (arg, "verbose")    == 0 ) flag_bits &= ~POSIX_LOG_VERBOSE;</div><div>-                else if (::strncasecmp (arg, "watch", 5)  == 0 ) flag_bits &= ~POSIX_LOG_WATCHPOINTS;</div>
<div>-                else</div><div>-                {</div><div>-                    feedback_strm->Printf("error: unrecognized log category '%s'\n", arg);</div><div>-                    ListLogCategories (feedback_strm);</div>
<div>-                }</div><div>-                </div><div>+            if      (::strcasecmp (arg, "all")        == 0 ) flag_bits &= ~POSIX_LOG_ALL;</div><div>+            else if (::strcasecmp (arg, "async")      == 0 ) flag_bits &= ~POSIX_LOG_ASYNC;</div>
<div>+            else if (::strncasecmp (arg, "break", 5)  == 0 ) flag_bits &= ~POSIX_LOG_BREAKPOINTS;</div><div>+            else if (::strncasecmp (arg, "comm", 4)   == 0 ) flag_bits &= ~POSIX_LOG_COMM;</div>
<div>+            else if (::strcasecmp (arg, "default")    == 0 ) flag_bits &= ~POSIX_LOG_DEFAULT;</div><div>+            else if (::strcasecmp (arg, "packets")    == 0 ) flag_bits &= ~POSIX_LOG_PACKETS;</div>
<div>+            else if (::strcasecmp (arg, "memory")     == 0 ) flag_bits &= ~POSIX_LOG_MEMORY;</div><div>+            else if (::strcasecmp (arg, "data-short") == 0 ) flag_bits &= ~POSIX_LOG_MEMORY_DATA_SHORT;</div>
<div>+            else if (::strcasecmp (arg, "data-long")  == 0 ) flag_bits &= ~POSIX_LOG_MEMORY_DATA_LONG;</div><div>+            else if (::strcasecmp (arg, "process")    == 0 ) flag_bits &= ~POSIX_LOG_PROCESS;</div>
<div>+            else if (::strcasecmp (arg, "ptrace")     == 0 ) flag_bits &= ~POSIX_LOG_PTRACE;</div><div>+            else if (::strcasecmp (arg, "registers")  == 0 ) flag_bits &= ~POSIX_LOG_REGISTERS;</div>
<div>+            else if (::strcasecmp (arg, "step")       == 0 ) flag_bits &= ~POSIX_LOG_STEP;</div><div>+            else if (::strcasecmp (arg, "thread")     == 0 ) flag_bits &= ~POSIX_LOG_THREAD;</div>
<div>+            else if (::strcasecmp (arg, "verbose")    == 0 ) flag_bits &= ~POSIX_LOG_VERBOSE;</div><div>+            else if (::strncasecmp (arg, "watch", 5)  == 0 ) flag_bits &= ~POSIX_LOG_WATCHPOINTS;</div>
<div>+            else</div><div>+            {</div><div>+                feedback_strm->Printf("error: unrecognized log category '%s'\n", arg);</div><div>+                ListLogCategories (feedback_strm);</div>
<div>             }</div><div>         }</div><div>         </div><div>@@ -95,7 +89,7 @@</div><div> }</div><div> </div><div> LogSP</div><div>-ProcessPOSIXLog::EnableLog (StreamSP &log_stream_sp, uint32_t log_options, Args &args, Stream *feedback_strm)</div>
<div>+ProcessPOSIXLog::EnableLog (StreamSP &log_stream_sp, uint32_t log_options, const char **args, Stream *feedback_strm)</div><div> {</div><div>     // Try see if there already is a log - that way we can reuse its settings.</div>
<div>     // We could reuse the log in toto, but we don't know that the stream is the same.</div><div>@@ -107,17 +101,16 @@</div><div>     // Now make a new log with this stream if one was provided</div><div>     if (log_stream_sp)</div>
<div>     {</div><div>-        log = make_shared<Log>(log_stream_sp);</div><div>+        log = LogSP(new Log(log_stream_sp));</div><div>         GetLog () = log;</div><div>     }</div><div> </div><div>     if (log)</div>
<div>     {</div><div>         bool got_unknown_category = false;</div><div>-        const size_t argc = args.GetArgumentCount();</div><div>-        for (size_t i=0; i<argc; ++i)</div><div>+        for (; args[0]; args++)</div>
<div>         {</div><div>-            const char *arg = args.GetArgumentAtIndex(i);</div><div>+            const char *arg = args[0];</div><div> </div><div>             if      (::strcasecmp (arg, "all")        == 0 ) flag_bits |= POSIX_LOG_ALL;</div>
<div>             else if (::strcasecmp (arg, "async")      == 0 ) flag_bits |= POSIX_LOG_ASYNC;</div><div>Index: source/Plugins/Process/POSIX/RegisterContext_x86_64.cpp</div><div>===================================================================</div>
<div>--- source/Plugins/Process/POSIX/RegisterContext_x86_64.cpp<span class="Apple-tab-span" style="white-space:pre">   </span>(revision 151036)</div><div>+++ source/Plugins/Process/POSIX/RegisterContext_x86_64.cpp<span class="Apple-tab-span" style="white-space:pre"> </span>(working copy)</div>
<div>@@ -434,7 +434,8 @@</div><div> ProcessMonitor &</div><div> RegisterContext_x86_64::GetMonitor()</div><div> {</div><div>-    ProcessPOSIX *process = static_cast<ProcessPOSIX*>(CalculateProcess());</div><div>
+    ProcessSP base = CalculateProcess();</div><div>+    ProcessPOSIX *process = static_cast<ProcessPOSIX*>(base.get());</div><div>     return process->GetMonitor();</div><div> }</div><div> </div><div>Index: source/Plugins/Process/POSIX/ProcessPOSIXLog.h</div>
<div>===================================================================</div><div>--- source/Plugins/Process/POSIX/ProcessPOSIXLog.h<span class="Apple-tab-span" style="white-space:pre">  </span>(revision 151036)</div><div>
+++ source/Plugins/Process/POSIX/ProcessPOSIXLog.h<span class="Apple-tab-span" style="white-space:pre">       </span>(working copy)</div><div>@@ -54,11 +54,11 @@</div><div>     GetLogIfAllCategoriesSet(uint32_t mask = 0);</div>
<div> </div><div>     static void</div><div>-    DisableLog (lldb_private::Args &args, lldb_private::Stream *feedback_strm);</div><div>+    DisableLog (const char **args, lldb_private::Stream *feedback_strm);</div><div>
 </div><div>     static lldb::LogSP</div><div>     EnableLog (lldb::StreamSP &log_stream_sp, uint32_t log_options,</div><div>-               lldb_private::Args &args, lldb_private::Stream *feedback_strm);</div><div>
+               const char **args, lldb_private::Stream *feedback_strm);</div><div> </div><div>     static void</div><div>     ListLogCategories (lldb_private::Stream *strm);</div><div>Index: source/Plugins/Process/POSIX/POSIXThread.cpp</div>
<div>===================================================================</div><div>--- source/Plugins/Process/POSIX/POSIXThread.cpp<span class="Apple-tab-span" style="white-space:pre">    </span>(revision 151036)</div><div>+++ source/Plugins/Process/POSIX/POSIXThread.cpp<span class="Apple-tab-span" style="white-space:pre">    </span>(working copy)</div>
<div>@@ -29,10 +29,11 @@</div><div> </div><div> #include "UnwindLLDB.h"</div><div> </div><div>+using namespace lldb;</div><div> using namespace lldb_private;</div><div> </div><div> </div><div>-POSIXThread::POSIXThread(Process &process, lldb::tid_t tid)</div>
<div>+POSIXThread::POSIXThread(ProcessSP &process, lldb::tid_t tid)</div><div>     : Thread(process, tid),</div><div>       m_frame_ap(0)</div><div> {</div><div>@@ -49,7 +50,8 @@</div><div> ProcessMonitor &</div><div>
 POSIXThread::GetMonitor()</div><div> {</div><div>-    ProcessPOSIX &process = static_cast<ProcessPOSIX&>(GetProcess());</div><div>+    ProcessSP base = GetProcess();</div><div>+    ProcessPOSIX &process = static_cast<ProcessPOSIX&>(*base);</div>
<div>     return process.GetMonitor();</div><div> }</div><div> </div><div>@@ -62,7 +64,8 @@</div><div> </div><div>     // Let all threads recover from stopping and do any clean up based</div><div>     // on the previous thread state (if any).</div>
<div>-    ProcessPOSIX &process = static_cast<ProcessPOSIX&>(GetProcess());</div><div>+    ProcessSP base = GetProcess();</div><div>+    ProcessPOSIX &process = static_cast<ProcessPOSIX&>(*base);</div>
<div>     process.GetThreadList().RefreshStateAfterStop();</div><div> }</div><div> </div><div>@@ -237,7 +240,7 @@</div><div>     lldb::addr_t pc = GetRegisterContext()->GetPC();</div><div>     if (log)</div><div>         log->Printf ("POSIXThread::%s () PC=0x%8.8llx", __FUNCTION__, pc);</div>
<div>-    lldb::BreakpointSiteSP bp_site(GetProcess().GetBreakpointSiteList().FindByAddress(pc));</div><div>+    lldb::BreakpointSiteSP bp_site(GetProcess()->GetBreakpointSiteList().FindByAddress(pc));</div><div>     assert(bp_site);</div>
<div>     lldb::break_id_t bp_id = bp_site->GetID();</div><div>     assert(bp_site && bp_site->ValidForThisThread(this));</div><div>Index: source/Plugins/Process/Utility/StopInfoMachException.cpp</div><div>===================================================================</div>
<div>--- source/Plugins/Process/Utility/StopInfoMachException.cpp<span class="Apple-tab-span" style="white-space:pre">  </span>(revision 151036)</div><div>+++ source/Plugins/Process/Utility/StopInfoMachException.cpp<span class="Apple-tab-span" style="white-space:pre">        </span>(working copy)</div>
<div>@@ -34,7 +34,7 @@</div><div>     {</div><div>         ExecutionContext exe_ctx (m_thread.shared_from_this());</div><div>         Target *target = exe_ctx.GetTargetPtr();</div><div>-        const llvm::Triple::ArchType cpu = target ? target->GetArchitecture().GetMachine() : llvm::Triple::InvalidArch;</div>
<div>+        const llvm::Triple::ArchType cpu = target ? target->GetArchitecture().GetMachine() : llvm::Triple::UnknownArch;</div><div> </div><div>         const char *exc_desc = NULL;</div><div>         const char *code_label = "code";</div>
<div>@@ -257,7 +257,7 @@</div><div>     {</div><div>         ExecutionContext exe_ctx (thread.shared_from_this());</div><div>         Target *target = exe_ctx.GetTargetPtr();</div><div>-        const llvm::Triple::ArchType cpu = target ? target->GetArchitecture().GetMachine() : llvm::Triple::InvalidArch;</div>
<div>+        const llvm::Triple::ArchType cpu = target ? target->GetArchitecture().GetMachine() : llvm::Triple::UnknownArch;</div><div> </div><div>         switch (exc_type)</div><div>         {</div><div><br></div><div>
<br></div>