[llvm] cbce11c - WebAssembly: Move exception handling code together
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 2 16:05:43 PDT 2022
Author: Matt Arsenault
Date: 2022-11-02T16:05:34-07:00
New Revision: cbce11c42266fd2f61bc52d427f1c2f3d0290c5a
URL: https://github.com/llvm/llvm-project/commit/cbce11c42266fd2f61bc52d427f1c2f3d0290c5a
DIFF: https://github.com/llvm/llvm-project/commit/cbce11c42266fd2f61bc52d427f1c2f3d0290c5a.diff
LOG: WebAssembly: Move exception handling code together
Added:
Modified:
llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
Removed:
################################################################################
diff --git a/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp b/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
index bf67ef99b6b4..3e59d0d2b753 100644
--- a/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
@@ -119,10 +119,6 @@ void FunctionLoweringInfo::set(const Function &fn, MachineFunction &mf,
}
}
}
- if (Personality == EHPersonality::Wasm_CXX) {
- WasmEHFuncInfo &EHInfo = *MF->getWasmEHFuncInfo();
- calculateWasmEHInfo(&fn, EHInfo);
- }
// Initialize the mapping of values to registers. This is only set up for
// instruction values that are used outside of the block that defines
@@ -323,10 +319,10 @@ void FunctionLoweringInfo::set(const Function &fn, MachineFunction &mf,
const auto *BB = CME.Handler.get<const BasicBlock *>();
CME.Handler = MBBMap[BB];
}
- }
-
- else if (Personality == EHPersonality::Wasm_CXX) {
+ } else if (Personality == EHPersonality::Wasm_CXX) {
WasmEHFuncInfo &EHInfo = *MF->getWasmEHFuncInfo();
+ calculateWasmEHInfo(&fn, EHInfo);
+
// Map all BB references in the Wasm EH data to MBBs.
DenseMap<BBOrMBB, BBOrMBB> SrcToUnwindDest;
for (auto &KV : EHInfo.SrcToUnwindDest) {
More information about the llvm-commits
mailing list