The ResourceMark shown here is new in 1.5.0_06. It is incorrect, in that calls to "get_ctrl" can call "_nodes.map" which is a growable array. If the array DOES grow here, the then new storage will be allocated inside the ResourceMark, and reclaimed on exit from get_late_ctrl, leaving the _nodes data structure dangling. //------------------------------get_late_ctrl---------------------------------- // Compute latest legal control. Node *PhaseIdealLoop::get_late_ctrl( Node *n, Node *early ) { ResourceMark rm; // Temp allocation assert(early != NULL, "early control should not be NULL");
|