--- a/hotspot/src/share/vm/opto/output.cpp Wed Apr 24 20:55:28 2013 -0400
+++ b/hotspot/src/share/vm/opto/output.cpp Wed Apr 24 21:11:02 2013 -0400
@@ -1043,21 +1043,6 @@
debug_info->end_non_safepoint(pc_offset);
}
-
-
-// helper for fill_buffer bailout logic
-static void turn_off_compiler(Compile* C) {
- if (CodeCache::largest_free_block() >= CodeCacheMinimumFreeSpace*10) {
- // Do not turn off compilation if a single giant method has
- // blown the code cache size.
- C->record_failure("excessive request to CodeCache");
- } else {
- // Let CompilerBroker disable further compilations.
- C->record_failure("CodeCache is full");
- }
-}
-
-
//------------------------------init_buffer------------------------------------
CodeBuffer* Compile::init_buffer(uint* blk_starts) {
@@ -1157,7 +1142,7 @@
// Have we run out of code space?
if ((cb->blob() == NULL) || (!CompileBroker::should_compile_new_jobs())) {
- turn_off_compiler(this);
+ C->record_failure("CodeCache is full");
return NULL;
}
// Configure the code buffer.
@@ -1475,7 +1460,7 @@
// Verify that there is sufficient space remaining
cb->insts()->maybe_expand_to_ensure_remaining(MAX_inst_size);
if ((cb->blob() == NULL) || (!CompileBroker::should_compile_new_jobs())) {
- turn_off_compiler(this);
+ C->record_failure("CodeCache is full");
return;
}
@@ -1632,7 +1617,7 @@
// One last check for failed CodeBuffer::expand:
if ((cb->blob() == NULL) || (!CompileBroker::should_compile_new_jobs())) {
- turn_off_compiler(this);
+ C->record_failure("CodeCache is full");
return;
}