[Lldb-commits] [lldb] r112221 - in /lldb/trunk: include/lldb/API/ include/lldb/Core/ include/lldb/Target/ source/API/ source/Commands/ source/Core/ source/Interpreter/ source/Plugins/Process/MacOSX-User/scripts/ source/Target/ tools/driver/

Jim Ingham jingham at apple.com
Thu Aug 26 14:32:51 PDT 2010


Author: jingham
Date: Thu Aug 26 16:32:51 2010
New Revision: 112221

URL: http://llvm.org/viewvc/llvm-project?rev=112221&view=rev
Log:
Change "Current" as in GetCurrentThread, GetCurrentStackFrame, etc, to "Selected" i.e. GetSelectedThread.  Selected makes more sense, since these are set by some user action (a selection).  I didn't change "CurrentProcess" since this is always controlled by the target, and a given target can only have one process, so it really can't be selected.

Modified:
    lldb/trunk/include/lldb/API/SBDebugger.h
    lldb/trunk/include/lldb/API/SBProcess.h
    lldb/trunk/include/lldb/API/SBTarget.h
    lldb/trunk/include/lldb/API/SBThread.h
    lldb/trunk/include/lldb/API/SBValue.h
    lldb/trunk/include/lldb/Core/Debugger.h
    lldb/trunk/include/lldb/Target/StackFrameList.h
    lldb/trunk/include/lldb/Target/TargetList.h
    lldb/trunk/include/lldb/Target/Thread.h
    lldb/trunk/include/lldb/Target/ThreadList.h
    lldb/trunk/source/API/SBCommandInterpreter.cpp
    lldb/trunk/source/API/SBDebugger.cpp
    lldb/trunk/source/API/SBProcess.cpp
    lldb/trunk/source/API/SBTarget.cpp
    lldb/trunk/source/API/SBThread.cpp
    lldb/trunk/source/API/SBValue.cpp
    lldb/trunk/source/Commands/CommandCompletions.cpp
    lldb/trunk/source/Commands/CommandObjectArgs.cpp
    lldb/trunk/source/Commands/CommandObjectBreakpoint.cpp
    lldb/trunk/source/Commands/CommandObjectBreakpointCommand.cpp
    lldb/trunk/source/Commands/CommandObjectDisassemble.cpp
    lldb/trunk/source/Commands/CommandObjectFile.cpp
    lldb/trunk/source/Commands/CommandObjectFrame.cpp
    lldb/trunk/source/Commands/CommandObjectImage.cpp
    lldb/trunk/source/Commands/CommandObjectProcess.cpp
    lldb/trunk/source/Commands/CommandObjectSource.cpp
    lldb/trunk/source/Commands/CommandObjectTarget.cpp
    lldb/trunk/source/Commands/CommandObjectThread.cpp
    lldb/trunk/source/Core/Debugger.cpp
    lldb/trunk/source/Interpreter/Options.cpp
    lldb/trunk/source/Plugins/Process/MacOSX-User/scripts/test-ProcessDebug.pl
    lldb/trunk/source/Target/ExecutionContext.cpp
    lldb/trunk/source/Target/StackFrameList.cpp
    lldb/trunk/source/Target/TargetList.cpp
    lldb/trunk/source/Target/Thread.cpp
    lldb/trunk/source/Target/ThreadList.cpp
    lldb/trunk/tools/driver/Driver.cpp
    lldb/trunk/tools/driver/Driver.h

Modified: lldb/trunk/include/lldb/API/SBDebugger.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBDebugger.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBDebugger.h (original)
+++ lldb/trunk/include/lldb/API/SBDebugger.h Thu Aug 26 16:32:51 2010
@@ -99,10 +99,10 @@
     GetNumTargets ();
 
     lldb::SBTarget
-    GetCurrentTarget ();
+    GetSelectedTarget ();
 
     void
-    UpdateCurrentThread (lldb::SBProcess &process);
+    UpdateSelectedThread (lldb::SBProcess &process);
 
     lldb::SBSourceManager &
     GetSourceManager ();

Modified: lldb/trunk/include/lldb/API/SBProcess.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBProcess.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBProcess.h (original)
+++ lldb/trunk/include/lldb/API/SBProcess.h Thu Aug 26 16:32:51 2010
@@ -58,10 +58,10 @@
     GetSTDERR (char *dst, size_t dst_len) const;
 
     void
-    ReportCurrentState (const lldb::SBEvent &event, FILE *out) const;
+    ReportEventState (const lldb::SBEvent &event, FILE *out) const;
 
     void
-    AppendCurrentStateReport (const lldb::SBEvent &event, lldb::SBCommandReturnObject &result);
+    AppendEventStateReport (const lldb::SBEvent &event, lldb::SBCommandReturnObject &result);
 
     //------------------------------------------------------------------
     // Thread related functions
@@ -76,13 +76,13 @@
     GetThreadByID (lldb::tid_t sb_thread_id);
 
     lldb::SBThread
-    GetCurrentThread () const;
+    GetSelectedThread () const;
 
     bool
-    SetCurrentThread (const lldb::SBThread &thread);
+    SetSelectedThread (const lldb::SBThread &thread);
 
     bool
-    SetCurrentThreadByID (uint32_t tid);
+    SetSelectedThreadByID (uint32_t tid);
 
     //------------------------------------------------------------------
     // Stepping related functions

Modified: lldb/trunk/include/lldb/API/SBTarget.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBTarget.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBTarget.h (original)
+++ lldb/trunk/include/lldb/API/SBTarget.h Thu Aug 26 16:32:51 2010
@@ -82,9 +82,6 @@
     bool
     DeleteTargetFromList (lldb_private::TargetList *list);
 
-    bool
-    MakeCurrentTarget ();
-
     lldb::SBBreakpoint
     BreakpointCreateByLocation (const char *file, uint32_t line);
 

Modified: lldb/trunk/include/lldb/API/SBThread.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBThread.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBThread.h (original)
+++ lldb/trunk/include/lldb/API/SBThread.h Thu Aug 26 16:32:51 2010
@@ -52,7 +52,7 @@
     GetQueueName() const;
 
     void
