From ea9b66b204fb4aa59227e677298c1e524b961bf3 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Sun, 11 Feb 2018 14:02:02 -0800 Subject: remove recursion-avoiding code in fuzzer, now that we have hang prevention it's useful to test infinite loops (#1404) --- src/tools/fuzzing.h | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src') diff --git a/src/tools/fuzzing.h b/src/tools/fuzzing.h index d90660e89..a4c4e054b 100644 --- a/src/tools/fuzzing.h +++ b/src/tools/fuzzing.h @@ -151,9 +151,6 @@ private: // beyond a nesting limit, greatly decrease the chance to continue to nest static const int NESTING_LIMIT = 11; - // reduce the chance for a function to call itself by this factor - static const int RECURSION_FACTOR = 10; - // the maximum size of a block static const int BLOCK_FACTOR = 5; @@ -774,8 +771,6 @@ private: target = vectorPick(wasm.functions).get(); } if (target->result != type) continue; - // reduce the odds of recursion dramatically, to limit infinite loops - if (target == func && !oneIn(RECURSION_FACTOR * TRIES)) continue; // we found one! std::vector args; for (auto argType : target->params) { -- cgit v1.2.3