New corpus-building script with multiple restarts
This commit is contained in:
parent
4fd5cb7ea5
commit
825ea4336b
1 changed files with 19 additions and 0 deletions
19
build-fuzz-corpus-multiple-restarts.sh
Executable file
19
build-fuzz-corpus-multiple-restarts.sh
Executable file
|
@ -0,0 +1,19 @@
|
|||
#!/bin/bash
|
||||
ncpus=$(nproc || getconf NPROCESSORS_ONLN)
|
||||
ncpus=$(( ncpus / ( 1 + $(cat /sys/devices/system/cpu/smt/active))))
|
||||
RESTARTS=25
|
||||
mv "fuzz/corpus/fuzz_$1" "fuzz/corpus/fuzz_$1_pre_fresh_blood"
|
||||
for i in $(seq 1 RESTARTS); do
|
||||
echo "RESTART ${i}"
|
||||
mkdir "fuzz/corpus/fuzz_$1"
|
||||
cargo fuzz run --all-features "fuzz_$1" "fuzz/corpus/fuzz_$1" -- \
|
||||
-dict=fuzz/fuzz.dict -max_len="$2" -fork="$ncpus" \
|
||||
-max_total_time=2400 -runs=50000000
|
||||
mv "fuzz/corpus/fuzz_$1" "fuzz/corpus/fuzz_$1_restart_${i}"
|
||||
done
|
||||
mkdir "fuzz/corpus/fuzz_$1"
|
||||
for i in $(seq 1 RESTARTS); do
|
||||
mv "fuzz/corpus/fuzz_$1_restart_${i}/*" "fuzz/corpus/fuzz_$1"
|
||||
rmdir "fuzz/corpus/fuzz_$1_restart_${i}"
|
||||
done
|
||||
./fuzz-until-converged.sh $1 $2
|
Loading…
Add table
Reference in a new issue