1.1 --- a/src/share/vm/runtime/compilationPolicy.cpp Fri Aug 31 16:39:35 2012 -0700 1.2 +++ b/src/share/vm/runtime/compilationPolicy.cpp Sat Sep 01 13:25:18 2012 -0400 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -28,8 +28,8 @@ 1.11 #include "code/scopeDesc.hpp" 1.12 #include "compiler/compilerOracle.hpp" 1.13 #include "interpreter/interpreter.hpp" 1.14 -#include "oops/methodDataOop.hpp" 1.15 -#include "oops/methodOop.hpp" 1.16 +#include "oops/methodData.hpp" 1.17 +#include "oops/method.hpp" 1.18 #include "oops/oop.inline.hpp" 1.19 #include "prims/nativeLookup.hpp" 1.20 #include "runtime/advancedThresholdPolicy.hpp" 1.21 @@ -222,7 +222,7 @@ 1.22 // 1.23 class CounterDecay : public AllStatic { 1.24 static jlong _last_timestamp; 1.25 - static void do_method(methodOop m) { 1.26 + static void do_method(Method* m) { 1.27 m->invocation_counter()->decay(); 1.28 } 1.29 public: 1.30 @@ -245,9 +245,9 @@ 1.31 double classes_per_tick = nclasses * (CounterDecayMinIntervalLength * 1e-3 / 1.32 CounterHalfLifeTime); 1.33 for (int i = 0; i < classes_per_tick; i++) { 1.34 - klassOop k = SystemDictionary::try_get_next_class(); 1.35 - if (k != NULL && k->klass_part()->oop_is_instance()) { 1.36 - instanceKlass::cast(k)->methods_do(do_method); 1.37 + Klass* k = SystemDictionary::try_get_next_class(); 1.38 + if (k != NULL && k->oop_is_instance()) { 1.39 + InstanceKlass::cast(k)->methods_do(do_method); 1.40 } 1.41 } 1.42 } 1.43 @@ -277,12 +277,12 @@ 1.44 1.45 // This method can be called by any component of the runtime to notify the policy 1.46 // that it's recommended to delay the complation of this method. 1.47 -void NonTieredCompPolicy::delay_compilation(methodOop method) { 1.48 +void NonTieredCompPolicy::delay_compilation(Method* method) { 1.49 method->invocation_counter()->decay(); 1.50 method->backedge_counter()->decay(); 1.51 } 1.52 1.53 -void NonTieredCompPolicy::disable_compilation(methodOop method) { 1.54 +void NonTieredCompPolicy::disable_compilation(Method* method) { 1.55 method->invocation_counter()->set_state(InvocationCounter::wait_for_nothing); 1.56 method->backedge_counter()->set_state(InvocationCounter::wait_for_nothing); 1.57 } 1.58 @@ -291,8 +291,8 @@ 1.59 return compile_queue->first(); 1.60 } 1.61 1.62 -bool NonTieredCompPolicy::is_mature(methodOop method) { 1.63 - methodDataOop mdo = method->method_data(); 1.64 +bool NonTieredCompPolicy::is_mature(Method* method) { 1.65 + MethodData* mdo = method->method_data(); 1.66 assert(mdo != NULL, "Should be"); 1.67 uint current = mdo->mileage_of(method); 1.68 uint initial = mdo->creation_mileage(); 1.69 @@ -371,7 +371,7 @@ 1.70 bc->print(); 1.71 if (ProfileInterpreter) { 1.72 if (bci != InvocationEntryBci) { 1.73 - methodDataOop mdo = m->method_data(); 1.74 + MethodData* mdo = m->method_data(); 1.75 if (mdo != NULL) { 1.76 int count = mdo->bci_to_data(branch_bci)->as_JumpData()->taken(); 1.77 tty->print_cr("back branch count = %d", count); 1.78 @@ -627,7 +627,7 @@ 1.79 // negative filter: should send NOT be inlined? returns NULL (--> inline) or rejection msg 1.80 if (m->is_abstract()) return (_msg = "abstract method"); 1.81 // note: we allow ik->is_abstract() 1.82 - if (!instanceKlass::cast(m->method_holder())->is_initialized()) return (_msg = "method holder not initialized"); 1.83 + if (!InstanceKlass::cast(m->method_holder())->is_initialized()) return (_msg = "method holder not initialized"); 1.84 if (m->is_native()) return (_msg = "native method"); 1.85 nmethod* m_code = m->code(); 1.86 if (m_code != NULL && m_code->code_size() > InlineSmallCode) 1.87 @@ -639,7 +639,7 @@ 1.88 if ((m->code() == NULL) && m->was_never_executed()) return (_msg = "never executed"); 1.89 if (!m->was_executed_more_than(MIN2(MinInliningThreshold, CompileThreshold >> 1))) return (_msg = "executed < MinInliningThreshold times"); 1.90 } 1.91 - if (methodOopDesc::has_unloaded_classes_in_signature(m, JavaThread::current())) return (_msg = "unloaded signature classes"); 1.92 + if (Method::has_unloaded_classes_in_signature(m, JavaThread::current())) return (_msg = "unloaded signature classes"); 1.93 1.94 return NULL; 1.95 }