equal
deleted
inserted
replaced
33 // Get the hash code of the classes mirror if it exists, otherwise just |
33 // Get the hash code of the classes mirror if it exists, otherwise just |
34 // return a random number, which is one of the possible hash code used for |
34 // return a random number, which is one of the possible hash code used for |
35 // objects. We don't want to call the synchronizer hash code to install |
35 // objects. We don't want to call the synchronizer hash code to install |
36 // this value because it may safepoint. |
36 // this value because it may safepoint. |
37 static intptr_t object_hash(Klass* k) { |
37 static intptr_t object_hash(Klass* k) { |
38 intptr_t hc = k->java_mirror()->mark()->hash(); |
38 intptr_t hc = k->java_mirror()->mark().hash(); |
39 return hc != markOopDesc::no_hash ? hc : os::random(); |
39 return hc != markWord::no_hash ? hc : os::random(); |
40 } |
40 } |
41 |
41 |
42 // Seed value used for each alternative hash calculated. |
42 // Seed value used for each alternative hash calculated. |
43 juint AltHashing::compute_seed() { |
43 juint AltHashing::compute_seed() { |
44 jlong nanos = os::javaTimeNanos(); |
44 jlong nanos = os::javaTimeNanos(); |