summaryrefslogtreecommitdiff
path: root/performance-tests
diff options
context:
space:
mode:
authorOssama Othman <ossama-othman@users.noreply.github.com>2004-05-13 04:44:54 +0000
committerOssama Othman <ossama-othman@users.noreply.github.com>2004-05-13 04:44:54 +0000
commit7142127c452bb039b0ac6d3b40c9dc96f7c78780 (patch)
treeccd98cf15d332f67f14b6049b2171201e4b2b7fc /performance-tests
parentd454cdb1f24976f62849511b753e53e12810dc3d (diff)
downloadATCD-7142127c452bb039b0ac6d3b40c9dc96f7c78780.tar.gz
ChangeLogTag:Wed May 12 21:26:37 2004 Ossama Othman <ossama@dre.vanderbilt.edu>
Diffstat (limited to 'performance-tests')
-rw-r--r--performance-tests/Server_Concurrency/Leader_Follower/leader_follower.cpp2
-rw-r--r--performance-tests/Server_Concurrency/Queue_Based_Workers/workers.cpp12
-rw-r--r--performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.cpp11
-rw-r--r--performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.h8
-rw-r--r--performance-tests/Synch-Benchmarks/Base_Test/base_test.cpp7
-rw-r--r--performance-tests/Synch-Benchmarks/Base_Test/mutex_test.cpp8
-rw-r--r--performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.cpp14
-rw-r--r--performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.h4
8 files changed, 50 insertions, 16 deletions
diff --git a/performance-tests/Server_Concurrency/Leader_Follower/leader_follower.cpp b/performance-tests/Server_Concurrency/Leader_Follower/leader_follower.cpp
index 6b6a56c3eee..d5a8e6839be 100644
--- a/performance-tests/Server_Concurrency/Leader_Follower/leader_follower.cpp
+++ b/performance-tests/Server_Concurrency/Leader_Follower/leader_follower.cpp
@@ -31,7 +31,7 @@ enum DEBUGGING_RANGE
static DEBUGGING_RANGE debug = DEBUG_NONE;
-typedef ACE_Task<ACE_MT_SYNCH> TASK;
+typedef ACE_Task<ACE_SYNCH> TASK;
class Leader_Follower_Task : public TASK
{
diff --git a/performance-tests/Server_Concurrency/Queue_Based_Workers/workers.cpp b/performance-tests/Server_Concurrency/Queue_Based_Workers/workers.cpp
index 9c5a6939e1c..3e142b8b991 100644
--- a/performance-tests/Server_Concurrency/Queue_Based_Workers/workers.cpp
+++ b/performance-tests/Server_Concurrency/Queue_Based_Workers/workers.cpp
@@ -43,12 +43,12 @@ Message_Block::Message_Block (ACE_Data_Block *data_block,
{
}
-typedef ACE_Task<ACE_MT_SYNCH> TASK;
+typedef ACE_Task<ACE_SYNCH> TASK;
class Worker_Task : public TASK
{
public:
- Worker_Task (ACE_Message_Queue<ACE_MT_SYNCH> *mq);
+ Worker_Task (ACE_Message_Queue<ACE_SYNCH> *mq);
int svc (void);
size_t messages_dequeued_;
@@ -60,11 +60,11 @@ public:
class IO_Task : public TASK
{
public:
- IO_Task (ACE_Message_Queue<ACE_MT_SYNCH> *mq);
+ IO_Task (ACE_Message_Queue<ACE_SYNCH> *mq);
int svc (void);
};
-Worker_Task::Worker_Task (ACE_Message_Queue<ACE_MT_SYNCH> *mq)
+Worker_Task::Worker_Task (ACE_Message_Queue<ACE_SYNCH> *mq)
: TASK (0, mq),
messages_dequeued_ (0)
{
@@ -158,7 +158,7 @@ Worker_Task::svc (void)
return 0;
}
-IO_Task::IO_Task (ACE_Message_Queue<ACE_MT_SYNCH> *mq)
+IO_Task::IO_Task (ACE_Message_Queue<ACE_SYNCH> *mq)
: TASK (0, mq)
{
}
@@ -299,7 +299,7 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[])
data_block->duplicate ();
}
- ACE_Message_Queue<ACE_MT_SYNCH> message_queue;
+ ACE_Message_Queue<ACE_SYNCH> message_queue;
// Workers.
Worker_Task **workers = 0;
diff --git a/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.cpp b/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.cpp
index 33b69a8324e..553c4d49c94 100644
--- a/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.cpp
+++ b/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.cpp
@@ -1,17 +1,22 @@
// $Id$
+#include "Baseline_Test.h"
+
+# if defined (ACE_HAS_THREADS)
+
#define ACE_BUILD_SVC_DLL
#include "ace/OS_NS_unistd.h"
#include "ace/Service_Repository.h"
#include "ace/Get_Opt.h"
#include "ace/Thread_Manager.h"
-#include "Baseline_Test.h"
#if !defined (__ACE_INLINE__)
#include "Baseline_Test.i"
#endif /* __ACE_INLINE__ */
-ACE_RCSID(Synch_Benchmarks, Baseline_Test, "$Id$")
+ACE_RCSID (Base_Test,
+ Baseline_Test,
+ "$Id$")
Baseline_Test_Options baseline_options;
// Static Baseline Options holds the test configuration information
@@ -223,3 +228,5 @@ Baseline_Test::hold_lock (void *arg)
}
ACE_SVC_FACTORY_DEFINE (Baseline_Test)
+
+#endif /* ACE_HAS_THREADS */
diff --git a/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.h b/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.h
index aa721619635..b19c2158e1f 100644
--- a/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.h
+++ b/performance-tests/Synch-Benchmarks/Base_Test/Baseline_Test.h
@@ -4,12 +4,14 @@
#ifndef ACE_BASELINE_TEST_H
#define ACE_BASELINE_TEST_H
+#include "Synch_Lib/Benchmark_Base.h"
+
+#if defined (ACE_HAS_THREADS)
+
#include "ace/Profile_Timer.h"
#include "ace/svc_export.h"
#include "ace/Barrier.h"
-#include "Synch_Lib/Benchmark_Base.h"
-
const unsigned long DEFAULT_ITERATIONS = 1000000;
class ACE_Svc_Export Baseline_Test_Base : public Benchmark_Base
@@ -146,4 +148,6 @@ ACE_SVC_FACTORY_DECLARE (Baseline_Test)
#include "Baseline_Test.i"
#endif /* __ACE_INLINE__ */
+#endif /* ACE_HAS_THREADS */
+
#endif /* ACE_BASELINE_TEST_H */
diff --git a/performance-tests/Synch-Benchmarks/Base_Test/base_test.cpp b/performance-tests/Synch-Benchmarks/Base_Test/base_test.cpp
index 67bbf81134c..6d3622c27b8 100644
--- a/performance-tests/Synch-Benchmarks/Base_Test/base_test.cpp
+++ b/performance-tests/Synch-Benchmarks/Base_Test/base_test.cpp
@@ -2,9 +2,12 @@
#define ACE_BUILD_SVC_DLL
-#include "ace/Log_Msg.h"
#include "Baseline_Test.h"
+# if defined (ACE_HAS_THREADS)
+
+#include "ace/Log_Msg.h"
+
class ACE_Svc_Export Baseline_Base_Test : public Baseline_Test_Base
{
public:
@@ -55,3 +58,5 @@ Baseline_Base_Test::test_try_lock ()
ACE_SVC_FACTORY_DECLARE (Baseline_Base_Test)
ACE_SVC_FACTORY_DEFINE (Baseline_Base_Test)
+
+#endif /* ACE_HAS_THREADS */
diff --git a/performance-tests/Synch-Benchmarks/Base_Test/mutex_test.cpp b/performance-tests/Synch-Benchmarks/Base_Test/mutex_test.cpp
index b37415ce9d3..307f093c4fa 100644
--- a/performance-tests/Synch-Benchmarks/Base_Test/mutex_test.cpp
+++ b/performance-tests/Synch-Benchmarks/Base_Test/mutex_test.cpp
@@ -2,6 +2,10 @@
#define ACE_BUILD_SVC_DLL
+#include "Baseline_Test.h"
+
+# if defined (ACE_HAS_THREADS)
+
#include "ace/Log_Msg.h"
#include "ace/Token.h"
#include "ace/Process_Mutex.h"
@@ -13,7 +17,7 @@
#include "ace/Semaphore.h"
#include "ace/Null_Semaphore.h"
#include "ace/Process_Semaphore.h"
-#include "Baseline_Test.h"
+
template<class LOCK>
class ACE_Svc_Export Baseline_Lock_Test : public Baseline_Test_Base
@@ -239,3 +243,5 @@ template class Baseline_Lock_Test<ACE_Token>;
#pragma instantiate Baseline_Lock_Test<ACE_Null_Semaphore>
#pragma instantiate Baseline_Lock_Test<ACE_Token>
#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */
+
+#endif /* ACE_HAS_THREADS */
diff --git a/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.cpp b/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.cpp
index 4dd6126f06b..13c9863d7f1 100644
--- a/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.cpp
+++ b/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.cpp
@@ -1,13 +1,19 @@
// $Id$
#define ACE_BUILD_SVC_DLL
-#include "ace/Service_Repository.h"
+
+#include "Performance_Test.h"
+
+# if defined (ACE_HAS_THREADS)
#include "Performance_Test_Options.h"
#include "Benchmark_Performance.h"
-#include "Performance_Test.h"
-ACE_RCSID(Synch_Benchmarks, Performance_Test, "$Id$")
+#include "ace/Service_Repository.h"
+
+ACE_RCSID (Perf_Test,
+ Performance_Test,
+ "$Id$")
Performance_Test::Performance_Test (void)
: n_lwps_ (0),
@@ -111,3 +117,5 @@ Performance_Test::valid_test_object (Benchmark_Base *bb)
}
ACE_SVC_FACTORY_DEFINE (Performance_Test)
+
+#endif /* ACE_HAS_THREADS */
diff --git a/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.h b/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.h
index ee8e9d8ee2f..f0937f812c7 100644
--- a/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.h
+++ b/performance-tests/Synch-Benchmarks/Perf_Test/Performance_Test.h
@@ -6,6 +6,8 @@
#include "Synch_Lib/Benchmark_Base.h"
+#if defined (ACE_HAS_THREADS)
+
class ACE_Svc_Export Performance_Test : public Benchmark_Method_Base
{
public:
@@ -22,4 +24,6 @@ private:
ACE_SVC_FACTORY_DECLARE (Performance_Test)
+#endif /* ACE_HAS_THREADS */
+
#endif /* ACE_PERFORMANCE_TEST_H */