diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2019-03-22 12:56:42 +0100 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2019-03-22 12:56:42 +0100 |
| commit | 028c09511bd506471368d5c7bd35e0475c7059f2 (patch) | |
| tree | a6c2c08753a27fbaf2d0cd35a4f8496bda5f09f2 /pkg/bisect | |
| parent | 9ad9ef29caa52714dd5faff167e4b61643e40a7e (diff) | |
pkg/bisect: detect when too many instances errored
We currently skip a commit iff all 10 instances errored.
But if, say, only 9 errored we consider it as OK,
but this significnalty reduces chances of detecting flaky crashes.
So skip if more than 2/3 errored.
Update #501
Diffstat (limited to 'pkg/bisect')
| -rw-r--r-- | pkg/bisect/bisect.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/pkg/bisect/bisect.go b/pkg/bisect/bisect.go index eff0601b4..dea41581f 100644 --- a/pkg/bisect/bisect.go +++ b/pkg/bisect/bisect.go @@ -275,7 +275,8 @@ func (env *env) test() (vcs.BisectResult, *vcs.Commit, *report.Report, error) { return vcs.BisectSkip, current, nil, nil } testStart := time.Now() - results, err := env.inst.Test(10, cfg.Repro.Syz, cfg.Repro.Opts, cfg.Repro.C) + const numTests = 10 + results, err := env.inst.Test(numTests, cfg.Repro.Syz, cfg.Repro.Opts, cfg.Repro.C) env.testTime += time.Since(testStart) if err != nil { env.log("failed: %v", err) @@ -285,6 +286,10 @@ func (env *env) test() (vcs.BisectResult, *vcs.Commit, *report.Report, error) { res := vcs.BisectSkip if bad != 0 { res = vcs.BisectBad + } else if numTests-good-bad > numTests/3*2 { + // More than 2/3 of instances failed with infrastructure error, + // can't reliably tell that the commit is good. + res = vcs.BisectSkip } else if good != 0 { res = vcs.BisectGood } |
