From 3ddc9e924e7e747f3d75501eaa8cd731d67f5e7c Mon Sep 17 00:00:00 2001 From: Omar Rizwan Date: Sun, 13 Aug 2023 23:07:57 -0400 Subject: More small monitoring improvements. Remote flamegraph tid --- virtual-programs/display.folk | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'virtual-programs') diff --git a/virtual-programs/display.folk b/virtual-programs/display.folk index d5623d10..5e16797f 100644 --- a/virtual-programs/display.folk +++ b/virtual-programs/display.folk @@ -80,19 +80,20 @@ On process { } set displayCommands [lmap sublist [lsort -command lcomp $displayList] {lindex $sublist 1}] + set renderTime [baretime [list foreach command $displayCommands { {*}$command }]] set commitTime [baretime commitThenClearStaging] - set inLastSecond 0 + set framesInLastSecond 0 set now [clock milliseconds] lappend frames $now foreach frame $frames { if {$frame > $now - 1000} { - incr inLastSecond + incr framesInLastSecond } } - set frames [lreplace $frames 0 end-$inLastSecond] - Commit { Claim the display time is "render $renderTime us + commit $commitTime us ($inLastSecond fps)" } + set frames [lreplace $frames 0 end-$framesInLastSecond] + Commit { Claim the display time is "render $renderTime us + commit $commitTime us ($framesInLastSecond fps)" } } } # TODO: remove this compatibility hack -- cgit v1.2.3