Add a test for the LCSSA issue I just fixed.
[oota-llvm.git] / test / Transforms / LCSSA / 2006-07-09-NoDominator.ll
1 ; RUN: llvm-as < %s | opt -lcssa
2
3         %struct.SetJmpMapEntry = type { sbyte*, uint, %struct.SetJmpMapEntry* }
4
5 implementation   ; Functions:
6
7 void %__llvm_sjljeh_try_catching_longjmp_exception() {
8 entry:
9         br label %loopentry
10
11 loopentry:              ; preds = %endif, %entry
12         %SJE.0 = phi %struct.SetJmpMapEntry* [ null, %entry ], [ %tmp.25, %endif ]              ; <%struct.SetJmpMapEntry*> [#uses=1]
13         br bool false, label %no_exit, label %loopexit
14
15 no_exit:                ; preds = %loopentry
16         br bool false, label %then, label %endif
17
18 then:           ; preds = %no_exit
19         %tmp.21 = getelementptr %struct.SetJmpMapEntry* %SJE.0, int 0, uint 1           ; <uint*> [#uses=0]
20         br label %return
21
22 endif:          ; preds = %after_ret.0, %no_exit
23         %tmp.25 = load %struct.SetJmpMapEntry** null            ; <%struct.SetJmpMapEntry*> [#uses=1]
24         br label %loopentry
25
26 loopexit:               ; preds = %loopentry
27         br label %return
28
29 return:         ; preds = %after_ret.1, %loopexit, %then
30         ret void
31 }