-    DisplayFramesForCurrentContext (FILE *out,
+    DisplayFramesForSelectedContext (FILE *out,
                                     FILE *err,
                                     uint32_t first_frame,
                                     uint32_t num_frames,
@@ -62,7 +62,7 @@
                                     uint32_t source_lines_after = 3);
 
     bool
-    DisplaySingleFrameForCurrentContext (FILE *out,
+    DisplaySingleFrameForSelectedContext (FILE *out,
                                          FILE *err,
                                          lldb::SBFrame &frame,
                                          bool show_frame_info,

Modified: lldb/trunk/include/lldb/API/SBValue.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBValue.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBValue.h (original)
+++ lldb/trunk/include/lldb/API/SBValue.h Thu Aug 26 16:32:51 2010
@@ -112,10 +112,6 @@
 #endif
 
 private:
-//
-//    lldb_private::ExecutionContext
-//    GetCurrentExecutionContext ();
-//
     lldb::ValueObjectSP m_opaque_sp;
 };
 

Modified: lldb/trunk/include/lldb/Core/Debugger.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Core/Debugger.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/Core/Debugger.h (original)
+++ lldb/trunk/include/lldb/Core/Debugger.h Thu Aug 26 16:32:51 2010
@@ -101,10 +101,10 @@
     GetSourceManager ();
 
     lldb::TargetSP
-    GetCurrentTarget ();
+    GetSelectedTarget ();
 
     ExecutionContext
-    GetCurrentExecutionContext();
+    GetSelectedExecutionContext();
     //------------------------------------------------------------------
     /// Get accessor for the target list.
     ///

Modified: lldb/trunk/include/lldb/Target/StackFrameList.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Target/StackFrameList.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/Target/StackFrameList.h (original)
+++ lldb/trunk/include/lldb/Target/StackFrameList.h Thu Aug 26 16:32:51 2010
@@ -41,14 +41,14 @@
 
     // Mark a stack frame as the current frame
     uint32_t
-    SetCurrentFrame (lldb_private::StackFrame *frame);
+    SetSelectedFrame (lldb_private::StackFrame *frame);
 
     uint32_t
-    GetCurrentFrameIndex () const;
+    GetSelectedFrameIndex () const;
 
     // Mark a stack frame as the current frame using the frame index
     void
-    SetCurrentFrameByIndex (uint32_t idx);
+    SetSelectedFrameByIndex (uint32_t idx);
 
     void
     Clear ();
@@ -90,7 +90,7 @@
     collection m_unwind_frames;
     collection m_inline_frames;
     InlinedFrameInfoCollection m_inlined_info;
-    uint32_t m_current_frame_idx;
+    uint32_t m_selected_frame_idx;
     bool m_show_inlined_frames;
 
 private:

Modified: lldb/trunk/include/lldb/Target/TargetList.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Target/TargetList.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/Target/TargetList.h (original)
+++ lldb/trunk/include/lldb/Target/TargetList.h Thu Aug 26 16:32:51 2010
@@ -181,13 +181,13 @@
     SignalIfRunning (lldb::pid_t pid, int signo);
 
     uint32_t
-    SetCurrentTarget (Target *target);
+    SetSelectedTarget (Target *target);
 
     void
-    SetCurrentTargetWithIndex (uint32_t idx);
+    SetSelectedTargetWithIndex (uint32_t idx);
 
     lldb::TargetSP
-    GetCurrentTarget ();
+    GetSelectedTarget ();
 
 
 protected:
@@ -197,7 +197,7 @@
     //------------------------------------------------------------------
     collection m_target_list;
     mutable Mutex m_target_list_mutex;
-    uint32_t m_current_target_idx;
+    uint32_t m_selected_target_idx;
 private:
     DISALLOW_COPY_AND_ASSIGN (TargetList);
 };

Modified: lldb/trunk/include/lldb/Target/Thread.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Target/Thread.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/Target/Thread.h (original)
+++ lldb/trunk/include/lldb/Target/Thread.h Thu Aug 26 16:32:51 2010
@@ -177,13 +177,13 @@
     GetStackFrameAtIndex (uint32_t idx);
 
     lldb::StackFrameSP
-    GetCurrentFrame ();
+    GetSelectedFrame ();
 
     uint32_t
-    SetCurrentFrame (lldb_private::StackFrame *frame);
+    SetSelectedFrame (lldb_private::StackFrame *frame);
 
     void
-    SetCurrentFrameByIndex (uint32_t frame_idx);
+    SetSelectedFrameByIndex (uint32_t frame_idx);
 
     virtual RegisterContext *
     GetRegisterContext () = 0;

Modified: lldb/trunk/include/lldb/Target/ThreadList.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/Target/ThreadList.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/include/lldb/Target/ThreadList.h (original)
+++ lldb/trunk/include/lldb/Target/ThreadList.h Thu Aug 26 16:32:51 2010
@@ -46,13 +46,13 @@
     AddThread (lldb::ThreadSP &thread_sp);
 
     lldb::ThreadSP
-    GetCurrentThread ();
+    GetSelectedThread ();
 
     bool
-    SetCurrentThreadByID (lldb::tid_t tid);
+    SetSelectedThreadByID (lldb::tid_t tid);
 
     bool
-    SetCurrentThreadByIndexID (uint32_t index_id);
+    SetSelectedThreadByIndexID (uint32_t index_id);
 
     void
     Clear();
@@ -109,7 +109,7 @@
     uint32_t m_stop_id; ///< The process stop ID that this thread list is valid for.
     collection m_threads; ///< The threads for this process.
     mutable Mutex m_threads_mutex;
-    lldb::tid_t m_current_tid;  ///< For targets that need the notion of a current thread.
+    lldb::tid_t m_selected_tid;  ///< For targets that need the notion of a current thread.
 
 private:
     ThreadList ();

Modified: lldb/trunk/source/API/SBCommandInterpreter.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBCommandInterpreter.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/API/SBCommandInterpreter.cpp (original)
+++ lldb/trunk/source/API/SBCommandInterpreter.cpp Thu Aug 26 16:32:51 2010
@@ -166,7 +166,7 @@
     if (m_opaque_ptr)
     {
         Debugger &debugger = m_opaque_ptr->GetDebugger();
-        Target *target = debugger.GetCurrentTarget().get();
+        Target *target = debugger.GetSelectedTarget().get();
         if (target)
             process.SetProcess(target->GetProcessSP());
     }

Modified: lldb/trunk/source/API/SBDebugger.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBDebugger.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/API/SBDebugger.cpp (original)
+++ lldb/trunk/source/API/SBDebugger.cpp Thu Aug 26 16:32:51 2010
@@ -215,16 +215,16 @@
 
          bool is_stopped = StateIsStoppedState (event_state);
          if (!is_stopped)
-             process.ReportCurrentState (event, out);
+             process.ReportEventState (event, out);
    }
 }
 
 void
-SBDebugger::UpdateCurrentThread (SBProcess &process)
+SBDebugger::UpdateSelectedThread (SBProcess &process)
 {
     if (process.IsValid())
     {
-        SBThread curr_thread = process.GetCurrentThread ();
+        SBThread curr_thread = process.GetSelectedThread ();
         SBThread thread;
         StopReason curr_thread_stop_reason = eStopReasonInvalid;
         if (curr_thread.IsValid())
@@ -270,9 +270,9 @@
                 }
             }
             if (plan_thread.IsValid())
-                process.SetCurrentThreadByID (plan_thread.GetThreadID());
+                process.SetSelectedThreadByID (plan_thread.GetThreadID());
             else if (other_thread.IsValid())
-                process.SetCurrentThreadByID (other_thread.GetThreadID());
+                process.SetSelectedThreadByID (other_thread.GetThreadID());
             else
             {
                 if (curr_thread.IsValid())
@@ -281,7 +281,7 @@
                     thread = process.GetThreadAtIndex(0);
 
                 if (thread.IsValid())
-                    process.SetCurrentThreadByID (thread.GetThreadID());
+                    process.SetSelectedThreadByID (thread.GetThreadID());
             }
         }
     }
