@@ -216,7 +216,7 @@ PhaseChaitin::PhaseChaitin(uint unique, PhaseCFG &cfg, Matcher &matcher, bool sc
216216 , _scratch_int_pressure(0 , Matcher::int_pressure_limit())
217217 , _scratch_float_pressure(0 , Matcher::float_pressure_limit())
218218{
219- Compile::TracePhase tp (" ctorChaitin " , &timers[ _t_ctorChaitin] );
219+ Compile::TracePhase tp (_t_ctorChaitin);
220220
221221 _high_frequency_lrg = MIN2 (double (OPTO_LRG_HIGH_FREQ), _cfg.get_outer_loop_frequency ());
222222
@@ -321,7 +321,7 @@ int PhaseChaitin::clone_projs(Block* b, uint idx, Node* orig, Node* copy, uint&
321321
322322// Renumber the live ranges to compact them. Makes the IFG smaller.
323323void PhaseChaitin::compact () {
324- Compile::TracePhase tp (" chaitinCompact " , &timers[ _t_chaitinCompact] );
324+ Compile::TracePhase tp (_t_chaitinCompact);
325325
326326 // Current the _uf_map contains a series of short chains which are headed
327327 // by a self-cycle. All the chains run from big numbers to little numbers.
@@ -397,7 +397,7 @@ void PhaseChaitin::Register_Allocate() {
397397#endif
398398
399399 {
400- Compile::TracePhase tp (" computeLive " , &timers[ _t_computeLive] );
400+ Compile::TracePhase tp (_t_computeLive);
401401 _live = nullptr ; // Mark live as being not available
402402 rm.reset_to_mark (); // Reclaim working storage
403403 IndexSet::reset_memory (C, &live_arena);
@@ -414,7 +414,7 @@ void PhaseChaitin::Register_Allocate() {
414414 // at all the GC points, and "stretches" the live range of any base pointer
415415 // to the GC point.
416416 if (stretch_base_pointer_live_ranges (&live_arena)) {
417- Compile::TracePhase tp (" computeLive (sbplr)" , &timers[ _t_computeLive] );
417+ Compile::TracePhase tp (" computeLive (sbplr)" , _t_computeLive);
418418 // Since some live range stretched, I need to recompute live
419419 _live = nullptr ;
420420 rm.reset_to_mark (); // Reclaim working storage
@@ -439,7 +439,7 @@ void PhaseChaitin::Register_Allocate() {
439439 // This pass works on virtual copies. Any virtual copies which are not
440440 // coalesced get manifested as actual copies
441441 {
442- Compile::TracePhase tp (" chaitinCoalesce1 " , &timers[ _t_chaitinCoalesce1] );
442+ Compile::TracePhase tp (_t_chaitinCoalesce1);
443443
444444 PhaseAggressiveCoalesce coalesce (*this );
445445 coalesce.coalesce_driver ();
@@ -454,7 +454,7 @@ void PhaseChaitin::Register_Allocate() {
454454 // After aggressive coalesce, attempt a first cut at coloring.
455455 // To color, we need the IFG and for that we need LIVE.
456456 {
457- Compile::TracePhase tp (" computeLive " , &timers[ _t_computeLive] );
457+ Compile::TracePhase tp (_t_computeLive);
458458 _live = nullptr ;
459459 rm.reset_to_mark (); // Reclaim working storage
460460 IndexSet::reset_memory (C, &live_arena);
@@ -495,7 +495,7 @@ void PhaseChaitin::Register_Allocate() {
495495 compact (); // Compact LRGs; return new lower max lrg
496496
497497 {
498- Compile::TracePhase tp (" computeLive " , &timers[ _t_computeLive] );
498+ Compile::TracePhase tp (_t_computeLive);
499499 _live = nullptr ;
500500 rm.reset_to_mark (); // Reclaim working storage
501501 IndexSet::reset_memory (C, &live_arena);
@@ -509,7 +509,7 @@ void PhaseChaitin::Register_Allocate() {
509509 _ifg->Compute_Effective_Degree ();
510510 // Only do conservative coalescing if requested
511511 if (OptoCoalesce) {
512- Compile::TracePhase tp (" chaitinCoalesce2 " , &timers[ _t_chaitinCoalesce2] );
512+ Compile::TracePhase tp (_t_chaitinCoalesce2);
513513 // Conservative (and pessimistic) copy coalescing of those spills
514514 PhaseConservativeCoalesce coalesce (*this );
515515 // If max live ranges greater than cutoff, don't color the stack.
@@ -568,7 +568,7 @@ void PhaseChaitin::Register_Allocate() {
568568
569569 // Nuke the live-ness and interference graph and LiveRanGe info
570570 {
571- Compile::TracePhase tp (" computeLive " , &timers[ _t_computeLive] );
571+ Compile::TracePhase tp (_t_computeLive);
572572 _live = nullptr ;
573573 rm.reset_to_mark (); // Reclaim working storage
574574 IndexSet::reset_memory (C, &live_arena);
@@ -586,7 +586,7 @@ void PhaseChaitin::Register_Allocate() {
586586
587587 // Only do conservative coalescing if requested
588588 if (OptoCoalesce) {
589- Compile::TracePhase tp (" chaitinCoalesce3 " , &timers[ _t_chaitinCoalesce3] );
589+ Compile::TracePhase tp (_t_chaitinCoalesce3);
590590 // Conservative (and pessimistic) copy coalescing
591591 PhaseConservativeCoalesce coalesce (*this );
592592 // Check for few live ranges determines how aggressive coalesce is.
@@ -1183,7 +1183,7 @@ void PhaseChaitin::set_was_low() {
11831183
11841184// Compute cost/area ratio, in case we spill. Build the lo-degree list.
11851185void PhaseChaitin::cache_lrg_info ( ) {
1186- Compile::TracePhase tp (" chaitinCacheLRG " , &timers[ _t_chaitinCacheLRG] );
1186+ Compile::TracePhase tp (_t_chaitinCacheLRG);
11871187
11881188 for (uint i = 1 ; i < _lrg_map.max_lrg_id (); i++) {
11891189 LRG &lrg = lrgs (i);
@@ -1217,7 +1217,7 @@ void PhaseChaitin::cache_lrg_info( ) {
12171217
12181218// Simplify the IFG by removing LRGs of low degree.
12191219void PhaseChaitin::Simplify ( ) {
1220- Compile::TracePhase tp (" chaitinSimplify " , &timers[ _t_chaitinSimplify] );
1220+ Compile::TracePhase tp (_t_chaitinSimplify);
12211221
12221222 while ( 1 ) { // Repeat till simplified it all
12231223 // May want to explore simplifying lo_degree before _lo_stk_degree.
@@ -1516,7 +1516,7 @@ OptoReg::Name PhaseChaitin::choose_color( LRG &lrg, int chunk ) {
15161516// everything going back is guaranteed a color. Select that color. If some
15171517// hi-degree LRG cannot get a color then we record that we must spill.
15181518uint PhaseChaitin::Select ( ) {
1519- Compile::TracePhase tp (" chaitinSelect " , &timers[ _t_chaitinSelect] );
1519+ Compile::TracePhase tp (_t_chaitinSelect);
15201520
15211521 uint spill_reg = LRG::SPILL_REG;
15221522 _max_reg = OptoReg::Name (0 ); // Past max register used
@@ -1704,7 +1704,7 @@ void PhaseChaitin::fixup_spills() {
17041704 // This function does only cisc spill work.
17051705 if ( !UseCISCSpill ) return ;
17061706
1707- Compile::TracePhase tp (" fixupSpills " , &timers[ _t_fixupSpills] );
1707+ Compile::TracePhase tp (_t_fixupSpills);
17081708
17091709 // Grab the Frame Pointer
17101710 Node *fp = _cfg.get_root_block ()->head ()->in (1 )->in (TypeFunc::FramePtr);
0 commit comments