[wasm] Move the wasm fuzzer corpus to a different directory

The current test/fuzzer/wasm directory is used for two things:
1) as the corpus directory for clusterfuzz
2) to test in v8 that the fuzzer runs correctly.

With the newly added files from the wasm spec tests this directory grew
quite big and adds unnecessary load on the trybots. Therefore I want to
do the following steps:
1) In this CL for V8: create a new directory for the clusterfuzz corpus
2) In chromium: use the new corpus directory
3) In v8: clean up the old directory to use it on the trybots.

R=bradnelson@chromium.org
CC=mmoroz@chromium.org

Change-Id: If690022558bb5780edf5a3649fb9745ef9c7407a
Reviewed-on: https://chromium-review.googlesource.com/490367
Commit-Queue: Brad Nelson <bradnelson@chromium.org>
Reviewed-by: Brad Nelson <bradnelson@chromium.org>
Cr-Commit-Position: refs/heads/master@{#44991}
This commit is contained in:
Andreas Haas 2017-04-28 19:22:29 +02:00 committed by Commit Bot
parent f2bd913cd4
commit 1f629aace8
5 changed files with 42 additions and 14 deletions

4
.gitignore vendored
View File

@ -46,6 +46,10 @@
/src/inspector/build/closure-compiler
/src/inspector/build/closure-compiler.tar.gz
/test/benchmarks/data
/test/fuzzer/wasm_corpus
/test/fuzzer/wasm_corpus.tar.gz
/test/fuzzer/wasm_asmjs_corpus
/test/fuzzer/wasm_asmjs_corpus.tar.gz
/test/fuzzer/wasm
/test/fuzzer/wasm.tar.gz
/test/fuzzer/wasm_asmjs

22
DEPS
View File

@ -212,6 +212,17 @@ hooks = [
"-s", "v8/test/wasm-spec-tests/tests.tar.gz.sha1",
],
},
{
"name": "wasm_fuzzer_new",
"pattern": ".",
"action": [ "download_from_google_storage",
"--no_resume",
"--no_auth",
"-u",
"--bucket", "v8-wasm-fuzzer",
"-s", "v8/test/fuzzer/wasm_corpus.tar.gz.sha1",
],
},
{
"name": "wasm_fuzzer",
"pattern": ".",
@ -223,6 +234,17 @@ hooks = [
"-s", "v8/test/fuzzer/wasm.tar.gz.sha1",
],
},
{
"name": "wasm_asmjs_fuzzer_new",
"pattern": ".",
"action": [ "download_from_google_storage",
"--no_resume",
"--no_auth",
"-u",
"--bucket", "v8-wasm-asmjs-fuzzer",
"-s", "v8/test/fuzzer/wasm_asmjs_corpus.tar.gz.sha1",
],
},
{
"name": "wasm_asmjs_fuzzer",
"pattern": ".",

View File

@ -0,0 +1 @@
cf1777646f8d4557504442e9bd59e908519ffec8

View File

@ -0,0 +1 @@
f6b95b7dd8300efa84b6382f16cfcae4ec9fa108

View File

@ -9,48 +9,48 @@ TOOLS_WASM_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
cd ${TOOLS_WASM_DIR}/../..
rm -rf test/fuzzer/wasm
rm -rf test/fuzzer/wasm_asmjs
rm -rf test/fuzzer/wasm_corpus
rm -rf test/fuzzer/wasm_asmjs_corpus
tools/dev/gm.py x64.release all
mkdir -p test/fuzzer/wasm
mkdir -p test/fuzzer/wasm_asmjs
mkdir -p test/fuzzer/wasm_corpus
mkdir -p test/fuzzer/wasm_asmjs_corpus
# asm.js
./tools/run-tests.py -j8 --variants=default --timeout=10 --arch=x64 \
--mode=release --no-presubmit --extra-flags="--dump-wasm-module \
--dump-wasm-module-path=./test/fuzzer/wasm_asmjs/" mjsunit/wasm/asm*
--dump-wasm-module-path=./test/fuzzer/wasm_asmjs_corpus/" mjsunit/wasm/asm*
./tools/run-tests.py -j8 --variants=default --timeout=10 --arch=x64 \
--mode=release --no-presubmit --extra-flags="--dump-wasm-module \
--dump-wasm-module-path=./test/fuzzer/wasm_asmjs/" mjsunit/asm/*
--dump-wasm-module-path=./test/fuzzer/wasm_asmjs_corpus/" mjsunit/asm/*
# WASM
./tools/run-tests.py -j8 --variants=default --timeout=10 --arch=x64 \
--mode=release --no-presubmit --extra-flags="--dump-wasm-module \
--dump-wasm-module-path=./test/fuzzer/wasm/" unittests
--dump-wasm-module-path=./test/fuzzer/wasm_corpus/" unittests
./tools/run-tests.py -j8 --variants=default --timeout=10 --arch=x64 \
--mode=release --no-presubmit --extra-flags="--dump-wasm-module \
--dump-wasm-module-path=./test/fuzzer/wasm/" wasm-spec-tests/*
--dump-wasm-module-path=./test/fuzzer/wasm_corpus/" wasm-spec-tests/*
./tools/run-tests.py -j8 --variants=default --timeout=10 --arch=x64 \
--mode=release --no-presubmit --extra-flags="--dump-wasm-module \
--dump-wasm-module-path=./test/fuzzer/wasm/" mjsunit/wasm/*
--dump-wasm-module-path=./test/fuzzer/wasm_corpus/" mjsunit/wasm/*
./tools/run-tests.py -j8 --variants=default --timeout=10 --arch=x64 \
--mode=release --no-presubmit --extra-flags="--dump-wasm-module \
--dump-wasm-module-path=./test/fuzzer/wasm/" \
--dump-wasm-module-path=./test/fuzzer/wasm_corpus/" \
$(cd test/; ls cctest/wasm/test-*.cc | \
sed -es/wasm\\///g | sed -es/[.]cc/\\/\\*/g)
# Delete items over 20k.
for x in $(find ./test/fuzzer/wasm/ -type f -size +20k)
for x in $(find ./test/fuzzer/wasm_corpus/ -type f -size +20k)
do
rm $x
done
for x in $(find ./test/fuzzer/wasm_asmjs/ -type f -size +20k)
for x in $(find ./test/fuzzer/wasm_asmjs_corpus/ -type f -size +20k)
do
rm $x
done
# Upload changes.
cd test/fuzzer
upload_to_google_storage.py -a -b v8-wasm-fuzzer wasm
upload_to_google_storage.py -a -b v8-wasm-asmjs-fuzzer wasm_asmjs
upload_to_google_storage.py -a -b v8-wasm-fuzzer wasm_corpus
upload_to_google_storage.py -a -b v8-wasm-asmjs-fuzzer wasm_asmjs_corpus