New testcase distilled from SPEC MCF benchmark
[oota-llvm.git] / test / Transforms / LevelRaise / 2002-05-02-MissedRaise.ll
1 ; This testcase is not level raised properly...
2 ;
3 ; RUN: if as < %s | opt -raise | dis | grep ' cast ' | grep '*'
4 ; RUN: then exit 1
5 ; RUN: else exit 0
6 ; RUN: fi
7
8         %List = type { int, %List* }
9
10 implementation
11
12 %List* "createList"(uint %Depth)
13 begin
14         %reg110 = malloc uint, uint 4
15         store uint %Depth, uint* %reg110
16         %reg113 = call %List* %createList( uint %Depth )
17         %reg217 = getelementptr uint* %reg110, uint 2
18         %cast221 = cast uint* %reg217 to %List**
19         store %List* %reg113, %List** %cast221
20         %cast222 = cast uint* %reg110 to %List*
21         ret %List* %cast222
22 end
23