File tree Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -61,6 +61,7 @@ import System.FilePath ((<.>), (</>))
6161import System.Process
6262import System.Time.Extra
6363import Text.ParserCombinators.ReadP (readP_to_S )
64+ import Text.Printf
6465charEdit :: Position -> TextDocumentContentChangeEvent
6566charEdit p =
6667 TextDocumentContentChangeEvent
@@ -368,15 +369,15 @@ runBenchmarksFun dir allBenchmarks = do
368369 [ [ name,
369370 show success,
370371 show samples,
371- show startup,
372- show runSetup',
373- show userWaits,
374- show delayedWork,
375- show $ firstResponse+ firstResponseDelayed,
372+ showMs startup,
373+ showMs runSetup',
374+ showMs userWaits,
375+ showMs delayedWork,
376+ showMs $ firstResponse+ firstResponseDelayed,
376377 -- Exclude first response as it has a lot of setup time included
377378 -- Assume that number of requests = number of modules * number of samples
378- show ((userWaits - firstResponse)/ ((fromIntegral samples - 1 )* modules)),
379- show runExperiment,
379+ showMs ((userWaits - firstResponse)/ ((fromIntegral samples - 1 )* modules)),
380+ showMs runExperiment,
380381 show rulesBuilt,
381382 show rulesChanged,
382383 show rulesVisited,
@@ -443,6 +444,9 @@ runBenchmarksFun dir allBenchmarks = do
443444 lspTestCaps =
444445 fullCaps {_window = Just $ WindowClientCapabilities (Just True ) Nothing Nothing }
445446
447+ showMs :: Seconds -> String
448+ showMs = printf " %.2f"
449+
446450data BenchRun = BenchRun
447451 { startup :: ! Seconds ,
448452 runSetup :: ! Seconds ,
You can’t perform that action at this time.
0 commit comments