testing of multithreaded application

A

aziz rachid

Hi,
I want to display the results of the execution of a set of threads to
see how often they are inconsistent. I have the threads code.
I can trace the results values by creating a loop within which
1- all the threads are launched, i gather thx.start() will be
sufficient
2- wait for all the threads to complete its operations
3- kill all threads, then loop back

how can i implement 2) and 3) in Java? Is there another mean to
benchmark the results of multithreaded application execution.

Cheers.
 
J

John B. Matthews

aziz rachid said:
I want to display the results of the execution of a set of threads to
see how often they are inconsistent. I have the threads code. I can
trace the results values by creating a loop within which
1- all the threads are launched, i gather thx.start() will be
sufficient
2- wait for all the threads to complete its operations
3- kill all threads, then loop back

how can i implement 2) and 3) in Java? Is there another mean to
benchmark the results of multithreaded application execution.

CountDownLatch [1] may of use, for example [2].

[1]<http://download.oracle.com/javase/6/docs/api/java/util/concurrent/CountDownLatch.html>
[2]<http://groups.google.com/group/comp.lang.java.programmer/msg/1d9c821dcda040f6>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,011
Latest member
AjaUqq1950

Latest Threads

Top