Skip to content

Commit e062f85

Browse files
committed
Fixed Perf Result Calculation
1 parent 80afdbc commit e062f85

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

UnityPerformanceBenchmarkReporter/PerformanceTestRunProcessor.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,8 +163,10 @@ private double GetAggregatedSampleValue(SampleGroup sampleGroup)
163163
private MeasurementResult DeterminePerformanceResult(SampleGroupResult sampleGroup, uint sigFig)
164164
{
165165
var measurementResult = MeasurementResult.Neutral;
166-
var positiveThresholdValue = sampleGroup.BaselineValue + (sampleGroup.BaselineValue + sampleGroup.StandardDeviation) * sampleGroup.Threshold;
167-
var negativeThresholdValue = sampleGroup.BaselineValue - (sampleGroup.BaselineValue + sampleGroup.StandardDeviation) * sampleGroup.Threshold;
166+
var positiveThresholdValue = sampleGroup.BaselineValue + (sampleGroup.BaselineValue * sampleGroup.Threshold);
167+
var negativeThresholdValue = sampleGroup.BaselineValue - (sampleGroup.BaselineValue * sampleGroup.Threshold);
168+
positiveThresholdValue += sampleGroup.StandardDeviation;
169+
negativeThresholdValue -= sampleGroup.StandardDeviation;
168170

169171
if (sampleGroup.IncreaseIsBetter)
170172
{

0 commit comments

Comments
 (0)