--- a/src/hotspot/share/code/dependencies.cpp Tue Apr 03 10:27:46 2018 +0200
+++ b/src/hotspot/share/code/dependencies.cpp Tue Apr 03 13:15:27 2018 +0200
@@ -1818,12 +1818,12 @@
if (changes == NULL) {
// Validate all CallSites
- if (java_lang_invoke_CallSite::target(call_site) != method_handle)
+ if (!oopDesc::equals(java_lang_invoke_CallSite::target(call_site), method_handle))
return call_site->klass(); // assertion failed
} else {
// Validate the given CallSite
- if (call_site == changes->call_site() && java_lang_invoke_CallSite::target(call_site) != changes->method_handle()) {
- assert(method_handle != changes->method_handle(), "must be");
+ if (oopDesc::equals(call_site, changes->call_site()) && !oopDesc::equals(java_lang_invoke_CallSite::target(call_site), changes->method_handle())) {
+ assert(!oopDesc::equals(method_handle, changes->method_handle()), "must be");
return call_site->klass(); // assertion failed
}
}