Codegen: Don't tail-duplicate blocks with un-analyzable fallthrough.
authorKyle Butt <kyle+llvm@iteratee.net>
Wed, 10 Aug 2016 21:03:27 +0000 (21:03 +0000)
committerKyle Butt <kyle+llvm@iteratee.net>
Wed, 10 Aug 2016 21:03:27 +0000 (21:03 +0000)
commit81d32846b03a7de6dd7cfe699093ac23bdb237c3
tree15c65a50cb31199b66780f0d9ccf415346469006
parente1c931b171288a42f9d65035a7e91b4e52d91643
Codegen: Don't tail-duplicate blocks with un-analyzable fallthrough.

If AnalyzeBranch can't analyze a block and it is possible to
fallthrough, then duplicating the block doesn't make sense, as only one
block can be the layout predecessor for the un-analyzable fallthrough.

Submitted wit a test case, but NOTE: the test case doesn't currently
fail. However, the test case fails with D20505 and would have saved me
some time debugging.

llvm-svn: 278288
llvm/lib/CodeGen/TailDuplicator.cpp
llvm/test/CodeGen/PowerPC/tail-dup-analyzable-fallthrough.ll [new file with mode: 0644]