Use the llvm-upgrade program to upgrade llvm assembly.
[oota-llvm.git] / test / CodeGen / Generic / 2006-05-06-GEP-Cast-Sink-Crash.ll
1 ; RUN: llvm-upgrade < %s | llvm-as | llc
2
3        %struct.FILE = type { ubyte*, int, int, short, short, %struct.__sbuf, int, sbyte*, int (sbyte*)*, int (sbyte*, sbyte*, int)*, long (sbyte*, long, int)*, int (sbyte*, sbyte*, int)*, %struct.__sbuf, %struct.__sFILEX*, int, [3 x ubyte], [1 x ubyte], %struct.__sbuf, int, long }
4         %struct.SYMBOL_TABLE_ENTRY = type { [9 x sbyte], [9 x sbyte], int, int, uint, %struct.SYMBOL_TABLE_ENTRY* }
5         %struct.__sFILEX = type opaque
6         %struct.__sbuf = type { ubyte*, int }
7 %str14 = external global [6 x sbyte]            ; <[6 x sbyte]*> [#uses=0]
8
9 implementation   ; Functions:
10
11 declare void %fprintf(int, ...)
12
13 void %OUTPUT_TABLE(%struct.SYMBOL_TABLE_ENTRY* %SYM_TAB) {
14 entry:
15         %tmp11 = getelementptr %struct.SYMBOL_TABLE_ENTRY* %SYM_TAB, int 0, uint 1, int 0               ; <sbyte*> [#uses=2]
16         %tmp.i = cast sbyte* %tmp11 to ubyte*           ; <ubyte*> [#uses=1]
17         br label %bb.i
18
19 bb.i:           ; preds = %cond_next.i, %entry
20         %s1.0.i = phi ubyte* [ %tmp.i, %entry ], [ null, %cond_next.i ]         ; <ubyte*> [#uses=0]
21         br bool false, label %cond_true.i31, label %cond_next.i
22
23 cond_true.i31:          ; preds = %bb.i
24         call void (int, ...)* %fprintf( int 0, sbyte* %tmp11, sbyte* null )
25         ret void
26
27 cond_next.i:            ; preds = %bb.i
28         br bool false, label %bb.i, label %bb19.i
29
30 bb19.i:         ; preds = %cond_next.i
31         ret void
32 }
33