Re: JavaMemoryModel: More synchronization statistics

From: Bill Pugh (pugh@cs.umd.edu)
Date: Wed Nov 10 1999 - 23:53:05 EST


The results from the Volano benchmark.

Should we take the following lesson from all of these statistics?

   * For most programs, including many multithreaded benchmarks,
     99% of the synchronization cost involves useless locks
     (e.g., locks that are not being used to synchronize threads).

     Thus, the big issue is not how to use faster techniques when
     we need to communication between threads, but to avoid
     paying the cost for synchronization when we aren't.

3992510 java/io/DataOutputStream.writeUTF java/io/BufferedOutputStream.write
327200 java/io/DataOutputStream.writeInt java/io/BufferedOutputStream.write
220310 java/io/DataInputStream.readUnsignedByte
java/io/BufferedInputStream.rea
d
42598 java/io/DataOutputStream.flush java/io/BufferedOutputStream.flush
42552 COM/volano/mca.run COM/volano/mcf.D
42400 COM/volano/mcf.D java/util/Vector.addElement
42400 COM/volano/mcf.D java/util/Vector.removeAllElements
42400 COM/volano/mby.F5 COM/volano/mcf.D
24398 java/io/DataInputStream.readUnsignedShort
java/io/BufferedInputStream.rea
d
20000 java/io/DataInputStream.readInt java/io/BufferedInputStream.read
8000 java/text/DecimalFormat.subformat java/lang/StringBuffer.append
7799 java/text/MessageFormat.format java/lang/StringBuffer.append
5420 java/util/Observable.notifyObservers java/util/Vector.toArray
3770 java/lang/StringBuffer.toString java/lang/String.<init>
3000 java/text/SimpleDateFormat.format java/lang/StringBuffer.append
3000 java/io/FilterInputStream.mark java/io/BufferedInputStream.mark
3000 COM/volano/mby.F: java/io/FilterInputStream.mark
3000 COM/volano/mby.run java/util/Observable.setChanged
2800 COM/volano/mby. java/util/Observable.notifyObservers
2420 COM/volano/mbp.E# java/util/Observable.setChanged
-------------------------------
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel



This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:22 EDT