summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h
diff options
context:
space:
mode:
authorKate Stone <katherine.stone@apple.com>2016-09-06 20:57:50 +0000
committerKate Stone <katherine.stone@apple.com>2016-09-06 20:57:50 +0000
commitb9c1b51e45b845debb76d8658edabca70ca56079 (patch)
treedfcb5a13ef2b014202340f47036da383eaee74aa /lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h
parentd5aa73376966339caad04013510626ec2e42c760 (diff)
downloadbcm5719-llvm-b9c1b51e45b845debb76d8658edabca70ca56079.tar.gz
bcm5719-llvm-b9c1b51e45b845debb76d8658edabca70ca56079.zip
*** This commit represents a complete reformatting of the LLDB source code
*** to conform to clang-format’s LLVM style. This kind of mass change has *** two obvious implications: Firstly, merging this particular commit into a downstream fork may be a huge effort. Alternatively, it may be worth merging all changes up to this commit, performing the same reformatting operation locally, and then discarding the merge for this particular commit. The commands used to accomplish this reformatting were as follows (with current working directory as the root of the repository): find . \( -iname "*.c" -or -iname "*.cpp" -or -iname "*.h" -or -iname "*.mm" \) -exec clang-format -i {} + find . -iname "*.py" -exec autopep8 --in-place --aggressive --aggressive {} + ; The version of clang-format used was 3.9.0, and autopep8 was 1.2.4. Secondly, “blame” style tools will generally point to this commit instead of a meaningful prior commit. There are alternatives available that will attempt to look through this change and find the appropriate prior commit. YMMV. llvm-svn: 280751
Diffstat (limited to 'lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h')
-rw-r--r--lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h113
1 files changed, 45 insertions, 68 deletions
diff --git a/lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h b/lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h
index 588013043e1..2b194bcc153 100644
--- a/lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h
+++ b/lldb/source/Plugins/Process/Darwin/NativeThreadListDarwin.h
@@ -1,4 +1,5 @@
-//===-- NativeThreadListDarwin.h --------------------------------------*- C++ -*-===//
+//===-- NativeThreadListDarwin.h --------------------------------------*- C++
+//-*-===//
//
// The LLVM Compiler Infrastructure
//
@@ -34,19 +35,16 @@ class NativeProcessDarwin;
class NativeThreadDarwin;
using NativeThreadDarwinSP = std::shared_ptr<NativeThreadDarwin>;
-class NativeThreadListDarwin
-{
+class NativeThreadListDarwin {
public:
- NativeThreadListDarwin();
- ~NativeThreadListDarwin();
+ NativeThreadListDarwin();
+ ~NativeThreadListDarwin();
- void
- Clear();
+ void Clear();
- void
- Dump(Stream &stream) const;
+ void Dump(Stream &stream) const;
- // These methods will be accessed directly from NativeThreadDarwin
+// These methods will be accessed directly from NativeThreadDarwin
#if 0
bool GetRegisterValue (nub_thread_t tid, uint32_t set, uint32_t reg, DNBRegisterValue *reg_value) const;
bool SetRegisterValue (nub_thread_t tid, uint32_t set, uint32_t reg, const DNBRegisterValue *reg_value) const;
@@ -56,30 +54,25 @@ public:
bool RestoreRegisterState (nub_thread_t tid, uint32_t save_id);
#endif
- const char *
- GetThreadInfo(lldb::tid_t tid) const;
+ const char *GetThreadInfo(lldb::tid_t tid) const;
- void
- ProcessWillResume(NativeProcessDarwin &process,
- const ResumeActionList &thread_actions);
+ void ProcessWillResume(NativeProcessDarwin &process,
+ const ResumeActionList &thread_actions);
- uint32_t
- ProcessDidStop(NativeProcessDarwin &process);
+ uint32_t ProcessDidStop(NativeProcessDarwin &process);
- bool
- NotifyException(MachException::Data& exc);
+ bool NotifyException(MachException::Data &exc);
- bool
- ShouldStop(bool &step_more);
+ bool ShouldStop(bool &step_more);
- // These methods will be accessed directly from NativeThreadDarwin
+// These methods will be accessed directly from NativeThreadDarwin
#if 0
const char * GetName (nub_thread_t tid);
nub_state_t GetState (nub_thread_t tid);
nub_thread_t SetCurrentThread (nub_thread_t tid);
#endif
- // TODO: figure out if we need to add this to NativeThreadDarwin yet.
+// TODO: figure out if we need to add this to NativeThreadDarwin yet.
#if 0
ThreadInfo::QoS GetRequestedQoS (nub_thread_t tid, nub_addr_t tsd, uint64_t dti_qos_class_index);
nub_addr_t GetPThreadT (nub_thread_t tid);
@@ -87,76 +80,60 @@ public:
nub_addr_t GetTSDAddressForThread (nub_thread_t tid, uint64_t plo_pthread_tsd_base_address_offset, uint64_t plo_pthread_tsd_base_offset, uint64_t plo_pthread_tsd_entry_size);
#endif
- // These methods will be accessed directly from NativeThreadDarwin
+// These methods will be accessed directly from NativeThreadDarwin
#if 0
bool GetThreadStoppedReason (nub_thread_t tid, struct DNBThreadStopInfo *stop_info) const;
void DumpThreadStoppedReason (nub_thread_t tid) const;
bool GetIdentifierInfo (nub_thread_t tid, thread_identifier_info_data_t *ident_info);
#endif
- size_t
- GetNumberOfThreads() const;
+ size_t GetNumberOfThreads() const;
- lldb::tid_t
- ThreadIDAtIndex(size_t idx) const;
+ lldb::tid_t ThreadIDAtIndex(size_t idx) const;
- lldb::tid_t
- GetCurrentThreadID();
+ lldb::tid_t GetCurrentThreadID();
- NativeThreadDarwinSP
- GetCurrentThread();
+ NativeThreadDarwinSP GetCurrentThread();
- void
- NotifyBreakpointChanged(const NativeBreakpointDarwin *bp);
+ void NotifyBreakpointChanged(const NativeBreakpointDarwin *bp);
- uint32_t
- EnableHardwareBreakpoint(const NativeBreakpointDarwin *bp) const;
+ uint32_t EnableHardwareBreakpoint(const NativeBreakpointDarwin *bp) const;
- bool
- DisableHardwareBreakpoint(const NativeBreakpointDarwin *bp) const;
+ bool DisableHardwareBreakpoint(const NativeBreakpointDarwin *bp) const;
- uint32_t
- EnableHardwareWatchpoint(const NativeBreakpointDarwin *wp) const;
+ uint32_t EnableHardwareWatchpoint(const NativeBreakpointDarwin *wp) const;
- bool
- DisableHardwareWatchpoint(const NativeBreakpointDarwin *wp) const;
+ bool DisableHardwareWatchpoint(const NativeBreakpointDarwin *wp) const;
- uint32_t
- GetNumberOfSupportedHardwareWatchpoints() const;
+ uint32_t GetNumberOfSupportedHardwareWatchpoints() const;
- size_t
- GetThreadIndexForThreadStoppedWithSignal(const int signo) const;
+ size_t GetThreadIndexForThreadStoppedWithSignal(const int signo) const;
- NativeThreadDarwinSP
- GetThreadByID(lldb::tid_t tid) const;
+ NativeThreadDarwinSP GetThreadByID(lldb::tid_t tid) const;
- NativeThreadDarwinSP
- GetThreadByMachPortNumber(::thread_t mach_port_number) const;
+ NativeThreadDarwinSP
+ GetThreadByMachPortNumber(::thread_t mach_port_number) const;
- lldb::tid_t
- GetThreadIDByMachPortNumber(::thread_t mach_port_number) const;
+ lldb::tid_t GetThreadIDByMachPortNumber(::thread_t mach_port_number) const;
- thread_t
- GetMachPortNumberByThreadID(lldb::tid_t globally_unique_id) const;
+ thread_t GetMachPortNumberByThreadID(lldb::tid_t globally_unique_id) const;
protected:
- typedef std::vector<NativeThreadDarwinSP> collection;
- typedef collection::iterator iterator;
- typedef collection::const_iterator const_iterator;
-
- // Consider having this return an lldb_private::Error.
- uint32_t
- UpdateThreadList (NativeProcessDarwin &process, bool update,
- collection *num_threads = nullptr);
-
- collection m_threads;
- mutable std::recursive_mutex m_threads_mutex;
- NativeThreadDarwinSP m_current_thread;
- bool m_is_64_bit;
+ typedef std::vector<NativeThreadDarwinSP> collection;
+ typedef collection::iterator iterator;
+ typedef collection::const_iterator const_iterator;
+
+ // Consider having this return an lldb_private::Error.
+ uint32_t UpdateThreadList(NativeProcessDarwin &process, bool update,
+ collection *num_threads = nullptr);
+
+ collection m_threads;
+ mutable std::recursive_mutex m_threads_mutex;
+ NativeThreadDarwinSP m_current_thread;
+ bool m_is_64_bit;
};
} // namespace process_darwin
} // namespace lldb_private
#endif // #ifndef __NativeThreadListDarwin_h__
-
OpenPOWER on IntegriCloud