diff --git a/bin/jqf-blind b/bin/jqf-blind new file mode 100755 index 000000000..1e2a28b1e --- /dev/null +++ b/bin/jqf-blind @@ -0,0 +1,72 @@ +#!/bin/bash + +# Figure out script absolute path +pushd `dirname $0` > /dev/null +BIN_DIR=`pwd` +popd > /dev/null + +ROOT_DIR=`dirname $BIN_DIR` + +print_usage() { + echo "Usage: $0 [-c CLASSPATH] [-v] TEST_CLASS TEST_METHOD [OUT_DIR [SEED_FILES...]]" +} + +while getopts ":c:r:vt:dfsbm:uq" opt; do + case $opt in + /?) + echo "Invalid option: -$OPTARG" >&2 + print_usage >&1 + exit 1 + ;; + c) + export CLASSPATH="$OPTARG" + ;; + r) + export JVM_OPTS="$JVM_OPTS -Djqf.guidance.STATS_REFRESH_TIME_PERIOD=$OPTARG" + ;; + v) + export JVM_OPTS="$JVM_OPTS -Djqf.logCoverage=true" + ;; + t) + export JVM_OPTS="$JVM_OPTS -Djqf.ei.TIMEOUT=$OPTARG" + ;; + d) + debug=true + ;; + f) + export JVM_OPTS="$JVM_OPTS -DuseFastNonCollidingCoverageInstrumentation=true" + ;; + s) + export JVM_OPTS="$JVM_OPTS -Djqf.guidance.TRACK_SEMANTIC_COVERAGE=true" + ;; + b) + export JVM_OPTS="$JVM_OPTS -Djqf.guidance.LOG_BRANCH_HIT_COUNTS=true" + ;; + m) + export JVM_OPTS="$JVM_OPTS -Djqf.guidance.METRICS=$OPTARG" + ;; + u) + export JVM_OPTS="$JVM_OPTS -Djqf.ei.LOG_UNIQUE_PATH_INPUTS=true" + ;; + q) + export JVM_OPTS="$JVM_OPTS -Djqf.ei.DISABLE_LOG_QUEUE=true" + ;; + esac +done +shift $((OPTIND-1)) + +# Check arguments +if [ $# -lt 2 ]; then + print_usage >&1 + exit 1 +fi + +# Disable coverage guidance +export JVM_OPTS="$JVM_OPTS -Djqf.ei.TOTALLY_RANDOM=true" + +# Run the Zest input driver +if [ "$debug" = true ] ; then + $ROOT_DIR/scripts/jqf-debug-driver.sh edu.berkeley.cs.jqf.fuzz.ei.ZestDriver $@ +else + $ROOT_DIR/scripts/jqf-driver.sh edu.berkeley.cs.jqf.fuzz.ei.ZestDriver $@ +fi diff --git a/run-experiments.sbatch b/run-experiments.sbatch index e0261c8ea..a6e76dd2f 100755 --- a/run-experiments.sbatch +++ b/run-experiments.sbatch @@ -5,7 +5,7 @@ #SBATCH --cpus-per-task=1 #SBATCH --mem-per-cpu=16G #SBATCH --time=03:15:00 -#SBATCH --array=1-400%40 +#SBATCH --array=1-600%40 # Ensure tasks are only run on gruenau[3-6] #SBATCH --constraint=ivybridge @@ -21,7 +21,7 @@ timeout=181m declare -a config index=1 -for fuzzer in 'zest' 'bedivfuzz' +for fuzzer in 'zest' 'bedivfuzz' 'blind' do for subject in 'ant.ProjectBuilderTest' 'bcel.ParserTest' 'chocopy.SemanticAnalysisTest' 'closure.CompilerTest' 'imageio.PngReaderTest' 'maven.ModelReaderTest' 'nashorn.CompilerTest' 'pngj.PngReaderTest' 'rhino.CompilerTest' 'tomcat.WebXmlTest' do @@ -54,6 +54,10 @@ elif [[ "$fuzzer" == "bedivfuzz" ]]; then timeout $timeout bin/jqf-bedivfuzz -r 3000 -h 0.1 -m UPATHS:BEDIV -f -c $(scripts/examples_classpath.sh) edu.berkeley.cs.jqf.examples.$subject testWithSplitGenerator /vol/tmp/nguyehoa/$output_dir PID=$! wait $PID +elif [[ "$fuzzer" == "blind" ]]; then + timeout $timeout bin/jqf-blind -r 3000 -m UPATHS:BEDIV -f -c $(scripts/examples_classpath.sh) edu.berkeley.cs.jqf.examples.$subject testWithGenerator /vol/tmp/nguyehoa/$output_dir + PID=$! + wait $PID else echo "Unknown fuzzer: $fuzzer" fi