blob: bdf155a4d49d983e881d4bf72fe821da17a1c387 [file] [log] [blame]
Chris Lattnerbcecb4b2003-04-18 19:22:39 +00001; This testcases makes sure that mem2reg can handle unreachable blocks.
Misha Brukmane78760e2003-09-16 15:29:54 +00002; RUN: llvm-as < %s | opt -mem2reg
Chris Lattnerbcecb4b2003-04-18 19:22:39 +00003
4int %test() {
5 %X = alloca int
6
7 store int 6, int* %X
8 br label %Loop
9Loop:
10 store int 5, int* %X
11 br label %EndOfLoop
12Unreachable:
13 br label %EndOfLoop
14
15EndOfLoop:
16 br label %Loop
17}