<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Assertion failed: ExitBlockSet.count(ExitBlock) && "The LCSSA PHI is not in an exit block!""
   href="http://llvm.org/bugs/show_bug.cgi?id=21906">21906</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Assertion failed: ExitBlockSet.count(ExitBlock) && "The LCSSA PHI is not in an exit block!"
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Scalar Optimizations
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>patrik.h.hagglund@ericsson.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=13536" name="attach_13536" title="testcase">attachment 13536</a> <a href="attachment.cgi?id=13536&action=edit" title="testcase">[details]</a></span>
testcase

This bug is present on r224187, and seems to be introduced by r215343.

bin/opt -S -instcombine -simplifycfg -inline -sroa -early-cse -jump-threading
-instcombine -licm -gvn -simplifycfg csmith-461848576.ll
opt: ../lib/Transforms/Scalar/LICM.cpp:613: void (anonymous
namespace)::LICM::sink(llvm::Instruction &): Assertion
`ExitBlockSet.count(ExitBlock) && "The LCSSA PHI is not in an exit block!"'
failed.
0  opt             0x0000000001382be8 llvm::sys::PrintStackTrace(_IO_FILE*) +
40
1  opt             0x00000000013841cb
2  libpthread.so.0 0x00007f77ab37a810
3  libc.so.6       0x00007f77aab95755 gsignal + 53
4  libc.so.6       0x00007f77aab96d31 abort + 385
5  libc.so.6       0x00007f77aab8e610 __assert_fail + 240
6  opt             0x0000000001269540
7  opt             0x00000000012677e5
8  opt             0x0000000001267433
9  opt             0x0000000001265e32
10 opt             0x0000000000cb15cd
llvm::LPPassManager::runOnFunction(llvm::Function&) + 1085
11 opt             0x000000000104b69b
llvm::FPPassManager::runOnFunction(llvm::Function&) + 539
12 opt             0x000000000108f7a9
13 opt             0x000000000104be87
llvm::legacy::PassManagerImpl::run(llvm::Module&) + 967
14 opt             0x00000000005b83e9 main + 6345
15 libc.so.6       0x00007f77aab81c16 __libc_start_main + 230
16 opt             0x00000000005a5f55
Stack dump:
0.      Program arguments: bin/opt -S -instcombine -simplifycfg -inline -sroa
-early-cse -jump-threading -instcombine -licm -gvn -simplifycfg
csmith-461848576.ll
1.      Running pass 'CallGraph Pass Manager' on module 'csmith-461848576.ll'.
2.      Running pass 'Loop Pass Manager' on function '@fn1'
3.      Running pass 'Loop Invariant Code Motion' on basic block '%for.cond'
Abort (core dumped)</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>