================ @@ -1738,10 +1792,16 @@ void WebAssemblyLowerEmscriptenEHSjLj::handleLongjmpableCallsForWasmSjLj( BasicBlock *ThenBB = BasicBlock::Create(C, "if.then", &F); BasicBlock *EndBB = BasicBlock::Create(C, "if.end", &F); Value *EnvP = IRB.CreateBitCast(Env, getAddrPtrType(&M), "env.p"); - Value *SetjmpID = IRB.CreateLoad(getAddrIntType(&M), EnvP, "setjmp.id"); - Value *Label = - IRB.CreateCall(TestSetjmpF, {SetjmpID, SetjmpTable, SetjmpTableSize}, - OperandBundleDef("funclet", CatchPad), "label"); + Value *Label; + if (EnableWasmAltSjLj) { + Label = IRB.CreateCall(TestSetjmpF, {EnvP, SetjmpTable}, + OperandBundleDef("funclet", CatchPad), "label"); + } else { ---------------- aheejin wrote:
The reason I added all setjmp instructions in `SetjmpTableInsts` was to do the SSA update. Now we have a single `setjmpTable`, we don't need to do it and we don't need `SetjmpTableInsts`. (Sorry I missed this comment before) https://github.com/llvm/llvm-project/pull/84137 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits