United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-7074017 Introduce MemBarAcquireLock/MemBarReleaseLock nodes for monitor enter/exit code paths
JDK-7074017 : Introduce MemBarAcquireLock/MemBarReleaseLock nodes for monitor enter/exit code paths

Details
Type:
Bug
Submit Date:
2011-08-02
Status:
Closed
Updated Date:
2011-11-25
Project Name:
JDK
Resolved Date:
2011-09-30
Component:
hotspot
OS:
linux,generic
Sub-Component:
compiler
CPU:
arm,generic
Priority:
P4
Resolution:
Fixed
Affected Versions:
hs21,hs22
Fixed Versions:
hs22 (b02)

Related Reports
Backport:

Sub Tasks

Description
To implement the java memory model, on a monitor operation, c2 currently adds a MemBarAcquire/MemBarRelease node after/before the monitor enter/exit. No membar instruction is emitted for these MemBarAcquire/MemBarRelease: in the ad file, Matcher::prior_fast_lock()/Matcher::post_fast_unlock() is used to detect a MemBarAcquire/MemBarRelease associated with a monitor enter/exit and to use an empty encoding.

Matcher::post_fast_unlock() is broken with UseOptoBiasInlining: it never returns true.

This CR covers the replacement of MemBarAcquire/MemBarRelease nodes on the monitor enter/exit code paths with new MemBarAcquireLock/MemBarReleaseLock nodes. It  makes it straightforward to distinguish between MemBarAcquire/MemBarRelease on the monitor enter/exit code paths and other code paths without the need for the MemBarAcquire/MemBarRelease machinery.

                                    

Comments
EVALUATION

See description.
                                     
2011-08-02
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-comp/hotspot/rev/f1c12354c3f7
                                     
2011-08-10
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-rt/hotspot/rev/f1c12354c3f7
                                     
2011-08-23
EVALUATION

See main CR
                                     
2011-09-12



Hardware and Software, Engineered to Work Together