[clang] [WebAssembly] Refactor Wasm EH/SjLj error checking (PR #122466)
Heejin Ahn via cfe-commits
cfe-commits at lists.llvm.org
Fri Jan 10 06:55:21 PST 2025
================
@@ -120,26 +120,33 @@
// RUN: | FileCheck -check-prefix=EMSCRIPTEN_EH_ALLOWED_WO_ENABLE %s
// EMSCRIPTEN_EH_ALLOWED_WO_ENABLE: invalid argument '-mllvm -emscripten-cxx-exceptions-allowed' only allowed with '-mllvm -enable-emscripten-cxx-exceptions'
-// '-fwasm-exceptions' sets +exception-handling, -multivalue, -reference-types
-// and '-mllvm -wasm-enable-eh'
+// '-fwasm-exceptions' sets +exception-handling, -multivalue, -reference-types,
+// "-exception-model=wasm", and '-mllvm -wasm-enable-eh'
----------------
aheejin wrote:
`-exception-model=wasm` is also set in
https://github.com/llvm/llvm-project/blob/9c85cdec4ad29389c27cc2372d45f73d1ca8053a/clang/lib/Driver/ToolChains/Clang.cpp#L7469-L7470
which is the reason we set this only for Wasm SjLj and not Wasm EH here. But now `EnableFeaturesForWasmEHSjLj` includes it so it is set for both, which I think is harmless anyway.
https://github.com/llvm/llvm-project/pull/122466
More information about the cfe-commits
mailing list