Current code in AdapterHandlerLibrary::print_handler_on() searches for a AdapterHandlerEntry that corresponds to the CodeBlob passed as parameter. During the search it converts AdapterHandlerEntry to its CodeBlob by calling CodeCache::find_blob(handler->get_i2c_entry():
auto findblob_runtime_table = [&] (AdapterFingerPrint* key, AdapterHandlerEntry* handler) {
if (b == CodeCache::find_blob(handler->get_i2c_entry())) {
found = true;
return false; // abort iteration
} else {
return true; // keep looking
}
But with https://bugs.openjdk.org/browse/JDK-8366905, AdapterHandlerEntry stores a direct pointer to the AdapterBlob, so the call to CodeBlob::find_blob() is not needed.
auto findblob_runtime_table = [&] (AdapterFingerPrint* key, AdapterHandlerEntry* handler) {
if (b == CodeCache::find_blob(handler->get_i2c_entry())) {
found = true;
return false; // abort iteration
} else {
return true; // keep looking
}
But with https://bugs.openjdk.org/browse/JDK-8366905, AdapterHandlerEntry stores a direct pointer to the AdapterBlob, so the call to CodeBlob::find_blob() is not needed.