@@ -415,7 +415,7 @@
 
         if (error.Success())
         {
-            m_opaque_sp->GetTargetList().SetCurrentTarget (target_sp.get());
+            m_opaque_sp->GetTargetList().SetSelectedTarget (target_sp.get());
             target.reset(target_sp);
         }
     }
@@ -450,7 +450,7 @@
 
         if (error.Success())
         {
-            m_opaque_sp->GetTargetList().SetCurrentTarget (target_sp.get());
+            m_opaque_sp->GetTargetList().SetSelectedTarget (target_sp.get());
             target.reset (target_sp);
         }
     }
@@ -509,11 +509,11 @@
 }
 
 SBTarget
-SBDebugger::GetCurrentTarget ()
+SBDebugger::GetSelectedTarget ()
 {
     SBTarget sb_target;
     if (m_opaque_sp)
-        sb_target.reset(m_opaque_sp->GetTargetList().GetCurrentTarget ());
+        sb_target.reset(m_opaque_sp->GetTargetList().GetSelectedTarget ());
     return sb_target;
 }
 

Modified: lldb/trunk/source/API/SBProcess.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBProcess.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/API/SBProcess.cpp (original)
+++ lldb/trunk/source/API/SBProcess.cpp Thu Aug 26 16:32:51 2010
@@ -97,11 +97,11 @@
 }
 
 SBThread
-SBProcess::GetCurrentThread () const
+SBProcess::GetSelectedThread () const
 {
     SBThread sb_thread;
     if (m_opaque_sp)
-        sb_thread.SetThread (m_opaque_sp->GetThreadList().GetCurrentThread());
+        sb_thread.SetThread (m_opaque_sp->GetThreadList().GetSelectedThread());
     return sb_thread;
 }
 
@@ -152,7 +152,7 @@
 }
 
 void
-SBProcess::ReportCurrentState (const SBEvent &event, FILE *out) const
+SBProcess::ReportEventState (const SBEvent &event, FILE *out) const
 {
     if (out == NULL)
         return;
@@ -173,7 +173,7 @@
 }
 
 void
-SBProcess::AppendCurrentStateReport (const SBEvent &event, SBCommandReturnObject &result)
+SBProcess::AppendEventStateReport (const SBEvent &event, SBCommandReturnObject &result)
 {
     if (m_opaque_sp != NULL)
     {
@@ -190,18 +190,18 @@
 }
 
 bool
-SBProcess::SetCurrentThread (const SBThread &thread)
+SBProcess::SetSelectedThread (const SBThread &thread)
 {
     if (m_opaque_sp != NULL)
-        return m_opaque_sp->GetThreadList().SetCurrentThreadByID (thread.GetThreadID());
+        return m_opaque_sp->GetThreadList().SetSelectedThreadByID (thread.GetThreadID());
     return false;
 }
 
 bool
-SBProcess::SetCurrentThreadByID (uint32_t tid)
+SBProcess::SetSelectedThreadByID (uint32_t tid)
 {
     if (m_opaque_sp != NULL)
-        return m_opaque_sp->GetThreadList().SetCurrentThreadByID (tid);
+        return m_opaque_sp->GetThreadList().SetSelectedThreadByID (tid);
     return false;
 }
 
@@ -274,7 +274,7 @@
         {
             state = m_opaque_sp->WaitForStateChangedEvents (NULL, event_sp);
             SBEvent event (event_sp);
-            AppendCurrentStateReport (event, result);
+            AppendEventStateReport (event, result);
             state_changed = true;
         }
     }

Modified: lldb/trunk/source/API/SBTarget.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBTarget.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/API/SBTarget.cpp (original)
+++ lldb/trunk/source/API/SBTarget.cpp Thu Aug 26 16:32:51 2010
@@ -167,17 +167,6 @@
 }
 
 bool
-SBTarget::MakeCurrentTarget ()
-{
-    if (m_opaque_sp)
-    {
-        m_opaque_sp->GetDebugger().GetTargetList().SetCurrentTarget (m_opaque_sp.get());
-        return true;
-    }
-    return false;
-}
-
-bool
 SBTarget::operator == (const SBTarget &rhs) const
 {
     return m_opaque_sp.get() == rhs.m_opaque_sp.get();

Modified: lldb/trunk/source/API/SBThread.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBThread.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/API/SBThread.cpp (original)
+++ lldb/trunk/source/API/SBThread.cpp Thu Aug 26 16:32:51 2010
@@ -219,7 +219,7 @@
 
 
 void
-SBThread::DisplayFramesForCurrentContext (FILE *out,
+SBThread::DisplayFramesForSelectedContext (FILE *out,
                                           FILE *err,
                                           uint32_t first_frame,
                                           uint32_t num_frames,
@@ -247,7 +247,7 @@
                 break;
 
             SBFrame sb_frame (frame_sp);
-            if (DisplaySingleFrameForCurrentContext (out,
+            if (DisplaySingleFrameForSelectedContext (out,
                                                      err,
                                                      sb_frame,
                                                      show_frame_info,
@@ -260,13 +260,13 @@
 }
 
 bool
-SBThread::DisplaySingleFrameForCurrentContext (FILE *out,
-                                               FILE *err,
-                                               SBFrame &frame,
-                                               bool show_frame_info,
-                                               bool show_source,
-                                               uint32_t source_lines_after,
-                                               uint32_t source_lines_before)
+SBThread::DisplaySingleFrameForSelectedContext (FILE *out,
+                                                FILE *err,
+                                                SBFrame &frame,
+                                                bool show_frame_info,
+                                                bool show_source,
+                                                uint32_t source_lines_after,
+                                                uint32_t source_lines_before)
 {
     bool success = false;
     
@@ -349,7 +349,7 @@
 
         Process &process = m_opaque_sp->GetProcess();
         // Why do we need to set the current thread by ID here???
-        process.GetThreadList().SetCurrentThreadByID (m_opaque_sp->GetID());
+        process.GetThreadList().SetSelectedThreadByID (m_opaque_sp->GetID());
         process.Resume();
     }
 }
@@ -383,7 +383,7 @@
 
         Process &process = m_opaque_sp->GetProcess();
         // Why do we need to set the current thread by ID here???
-        process.GetThreadList().SetCurrentThreadByID (m_opaque_sp->GetID());
+        process.GetThreadList().SetSelectedThreadByID (m_opaque_sp->GetID());
         process.Resume();
 
     }
@@ -400,7 +400,7 @@
         m_opaque_sp->QueueThreadPlanForStepOut (abort_other_plans, NULL, false, stop_other_threads, eVoteYes, eVoteNoOpinion);
 
         Process &process = m_opaque_sp->GetProcess();
-        process.GetThreadList().SetCurrentThreadByID (m_opaque_sp->GetID());
+        process.GetThreadList().SetSelectedThreadByID (m_opaque_sp->GetID());
         process.Resume();
     }
 }
@@ -412,7 +412,7 @@
     {
         m_opaque_sp->QueueThreadPlanForStepSingleInstruction (step_over, true, true);
         Process &process = m_opaque_sp->GetProcess();
-        process.GetThreadList().SetCurrentThreadByID (m_opaque_sp->GetID());
+        process.GetThreadList().SetSelectedThreadByID (m_opaque_sp->GetID());
         process.Resume();
     }
 }
@@ -429,7 +429,7 @@
 
         m_opaque_sp->QueueThreadPlanForRunToAddress (abort_other_plans, target_addr, stop_other_threads);
         Process &process = m_opaque_sp->GetProcess();
-        process.GetThreadList().SetCurrentThreadByID (m_opaque_sp->GetID());
+        process.GetThreadList().SetSelectedThreadByID (m_opaque_sp->GetID());
         process.Resume();
     }
 

