brintos

brintos / llvm-project-archived public Read only

0
0
Text · 3.1 KiB · c4293ec Raw
93 lines · plain
1; RUN: llc < %s -regalloc=fast -optimize-regalloc=0 -verify-machineinstrs -mtriple=x86_64-apple-darwin102; <rdar://problem/7755473>3; PR128214 5%0 = type { i32, ptr, ptr, ptr, ptr, i64, i64, i32, i32, i32, i32, [1024 x i8] }6%1 = type { ptr, i32, i32, i16, i16, %2, i32, ptr, ptr, ptr, ptr, ptr, %2, ptr, i32, [3 x i8], [1 x i8], %2, i32, i64 }7%2 = type { ptr, i32 }8%3 = type opaque9 10declare fastcc i32 @func(ptr, i32, i32) nounwind ssp11 12define fastcc void @func2(ptr %arg, i32 %arg1, i1 %arg2) nounwind ssp {13bb:14  br label %.exit315 16.exit3:                                           ; preds = %.exit3, %bb17  switch i32 undef, label %.exit3 [18    i32 -1, label %.loopexit19    i32 37, label %bb220  ]21 22bb2:                                              ; preds = %bb5, %bb3, %.exit323  br i1 %arg2, label %bb3, label %bb524 25bb3:                                              ; preds = %bb226  switch i32 undef, label %infloop [27    i32 125, label %.loopexit28    i32 -1, label %bb429    i32 37, label %bb230  ]31 32bb4:                                              ; preds = %bb333  %tmp = add nsw i32 undef, 1                     ; <i32> [#uses=1]34  br label %.loopexit35 36bb5:                                              ; preds = %bb237  switch i32 undef, label %infloop1 [38    i32 -1, label %.loopexit39    i32 37, label %bb240  ]41 42.loopexit:                                        ; preds = %bb5, %bb4, %bb3, %.exit343  %.04 = phi i32 [ %tmp, %bb4 ], [ undef, %bb3 ], [ undef, %.exit3 ], [ undef, %bb5 ] ; <i32> [#uses=2]44  br i1 %arg2, label %bb8, label %bb645 46bb6:                                              ; preds = %.loopexit47  %tmp7 = tail call fastcc i32 @func(ptr %arg, i32 %.04, i32 undef) nounwind ssp ; <i32> [#uses=0]48  ret void49 50bb8:                                              ; preds = %.loopexit51  %tmp9 = sext i32 %.04 to i64                    ; <i64> [#uses=1]52  %tmp10 = getelementptr inbounds %0, ptr %arg, i64 0, i32 11, i64 %tmp9 ; <ptr> [#uses=1]53  store i8 0, ptr %tmp10, align 154  ret void55 56infloop:                                          ; preds = %infloop, %bb357  br label %infloop58 59infloop1:                                         ; preds = %infloop1, %bb560  br label %infloop161}62 63 64; RAFast would forget to add a super-register implicit-def when rewriting:65;  %10:sub_32bit<def,read-undef> = COPY killed %R9D66; This trips up the machine code verifier.67define void @autogen_SD24657(ptr, ptr, ptr, i32, i64, i8) {68BB:69  %A4 = alloca <16 x i16>70  %A3 = alloca double71  %A2 = alloca <2 x i8>72  %A1 = alloca i173  %A = alloca i3274  %L = load i8, ptr %075  store i8 -37, ptr %076  %E = extractelement <4 x i64> zeroinitializer, i32 277  %Shuff = shufflevector <4 x i64> zeroinitializer, <4 x i64> zeroinitializer, <4 x i32> <i32 5, i32 7, i32 1, i32 3>78  %I = insertelement <2 x i8> <i8 -1, i8 -1>, i8 %5, i32 179  %B = fadd float 0x45CDF5B1C0000000, 0x45CDF5B1C000000080  %FC = uitofp i32 275048 to double81  %Sl = select i1 true, <2 x i8> %I, <2 x i8> <i8 -1, i8 -1>82  %Cmp = icmp slt i64 0, %E83  br label %CF84 85CF:                                               ; preds = %BB86  store i8 %5, ptr %087  store <2 x i8> %I, ptr %A288  store i8 %5, ptr %089  store i8 %5, ptr %090  store i8 %5, ptr %091  ret void92}93