[concurrency-interest] Array allocation and access on the JVM

Aleksandar Prokopec aleksandar.prokopec at gmail.com
Mon Jan 30 12:24:42 EST 2012


Here are the results without the UseCondCardMark flag:

Executing: java -Xmx512m -Xms512m -server -Dsize=500000000 -Dpar=1 
-XX:CompileCommand=print,*Worker.run 
org.scalapool.bench.MultiStackJavaExperiment 7
CompilerOracle: print *Worker.run
Java HotSpot(TM) 64-Bit Server VM warning: printing of assembly code is 
enabled; turning on DebugNonSafepoints to gain additional output
0) Running time: 1930 ms
1) Running time: 1876 ms
2) Running time: 1220 ms
3) Running time: 1220 ms
4) Running time: 1219 ms
5) Running time: 1220 ms
6) Running time: 1220 ms
 >>>
 >>> All running times: [1930, 1876, 1220, 1220, 1219, 1220, 1220]
 >>>


With the UseCondCardMark flag:


Executing: java -Xmx512m -Xms512m -server -Dsize=500000000 -Dpar=1 
-XX:+UseCondCardMark -XX:CompileCommand=print,*Worker.run 
org.scalapool.bench.MultiStackJavaExperiment 7
CompilerOracle: print *Worker.run
Java HotSpot(TM) 64-Bit Server VM warning: printing of assembly code is 
enabled; turning on DebugNonSafepoints to gain additional output
0) Running time: 1325 ms
1) Running time: 1318 ms
2) Running time: 1407 ms
3) Running time: 1408 ms
4) Running time: 1407 ms
5) Running time: 1407 ms
6) Running time: 1407 ms
 >>>
 >>> All running times: [1325, 1318, 1407, 1408, 1407, 1407, 1407]
 >>>


Cheers,
Alex


On 1/27/12 7:24 PM, Vitaly Davidovich wrote:
>
> On the same 2x4 Xeon server you mentioned earlier? Given that you said 
> there were no GCs I'd expect the cards to stay dirty since you're 
> writing to same location and CPU should predict the branch perfectly 
> (cost of a predicted branch is just a few cycles).  Interesting 
> though, thanks for sharing.
>
> Sent from my phone
>



More information about the Concurrency-interest mailing list