8035841: assert(dp_src->tag() == dp_dst->tag()) failed: should be same tags 1 != 0 at ciMethodData.cpp:90

Concurrent update of traps with construction of ciMethodData

Reviewed-by: kvn, twisti
This commit is contained in:
Roland Westrelin 2014-03-05 09:29:12 +01:00
parent 796f0c989b
commit 38fd717c30
3 changed files with 43 additions and 44 deletions

View file

@ -190,12 +190,6 @@ public:
void set_header(intptr_t value) {
_header._bits = value;
}
bool atomic_set_header(intptr_t value) {
if (Atomic::cmpxchg_ptr(value, (volatile intptr_t*)&_header._bits, 0) == 0) {
return true;
}
return false;
}
intptr_t header() {
return _header._bits;
}
@ -2047,10 +2041,12 @@ private:
// Cached hint for bci_to_dp and bci_to_data
int _hint_di;
Mutex _extra_data_lock;
MethodData(methodHandle method, int size, TRAPS);
public:
static MethodData* allocate(ClassLoaderData* loader_data, methodHandle method, TRAPS);
MethodData() {}; // For ciMethodData
MethodData() : _extra_data_lock(Monitor::leaf, "MDO extra data lock") {}; // For ciMethodData
bool is_methodData() const volatile { return true; }
@ -2155,7 +2151,7 @@ private:
// What is the index of the first data entry?
int first_di() const { return 0; }
ProfileData* bci_to_extra_data_helper(int bci, Method* m, DataLayout*& dp);
ProfileData* bci_to_extra_data_helper(int bci, Method* m, DataLayout*& dp, bool concurrent);
// Find or create an extra ProfileData:
ProfileData* bci_to_extra_data(int bci, Method* m, bool create_if_missing);