OSDN Git Service

Always forward 'resume' instructions to the outter landing pad.
authorBill Wendling <isanbard@gmail.com>
Thu, 21 Mar 2013 23:30:12 +0000 (23:30 +0000)
committerBill Wendling <isanbard@gmail.com>
Thu, 21 Mar 2013 23:30:12 +0000 (23:30 +0000)
commitd9ff8c83d137586d8c06f98bdf8adbf0d1fa79ca
tree9eb3d25e40b034c95a8d90282c7be11e010510e7
parent3ea1b064a0b9c3d161b0f77a9e957970f98907ab
Always forward 'resume' instructions to the outter landing pad.

How did this ever work?

Basically, if you have a function that's inlined into the caller, it may not
have any 'call' instructions, but any 'resume' instructions it may have should
still be forwarded to the outer (caller's) landing pad. This requires that all
of the 'landingpad' instructions in the callee have their clauses merged with
the caller's outer 'landingpad' instruction (hence the bit of ugly code in the
`forwardResume' method).

Testcase in a follow commit to the test-suite repository.

<rdar://problem/13360379> & PR15555

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@177680 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Utils/InlineFunction.cpp