Chris Lattner | 006f2d0 | 2006-08-03 21:39:41 +0000 | [diff] [blame^] | 1 | ; RUN: llvm-as < %s | opt -load-vn -gcse -simplifycfg -disable-output |
| 2 | ; PR867 |
| 3 | |
| 4 | target endian = big |
| 5 | target pointersize = 32 |
| 6 | target triple = "powerpc-apple-darwin8" |
| 7 | %struct.CUMULATIVE_ARGS = type { int, int, int, int, int, int, int, int, int, int, int, int } |
| 8 | %struct.eh_status = type opaque |
| 9 | %struct.emit_status = type { int, int, %struct.rtx_def*, %struct.rtx_def*, %struct.sequence_stack*, int, %struct.location_t, int, ubyte*, %struct.rtx_def** } |
| 10 | %struct.expr_status = type { int, int, int, %struct.rtx_def*, %struct.rtx_def*, %struct.rtx_def* } |
| 11 | %struct.function = type { %struct.eh_status*, %struct.expr_status*, %struct.emit_status*, %struct.varasm_status*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.function*, int, int, int, int, %struct.rtx_def*, %struct.CUMULATIVE_ARGS, %struct.rtx_def*, %struct.rtx_def*, %struct.initial_value_struct*, %struct.rtx_def*, %struct.rtx_def*, %struct.rtx_def*, %struct.rtx_def*, %struct.rtx_def*, %struct.rtx_def*, ubyte, int, long, %struct.tree_node*, %struct.tree_node*, %struct.rtx_def*, %struct.varray_head_tag*, %struct.temp_slot*, int, %struct.var_refs_queue*, int, int, %struct.rtvec_def*, %struct.tree_node*, int, int, int, %struct.machine_function*, uint, uint, ubyte, ubyte, %struct.language_function*, %struct.rtx_def*, uint, int, int, int, %struct.location_t, %struct.varray_head_tag*, %struct.tree_node*, ubyte, ubyte, ubyte } |
| 12 | %struct.initial_value_struct = type opaque |
| 13 | %struct.lang_decl = type opaque |
| 14 | %struct.lang_type = type opaque |
| 15 | %struct.language_function = type opaque |
| 16 | %struct.location_t = type { sbyte*, int } |
| 17 | %struct.machine_function = type { int, uint, sbyte*, int, int } |
| 18 | %struct.rtunion = type { int } |
| 19 | %struct.rtvec_def = type { int, [1 x %struct.rtx_def*] } |
| 20 | %struct.rtx_def = type { ushort, ubyte, ubyte, %struct.u } |
| 21 | %struct.sequence_stack = type { %struct.rtx_def*, %struct.rtx_def*, %struct.sequence_stack* } |
| 22 | %struct.temp_slot = type opaque |
| 23 | %struct.tree_common = type { %struct.tree_node*, %struct.tree_node*, %union.tree_ann_d*, ubyte, ubyte, ubyte, ubyte, ubyte } |
| 24 | %struct.tree_decl = type { %struct.tree_common, %struct.location_t, uint, %struct.tree_node*, ubyte, ubyte, ubyte, ubyte, ubyte, ubyte, ubyte, ubyte, uint, %struct.tree_decl_u1, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.rtx_def*, %struct.tree_decl_u2, %struct.tree_node*, %struct.tree_node*, long, %struct.lang_decl* } |
| 25 | %struct.tree_decl_u1 = type { long } |
| 26 | %struct.tree_decl_u2 = type { %struct.function* } |
| 27 | %struct.tree_node = type { %struct.tree_decl } |
| 28 | %struct.tree_type = type { %struct.tree_common, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, uint, ushort, ubyte, ubyte, uint, %struct.tree_node*, %struct.tree_node*, %struct.rtunion, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, %struct.tree_node*, long, %struct.lang_type* } |
| 29 | %struct.u = type { [1 x long] } |
| 30 | %struct.var_refs_queue = type { %struct.rtx_def*, uint, int, %struct.var_refs_queue* } |
| 31 | %struct.varasm_status = type opaque |
| 32 | %struct.varray_head_tag = type { uint, uint, uint, sbyte*, %struct.u } |
| 33 | %union.tree_ann_d = type opaque |
| 34 | %mode_class = external global [35 x ubyte] ; <[35 x ubyte]*> [#uses=3] |
| 35 | |
| 36 | implementation ; Functions: |
| 37 | |
| 38 | void %fold_builtin_classify() { |
| 39 | entry: |
| 40 | %tmp63 = load int* null ; <int> [#uses=1] |
| 41 | switch int %tmp63, label %bb276 [ |
| 42 | int 414, label %bb145 |
| 43 | int 417, label %bb |
| 44 | ] |
| 45 | |
| 46 | bb: ; preds = %entry |
| 47 | ret void |
| 48 | |
| 49 | bb145: ; preds = %entry |
| 50 | %tmp146 = load %struct.tree_node** null ; <%struct.tree_node*> [#uses=1] |
| 51 | %tmp148 = getelementptr %struct.tree_node* %tmp146, int 0, uint 0, uint 0, uint 1 ; <%struct.tree_node**> [#uses=1] |
| 52 | %tmp149 = load %struct.tree_node** %tmp148 ; <%struct.tree_node*> [#uses=1] |
| 53 | %tmp150 = cast %struct.tree_node* %tmp149 to %struct.tree_type* ; <%struct.tree_type*> [#uses=1] |
| 54 | %tmp151 = getelementptr %struct.tree_type* %tmp150, int 0, uint 6 ; <ushort*> [#uses=1] |
| 55 | %tmp151 = cast ushort* %tmp151 to uint* ; <uint*> [#uses=1] |
| 56 | %tmp152 = load uint* %tmp151 ; <uint> [#uses=1] |
| 57 | %tmp154 = shr uint %tmp152, ubyte 16 ; <uint> [#uses=1] |
| 58 | %tmp154.mask = and uint %tmp154, 127 ; <uint> [#uses=1] |
| 59 | %tmp155 = getelementptr [35 x ubyte]* %mode_class, int 0, uint %tmp154.mask ; <ubyte*> [#uses=1] |
| 60 | %tmp156 = load ubyte* %tmp155 ; <ubyte> [#uses=1] |
| 61 | %tmp157 = seteq ubyte %tmp156, 4 ; <bool> [#uses=1] |
| 62 | br bool %tmp157, label %cond_next241, label %cond_true158 |
| 63 | |
| 64 | cond_true158: ; preds = %bb145 |
| 65 | %tmp172 = load %struct.tree_node** null ; <%struct.tree_node*> [#uses=1] |
| 66 | %tmp174 = getelementptr %struct.tree_node* %tmp172, int 0, uint 0, uint 0, uint 1 ; <%struct.tree_node**> [#uses=1] |
| 67 | %tmp175 = load %struct.tree_node** %tmp174 ; <%struct.tree_node*> [#uses=1] |
| 68 | %tmp176 = cast %struct.tree_node* %tmp175 to %struct.tree_type* ; <%struct.tree_type*> [#uses=1] |
| 69 | %tmp177 = getelementptr %struct.tree_type* %tmp176, int 0, uint 6 ; <ushort*> [#uses=1] |
| 70 | %tmp177 = cast ushort* %tmp177 to uint* ; <uint*> [#uses=1] |
| 71 | %tmp178 = load uint* %tmp177 ; <uint> [#uses=1] |
| 72 | %tmp180 = shr uint %tmp178, ubyte 16 ; <uint> [#uses=1] |
| 73 | %tmp180.mask = and uint %tmp180, 127 ; <uint> [#uses=1] |
| 74 | %tmp181 = getelementptr [35 x ubyte]* %mode_class, int 0, uint %tmp180.mask ; <ubyte*> [#uses=1] |
| 75 | %tmp182 = load ubyte* %tmp181 ; <ubyte> [#uses=1] |
| 76 | %tmp183 = seteq ubyte %tmp182, 8 ; <bool> [#uses=1] |
| 77 | br bool %tmp183, label %cond_next241, label %cond_true184 |
| 78 | |
| 79 | cond_true184: ; preds = %cond_true158 |
| 80 | %tmp185 = load %struct.tree_node** null ; <%struct.tree_node*> [#uses=1] |
| 81 | %tmp187 = getelementptr %struct.tree_node* %tmp185, int 0, uint 0, uint 0, uint 1 ; <%struct.tree_node**> [#uses=1] |
| 82 | %tmp188 = load %struct.tree_node** %tmp187 ; <%struct.tree_node*> [#uses=1] |
| 83 | %tmp189 = cast %struct.tree_node* %tmp188 to %struct.tree_type* ; <%struct.tree_type*> [#uses=1] |
| 84 | %tmp190 = getelementptr %struct.tree_type* %tmp189, int 0, uint 6 ; <ushort*> [#uses=1] |
| 85 | %tmp190 = cast ushort* %tmp190 to uint* ; <uint*> [#uses=1] |
| 86 | %tmp191 = load uint* %tmp190 ; <uint> [#uses=1] |
| 87 | %tmp193 = shr uint %tmp191, ubyte 16 ; <uint> [#uses=1] |
| 88 | %tmp193.mask = and uint %tmp193, 127 ; <uint> [#uses=1] |
| 89 | %tmp194 = getelementptr [35 x ubyte]* %mode_class, int 0, uint %tmp193.mask ; <ubyte*> [#uses=1] |
| 90 | %tmp195 = load ubyte* %tmp194 ; <ubyte> [#uses=1] |
| 91 | %tmp196 = seteq ubyte %tmp195, 4 ; <bool> [#uses=1] |
| 92 | br bool %tmp196, label %cond_next241, label %cond_true197 |
| 93 | |
| 94 | cond_true197: ; preds = %cond_true184 |
| 95 | ret void |
| 96 | |
| 97 | cond_next241: ; preds = %cond_true184, %cond_true158, %bb145 |
| 98 | %tmp245 = load uint* null ; <uint> [#uses=0] |
| 99 | ret void |
| 100 | |
| 101 | bb276: ; preds = %entry |
| 102 | ret void |
| 103 | } |