예제 #1
0
        private void AddResult(BenchmarkItem item, double totalTime, int timesRun)
        {
            if (!_results.ContainsKey(item.Title))
            {
                _results.Add(item.Title, new BenchmarkResult {
                    Title = item.Title, TotalTime = 0.0, TimeRun = 0
                });
            }

            var result = _results[item.Title];

            result.TimeRun     += timesRun;
            result.TotalTime   += totalTime;
            _totalMilliseconds += totalTime;
        }
예제 #2
0
        private void AddResult(BenchmarkItem item, double totalTime, int timesRun)
        {
            if (!_results.ContainsKey(item.Title))
            {
                _results.Add(item.Title, new BenchmarkResult { Title = item.Title, TotalTime = 0.0, TimeRun = 0});
            }

            var result = _results[item.Title];
            result.TimeRun += timesRun;
            result.TotalTime += totalTime;
            _totalMilliseconds += totalTime;
        }