diff options
-rw-r--r-- | src/pass.h | 4 | ||||
-rw-r--r-- | src/passes/pass.cpp | 1 | ||||
-rw-r--r-- | src/wasm-module-building.h | 9 |
3 files changed, 0 insertions, 14 deletions
diff --git a/src/pass.h b/src/pass.h index 7b42e3719..3cfa585a7 100644 --- a/src/pass.h +++ b/src/pass.h @@ -268,10 +268,6 @@ class Pass { public: virtual ~Pass() = default; - // Override this to perform preparation work before the pass runs. - // This will be called before the pass is run on a module. - virtual void prepareToRun(PassRunner* runner, Module* module) {} - // Implement this with code to run the pass on the whole module virtual void run(PassRunner* runner, Module* module) { WASM_UNREACHABLE("unimplemented"); diff --git a/src/passes/pass.cpp b/src/passes/pass.cpp index e6b537813..58083c43b 100644 --- a/src/passes/pass.cpp +++ b/src/passes/pass.cpp @@ -670,7 +670,6 @@ void PassRunner::runOnFunction(Function* func) { } void PassRunner::doAdd(std::unique_ptr<Pass> pass) { - pass->prepareToRun(this, wasm); passes.emplace_back(std::move(pass)); } diff --git a/src/wasm-module-building.h b/src/wasm-module-building.h index 63129f874..bff1683d2 100644 --- a/src/wasm-module-building.h +++ b/src/wasm-module-building.h @@ -122,15 +122,6 @@ public: return; } - // Before parallelism, create all passes on the main thread here, to ensure - // prepareToRun() is called for each pass before we start to optimize - // functions. - { - PassRunner passRunner(wasm, passOptions); - addPrePasses(passRunner); - passRunner.addDefaultFunctionOptimizationPasses(); - } - // prepare work list endMarker = new Function(); list = new std::atomic<Function*>[numFunctions]; |