# HG changeset patch # User ewendeli # Date 1359927837 -3600 # Node ID b5cb079ecaa4006688e18113b13e0277e2b66138 # Parent 20b605466ccb1b3725eb25314d9e8782199630c5# Parent 77443715ec55cf6fa0ed04d39a273719afcc9c2a Merge diff -r 20b605466ccb -r b5cb079ecaa4 src/share/vm/interpreter/linkResolver.cpp --- a/src/share/vm/interpreter/linkResolver.cpp Thu Jan 31 17:04:28 2013 -0800 +++ b/src/share/vm/interpreter/linkResolver.cpp Sun Feb 03 22:43:57 2013 +0100 @@ -803,7 +803,7 @@ if (!direct_calling_default_method && check_access && // a) check if ACC_SUPER flag is set for the current class - current_klass->is_super() && + (current_klass->is_super() || !AllowNonVirtualCalls) && // b) check if the method class is a superclass of the current class (superclass relation is not reflexive!) current_klass->is_subtype_of(method_klass()) && current_klass() != method_klass() && diff -r 20b605466ccb -r b5cb079ecaa4 src/share/vm/opto/loopTransform.cpp diff -r 20b605466ccb -r b5cb079ecaa4 src/share/vm/runtime/arguments.cpp diff -r 20b605466ccb -r b5cb079ecaa4 src/share/vm/runtime/globals.hpp --- a/src/share/vm/runtime/globals.hpp Thu Jan 31 17:04:28 2013 -0800 +++ b/src/share/vm/runtime/globals.hpp Sun Feb 03 22:43:57 2013 +0100 @@ -3634,7 +3634,10 @@ "Enable internal testing APIs") \ \ product(bool, PrintGCCause, true, \ - "Include GC cause in GC logging") + "Include GC cause in GC logging") \ + \ + product(bool, AllowNonVirtualCalls, false, \ + "Obey the ACC_SUPER flag and allow invokenonvirtual calls") /* * Macros for factoring of globals