summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschmidt <douglascraigschmidt@users.noreply.github.com>1998-05-06 05:21:11 +0000
committerschmidt <douglascraigschmidt@users.noreply.github.com>1998-05-06 05:21:11 +0000
commit17377d7a8f6c8defd58e4184ea3910eea86365c3 (patch)
tree4fb91ca3779c4719a93000522743428c09980790
parent01742cd090753884bc7bbbaa820dfb0ce81a27ff (diff)
downloadATCD-17377d7a8f6c8defd58e4184ea3910eea86365c3.tar.gz
*** empty log message ***
-rw-r--r--ChangeLog-98a5
-rw-r--r--examples/IPC_SAP/SOCK_SAP/CPP-inserver.cpp4
-rw-r--r--performance-tests/Misc/context_switch_time.cpp20
3 files changed, 17 insertions, 12 deletions
diff --git a/ChangeLog-98a b/ChangeLog-98a
index 26f850f356e..bab35121592 100644
--- a/ChangeLog-98a
+++ b/ChangeLog-98a
@@ -1,3 +1,8 @@
+Wed May 6 00:15:39 1998 Douglas C. Schmidt <schmidt@tango.cs.wustl.edu>
+
+ * performance-tests/Misc/context_switch_time.cpp (svc): An 'i'
+ was being defined twice, gorp! It's fixed now!
+
Tue May 5 14:12:08 1998 Douglas C. Schmidt <schmidt@flamenco.cs.wustl.edu>
* include/makeinclude/platform_sco5.0.0-fsu-pthread.GNU: Added a
diff --git a/examples/IPC_SAP/SOCK_SAP/CPP-inserver.cpp b/examples/IPC_SAP/SOCK_SAP/CPP-inserver.cpp
index 2d921bd102d..f79865a94cd 100644
--- a/examples/IPC_SAP/SOCK_SAP/CPP-inserver.cpp
+++ b/examples/IPC_SAP/SOCK_SAP/CPP-inserver.cpp
@@ -2,7 +2,7 @@
// This example tests the features of the ACE_SOCK_Acceptor and
// ACE_SOCK_Stream classes. If the platform supports threads it uses
-// a thread-per-request concurrency model.
+// a thread-per-connection concurrency model.
#include "ace/SOCK_Acceptor.h"
#include "ace/Thread_Manager.h"
@@ -106,6 +106,8 @@ run_event_loop (u_short port)
}
#if defined (ACE_HAS_THREADS)
+ // Spawn a new thread and run the new connection in that thread of
+ // control using the <server> function as the entry point.
if (ACE_Thread_Manager::instance ()->spawn ((ACE_THR_FUNC) server,
(void *) new_stream.get_handle (),
THR_DETACHED) == -1)
diff --git a/performance-tests/Misc/context_switch_time.cpp b/performance-tests/Misc/context_switch_time.cpp
index 8ee00a4faed..a299b17e058 100644
--- a/performance-tests/Misc/context_switch_time.cpp
+++ b/performance-tests/Misc/context_switch_time.cpp
@@ -231,10 +231,8 @@ Suspend_Resume_Test::svc ()
{
#if DEBUG > 0
if (i % (iterations_ >= 10 ? iterations_ / 10 : 1) == 0)
- {
- ACE_DEBUG ((LM_DEBUG, "Suspend_Resume_Test::svc (), iteration %u\n",
- i));
- }
+ ACE_DEBUG ((LM_DEBUG, "Suspend_Resume_Test::svc (), iteration %u\n",
+ i));
#endif /* DEBUG */
if (ACE_OS::thr_suspend (low_.thread_id ()) != 0)
@@ -450,7 +448,9 @@ Ping_Suspend_Resume_Test::svc ()
timer_.start ();
- for (ACE_UINT32 i = 0; i < iterations_; ++i)
+ ACE_UINT32 i;
+
+ for (i = 0; i < iterations_; ++i)
{
#if DEBUG > 0
if (i % (iterations_ >= 10 ? iterations_ / 10 : 1) == 0)
@@ -481,17 +481,15 @@ Ping_Suspend_Resume_Test::svc ()
// Resume the thread until thr_continue fails, indicating that it has
// finished.
- for (ACE_UINT32 i = 0; i < 10000 && ! ACE_OS::thr_continue (high_.thread_id ());
+ for (i = 0; i < 10000 && ! ACE_OS::thr_continue (high_.thread_id ());
++i) /* null */;
// Don't count the one iteration that was used to allow the high-priority
// thread to terminate.
if (high_.iterations () < iterations_)
- {
- ACE_DEBUG ((LM_DEBUG, "Ping_Suspend_Resume_Test: high priority task "
- "executed only %u iterations!\n",
- high_.iterations ()));
- }
+ ACE_DEBUG ((LM_DEBUG, "Ping_Suspend_Resume_Test: high priority task "
+ "executed only %u iterations!\n",
+ high_.iterations ()));
#if DEBUG > 0
ACE_DEBUG ((LM_DEBUG, "Ping_Suspend_Resume_Test::svc, finishing\n"));