65 result = queue_sp->GetID();
74 result = queue_sp->GetIndexID();
91 if (stop_locker.
TryLock(&queue_sp->GetProcess()->GetRunLock())) {
92 const std::vector<ThreadSP> thread_list(queue_sp->GetThreads());
94 const uint32_t num_threads = thread_list.size();
95 for (uint32_t idx = 0; idx < num_threads; ++idx) {
96 ThreadSP thread_sp = thread_list[idx];
97 if (thread_sp && thread_sp->IsValid()) {
111 if (stop_locker.
TryLock(&queue_sp->GetProcess()->GetRunLock())) {
112 const std::vector<QueueItemSP> queue_items(
113 queue_sp->GetPendingItems());
115 const uint32_t num_pending_items = queue_items.size();
116 for (uint32_t idx = 0; idx < num_pending_items; ++idx) {
118 if (item && item->IsValid()) {
142 if (queue_sp && idx <
m_threads.size()) {
143 ProcessSP process_sp = queue_sp->GetProcess();
159 result = queue_sp->GetNumPendingWorkItems();
179 result = queue_sp->GetNumRunningWorkItems();
187 result.
SetSP(queue_sp->GetProcess());
196 kind = queue_sp->GetKind();
203 std::vector<lldb::ThreadWP>
240 return this->
operator bool();
242SBQueue::operator bool()
const {
245 return m_opaque_sp->IsValid();
#define LLDB_INSTRUMENT_VA(...)
void SetSP(const lldb::ProcessSP &process_sp)
void SetQueueItem(const lldb::QueueItemSP &queue_item_sp)
uint32_t GetNumPendingItems()
lldb::SBProcess GetProcess()
const SBQueue & operator=(const lldb::SBQueue &rhs)
lldb::SBThread GetThreadAtIndex(uint32_t)
uint32_t GetIndexID() const
const char * GetName() const
uint32_t GetNumRunningItems()
lldb::queue_id_t GetQueueID() const
std::shared_ptr< lldb_private::QueueImpl > m_opaque_sp
lldb::QueueKind GetKind()
lldb::SBQueueItem GetPendingItemAtIndex(uint32_t)
void SetQueue(const lldb::QueueSP &queue_sp)
void SetThread(const lldb::ThreadSP &lldb_object_sp)
A uniqued constant string class.
const char * GetCString() const
Get the string value as a C string.
bool TryLock(ProcessRunLock *lock)
uint32_t GetIndexID() const
const char * GetName() const
lldb::queue_id_t GetQueueID() const
lldb::SBThread GetThreadAtIndex(uint32_t idx)
std::vector< lldb::ThreadWP > m_threads
lldb::SBQueueItem GetPendingItemAtIndex(uint32_t idx)
std::vector< lldb::QueueItemSP > m_pending_items
uint32_t GetNumPendingItems()
uint32_t GetNumRunningItems()
lldb::QueueKind GetKind()
QueueImpl(const QueueImpl &rhs)
bool m_pending_items_fetched
void SetQueue(const lldb::QueueSP &queue_sp)
bool m_thread_list_fetched
lldb::SBProcess GetProcess()
QueueImpl(const lldb::QueueSP &queue_sp)
#define LLDB_INVALID_QUEUE_ID
#define LLDB_INVALID_INDEX32
A class that represents a running process on the host machine.
std::shared_ptr< lldb_private::Queue > QueueSP
std::shared_ptr< lldb_private::Thread > ThreadSP
std::shared_ptr< lldb_private::Process > ProcessSP
std::weak_ptr< lldb_private::Queue > QueueWP
std::shared_ptr< lldb_private::QueueItem > QueueItemSP