[PATCH] D44090: [WebAssembly] Support instruction selection for catching exceptions

Heejin Ahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Apr 15 04:45:10 PDT 2018


aheejin added inline comments.


================
Comment at: lib/Target/WebAssembly/WebAssemblyRegStackify.cpp:165
 
-  if (MI.isDebugValue())
+  if (MI.isPosition() || MI.isDebugValue())
     return;
----------------
Now EH labels can be present and they are position instructions. I think we can safely ignore them here and don't need to crash.


================
Comment at: lib/Target/WebAssembly/WebAssemblyRegisterInfo.h:48
                      unsigned Kind = 0) const override;
+  const uint32_t *getNoPreservedMask() const override { return nullptr; }
 };
----------------
This was needed to prevent assertions from [[ https://github.com/llvm-mirror/llvm/blob/5365e8b41893d044805a280c862c6a9a8732f3cc/lib/CodeGen/MachineBasicBlock.cpp#L1426-L1438 | these functions ]].


Repository:
  rL LLVM

https://reviews.llvm.org/D44090





More information about the llvm-commits mailing list