Merging r278575 (with changes to the test):
------------------------------------------------------------------------
r278575 | haicheng | 2016-08-12 16:13:38 -0700 (Fri, 12 Aug 2016) | 6 lines
Reapply [BranchFolding] Restrict tail merging loop blocks after MBP
Fixed a bug in the test case.
To fix PR28104, this patch restricts tail merging to blocks that belong to the
same loop after MBP.
------------------------------------------------------------------------
I had to adjust the test as it wasn't passing on the branch, presumably
due to different machine block placement.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_39@278827
91177308-0d34-0410-b5e6-
96231b3b80d8