OSDN Git Service

Reapplying r281895 (and follow-up r281964) after fixing pr30468.
authorKeith Walker <kwalker@arm.com>
Thu, 22 Sep 2016 14:13:25 +0000 (14:13 +0000)
committerKeith Walker <kwalker@arm.com>
Thu, 22 Sep 2016 14:13:25 +0000 (14:13 +0000)
commit523c933b4c032777d1485140dcdb8238a39285d3
treef14f7a7c528ccd174dd9d07eed1b20a8849fa279
parentc63e7f7506712eb38d064133ff4b3bdb432a966d
Reapplying r281895 (and follow-up  r281964) after fixing pr30468.

The additional fix is:

When adding debug information to a lowered phi node in mem2reg
check that we have a valid insertion point after the phi for adding
the debug information.

This change addresses the issue in pr30468 where a lowered phi was
added before a catchswitch and no debug information should be added
after the phi in this case.

Differential Revision: https://reviews.llvm.org/D24797

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282155 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Transforms/Utils/Local.h
lib/Transforms/Utils/Local.cpp
lib/Transforms/Utils/PromoteMemoryToRegister.cpp