diff -r f67065f02409 -r b84fd7d73702 src/share/vm/oops/methodData.cpp --- a/src/share/vm/oops/methodData.cpp Mon Apr 08 07:40:08 2013 -0700 +++ b/src/share/vm/oops/methodData.cpp Tue Apr 09 09:54:17 2013 -0700 @@ -660,29 +660,9 @@ // Set the method back-pointer. _method = method(); - _invocation_counter.init(); - _backedge_counter.init(); - _invocation_counter_start = 0; - _backedge_counter_start = 0; - _num_loops = 0; - _num_blocks = 0; - _highest_comp_level = 0; - _highest_osr_comp_level = 0; - _would_profile = true; + init(); set_creation_mileage(mileage_of(method())); - // Initialize flags and trap history. - _nof_decompiles = 0; - _nof_overflow_recompiles = 0; - _nof_overflow_traps = 0; - _eflags = 0; - _arg_local = 0; - _arg_stack = 0; - _arg_returned = 0; - assert(sizeof(_trap_hist) % sizeof(HeapWord) == 0, "align"); - Copy::zero_to_words((HeapWord*) &_trap_hist, - sizeof(_trap_hist) / sizeof(HeapWord)); - // Go through the bytecodes and allocate and initialize the // corresponding data cells. int data_size = 0; @@ -721,7 +701,27 @@ post_initialize(&stream); set_size(object_size); +} +void MethodData::init() { + _invocation_counter.init(); + _backedge_counter.init(); + _invocation_counter_start = 0; + _backedge_counter_start = 0; + _num_loops = 0; + _num_blocks = 0; + _highest_comp_level = 0; + _highest_osr_comp_level = 0; + _would_profile = true; + + // Initialize flags and trap history. + _nof_decompiles = 0; + _nof_overflow_recompiles = 0; + _nof_overflow_traps = 0; + clear_escape_info(); + assert(sizeof(_trap_hist) % sizeof(HeapWord) == 0, "align"); + Copy::zero_to_words((HeapWord*) &_trap_hist, + sizeof(_trap_hist) / sizeof(HeapWord)); } // Get a measure of how much mileage the method has on it.