harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yuri Dolgov (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-4875) [drlvm][jit]Harmony has negative scalability in client mode
Date Fri, 28 Sep 2007 12:22:50 GMT
[drlvm][jit]Harmony has negative scalability in client mode
-----------------------------------------------------------

                 Key: HARMONY-4875
                 URL: https://issues.apache.org/jira/browse/HARMONY-4875
             Project: Harmony
          Issue Type: Improvement
          Components: DRLVM
            Reporter: Yuri Dolgov
            Priority: Minor


The scalability for some kinds of programs is negative 
on DRLVM whereas they scales fine on other VMs. This 
is due to profile counters are collecting even when profile 
is gathered.

Test to reproduce the issue:

MT.java:

public class MT extends Thread{

 static long result = 0;
 long len = 0;
 public MT(long len){
  this.len = len;
 }

 public void run(){
 long total = 0;
 for(long i = 0; i < len; ++i){
    total += 1;
 }
 result = total;
 }

 public static void main(String[] args) throws InterruptedException {
 long totalWork = Long.parseLong(args[0]);
 int numThreads = Integer.parseInt(args[1]);

 long work = totalWork / numThreads;

 MT[] v = new MT[numThreads];
 for(int i = 0; i < numThreads; ++i){
  v[i] = new MT(work);
 }

 long start = System.currentTimeMillis();
 for(int i = 0; i < numThreads; ++i){
  v[i].start();
 }
 for(int i = 0; i < numThreads; ++i){
   v[i].join();
 }
 long dur = System.currentTimeMillis() - start;

 System.out.println("Total time: " + dur);
 }

}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message