Skip to content

Commit

Permalink
Disable incompatible benchmarks for cloud experiments (#2030)
Browse files Browse the repository at this point in the history
Temporarily disable benchmark `stb_stbi_read_fuzzer` and
`openh264_decoder_fuzzer`from cloud experiments, becaue they are
[proven](#2023 (comment))
to be incompatible in cloud build/run environment.

@addisoncrump kindly confirmed that they [work in local
experiments](#2023 (comment)).
  • Loading branch information
DonggeLiu authored Aug 16, 2024
1 parent e72f5bb commit adff65e
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 4 deletions.
14 changes: 13 additions & 1 deletion experiment/run_experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,18 @@ def get_git_hash(allow_uncommitted_changes):
return ''


def _filter_incompatible_benchmarks(config: dict,
benchmarks: List[str]) -> List[str]:
"""Removes benchmarks that are incompatible with build/run environment."""
if config['local_experiment']:
return benchmarks
if 'openh264_decoder_fuzzer' in benchmarks:
benchmarks.remove('openh264_decoder_fuzzer')
if 'stb_stbi_read_fuzzer' in benchmarks:
benchmarks.remove('stb_stbi_read_fuzzer')
return benchmarks


def start_experiment( # pylint: disable=too-many-arguments
experiment_name: str,
config_filename: str,
Expand All @@ -322,7 +334,7 @@ def start_experiment( # pylint: disable=too-many-arguments

config = read_and_validate_experiment_config(config_filename)
config['fuzzers'] = fuzzers
config['benchmarks'] = benchmarks
config['benchmarks'] = _filter_incompatible_benchmarks(config, benchmarks)
config['experiment'] = experiment_name
config['git_hash'] = get_git_hash(allow_uncommitted_changes)
config['no_seeds'] = no_seeds
Expand Down
6 changes: 3 additions & 3 deletions service/experiment-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
# Unless you are a fuzzbench maintainer running this service, this
# will not work with your setup.

trials: 20
max_total_time: 82800 # 23 hours, the default time for preemptible experiments.
trials: 2
max_total_time: 2100
cloud_project: fuzzbench
docker_registry: gcr.io/fuzzbench
cloud_compute_zone: us-central1-c
Expand All @@ -15,7 +15,7 @@ preemptible_runners: true

# This experiment should generate a report that is combined with other public
# "production" experiments.
merge_with_nonprivate: true
merge_with_nonprivate: false

# This experiment should be merged with other reports in later experiments.
private: false
1 change: 1 addition & 0 deletions service/gcbrun_experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import logging
import os
import sys
# dummy

# pytype: disable=import-error
import github # pylint: disable=import-error
Expand Down

0 comments on commit adff65e

Please sign in to comment.