178 // Only perform a PerfData operation if the PerfData object has been
179 // allocated and if the PerfDataManager has not freed the PerfData
180 // objects which can happen at normal VM shutdown.
181 //
182 #define OM_PERFDATA_OP(f, op_str) \
183 do { \
184 if (ObjectMonitor::_sync_ ## f != NULL && \
185 PerfDataManager::has_PerfData()) { \
186 ObjectMonitor::_sync_ ## f->op_str; \
187 } \
188 } while (0)
189
190 static PerfCounter * _sync_ContendedLockAttempts;
191 static PerfCounter * _sync_FutileWakeups;
192 static PerfCounter * _sync_Parks;
193 static PerfCounter * _sync_Notifications;
194 static PerfCounter * _sync_Inflations;
195 static PerfCounter * _sync_Deflations;
196 static PerfLongVariable * _sync_MonExtant;
197
198 static int Knob_VerifyMatch;
199 static int Knob_SpinLimit;
200
201 void* operator new (size_t size) throw();
202 void* operator new[] (size_t size) throw();
203 void operator delete(void* p);
204 void operator delete[] (void *p);
205
206 // TODO-FIXME: the "offset" routines should return a type of off_t instead of int ...
207 // ByteSize would also be an appropriate type.
208 static int header_offset_in_bytes() { return offset_of(ObjectMonitor, _header); }
209 static int object_offset_in_bytes() { return offset_of(ObjectMonitor, _object); }
210 static int owner_offset_in_bytes() { return offset_of(ObjectMonitor, _owner); }
211 static int count_offset_in_bytes() { return offset_of(ObjectMonitor, _count); }
212 static int recursions_offset_in_bytes() { return offset_of(ObjectMonitor, _recursions); }
213 static int cxq_offset_in_bytes() { return offset_of(ObjectMonitor, _cxq); }
214 static int succ_offset_in_bytes() { return offset_of(ObjectMonitor, _succ); }
215 static int EntryList_offset_in_bytes() { return offset_of(ObjectMonitor, _EntryList); }
216
217 // ObjectMonitor references can be ORed with markOopDesc::monitor_value
218 // as part of the ObjectMonitor tagging mechanism. When we combine an
|
178 // Only perform a PerfData operation if the PerfData object has been
179 // allocated and if the PerfDataManager has not freed the PerfData
180 // objects which can happen at normal VM shutdown.
181 //
182 #define OM_PERFDATA_OP(f, op_str) \
183 do { \
184 if (ObjectMonitor::_sync_ ## f != NULL && \
185 PerfDataManager::has_PerfData()) { \
186 ObjectMonitor::_sync_ ## f->op_str; \
187 } \
188 } while (0)
189
190 static PerfCounter * _sync_ContendedLockAttempts;
191 static PerfCounter * _sync_FutileWakeups;
192 static PerfCounter * _sync_Parks;
193 static PerfCounter * _sync_Notifications;
194 static PerfCounter * _sync_Inflations;
195 static PerfCounter * _sync_Deflations;
196 static PerfLongVariable * _sync_MonExtant;
197
198 static int Knob_SpinLimit;
199
200 void* operator new (size_t size) throw();
201 void* operator new[] (size_t size) throw();
202 void operator delete(void* p);
203 void operator delete[] (void *p);
204
205 // TODO-FIXME: the "offset" routines should return a type of off_t instead of int ...
206 // ByteSize would also be an appropriate type.
207 static int header_offset_in_bytes() { return offset_of(ObjectMonitor, _header); }
208 static int object_offset_in_bytes() { return offset_of(ObjectMonitor, _object); }
209 static int owner_offset_in_bytes() { return offset_of(ObjectMonitor, _owner); }
210 static int count_offset_in_bytes() { return offset_of(ObjectMonitor, _count); }
211 static int recursions_offset_in_bytes() { return offset_of(ObjectMonitor, _recursions); }
212 static int cxq_offset_in_bytes() { return offset_of(ObjectMonitor, _cxq); }
213 static int succ_offset_in_bytes() { return offset_of(ObjectMonitor, _succ); }
214 static int EntryList_offset_in_bytes() { return offset_of(ObjectMonitor, _EntryList); }
215
216 // ObjectMonitor references can be ORed with markOopDesc::monitor_value
217 // as part of the ObjectMonitor tagging mechanism. When we combine an
|