Modified: lldb/trunk/source/API/SBValue.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/API/SBValue.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/API/SBValue.cpp (original)
+++ lldb/trunk/source/API/SBValue.cpp Thu Aug 26 16:32:51 2010
@@ -302,42 +302,6 @@
     return is_ptr_type;
 }
 
-
-//lldb_private::ExecutionContext
-//SBValue::GetCurrentExecutionContext ()
-//{
-//    lldb_private::Process *process = NULL;
-//    lldb_private::Thread *thread = NULL;
-//    lldb_private::StackFrame *frame = NULL;
-//
-//    SBTarget sb_target = SBDebugger::GetCurrentTarget();
-//    if (sb_target.IsValid())
-//    {
-//        SBProcess sb_process = sb_target.GetProcess();
-//        if (sb_process.IsValid())
-//        {
-//            process = sb_process.get();
-//            SBThread sb_thread = sb_process.GetCurrentThread();
-//            if (sb_thread.IsValid())
-//            {
-//                thread = sb_thread.GetLLDBObjectPtr();
-//                frame = thread->GetStackFrameAtIndex(0).get();
-//                lldb_private::ExecutionContext exe_context (process, thread, frame);
-//                return exe_context;
-//            }
-//            else
-//            {
-//                lldb_private::ExecutionContext exe_context (process, NULL, NULL);
-//                return exe_context;
-//            }
-//        }
-//    }
-//
-//    lldb_private::ExecutionContext exe_context (NULL, NULL, NULL);
-//    return exe_context;
-//}
-//
-//
 void *
 SBValue::GetOpaqueType()
 {

Modified: lldb/trunk/source/Commands/CommandCompletions.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandCompletions.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandCompletions.cpp (original)
+++ lldb/trunk/source/Commands/CommandCompletions.cpp Thu Aug 26 16:32:51 2010
@@ -102,7 +102,7 @@
 
     if (searcher == NULL)
     {
-        lldb::TargetSP target_sp = interpreter.GetDebugger().GetCurrentTarget();
+        lldb::TargetSP target_sp = interpreter.GetDebugger().GetSelectedTarget();
         SearchFilter null_searcher (target_sp);
         completer.DoCompletion (&null_searcher);
     }
@@ -368,7 +368,7 @@
     
     if (searcher == NULL)
     {
-        lldb::TargetSP target_sp = interpreter.GetDebugger().GetCurrentTarget();
+        lldb::TargetSP target_sp = interpreter.GetDebugger().GetSelectedTarget();
         SearchFilter null_searcher (target_sp);
         completer.DoCompletion (&null_searcher);
     }
@@ -399,7 +399,7 @@
 
     if (searcher == NULL)
     {
-        lldb::TargetSP target_sp = interpreter.GetDebugger().GetCurrentTarget();
+        lldb::TargetSP target_sp = interpreter.GetDebugger().GetSelectedTarget();
         SearchFilter null_searcher (target_sp);
         completer.DoCompletion (&null_searcher);
     }

Modified: lldb/trunk/source/Commands/CommandObjectArgs.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectArgs.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectArgs.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectArgs.cpp Thu Aug 26 16:32:51 2010
@@ -140,7 +140,7 @@
         return false;
     }
         
-    lldb::StackFrameSP thread_cur_frame = thread->GetCurrentFrame ();
+    lldb::StackFrameSP thread_cur_frame = thread->GetSelectedFrame ();
     if (!thread_cur_frame)
     {
         result.AppendError ("The current thread has no current frame.");

Modified: lldb/trunk/source/Commands/CommandObjectBreakpoint.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectBreakpoint.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectBreakpoint.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectBreakpoint.cpp Thu Aug 26 16:32:51 2010
@@ -273,7 +273,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("Invalid target, set executable file using 'file' command.");
@@ -706,7 +706,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("Invalid target, set executable file using 'file' command.");
@@ -797,7 +797,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("Invalid target, set executable file using 'file' command.");
@@ -897,7 +897,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("Invalid target, set executable file using 'file' command.");
@@ -993,7 +993,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("Invalid target, set executable file using 'file' command.");
@@ -1240,7 +1240,7 @@
         return false;
     }
 
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("Invalid target, set executable file using 'file' command.");

Modified: lldb/trunk/source/Commands/CommandObjectBreakpointCommand.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectBreakpointCommand.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectBreakpointCommand.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectBreakpointCommand.cpp Thu Aug 26 16:32:51 2010
@@ -213,7 +213,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
 
     if (target == NULL)
     {
@@ -417,7 +417,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
 
     if (target == NULL)
     {
@@ -503,7 +503,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
 
     if (target == NULL)
     {

Modified: lldb/trunk/source/Commands/CommandObjectDisassemble.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectDisassemble.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectDisassemble.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectDisassemble.cpp Thu Aug 26 16:32:51 2010
@@ -160,7 +160,7 @@
     CommandReturnObject &result
 )
 {
-    Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+    Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
     if (target == NULL)
     {
         result.AppendError ("invalid target, set executable file using 'file' command");

Modified: lldb/trunk/source/Commands/CommandObjectFile.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectFile.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectFile.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectFile.cpp Thu Aug 26 16:32:51 2010
@@ -132,7 +132,7 @@
 
         if (target_sp)
         {
-            debugger.GetTargetList().SetCurrentTarget(target_sp.get());
+            debugger.GetTargetList().SetSelectedTarget(target_sp.get());
             result.AppendMessageWithFormat ("Current executable set to '%s' (%s).\n", file_path, target_sp->GetArchitecture().AsCString());
             result.SetStatus (eReturnStatusSuccessFinishNoResult);
         }

Modified: lldb/trunk/source/Commands/CommandObjectFrame.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectFrame.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectFrame.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectFrame.cpp Thu Aug 26 16:32:51 2010
@@ -109,8 +109,8 @@
                 const uint32_t frame_idx = Args::StringToUInt32 (frame_idx_cstr, UINT32_MAX, 0);
                 if (frame_idx < num_frames)
                 {
-                    exe_ctx.thread->SetCurrentFrameByIndex (frame_idx);
-                    exe_ctx.frame = exe_ctx.thread->GetCurrentFrame ().get();
+                    exe_ctx.thread->SetSelectedFrameByIndex (frame_idx);
+                    exe_ctx.frame = exe_ctx.thread->GetSelectedFrame ().get();
 
                     if (exe_ctx.frame)
                     {

Modified: lldb/trunk/source/Commands/CommandObjectImage.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectImage.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectImage.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectImage.cpp Thu Aug 26 16:32:51 2010
@@ -579,7 +579,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target == NULL)
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
@@ -687,7 +687,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target == NULL)
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
@@ -794,7 +794,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target == NULL)
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
@@ -901,7 +901,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target == NULL)
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
@@ -1070,7 +1070,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target == NULL)
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
@@ -1438,7 +1438,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target == NULL)
         {
             result.AppendError ("invalid target, set executable file using 'file' command");

Modified: lldb/trunk/source/Commands/CommandObjectProcess.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectProcess.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectProcess.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectProcess.cpp Thu Aug 26 16:32:51 2010
@@ -124,7 +124,7 @@
              Args& launch_args,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         bool synchronous_execution = interpreter.GetSynchronous ();
     //    bool launched = false;
     //    bool stopped_after_launch = false;
@@ -377,7 +377,7 @@
                 if (process && process->IsAlive())
                     return true;
                     
-                Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+                Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
                 if (target == NULL)
                 {
                     // No target has been set yet, for now do host completion.  Otherwise I don't know how we would
@@ -436,7 +436,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
 
         Process *process = interpreter.GetDebugger().GetExecutionContext().process;
         if (process)
@@ -470,7 +470,7 @@
                 result.AppendError(error.AsCString("Error creating empty target"));
                 return false;
             }
-            interpreter.GetDebugger().GetTargetList().SetCurrentTarget(target);
+            interpreter.GetDebugger().GetTargetList().SetSelectedTarget(target);
         }
         
         // Record the old executable module, we want to issue a warning if the process of attaching changed the

