ReentrantLock performance regression between JDK5 and 6/7?

Florian Weimer fweimer at
Fri Aug 12 00:57:50 PDT 2011

* Tom Rodriguez:

> I believe this was caused by the switch to using lock addl[esp], 0
> instead of mfence for volatile membars, 6822204.  My review request
> for that said that at the time I didn't measure any performance change
> for Intel,  On your
> microbenchmark I can measure the difference though so I'm going to
> remeasure derby which previously showed the big difference.  We may
> want to make the lock addl be AMD specific.

Couldn't the relative speed of the two instructions also depend on the
type of benchmark?

Florian Weimer                <fweimer at>
BFK edv-consulting GmbH
Kriegsstraße 100              tel: +49-721-96201-1
D-76133 Karlsruhe             fax: +49-721-96201-99

More information about the hotspot-runtime-dev mailing list