3149 // Box the stack location |
3149 // Box the stack location |
3150 Node* box = _gvn.transform(new (C) BoxLockNode(next_monitor())); |
3150 Node* box = _gvn.transform(new (C) BoxLockNode(next_monitor())); |
3151 Node* mem = reset_memory(); |
3151 Node* mem = reset_memory(); |
3152 |
3152 |
3153 FastLockNode * flock = _gvn.transform(new (C) FastLockNode(0, obj, box) )->as_FastLock(); |
3153 FastLockNode * flock = _gvn.transform(new (C) FastLockNode(0, obj, box) )->as_FastLock(); |
3154 if (PrintPreciseBiasedLockingStatistics) { |
3154 if (UseBiasedLocking && PrintPreciseBiasedLockingStatistics) { |
3155 // Create the counters for this fast lock. |
3155 // Create the counters for this fast lock. |
3156 flock->create_lock_counter(sync_jvms()); // sync_jvms used to get current bci |
3156 flock->create_lock_counter(sync_jvms()); // sync_jvms used to get current bci |
3157 } |
3157 } |
|
3158 |
|
3159 // Create the rtm counters for this fast lock if needed. |
|
3160 flock->create_rtm_lock_counter(sync_jvms()); // sync_jvms used to get current bci |
|
3161 |
3158 // Add monitor to debug info for the slow path. If we block inside the |
3162 // Add monitor to debug info for the slow path. If we block inside the |
3159 // slow path and de-opt, we need the monitor hanging around |
3163 // slow path and de-opt, we need the monitor hanging around |
3160 map()->push_monitor( flock ); |
3164 map()->push_monitor( flock ); |
3161 |
3165 |
3162 const TypeFunc *tf = LockNode::lock_type(); |
3166 const TypeFunc *tf = LockNode::lock_type(); |