Mercurial > hg > graal-jvmci-8
comparison src/share/vm/opto/domgraph.cpp @ 23421:c1091733abe6
8011858: Use Compile::live_nodes() instead of Compile::unique() in appropriate places
Reviewed-by: kvn, vlivanov
Contributed-by: vlad.ureche@gmail.com
author | zmajo |
---|---|
date | Wed, 16 Sep 2015 11:09:09 +0200 |
parents | 55fb97c4c58d |
children | b5f3a471e646 |
comparison
equal
deleted
inserted
replaced
23420:c1374141598c | 23421:c1091733abe6 |
---|---|
503 } | 503 } |
504 | 504 |
505 // Perform DFS search. Setup 'vertex' as DFS to vertex mapping. Setup | 505 // Perform DFS search. Setup 'vertex' as DFS to vertex mapping. Setup |
506 // 'semi' as vertex to DFS mapping. Set 'parent' to DFS parent. | 506 // 'semi' as vertex to DFS mapping. Set 'parent' to DFS parent. |
507 int NTarjan::DFS( NTarjan *ntarjan, VectorSet &visited, PhaseIdealLoop *pil, uint *dfsorder) { | 507 int NTarjan::DFS( NTarjan *ntarjan, VectorSet &visited, PhaseIdealLoop *pil, uint *dfsorder) { |
508 // Allocate stack of size C->unique()/8 to avoid frequent realloc | 508 // Allocate stack of size C->live_nodes()/8 to avoid frequent realloc |
509 GrowableArray <Node *> dfstack(pil->C->unique() >> 3); | 509 GrowableArray <Node *> dfstack(pil->C->live_nodes() >> 3); |
510 Node *b = pil->C->root(); | 510 Node *b = pil->C->root(); |
511 int dfsnum = 1; | 511 int dfsnum = 1; |
512 dfsorder[b->_idx] = dfsnum; // Cache parent's dfsnum for a later use | 512 dfsorder[b->_idx] = dfsnum; // Cache parent's dfsnum for a later use |
513 dfstack.push(b); | 513 dfstack.push(b); |
514 | 514 |