diff options
author | Dave Parks <davep@lindenlab.com> | 2021-10-28 18:06:21 +0000 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2021-10-28 18:06:21 +0000 |
commit | 8d20480c5f77fe1fab8149d3cda79bdd61e77656 (patch) | |
tree | 6ba8844d6e3b29451dc70213f8e7278db4943fa3 /indra/newview/llfasttimerview.cpp | |
parent | aa7ca0aea134c9c40a0d4d1450cc64b7831d005f (diff) |
SL-16148 SL-16244 SL-16270 SL-16253 Remove most BlockTimers, remove LLMemTracked, introduce alignas, hook most/all reamining allocs, disable synchronous occlusion, and convert frequently accessed LLSingletons to LLSimpleton
Diffstat (limited to 'indra/newview/llfasttimerview.cpp')
-rw-r--r-- | indra/newview/llfasttimerview.cpp | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/indra/newview/llfasttimerview.cpp b/indra/newview/llfasttimerview.cpp index 239d162101..1605e4133d 100644 --- a/indra/newview/llfasttimerview.cpp +++ b/indra/newview/llfasttimerview.cpp @@ -716,7 +716,6 @@ void LLFastTimerView::exportCharts(const std::string& base, const std::string& t //====================================== buffer.clear(); - gGL.color3fv(base_col.mV); U32 count = 0; U32 total_count = base_execution.size(); @@ -1019,11 +1018,9 @@ void LLFastTimerView::printLineStats() } } -static LLTrace::BlockTimerStatHandle FTM_DRAW_LINE_GRAPH("Draw line graph"); - void LLFastTimerView::drawLineGraph() { - LL_RECORD_BLOCK_TIME(FTM_DRAW_LINE_GRAPH); + LL_PROFILE_ZONE_SCOPED; //draw line graph history gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); LLLocalClipRect clip(mGraphRect); @@ -1062,6 +1059,7 @@ void LLFastTimerView::drawLineGraph() F32Seconds cur_max(0); U32 cur_max_calls = 0; + for(block_timer_tree_df_iterator_t it = LLTrace::begin_block_timer_tree_df(FTM_FRAME); it != LLTrace::end_block_timer_tree_df(); ++it) @@ -1096,6 +1094,7 @@ void LLFastTimerView::drawLineGraph() F32 call_scale_factor = (F32)mGraphRect.getHeight() / (F32)max_calls; F32 time_scale_factor = (F32)mGraphRect.getHeight() / max_time.value(); F32 hz_scale_factor = (F32) mGraphRect.getHeight() / (1.f / max_time.value()); + for (U32 j = mRecording.getNumRecordedPeriods(); j > 0; j--) @@ -1103,7 +1102,7 @@ void LLFastTimerView::drawLineGraph() LLTrace::Recording& recording = mRecording.getPrevRecording(j); F32Seconds time = llmax(recording.getSum(*idp), F64Seconds(0.000001)); U32 calls = recording.getSum(idp->callCount()); - + if (is_hover_timer) { //normalize to highlighted timer @@ -1450,6 +1449,7 @@ void LLFastTimerView::updateTotalTime() void LLFastTimerView::drawBars() { + LL_PROFILE_ZONE_SCOPED; LLLocalClipRect clip(mBarRect); S32 bar_height = mBarRect.getHeight() / (MAX_VISIBLE_HISTORY + 2); @@ -1527,11 +1527,9 @@ void LLFastTimerView::drawBars() gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); } -static LLTrace::BlockTimerStatHandle FTM_UPDATE_TIMER_BAR_WIDTHS("Update timer bar widths"); - F32Seconds LLFastTimerView::updateTimerBarWidths(LLTrace::BlockTimerStatHandle* time_block, TimerBarRow& row, S32 history_index, U32& bar_index) { - LL_RECORD_BLOCK_TIME(FTM_UPDATE_TIMER_BAR_WIDTHS); + LL_PROFILE_ZONE_SCOPED; const F32Seconds self_time = history_index == -1 ? mRecording.getPeriodMean(time_block->selfTime(), RUNNING_AVERAGE_WIDTH) : mRecording.getPrevRecording(history_index).getSum(time_block->selfTime()); @@ -1555,11 +1553,9 @@ F32Seconds LLFastTimerView::updateTimerBarWidths(LLTrace::BlockTimerStatHandle* return full_time; } -static LLTrace::BlockTimerStatHandle FTM_UPDATE_TIMER_BAR_FRACTIONS("Update timer bar fractions"); - S32 LLFastTimerView::updateTimerBarOffsets(LLTrace::BlockTimerStatHandle* time_block, TimerBarRow& row, S32 timer_bar_index) { - LL_RECORD_BLOCK_TIME(FTM_UPDATE_TIMER_BAR_FRACTIONS); + LL_PROFILE_ZONE_SCOPED; TimerBar& timer_bar = row.mBars[timer_bar_index]; const F32Seconds bar_time = timer_bar.mTotalTime - timer_bar.mSelfTime; @@ -1620,6 +1616,7 @@ S32 LLFastTimerView::updateTimerBarOffsets(LLTrace::BlockTimerStatHandle* time_b S32 LLFastTimerView::drawBar(LLRect bar_rect, TimerBarRow& row, S32 image_width, S32 image_height, bool hovered, bool visible, S32 bar_index) { + LL_PROFILE_ZONE_SCOPED; TimerBar& timer_bar = row.mBars[bar_index]; LLTrace::BlockTimerStatHandle* time_block = timer_bar.mTimeBlock; |