[PATCH] D15846: [WinEH] Simplify unreachable catchpads

Joseph Tremoulet via llvm-commits llvm-commits at lists.llvm.org
Sat Jan 2 05:41:18 PST 2016


JosephTremoulet created this revision.
JosephTremoulet added reviewers: majnemer, rnk, andrew.w.kaylor.
JosephTremoulet added a subscriber: llvm-commits.

At least for CoreCLR, a catchpad which immediately executes an
`unreachable` instruction indicates that the exception can never have a
matching type, and so such catchpads can be removed, and so can their
catchswitches if the catchswitch becomes empty.

http://reviews.llvm.org/D15846

Files:
  include/llvm/IR/Instructions.h
  lib/IR/Instructions.cpp
  lib/Transforms/Utils/SimplifyCFG.cpp
  test/Transforms/SimplifyCFG/empty-catchpad.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15846.43847.patch
Type: text/x-patch
Size: 6450 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160102/d1ea230f/attachment.bin>


More information about the llvm-commits mailing list