aboutsummaryrefslogtreecommitdiffstats
path: root/syz-cluster/pkg
diff options
context:
space:
mode:
authorAleksandr Nogikh <nogikh@google.com>2025-08-19 12:09:14 +0200
committerAleksandr Nogikh <nogikh@google.com>2025-08-19 15:02:37 +0000
commit8c32f0ff1ce7f5076910229181d6f43a194531e4 (patch)
treef5c43e76dc546d14995c0254d9690960d3fb3a73 /syz-cluster/pkg
parent0773c4252b9eda702503351c75aca73526a13b6c (diff)
syz-cluster: skip fuzzing if binaries are the same
If all symbol hashes between the base and the pathed kernel match, there's no reason to spend time fuzzing the series. Add a 'skipped' status to the enum of possible session test results and set it from the fuzz-step.
Diffstat (limited to 'syz-cluster/pkg')
-rw-r--r--syz-cluster/pkg/api/api.go1
-rw-r--r--syz-cluster/pkg/db/migrations/5_session_test_skipped.down.sql3
-rw-r--r--syz-cluster/pkg/db/migrations/5_session_test_skipped.up.sql3
3 files changed, 7 insertions, 0 deletions
diff --git a/syz-cluster/pkg/api/api.go b/syz-cluster/pkg/api/api.go
index 60c106254..65f0f4bd2 100644
--- a/syz-cluster/pkg/api/api.go
+++ b/syz-cluster/pkg/api/api.go
@@ -73,6 +73,7 @@ type Build struct {
const (
TestRunning string = "running"
TestPassed string = "passed"
+ TestSkipped string = "skipped"
TestFailed string = "failed" // TODO: drop it? only mark completion?
TestError string = "error"
)
diff --git a/syz-cluster/pkg/db/migrations/5_session_test_skipped.down.sql b/syz-cluster/pkg/db/migrations/5_session_test_skipped.down.sql
new file mode 100644
index 000000000..dbda912f2
--- /dev/null
+++ b/syz-cluster/pkg/db/migrations/5_session_test_skipped.down.sql
@@ -0,0 +1,3 @@
+ALTER TABLE SessionTests DROP CONSTRAINT ResultEnum;
+ALTER TABLE SessionTests ADD CONSTRAINT ResultEnum CHECK (Result IN ('passed', 'failed', 'error', 'running'));
+DROP INDEX SessionTestsByResult;
diff --git a/syz-cluster/pkg/db/migrations/5_session_test_skipped.up.sql b/syz-cluster/pkg/db/migrations/5_session_test_skipped.up.sql
new file mode 100644
index 000000000..8509fd816
--- /dev/null
+++ b/syz-cluster/pkg/db/migrations/5_session_test_skipped.up.sql
@@ -0,0 +1,3 @@
+ALTER TABLE SessionTests DROP CONSTRAINT ResultEnum;
+ALTER TABLE SessionTests ADD CONSTRAINT ResultEnum CHECK (Result IN ('passed', 'failed', 'error', 'running', 'skipped'));
+CREATE INDEX SessionTestsByResult ON SessionTests(SessionID, Result);