ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/test/loops/Sync100M.java
(Generate patch)

Comparing jsr166/src/test/loops/Sync100M.java (file contents):
Revision 1.3 by jsr166, Thu Oct 29 23:09:08 2009 UTC vs.
Revision 1.4 by jsr166, Tue Nov 3 01:04:02 2009 UTC

# Line 6 | Line 6
6  
7   class Sync100M {
8      public static void main(String[] args) throws Exception {
9 <        int x = loop((int)System.nanoTime(), 100000);
9 >        int x = loop((int) System.nanoTime(), 100000);
10          x = loop(x, 100000);
11          x = loop(x, 100000);
12          long start = System.nanoTime();
13          x = loop(x, 100000000);
14          if (x == 0) System.out.print(" ");
15          long time = System.nanoTime() - start;
16 <        double secs = (double)time / 1000000000.0;
16 >        double secs = (double) time / 1000000000.0;
17          System.out.println("time: " + secs);
18          start = System.nanoTime();
19          x = loop(x, 100000000);
20          if (x == 0) System.out.print(" ");
21          time = System.nanoTime() - start;
22 <        secs = (double)time / 1000000000.0;
22 >        secs = (double) time / 1000000000.0;
23          System.out.println("time: " + secs);
24  
25      }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines