33 #include "ci/ciTypeFlow.hpp" |
33 #include "ci/ciTypeFlow.hpp" |
34 #include "compiler/compileLog.hpp" |
34 #include "compiler/compileLog.hpp" |
35 #include "interpreter/bytecode.hpp" |
35 #include "interpreter/bytecode.hpp" |
36 #include "interpreter/bytecodes.hpp" |
36 #include "interpreter/bytecodes.hpp" |
37 #include "memory/allocation.inline.hpp" |
37 #include "memory/allocation.inline.hpp" |
|
38 #include "opto/compile.hpp" |
38 #include "runtime/deoptimization.hpp" |
39 #include "runtime/deoptimization.hpp" |
39 #include "utilities/growableArray.hpp" |
40 #include "utilities/growableArray.hpp" |
40 |
41 |
41 // ciTypeFlow::JsrSet |
42 // ciTypeFlow::JsrSet |
42 // |
43 // |
2644 if (!blk->is_visited()) { |
2645 if (!blk->is_visited()) { |
2645 // forward arc in graph |
2646 // forward arc in graph |
2646 assert (!blk->has_pre_order(), ""); |
2647 assert (!blk->has_pre_order(), ""); |
2647 blk->set_next_pre_order(); |
2648 blk->set_next_pre_order(); |
2648 |
2649 |
2649 if (_next_pre_order >= MaxNodeLimit / 2) { |
2650 if (_next_pre_order >= (int)Compile::current()->max_node_limit() / 2) { |
2650 // Too many basic blocks. Bail out. |
2651 // Too many basic blocks. Bail out. |
2651 // This can happen when try/finally constructs are nested to depth N, |
2652 // This can happen when try/finally constructs are nested to depth N, |
2652 // and there is O(2**N) cloning of jsr bodies. See bug 4697245! |
2653 // and there is O(2**N) cloning of jsr bodies. See bug 4697245! |
2653 // "MaxNodeLimit / 2" is used because probably the parser will |
2654 // "MaxNodeLimit / 2" is used because probably the parser will |
2654 // generate at least twice that many nodes and bail out. |
2655 // generate at least twice that many nodes and bail out. |