Modified: lldb/trunk/source/Commands/CommandObjectSource.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectSource.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectSource.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectSource.cpp Thu Aug 26 16:32:51 2010
@@ -267,7 +267,7 @@
         if (!m_options.symbol_name.empty())
         {
             // Displaying the source for a symbol:
-            Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+            Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
             if (target == NULL)
             {
                 result.AppendError ("invalid target, set executable file using 'file' command");
@@ -441,7 +441,7 @@
         else
         {
             const char *filename = m_options.file_name.c_str();
-            Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+            Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
             if (target == NULL)
             {
                 result.AppendError ("invalid target, set executable file using 'file' command");

Modified: lldb/trunk/source/Commands/CommandObjectTarget.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectTarget.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectTarget.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectTarget.cpp Thu Aug 26 16:32:51 2010
@@ -50,7 +50,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target)
         {
             uint32_t argc = command.GetArgumentCount();
@@ -113,7 +113,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target)
         {
             bool notify = true;
@@ -148,7 +148,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target)
         {
             uint32_t argc = command.GetArgumentCount();
@@ -231,7 +231,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target)
         {
             if (command.GetArgumentCount() != 0)
@@ -272,7 +272,7 @@
              Args& command,
              CommandReturnObject &result)
     {
-        Target *target = interpreter.GetDebugger().GetCurrentTarget().get();
+        Target *target = interpreter.GetDebugger().GetSelectedTarget().get();
         if (target)
         {
             if (command.GetArgumentCount() != 1)
@@ -337,8 +337,8 @@
 //                const uint32_t frame_idx = Args::StringToUInt32 (frame_idx_cstr, UINT32_MAX, 0);
 //                if (frame_idx < num_frames)
 //                {
-//                    exe_ctx.thread->SetCurrentFrameByIndex (frame_idx);
-//                    exe_ctx.frame = exe_ctx.thread->GetCurrentFrame ().get();
+//                    exe_ctx.thread->SetSelectedFrameByIndex (frame_idx);
+//                    exe_ctx.frame = exe_ctx.thread->GetSelectedFrame ().get();
 //
 //                    if (exe_ctx.frame)
 //                    {

Modified: lldb/trunk/source/Commands/CommandObjectThread.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectThread.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectThread.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectThread.cpp Thu Aug 26 16:32:51 2010
@@ -55,7 +55,7 @@
         }
 
         strm.Indent();
-        strm.Printf("%c ", thread->GetProcess().GetThreadList().GetCurrentThread().get() == thread ? '*' : ' ');
+        strm.Printf("%c ", thread->GetProcess().GetThreadList().GetSelectedThread().get() == thread ? '*' : ' ');
 
         // Show one frame with only the first showing source
         if (show_source)
@@ -465,7 +465,7 @@
 
             if (command.GetArgumentCount() == 0)
             {
-                thread = process->GetThreadList().GetCurrentThread().get();
+                thread = process->GetThreadList().GetSelectedThread().get();
                 if (thread == NULL)
                 {
                     result.AppendError ("no current thread in process");
@@ -525,7 +525,7 @@
                 else
                     new_plan = thread->QueueThreadPlanForStepSingleInstruction (false, abort_other_plans, bool_stop_other_threads);
 
-                process->GetThreadList().SetCurrentThreadByID (thread->GetID());
+                process->GetThreadList().SetSelectedThreadByID (thread->GetID());
                 process->Resume ();
             }
             else if (m_step_type == eStepTypeOver)
@@ -549,19 +549,19 @@
                 // Maybe there should be a parameter to control this.
                 new_plan->SetOkayToDiscard(false);
 
-                process->GetThreadList().SetCurrentThreadByID (thread->GetID());
+                process->GetThreadList().SetSelectedThreadByID (thread->GetID());
                 process->Resume ();
             }
             else if (m_step_type == eStepTypeTrace)
             {
                 thread->QueueThreadPlanForStepSingleInstruction (false, abort_other_plans, bool_stop_other_threads);
-                process->GetThreadList().SetCurrentThreadByID (thread->GetID());
+                process->GetThreadList().SetSelectedThreadByID (thread->GetID());
                 process->Resume ();
             }
             else if (m_step_type == eStepTypeTraceOver)
             {
                 thread->QueueThreadPlanForStepSingleInstruction (true, abort_other_plans, bool_stop_other_threads);
-                process->GetThreadList().SetCurrentThreadByID (thread->GetID());
+                process->GetThreadList().SetSelectedThreadByID (thread->GetID());
                 process->Resume ();
             }
             else if (m_step_type == eStepTypeOut)
@@ -573,7 +573,7 @@
                 // Maybe there should be a parameter to control this.
                 new_plan->SetOkayToDiscard(false);
 
-                process->GetThreadList().SetCurrentThreadByID (thread->GetID());
+                process->GetThreadList().SetSelectedThreadByID (thread->GetID());
                 process->Resume ();
             }
             else
@@ -591,7 +591,7 @@
                 //  {
                 //    state = process->WaitForStateChangedEvents (NULL, event_sp);
                 //  }
-                process->GetThreadList().SetCurrentThreadByID (thread->GetID());
+                process->GetThreadList().SetSelectedThreadByID (thread->GetID());
                 result.SetDidChangeProcessState (true);
                 result.AppendMessageWithFormat ("Process %i %s\n", process->GetID(), StateAsCString (state));
                 result.SetStatus (eReturnStatusSuccessFinishNoResult);
@@ -665,7 +665,7 @@
     {
         bool synchronous_execution = interpreter.GetSynchronous ();
 
-        if (!interpreter.GetDebugger().GetCurrentTarget().get())
+        if (!interpreter.GetDebugger().GetSelectedTarget().get())
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
             result.SetStatus (eReturnStatusFailed);
@@ -725,7 +725,7 @@
             }
             else
             {
-                Thread *current_thread = process->GetThreadList().GetCurrentThread().get();
+                Thread *current_thread = process->GetThreadList().GetSelectedThread().get();
                 if (current_thread == NULL)
                 {
                     result.AppendError ("the process doesn't have a current thread");
@@ -917,7 +917,7 @@
     {
         bool synchronous_execution = interpreter.GetSynchronous ();
 
-        if (!interpreter.GetDebugger().GetCurrentTarget().get())
+        if (!interpreter.GetDebugger().GetSelectedTarget().get())
         {
             result.AppendError ("invalid target, set executable file using 'file' command");
             result.SetStatus (eReturnStatusFailed);
@@ -953,7 +953,7 @@
 
             if (m_options.m_thread_idx == LLDB_INVALID_THREAD_ID)
             {
-                thread = process->GetThreadList().GetCurrentThread().get();
+                thread = process->GetThreadList().GetSelectedThread().get();
             }
             else
             {
@@ -1033,7 +1033,7 @@
 
             }
 
-            process->GetThreadList().SetCurrentThreadByID (m_options.m_thread_idx);
+            process->GetThreadList().SetSelectedThreadByID (m_options.m_thread_idx);
             Error error (process->Resume ());
             if (error.Success())
             {
@@ -1129,7 +1129,7 @@
             return false;
         }
 
-        process->GetThreadList().SetCurrentThreadByID(new_thread->GetID());
+        process->GetThreadList().SetSelectedThreadByID(new_thread->GetID());
         
         DisplayThreadInfo (interpreter,
                            result.GetOutputStream(),

Modified: lldb/trunk/source/Core/Debugger.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Core/Debugger.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Core/Debugger.cpp (original)
+++ lldb/trunk/source/Core/Debugger.cpp Thu Aug 26 16:32:51 2010
@@ -240,18 +240,18 @@
 
 
 TargetSP
-Debugger::GetCurrentTarget ()
+Debugger::GetSelectedTarget ()
 {
-    return m_target_list.GetCurrentTarget ();
+    return m_target_list.GetSelectedTarget ();
 }
 
 ExecutionContext
-Debugger::GetCurrentExecutionContext ()
+Debugger::GetSelectedExecutionContext ()
 {
     ExecutionContext exe_ctx;
     exe_ctx.Clear();
     
-    lldb::TargetSP target_sp = GetCurrentTarget();
+    lldb::TargetSP target_sp = GetSelectedTarget();
     exe_ctx.target = target_sp.get();
     
     if (target_sp)
@@ -259,12 +259,12 @@
         exe_ctx.process = target_sp->GetProcessSP().get();
         if (exe_ctx.process && exe_ctx.process->IsRunning() == false)
         {
-            exe_ctx.thread = exe_ctx.process->GetThreadList().GetCurrentThread().get();
+            exe_ctx.thread = exe_ctx.process->GetThreadList().GetSelectedThread().get();
             if (exe_ctx.thread == NULL)
                 exe_ctx.thread = exe_ctx.process->GetThreadList().GetThreadAtIndex(0).get();
             if (exe_ctx.thread)
             {
-                exe_ctx.frame = exe_ctx.thread->GetCurrentFrame().get();
+                exe_ctx.frame = exe_ctx.thread->GetSelectedFrame().get();
                 if (exe_ctx.frame == NULL)
                     exe_ctx.frame = exe_ctx.thread->GetStackFrameAtIndex (0).get();
             }
@@ -301,7 +301,7 @@
         return;
 
     // TODO: implement the STDIO to the process as an input reader...
-    TargetSP target = GetCurrentTarget();
+    TargetSP target = GetSelectedTarget();
     if (target.get() != NULL)
     {
         ProcessSP process_sp = target->GetProcessSP();
@@ -473,19 +473,19 @@
     }
     else
     {
-        TargetSP target_sp (GetCurrentTarget());
+        TargetSP target_sp (GetSelectedTarget());
         if (target_sp)
         {
             m_exe_ctx.target = target_sp.get();
             m_exe_ctx.process = target_sp->GetProcessSP().get();
             if (m_exe_ctx.process && m_exe_ctx.process->IsRunning() == false)
             {
-                m_exe_ctx.thread = m_exe_ctx.process->GetThreadList().GetCurrentThread().get();
+                m_exe_ctx.thread = m_exe_ctx.process->GetThreadList().GetSelectedThread().get();
                 if (m_exe_ctx.thread == NULL)
                     m_exe_ctx.thread = m_exe_ctx.process->GetThreadList().GetThreadAtIndex(0).get();
                 if (m_exe_ctx.thread)
                 {
-                    m_exe_ctx.frame = m_exe_ctx.thread->GetCurrentFrame().get();
+                    m_exe_ctx.frame = m_exe_ctx.thread->GetSelectedFrame().get();
                     if (m_exe_ctx.frame == NULL)
                         m_exe_ctx.frame = m_exe_ctx.thread->GetStackFrameAtIndex (0).get();
                 }

Modified: lldb/trunk/source/Interpreter/Options.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Interpreter/Options.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Interpreter/Options.cpp (original)
+++ lldb/trunk/source/Interpreter/Options.cpp Thu Aug 26 16:32:51 2010
@@ -746,7 +746,7 @@
                 if (module_name)
                 {
                     FileSpec module_spec(module_name);
-                    lldb::TargetSP target_sp = interpreter.GetDebugger().GetCurrentTarget();
+                    lldb::TargetSP target_sp = interpreter.GetDebugger().GetSelectedTarget();
                     // Search filters require a target...
                     if (target_sp != NULL)
                         filter_ap.reset (new SearchFilterByModule (target_sp, module_spec));

Modified: lldb/trunk/source/Plugins/Process/MacOSX-User/scripts/test-ProcessDebug.pl
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/MacOSX-User/scripts/test-ProcessDebug.pl?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/MacOSX-User/scripts/test-ProcessDebug.pl (original)
+++ lldb/trunk/source/Plugins/Process/MacOSX-User/scripts/test-ProcessDebug.pl Thu Aug 26 16:32:51 2010
@@ -338,7 +338,7 @@
 			}
 		    elsif (	$pid_state == $lldb::eStateStopped )
 			{
-				my $tid = lldb::PDProcessGetCurrentThread ( $pid );
+				my $tid = lldb::PDProcessGetSelectedThread ( $pid );
 				my $pc = lldb::PDThreadGetRegisterHexValueByName($pid, $tid, $lldb::PD_REGISTER_SET_ALL, "eip", 0);
 				$pc != 0 and printf("pc = 0x%8.8x ", $pc); 
 				# my $sp = lldb::PDThreadGetRegisterHexValueByName($pid, $tid, $lldb::PD_REGISTER_SET_ALL, "esp", 0);

Modified: lldb/trunk/source/Target/ExecutionContext.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/ExecutionContext.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Target/ExecutionContext.cpp (original)
+++ lldb/trunk/source/Target/ExecutionContext.cpp Thu Aug 26 16:32:51 2010
@@ -41,9 +41,9 @@
         process = t->GetProcessSP().get();
         if (process)
         {
-            thread = process->GetThreadList().GetCurrentThread().get();
+            thread = process->GetThreadList().GetSelectedThread().get();
             if (thread)
-                frame = thread->GetCurrentFrame().get();
+                frame = thread->GetSelectedFrame().get();
         }
     }
 }

Modified: lldb/trunk/source/Target/StackFrameList.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/StackFrameList.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Target/StackFrameList.cpp (original)
+++ lldb/trunk/source/Target/StackFrameList.cpp Thu Aug 26 16:32:51 2010
@@ -33,7 +33,7 @@
     m_mutex (Mutex::eMutexTypeRecursive),
     m_unwind_frames (),
     m_inline_frames (),
-    m_current_frame_idx (0)
+    m_selected_frame_idx (0)
 {
 }
 
@@ -306,15 +306,15 @@
 }
 
 uint32_t
-StackFrameList::GetCurrentFrameIndex () const
+StackFrameList::GetSelectedFrameIndex () const
 {
     Mutex::Locker locker (m_mutex);
-    return m_current_frame_idx;
+    return m_selected_frame_idx;
 }
 
 
 uint32_t
-StackFrameList::SetCurrentFrame (lldb_private::StackFrame *frame)
+StackFrameList::SetSelectedFrame (lldb_private::StackFrame *frame)
 {
     Mutex::Locker locker (m_mutex);
     const_iterator pos;
@@ -324,20 +324,20 @@
     {
         if (pos->get() == frame)
         {
-            m_current_frame_idx = std::distance (begin, pos);
-            return m_current_frame_idx;
+            m_selected_frame_idx = std::distance (begin, pos);
+            return m_selected_frame_idx;
         }
     }
-    m_current_frame_idx = 0;
-    return m_current_frame_idx;
+    m_selected_frame_idx = 0;
+    return m_selected_frame_idx;
 }
 
 // Mark a stack frame as the current frame using the frame index
 void
-StackFrameList::SetCurrentFrameByIndex (uint32_t idx)
+StackFrameList::SetSelectedFrameByIndex (uint32_t idx)
 {
     Mutex::Locker locker (m_mutex);
-    m_current_frame_idx = idx;
+    m_selected_frame_idx = idx;
 }
 
 // The thread has been run, reset the number stack frames to zero so we can

Modified: lldb/trunk/source/Target/TargetList.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/TargetList.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Target/TargetList.cpp (original)
+++ lldb/trunk/source/Target/TargetList.cpp Thu Aug 26 16:32:51 2010
@@ -30,7 +30,7 @@
     Broadcaster("TargetList"),
     m_target_list(),
     m_target_list_mutex (Mutex::eMutexTypeRecursive),
-    m_current_target_idx (0)
+    m_selected_target_idx (0)
 {
 }
 
@@ -101,7 +101,7 @@
     if (target_sp.get())
     {
         Mutex::Locker locker(m_target_list_mutex);
-        m_current_target_idx = m_target_list.size();
+        m_selected_target_idx = m_target_list.size();
         m_target_list.push_back(target_sp);
     }
 
@@ -123,7 +123,7 @@
 //            {
 //                error.Clear();
 //                Mutex::Locker locker(m_target_list_mutex);
-//                m_current_target_idx = m_target_list.size();
+//                m_selected_target_idx = m_target_list.size();
 //                m_target_list.push_back(target_sp);
 //            }
 //        }
@@ -334,7 +334,7 @@
 }
 
 uint32_t
-TargetList::SetCurrentTarget (Target* target)
+TargetList::SetSelectedTarget (Target* target)
 {
     Mutex::Locker locker (m_target_list_mutex);
     collection::const_iterator pos,
@@ -344,19 +344,19 @@
     {
         if (pos->get() == target)
         {
-            m_current_target_idx = std::distance (begin, pos);
-            return m_current_target_idx;
+            m_selected_target_idx = std::distance (begin, pos);
+            return m_selected_target_idx;
         }
     }
-    m_current_target_idx = 0;
-    return m_current_target_idx;
+    m_selected_target_idx = 0;
+    return m_selected_target_idx;
 }
 
 lldb::TargetSP
-TargetList::GetCurrentTarget ()
+TargetList::GetSelectedTarget ()
 {
     Mutex::Locker locker (m_target_list_mutex);
-    if (m_current_target_idx >= m_target_list.size())
-        m_current_target_idx = 0;
-    return GetTargetAtIndex (m_current_target_idx);
+    if (m_selected_target_idx >= m_target_list.size())
+        m_selected_target_idx = 0;
+    return GetTargetAtIndex (m_selected_target_idx);
 }

Modified: lldb/trunk/source/Target/Thread.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/Thread.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Target/Thread.cpp (original)
+++ lldb/trunk/source/Target/Thread.cpp Thu Aug 26 16:32:51 2010
@@ -823,21 +823,21 @@
 }
 
 lldb::StackFrameSP
-Thread::GetCurrentFrame ()
+Thread::GetSelectedFrame ()
 {
-    return GetStackFrameAtIndex (GetStackFrameList().GetCurrentFrameIndex());
+    return GetStackFrameAtIndex (GetStackFrameList().GetSelectedFrameIndex());
 }
 
 uint32_t
-Thread::SetCurrentFrame (lldb_private::StackFrame *frame)
+Thread::SetSelectedFrame (lldb_private::StackFrame *frame)
 {
-    return GetStackFrameList().SetCurrentFrame(frame);
+    return GetStackFrameList().SetSelectedFrame(frame);
 }
 
 void
-Thread::SetCurrentFrameByIndex (uint32_t idx)
+Thread::SetSelectedFrameByIndex (uint32_t idx)
 {
-    GetStackFrameList().SetCurrentFrameByIndex(idx);
+    GetStackFrameList().SetSelectedFrameByIndex(idx);
 }
 
 void

Modified: lldb/trunk/source/Target/ThreadList.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/ThreadList.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/source/Target/ThreadList.cpp (original)
+++ lldb/trunk/source/Target/ThreadList.cpp Thu Aug 26 16:32:51 2010
@@ -23,7 +23,7 @@
     m_stop_id (0),
     m_threads(),
     m_threads_mutex (Mutex::eMutexTypeRecursive),
-    m_current_tid (LLDB_INVALID_THREAD_ID)
+    m_selected_tid (LLDB_INVALID_THREAD_ID)
 {
 }
 
@@ -32,7 +32,7 @@
     m_stop_id (),
     m_threads (),
     m_threads_mutex (Mutex::eMutexTypeRecursive),
-    m_current_tid ()
+    m_selected_tid ()
 {
     // Use the assignment operator since it uses the mutex
     *this = rhs;
@@ -50,7 +50,7 @@
         m_process = rhs.m_process;
         m_stop_id = rhs.m_stop_id;
         m_threads = rhs.m_threads;
-        m_current_tid = rhs.m_current_tid;
+        m_selected_tid = rhs.m_selected_tid;
     }
     return *this;
 }
@@ -274,7 +274,7 @@
 {
     m_stop_id = 0;
     m_threads.clear();
-    m_current_tid = LLDB_INVALID_THREAD_ID;
+    m_selected_tid = LLDB_INVALID_THREAD_ID;
 }
 
 void
@@ -376,7 +376,7 @@
             // You can't say "stop others" and also want yourself to be suspended.
             assert (thread_sp->GetCurrentPlan()->RunState() != eStateSuspended);
 
-            if (thread_sp == GetCurrentThread())
+            if (thread_sp == GetSelectedThread())
             {
                 run_only_current_thread = true;
                 run_me_only_list.Clear();
@@ -415,7 +415,7 @@
 
         if (run_only_current_thread)
         {
-            thread_to_run = GetCurrentThread();
+            thread_to_run = GetSelectedThread();
         }
         else if (run_me_only_list.GetSize (false) == 1)
         {
@@ -456,34 +456,34 @@
 }
 
 ThreadSP
-ThreadList::GetCurrentThread ()
+ThreadList::GetSelectedThread ()
 {
     Mutex::Locker locker(m_threads_mutex);
-    return FindThreadByID(m_current_tid);
+    return FindThreadByID(m_selected_tid);
 }
 
 bool
-ThreadList::SetCurrentThreadByID (lldb::tid_t tid)
+ThreadList::SetSelectedThreadByID (lldb::tid_t tid)
 {
     Mutex::Locker locker(m_threads_mutex);
     if  (FindThreadByID(tid).get())
-        m_current_tid = tid;
+        m_selected_tid = tid;
     else
-        m_current_tid = LLDB_INVALID_THREAD_ID;
+        m_selected_tid = LLDB_INVALID_THREAD_ID;
 
-    return m_current_tid != LLDB_INVALID_THREAD_ID;
+    return m_selected_tid != LLDB_INVALID_THREAD_ID;
 }
 
 bool
-ThreadList::SetCurrentThreadByIndexID (uint32_t index_id)
+ThreadList::SetSelectedThreadByIndexID (uint32_t index_id)
 {
     Mutex::Locker locker(m_threads_mutex);
     ThreadSP thread_sp (FindThreadByIndexID(index_id));
     if  (thread_sp.get())
-        m_current_tid = thread_sp->GetID();
+        m_selected_tid = thread_sp->GetID();
     else
-        m_current_tid = LLDB_INVALID_THREAD_ID;
+        m_selected_tid = LLDB_INVALID_THREAD_ID;
 
-    return m_current_tid != LLDB_INVALID_THREAD_ID;
+    return m_selected_tid != LLDB_INVALID_THREAD_ID;
 }
 

Modified: lldb/trunk/tools/driver/Driver.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/driver/Driver.cpp?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/tools/driver/Driver.cpp (original)
+++ lldb/trunk/tools/driver/Driver.cpp Thu Aug 26 16:32:51 2010
@@ -603,7 +603,7 @@
     //  The process has stuff waiting for stdout; get it and write it out to the appropriate place.
     char stdio_buffer[1024];
     size_t len;
-    while ((len = m_debugger.GetCurrentTarget().GetProcess().GetSTDOUT (stdio_buffer, sizeof (stdio_buffer))) > 0)
+    while ((len = m_debugger.GetSelectedTarget().GetProcess().GetSTDOUT (stdio_buffer, sizeof (stdio_buffer))) > 0)
         m_io_channel_ap->OutWrite (stdio_buffer, len);
 }
 
@@ -613,18 +613,18 @@
     //  The process has stuff waiting for stderr; get it and write it out to the appropriate place.
     char stdio_buffer[1024];
     size_t len;
-    while ((len = m_debugger.GetCurrentTarget().GetProcess().GetSTDERR (stdio_buffer, sizeof (stdio_buffer))) > 0)
+    while ((len = m_debugger.GetSelectedTarget().GetProcess().GetSTDERR (stdio_buffer, sizeof (stdio_buffer))) > 0)
         m_io_channel_ap->ErrWrite (stdio_buffer, len);
 }
 
 void
-Driver::UpdateCurrentThread ()
+Driver::UpdateSelectedThread ()
 {
     using namespace lldb;
-    SBProcess process(m_debugger.GetCurrentTarget().GetProcess());
+    SBProcess process(m_debugger.GetSelectedTarget().GetProcess());
     if (process.IsValid())
     {
-        SBThread curr_thread (process.GetCurrentThread());
+        SBThread curr_thread (process.GetSelectedThread());
         SBThread thread;
         StopReason curr_thread_stop_reason = eStopReasonInvalid;
         curr_thread_stop_reason = curr_thread.GetStopReason();
@@ -664,9 +664,9 @@
                 }
             }
             if (plan_thread.IsValid())
-                process.SetCurrentThread (plan_thread);
+                process.SetSelectedThread (plan_thread);
             else if (other_thread.IsValid())
-                process.SetCurrentThread (other_thread);
+                process.SetSelectedThread (other_thread);
             else
             {
                 if (curr_thread.IsValid())
@@ -675,7 +675,7 @@
                     thread = process.GetThreadAtIndex(0);
 
                 if (thread.IsValid())
-                    process.SetCurrentThread (thread);
+                    process.SetSelectedThread (thread);
             }
         }
     }
@@ -756,7 +756,7 @@
             }
             else
             {
-                UpdateCurrentThread ();
+                UpdateSelectedThread ();
                 m_debugger.HandleCommand("process status");
                 m_io_channel_ap->RefreshPrompt();
             }
@@ -1201,7 +1201,7 @@
                             else
                                 done = HandleIOEvent (event);
                         }
-                        else if (event.BroadcasterMatchesRef (m_debugger.GetCurrentTarget().GetProcess().GetBroadcaster()))
+                        else if (event.BroadcasterMatchesRef (m_debugger.GetSelectedTarget().GetProcess().GetBroadcaster()))
                         {
                             HandleProcessEvent (event);
                         }
@@ -1231,7 +1231,7 @@
                 }
             }
 
-            SBProcess process = m_debugger.GetCurrentTarget().GetProcess();
+            SBProcess process = m_debugger.GetSelectedTarget().GetProcess();
             if (process.IsValid())
                 process.Destroy();
         }

Modified: lldb/trunk/tools/driver/Driver.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/driver/Driver.h?rev=112221&r1=112220&r2=112221&view=diff
==============================================================================
--- lldb/trunk/tools/driver/Driver.h (original)
+++ lldb/trunk/tools/driver/Driver.h Thu Aug 26 16:32:51 2010
@@ -139,7 +139,7 @@
     GetProcessSTDERR ();
 
     void
-    UpdateCurrentThread ();
+    UpdateSelectedThread ();
 
     void
     CloseIOChannelFile ();





More information about the lldb-commits mailing list