[PATCH] D102817: [Windows SEH]: HARDWARE EXCEPTION HANDLING (MSVC -EHa) - Part 2

Ten Tzen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 9 18:54:56 PST 2021


tentzen added inline comments.


================
Comment at: llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp:1321
+              (MI2->mayLoadOrStore() || MI2->mayRaiseFPException()))
+            emitNops(1);
+        }
----------------
dpaoliello wrote:
> Is this still required? LLVM is no longer adding 1 to the addresses in its SEH tables (although it does for its IP2State table).
Yes, this is required. -EHa is applied to C++ code too.  Without this Nop, exception occurs on the instruction immediately following an EH_LABEL won't be caught due to current "+1+offset" mechanism.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D102817/new/

https://reviews.llvm.org/D102817



More information about the llvm-commits mailing list