diff options
author | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-12-01 01:38:53 +0000 |
---|---|---|
committer | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-12-01 01:38:53 +0000 |
commit | 013d4901182f5e1ee9b19b1530afa2445a542aff (patch) | |
tree | db41060afadb53acb5d820451118995127c519af | |
parent | 90953f047c5229374dd06c07367ec45374136736 (diff) | |
download | ATCD-013d4901182f5e1ee9b19b1530afa2445a542aff.tar.gz |
Client and server output their priorities, and the perl script runs
several buffer sizes for SYNC_NONE.
3 files changed, 55 insertions, 5 deletions
diff --git a/TAO/performance-tests/RTCorba/Oneways/Reliable/client.cpp b/TAO/performance-tests/RTCorba/Oneways/Reliable/client.cpp index 40741bcbc3d..1ec9cb06b45 100644 --- a/TAO/performance-tests/RTCorba/Oneways/Reliable/client.cpp +++ b/TAO/performance-tests/RTCorba/Oneways/Reliable/client.cpp @@ -326,17 +326,25 @@ main (int argc, char *argv[]) if (ACE_OS::last_error () == EPERM) { ACE_DEBUG ((LM_DEBUG, - "server (%P|%t): user is not superuser, " + "client (%P|%t): user is not superuser, " "test runs in time-shared class\n")); policy = ACE_SCHED_OTHER; flags = THR_NEW_LWP|THR_JOINABLE; } else ACE_ERROR_RETURN ((LM_ERROR, - "server (%P|%t): sched_params failed\n"), + "client (%P|%t): sched_params failed\n"), 1); } + ACE_hthread_t self; + ACE_OS::thr_self (self); + + if (ACE_OS::thr_getprio (self, priority) == 0) + ACE_DEBUG ((LM_DEBUG, + "client (%P|%t): thread priority = %d.\n", + priority)); + ACE_TRY_NEW_ENV { // Calibrate the timer. diff --git a/TAO/performance-tests/RTCorba/Oneways/Reliable/run_test.pl b/TAO/performance-tests/RTCorba/Oneways/Reliable/run_test.pl index d8a2f9148dd..51cad92be85 100755 --- a/TAO/performance-tests/RTCorba/Oneways/Reliable/run_test.pl +++ b/TAO/performance-tests/RTCorba/Oneways/Reliable/run_test.pl @@ -9,9 +9,11 @@ unshift @INC, '../../../../../bin'; require ACEutils; $iorfile = "test.ior"; -$iterations = 1000; -$bufsize = 1002; +$iterations = 4000; +$bufsize = 4000; +$nagle = ""; $type = ""; +$all = 1; $other = ""; unlink $iorfile; @@ -20,10 +22,33 @@ sub run_test { my $type = shift(@_); + if ($type == "none") { + $nagle = "-ORBNodelay 0" + } + else { + $nagle = ""; + } + + print STDERR "\n***************** STARTING TEST ******************\n"; + + $CL = Process::Create ($EXEPREFIX."client".$EXE_EXT, + "$nagle -t $type -i $iterations -m $bufsize"); + + $client = $CL->TimedWait (60); + if ($client == -1) { + print STDERR "ERROR: client timedout\n"; + $CL->Kill (); $CL->TimedWait (1); + } +} + +sub run_buffered +{ + my $bufsize = shift (@_); + print STDERR "\n***************** STARTING TEST ******************\n"; $CL = Process::Create ($EXEPREFIX."client".$EXE_EXT, - "-t $type -i $iterations -m $bufsize"); + "-ORBNodelay 0 -t none -i $iterations -m $bufsize"); $client = $CL->TimedWait (60); if ($client == -1) { @@ -36,6 +61,8 @@ sub run_test @types = ("none", "transport", "server", "target", "twoway"); +@bufsizes = (10, 40, 100, 400, 1000, 2000); + for ($i = 0; $i <= $#ARGV; $i++) { SWITCH: @@ -65,6 +92,7 @@ for ($i = 0; $i <= $#ARGV; $i++) if ($ARGV[$i] eq "-t") { @types = split (',', $ARGV[$i + 1]); + $all = 0; $i++; last SWITCH; } @@ -82,6 +110,12 @@ if (ACE::waitforfile_timed ($iorfile, 5) == -1) { exit 1; } +if ($all == 1) { + foreach $bufsize (@bufsizes) { + run_buffered ($bufsize); + } +} + foreach $type (@types) { run_test ($type); } diff --git a/TAO/performance-tests/RTCorba/Oneways/Reliable/server.cpp b/TAO/performance-tests/RTCorba/Oneways/Reliable/server.cpp index 0ad2a39c7e1..034a39b1a76 100644 --- a/TAO/performance-tests/RTCorba/Oneways/Reliable/server.cpp +++ b/TAO/performance-tests/RTCorba/Oneways/Reliable/server.cpp @@ -35,6 +35,14 @@ main (int argc, char *argv[]) "server (%P|%t): sched_params failed\n")); } + ACE_hthread_t self; + ACE_OS::thr_self (self); + + if (ACE_OS::thr_getprio (self, priority) == 0) + ACE_DEBUG ((LM_DEBUG, + "server (%P|%t): thread priority = %d.\n", + priority)); + ACE_TRY_NEW_ENV { CORBA::ORB_var orb = |