summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scripts/fuzz_opt.py11
-rw-r--r--src/tools/fuzzing.h2
2 files changed, 8 insertions, 5 deletions
diff --git a/scripts/fuzz_opt.py b/scripts/fuzz_opt.py
index c84d9a6af..9af65b09d 100644
--- a/scripts/fuzz_opt.py
+++ b/scripts/fuzz_opt.py
@@ -36,9 +36,6 @@ NANS = True
# truncsat: https://github.com/WebAssembly/binaryen/issues/2198
CONSTANT_FEATURE_OPTS = ['--all-features']
-# possible feature options that are sometimes passed to the tools.
-POSSIBLE_FEATURE_OPTS = ['--disable-exception-handling', '--disable-simd', '--disable-threads', '--disable-bulk-memory', '--disable-nontrapping-float-to-int', '--disable-tail-call']
-
FUZZ_OPTS = []
INPUT_SIZE_LIMIT = 150 * 1024
@@ -297,7 +294,7 @@ class Wasm2JS(TestCaseHandler):
return out
def can_run_on_feature_opts(self, feature_opts):
- return all([x in feature_opts for x in ['--disable-exception-handling', '--disable-simd', '--disable-threads', '--disable-bulk-memory', '--disable-nontrapping-float-to-int', '--disable-tail-call']])
+ return all([x in feature_opts for x in ['--disable-exception-handling', '--disable-simd', '--disable-threads', '--disable-bulk-memory', '--disable-nontrapping-float-to-int', '--disable-tail-call', '--disable-sign-ext']])
class Asyncify(TestCaseHandler):
@@ -531,6 +528,12 @@ def get_multiple_opt_choices():
if not NANS:
FUZZ_OPTS += ['--no-fuzz-nans']
+# possible feature options that are sometimes passed to the tools. this
+# contains the list of all possible feature flags we can disable (after
+# we enable all before that in the constant options)
+POSSIBLE_FEATURE_OPTS = run([in_bin('wasm-opt'), '--print-features', '-all', in_binaryen('test', 'hello_world.wast'), '-all']).replace('--enable', '--disable').strip().split('\n')
+print('POSSIBLE_FEATURE_OPTS:', POSSIBLE_FEATURE_OPTS)
+
if __name__ == '__main__':
print('checking infinite random inputs')
random.seed(time.time() * os.getpid())
diff --git a/src/tools/fuzzing.h b/src/tools/fuzzing.h
index 832fa26ab..68c4d992a 100644
--- a/src/tools/fuzzing.h
+++ b/src/tools/fuzzing.h
@@ -1815,7 +1815,7 @@ private:
auto op =
pick(FeatureOptions<UnaryOp>()
.add(FeatureSet::MVP, ClzInt64, CtzInt64, PopcntInt64)
- .add(FeatureSet::Atomics,
+ .add(FeatureSet::SignExt,
ExtendS8Int64,
ExtendS16Int64,
ExtendS32Int64));