src/share/vm/opto/gcm.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File 7092905 Sdiff src/share/vm/opto

src/share/vm/opto/gcm.cpp

Print this page




1342   }
1343 #endif
1344 
1345   // Schedule locally.  Right now a simple topological sort.
1346   // Later, do a real latency aware scheduler.
1347   uint max_idx = C->unique();
1348   GrowableArray<int> ready_cnt(max_idx, max_idx, -1);
1349   visited.Clear();
1350   for (i = 0; i < _num_blocks; i++) {
1351     if (!_blocks[i]->schedule_local(this, matcher, ready_cnt, visited)) {
1352       if (!C->failure_reason_is(C2Compiler::retry_no_subsuming_loads())) {
1353         C->record_method_not_compilable("local schedule failed");
1354       }
1355       return;
1356     }
1357   }
1358 
1359   // If we inserted any instructions between a Call and his CatchNode,
1360   // clone the instructions on all paths below the Catch.
1361   for( i=0; i < _num_blocks; i++ )
1362     _blocks[i]->call_catch_cleanup(_bbs);
1363 
1364 #ifndef PRODUCT
1365   if (trace_opto_pipelining()) {
1366     tty->print("\n---- After GlobalCodeMotion ----\n");
1367     for (uint i = 0; i < _num_blocks; i++) {
1368       _blocks[i]->dump();
1369     }
1370   }
1371 #endif
1372   // Dead.
1373   _node_latency = (GrowableArray<uint> *)0xdeadbeef;
1374 }
1375 
1376 
1377 //------------------------------Estimate_Block_Frequency-----------------------
1378 // Estimate block frequencies based on IfNode probabilities.
1379 void PhaseCFG::Estimate_Block_Frequency() {
1380 
1381   // Force conditional branches leading to uncommon traps to be unlikely,
1382   // not because we get to the uncommon_trap with less relative frequency,




1342   }
1343 #endif
1344 
1345   // Schedule locally.  Right now a simple topological sort.
1346   // Later, do a real latency aware scheduler.
1347   uint max_idx = C->unique();
1348   GrowableArray<int> ready_cnt(max_idx, max_idx, -1);
1349   visited.Clear();
1350   for (i = 0; i < _num_blocks; i++) {
1351     if (!_blocks[i]->schedule_local(this, matcher, ready_cnt, visited)) {
1352       if (!C->failure_reason_is(C2Compiler::retry_no_subsuming_loads())) {
1353         C->record_method_not_compilable("local schedule failed");
1354       }
1355       return;
1356     }
1357   }
1358 
1359   // If we inserted any instructions between a Call and his CatchNode,
1360   // clone the instructions on all paths below the Catch.
1361   for( i=0; i < _num_blocks; i++ )
1362     _blocks[i]->call_catch_cleanup(_bbs, C);
1363 
1364 #ifndef PRODUCT
1365   if (trace_opto_pipelining()) {
1366     tty->print("\n---- After GlobalCodeMotion ----\n");
1367     for (uint i = 0; i < _num_blocks; i++) {
1368       _blocks[i]->dump();
1369     }
1370   }
1371 #endif
1372   // Dead.
1373   _node_latency = (GrowableArray<uint> *)0xdeadbeef;
1374 }
1375 
1376 
1377 //------------------------------Estimate_Block_Frequency-----------------------
1378 // Estimate block frequencies based on IfNode probabilities.
1379 void PhaseCFG::Estimate_Block_Frequency() {
1380 
1381   // Force conditional branches leading to uncommon traps to be unlikely,
1382   // not because we get to the uncommon_trap with less relative frequency,


src/share/vm/opto/gcm.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File