< prev index next >

src/hotspot/share/jvmci/jvmciRuntime.cpp

Print this page

1725         if (mdp->decompile_count() > (uint)PerMethodRecompilationCutoff) {
1726           ResourceMark m;
1727           tty->print_cr("WARN: endless recompilation of %s. Method was set to not compilable.", method()->name_and_sig_as_C_string());
1728         }
1729 #endif
1730       }
1731 
1732       // All buffers in the CodeBuffer are allocated in the CodeCache.
1733       // If the code buffer is created on each compile attempt
1734       // as in C2, then it must be freed.
1735       //code_buffer->free_blob();
1736     } else {
1737       nm =  nmethod::new_nmethod(method,
1738                                  compile_id,
1739                                  entry_bci,
1740                                  offsets,
1741                                  orig_pc_offset,
1742                                  debug_info, dependencies, code_buffer,
1743                                  frame_words, oop_map_set,
1744                                  handler_table, implicit_exception_table,
1745                                  compiler, comp_level, GrowableArrayView<RuntimeStub*>::EMPTY,
1746                                  speculations, speculations_len,
1747                                  nmethod_mirror_index, nmethod_mirror_name, failed_speculations);
1748 
1749 
1750       // Free codeBlobs
1751       if (nm == NULL) {
1752         // The CodeCache is full.  Print out warning and disable compilation.
1753         {
1754           MutexUnlocker ml(Compile_lock);
1755           MutexUnlocker locker(MethodCompileQueue_lock);
1756           CompileBroker::handle_full_code_cache(CodeCache::get_code_blob_type(comp_level));
1757         }
1758         result = JVMCI::cache_full;
1759       } else {
1760         nm->set_has_unsafe_access(has_unsafe_access);
1761         nm->set_has_wide_vectors(has_wide_vector);
1762 
1763         // Record successful registration.
1764         // (Put nm into the task handle *before* publishing to the Java heap.)
1765         if (JVMCIENV->compile_state() != NULL) {

1725         if (mdp->decompile_count() > (uint)PerMethodRecompilationCutoff) {
1726           ResourceMark m;
1727           tty->print_cr("WARN: endless recompilation of %s. Method was set to not compilable.", method()->name_and_sig_as_C_string());
1728         }
1729 #endif
1730       }
1731 
1732       // All buffers in the CodeBuffer are allocated in the CodeCache.
1733       // If the code buffer is created on each compile attempt
1734       // as in C2, then it must be freed.
1735       //code_buffer->free_blob();
1736     } else {
1737       nm =  nmethod::new_nmethod(method,
1738                                  compile_id,
1739                                  entry_bci,
1740                                  offsets,
1741                                  orig_pc_offset,
1742                                  debug_info, dependencies, code_buffer,
1743                                  frame_words, oop_map_set,
1744                                  handler_table, implicit_exception_table,
1745                                  compiler, comp_level,
1746                                  speculations, speculations_len,
1747                                  nmethod_mirror_index, nmethod_mirror_name, failed_speculations);
1748 
1749 
1750       // Free codeBlobs
1751       if (nm == NULL) {
1752         // The CodeCache is full.  Print out warning and disable compilation.
1753         {
1754           MutexUnlocker ml(Compile_lock);
1755           MutexUnlocker locker(MethodCompileQueue_lock);
1756           CompileBroker::handle_full_code_cache(CodeCache::get_code_blob_type(comp_level));
1757         }
1758         result = JVMCI::cache_full;
1759       } else {
1760         nm->set_has_unsafe_access(has_unsafe_access);
1761         nm->set_has_wide_vectors(has_wide_vector);
1762 
1763         // Record successful registration.
1764         // (Put nm into the task handle *before* publishing to the Java heap.)
1765         if (JVMCIENV->compile_state() != NULL) {
< prev index next >