| ; This tests that unreachable basic blocks are pruned from the CFG, so that |
| ; liveness analysis doesn't detect inconsistencies. |
| ; RUN: %p2i -i %s --filetype=obj --disassemble --args -Om1 \ |
| ; RUN: -allow-externally-defined-symbols | FileCheck %s |
| ; RUN: %p2i -i %s --filetype=obj --disassemble --args -O2 \ |
| ; RUN: -allow-externally-defined-symbols | FileCheck %s |
| define internal i32 @unreachable_block() { |
| ; ret_val has no reaching uses and so its assignment may be |
| %ret_val = add i32 undef, undef |
| ; ret_val has no reaching definitions, causing an inconsistency in |
| ; CHECK-LABEL: unreachable_block |