hotspot/src/share/vm/opto/loopUnswitch.cpp
changeset 14623 70c4c1be0a14
parent 13963 e5b53c306fb5
child 23528 8f1a7f5e8066
equal deleted inserted replaced
14622:8e94e4186d35 14623:70c4c1be0a14
    57     return false;
    57     return false;
    58   }
    58   }
    59   if (!_head->is_Loop()) {
    59   if (!_head->is_Loop()) {
    60     return false;
    60     return false;
    61   }
    61   }
    62   uint nodes_left = MaxNodeLimit - phase->C->unique();
    62   uint nodes_left = MaxNodeLimit - phase->C->live_nodes();
    63   if (2 * _body.size() > nodes_left) {
    63   if (2 * _body.size() > nodes_left) {
    64     return false; // Too speculative if running low on nodes.
    64     return false; // Too speculative if running low on nodes.
    65   }
    65   }
    66   LoopNode* head = _head->as_Loop();
    66   LoopNode* head = _head->as_Loop();
    67   if (head->unswitch_count() + 1 > head->unswitch_max()) {
    67   if (head->unswitch_count() + 1 > head->unswitch_max()) {