summaryrefslogtreecommitdiff
path: root/ace/Thread_Manager.h
diff options
context:
space:
mode:
authornanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-05-11 05:29:33 +0000
committernanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-05-11 05:29:33 +0000
commit48adf6bc4d2cb81c5bd542890ebe8a281510f3ac (patch)
treeba85bb509e6450faa09da37506a023e6fb2a93fc /ace/Thread_Manager.h
parent431388bf5c64d9d796d126ca81981fe363aeb393 (diff)
downloadATCD-48adf6bc4d2cb81c5bd542890ebe8a281510f3ac.tar.gz
More Thread_Manager optimization.
Diffstat (limited to 'ace/Thread_Manager.h')
-rw-r--r--ace/Thread_Manager.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/ace/Thread_Manager.h b/ace/Thread_Manager.h
index ee9e2844ca9..ed438682806 100644
--- a/ace/Thread_Manager.h
+++ b/ace/Thread_Manager.h
@@ -127,6 +127,15 @@ public:
long flags (void) const;
// Get the thread creation flags.
+ void acquire_release (void);
+ // Do nothing but to acquire the thread descriptor's lock and
+ // release. This will first check if the thread is registered or
+ // not. If it is already registered, there's no need to reacquire
+ // the lock again. This is used mainly to get newly spawned thread
+ // in synch with thread manager and prevent it from accessing its
+ // thread descriptor before it gets fully built. This function is
+ // only called from ACE_Log_Msg::thr_desc.
+
ACE_INLINE void set_next (ACE_Thread_Descriptor *td);
ACE_INLINE ACE_Thread_Descriptor *get_next (void);
// Set/get the <next_> pointer. These are required by the
@@ -456,12 +465,6 @@ public:
// array) to be destroyed. "cleanup_hook", for example, may delete
// the object (or array).
- int acquire_release (void);
- // Do nothing but to acquire the thread manager's lock and release.
- // This is used mainly to get newly spawned thread in synch with
- // thread manager and prevent it from accessing its thread
- // descriptor before it gets fully built.
-
void wait_on_exit (int dowait);
int wait_on_exit (void);
// Access function to determine whether the Thread_Manager will
@@ -639,7 +642,7 @@ public:
// Remove this thread from its associated <Thread_Manager> and exit
// the thread if <do_thr_exit> is enabled.
- int insert (ACE_Thread_Manager *tm);
+ int insert (ACE_Thread_Manager *tm, int insert = 0);
// Store the <Thread_Manager> and use it to register ourselves for
// correct shutdown.