--- a/src/hotspot/share/oops/cpCache.cpp Thu Jan 18 09:01:00 2018 -0800
+++ b/src/hotspot/share/oops/cpCache.cpp Thu Jan 18 18:58:46 2018 +0000
@@ -177,6 +177,7 @@
// instruction somehow links to a non-interface method (in Object).
// In that case, the method has no itable index and must be invoked as a virtual.
// Set a flag to keep track of this corner case.
+ assert(method->is_public(), "Calling non-public method in Object with invokeinterface");
change_to_virtual = true;
// ...and fall through as if we were handling invokevirtual: