aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/AsmPrinter/WinException.cpp
diff options
context:
space:
mode:
authorPhoebe Wang <phoebe.wang@intel.com>2023-03-29 08:20:14 +0800
committerPhoebe Wang <phoebe.wang@intel.com>2023-03-29 08:59:56 +0800
commit0efe111365ae176671e01252d24028047d807a84 (patch)
tree488e2952809357cd92bac7ea9f90916165f8f016 /llvm/lib/CodeGen/AsmPrinter/WinException.cpp
parent4c55fd974b9f7e26ead646150eadfe549f27ad6f (diff)
downloadllvm-0efe111365ae176671e01252d24028047d807a84.zip
llvm-0efe111365ae176671e01252d24028047d807a84.tar.gz
llvm-0efe111365ae176671e01252d24028047d807a84.tar.bz2
Reland "[Windows SEH]: HARDWARE EXCEPTION HANDLING (MSVC -EHa) - Part 2"
This reverts commit db6a979ae82410e42430e47afa488936ba8e3025. Reland D102817 without any change. The previous revert was a mistake. Differential Revision: https://reviews.llvm.org/D102817
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/WinException.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/WinException.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/WinException.cpp b/llvm/lib/CodeGen/AsmPrinter/WinException.cpp
index 7a80043..6bfb5a6 100644
--- a/llvm/lib/CodeGen/AsmPrinter/WinException.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/WinException.cpp
@@ -762,7 +762,11 @@ void WinException::emitCXXFrameHandler3Table(const MachineFunction *MF) {
OS.emitInt32(0);
AddComment("EHFlags");
- OS.emitInt32(1);
+ if (MMI->getModule()->getModuleFlag("eh-asynch")) {
+ OS.emitInt32(0);
+ } else {
+ OS.emitInt32(1);
+ }
// UnwindMapEntry {
// int32_t ToState;