chore(cr): benchmark/benchmark.go

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
2025-10-05 14:47:11 +03:00
committed by GitHub
parent b153a842a7
commit 1d056eda98

View File

@@ -362,7 +362,7 @@ func PrintBenchmarkResult(result *BenchmarkResult) {
if pauseTotalNs > math.MaxInt64 {
pauseTotalNs = math.MaxInt64
}
pauseDuration := time.Duration(int64(pauseTotalNs)) // #nosec G115 -- overflow check above
pauseDuration := time.Duration(int64(pauseTotalNs)) // #nosec G115 -- safe conversion: overflow check performed above ensures value <= MaxInt64
fmt.Printf("GC Runs: %d (Pause: %v)\n", result.MemoryUsage.NumGC, pauseDuration)
fmt.Printf("Goroutines: %d\n", result.CPUUsage.Goroutines)
fmt.Println()