--- old/src/share/vm/oops/methodCounters.hpp 2016-11-03 04:05:52.857678478 -0700 +++ new/src/share/vm/oops/methodCounters.hpp 2016-11-03 04:05:52.771674661 -0700 @@ -34,7 +34,9 @@ friend class VMStructs; friend class JVMCIVMStructs; private: +#if INCLUDE_AOT Method* _method; // Back link to Method +#endif #if defined(COMPILER2) || INCLUDE_JVMCI int _interpreter_invocation_count; // Count of times invoked (reused as prev_event_count in tiered) u2 _interpreter_throwout_count; // Count of times method was exited via exception while interpreting @@ -65,7 +67,10 @@ u1 _highest_osr_comp_level; // Same for OSR level #endif - MethodCounters(methodHandle mh) : _method(mh()), + MethodCounters(methodHandle mh) : +#if INCLUDE_AOT + _method(mh()), +#endif _nmethod_age(INT_MAX) #ifdef TIERED , _rate(0), @@ -109,7 +114,7 @@ void deallocate_contents(ClassLoaderData* loader_data) {} DEBUG_ONLY(bool on_stack() { return false; }) // for template - Method* method() const { return _method; } + AOT_ONLY(Method* method() const { return _method; }) static int size() { return sizeof(MethodCounters) / wordSize; }