diff options
author | nobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1997-01-01 08:00:34 +0000 |
---|---|---|
committer | nobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1997-01-01 08:00:34 +0000 |
commit | 437eea6fa08e931864f89be91d14a816f69075c7 (patch) | |
tree | b8c1fd723fdcd61c3855d3a3a21a9cd45a268219 /performance-tests/Synch-Benchmarks/Benchmark.cpp | |
parent | ea0d28240863caf437a18071bfd03e7b146c5ade (diff) | |
download | ATCD-unlabeled-4.2.2.tar.gz |
This commit was manufactured by cvs2svn to create branchunlabeled-4.2.2
'unlabeled-4.2.2'.
Diffstat (limited to 'performance-tests/Synch-Benchmarks/Benchmark.cpp')
-rw-r--r-- | performance-tests/Synch-Benchmarks/Benchmark.cpp | 94 |
1 files changed, 0 insertions, 94 deletions
diff --git a/performance-tests/Synch-Benchmarks/Benchmark.cpp b/performance-tests/Synch-Benchmarks/Benchmark.cpp deleted file mode 100644 index 74a8bf9f903..00000000000 --- a/performance-tests/Synch-Benchmarks/Benchmark.cpp +++ /dev/null @@ -1,94 +0,0 @@ -#include "Benchmark.h" -// $Id$ - - -#if defined (ACE_HAS_THREADS) - -// Global variables (used by the dynamically linked services). -int synch_count; -int buffer; - -// Initialize the static variables. -/* static */ -sig_atomic_t Benchmark::done_ = 0; - -sig_atomic_t -Benchmark::done (void) -{ - return Benchmark::done_; -} - -int -Benchmark::thr_id (void) -{ -#if defined (ACE_HAS_PTHREADS) || defined (ACE_HAS_DCETHREADS) || defined (VXWORKS) - // This invokes the thread-specific storage smart pointer. - return this->id_->thr_id (); -#else - return ACE_Thread::self (); -#endif /* ACE_HAS_PTHREADS || ACE_HAS_DCETHREADS || VXWORKS */ -} - -void -Benchmark::done (sig_atomic_t d) -{ - Benchmark::done_ = d; -} - -int -Benchmark::svc (void) -{ - return -1; -} - -int -Benchmark::init (int, char **) -{ - return 1; -} - -int -Benchmark::info (char **, size_t) const -{ - return -1; -} - -int -Benchmark::fini (void) -{ - return -1; -} - -void * -Benchmark::svc_run (Benchmark *bp) -{ - ACE_Thread_Control tc (ACE_Service_Config::thr_mgr ()); - return (void *) (bp->svc () == -1 ? -1 : 0); -} - -#if defined (ACE_HAS_PTHREADS) || defined (VXWORKS) -/* static */ -MT_INT Thr_ID::thread_id_ (0); - -Thr_ID::Thr_ID (void) - : thr_id_ (++Thr_ID::thread_id_) -{ -} - -int -Thr_ID::thr_id (void) -{ - return this->thr_id_; -} - -void -Thr_ID::thr_id (int i) -{ - this->thr_id_ = i; -} - -#if defined (ACE_TEMPLATES_REQUIRE_SPECIALIZATION) -template class ACE_TSS<Thr_ID>; -#endif /* ACE_TEMPLATES_REQUIRE_SPECIALIZATION */ -#endif /* ACE_HAS_PTHREADS || VXWORKS */ -#endif /* ACE_HAS_THREADS */ |