[llvm] [WebAssembly] Remove the `wasm-disable-fix-irreducible-control-flow-pass` switch (PR #185072)

Demetrius Kanios via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 6 10:19:19 PST 2026


https://github.com/QuantumSegfault updated https://github.com/llvm/llvm-project/pull/185072

>From 9b331796e1383784b9e7b56a0dfccdc81da96b9d Mon Sep 17 00:00:00 2001
From: Demetrius Kanios <demetrius at kanios.net>
Date: Fri, 6 Mar 2026 10:02:02 -0800
Subject: [PATCH] Revert "[WebAssembly] add: hidden option to disable slow wasm
 pass (#67715)"

This reverts commit 85b8958b56623cbe69be5cfcbb6c796ae48aff56.
---
 llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp b/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp
index ab1b24a4fd9b1..331bd0a360149 100644
--- a/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp
+++ b/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp
@@ -51,12 +51,6 @@ static cl::opt<bool> WasmDisableExplicitLocals(
              " instruction output for test purposes only."),
     cl::init(false));
 
-static cl::opt<bool> WasmDisableFixIrreducibleControlFlowPass(
-    "wasm-disable-fix-irreducible-control-flow-pass", cl::Hidden,
-    cl::desc("webassembly: disables the fix "
-             " irreducible control flow optimization pass"),
-    cl::init(false));
-
 // Exception handling & setjmp-longjmp handling related options.
 
 // Emscripten's asm.js-style exception handling
@@ -605,8 +599,7 @@ void WebAssemblyPassConfig::addPreEmitPass() {
   addPass(createWebAssemblyNullifyDebugValueLists());
 
   // Eliminate multiple-entry loops.
-  if (!WasmDisableFixIrreducibleControlFlowPass)
-    addPass(createWebAssemblyFixIrreducibleControlFlow());
+  addPass(createWebAssemblyFixIrreducibleControlFlow());
 
   // Do various transformations for exception handling.
   // Every CFG-changing optimizations should come before this.



More information about the llvm-commits mailing list