brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.9 KiB · 1c418a7 Raw
61 lines · plain
1; RUN: llc -mcpu=corei7 -disable-cgp-select2branch < %s2 3; We should not crash on this test.4 5target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:128:128-n8:16:32"6target triple = "x86_64-apple-darwin9.0.0"7 8@global = external constant [411 x i8], align 19 10define void @snork() nounwind {11bb:12  br i1 undef, label %bb26, label %bb2713 14bb26:                                             ; preds = %bb48, %bb26, %bb15  switch i32 undef, label %bb26 [16    i32 142771596, label %bb2817  ]18 19bb27:                                             ; preds = %bb48, %bb20  switch i32 undef, label %bb49 [21    i32 142771596, label %bb2822  ]23 24bb28:                                             ; preds = %bb27, %bb2625  %tmp = load i32, ptr null26  %tmp29 = trunc i32 %tmp to i827  store ptr undef, ptr undef28  %tmp30 = load i32, ptr null29  %tmp31 = icmp eq i32 %tmp30, 030  %tmp32 = getelementptr inbounds [411 x i8], ptr @global, i32 0, i32 undef31  %tmp33 = load i8, ptr %tmp32, align 132  %tmp35 = load i8, ptr @global, align 133  %tmp36 = select i1 %tmp31, i8 %tmp35, i8 %tmp3334  %tmp37 = select i1 undef, i8 %tmp29, i8 %tmp3635  %tmp38 = zext i8 %tmp37 to i3236  %tmp39 = select i1 undef, i32 0, i32 %tmp3837  %tmp40 = getelementptr inbounds i32, ptr null, i32 %tmp3938  %tmp41 = load i32, ptr %tmp40, align 439  %tmp42 = load i32, ptr undef, align 440  %tmp43 = load i32, ptr undef41  %tmp44 = xor i32 %tmp42, %tmp4342  %tmp45 = lshr i32 %tmp44, 843  %tmp46 = lshr i32 %tmp44, 744  call void @spam()45  unreachable46 47bb47:                                             ; No predecessors!48  ret void49 50bb48:                                             ; No predecessors!51  br i1 undef, label %bb27, label %bb2652 53bb49:                                             ; preds = %bb49, %bb2754  br label %bb4955 56bb50:                                             ; preds = %bb5057  br label %bb5058}59 60declare void @spam() noreturn nounwind61