8239072: subtype check macro node causes node budget to be exhausted

Reviewed-by: vlivanov, kvn
This commit is contained in:
Roland Westrelin 2020-03-31 10:40:17 +02:00
parent 73ddea766a
commit ea56776ef5
3 changed files with 71 additions and 15 deletions

View file

@ -4224,3 +4224,20 @@ void CloneMap::dump(node_idx_t key) const {
ni.dump();
}
}
// Move Allocate nodes to the start of the list
void Compile::sort_macro_nodes() {
int count = macro_count();
int allocates = 0;
for (int i = 0; i < count; i++) {
Node* n = macro_node(i);
if (n->is_Allocate()) {
if (i != allocates) {
Node* tmp = macro_node(allocates);
_macro_nodes->at_put(allocates, n);
_macro_nodes->at_put(i, tmp);
}
allocates++;
}
}
}