brintos

brintos / llvm-project-archived public Read only

0
0
Text · 9.7 KiB · 8225bd0 Raw
233 lines · plain
1; RUN: opt %loadNPMPolly '-passes=polly-custom<scops>' -polly-print-scops -disable-output < %s2 3; Verify that the compilation of this test case does not take infinite time.4; At some point Polly tried to model this test case and got stuck in5; computing a lexicographic minima. Today it should gracefully bail out.6target datalayout = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"7target triple = "aarch64--linux-android"8 9%0 = type { ptr, i64, i64, i64, i64, i64, i64 }10 11define void @_Z1fR1SS0_Ph(ptr nocapture readonly dereferenceable(56) %arg, ptr nocapture readonly dereferenceable(56) %arg1, ptr nocapture readonly %arg2) {12bb:13  %tmp = getelementptr inbounds %0, ptr %arg1, i64 0, i32 114  %tmp4 = load ptr, ptr %arg, align 815  %tmp5 = getelementptr inbounds %0, ptr %arg, i64 0, i32 416  %tmp6 = load i64, ptr %tmp5, align 817  %tmp7 = getelementptr inbounds %0, ptr %arg, i64 0, i32 118  %tmp8 = load i64, ptr %tmp7, align 819  %tmp9 = mul i64 %tmp8, %tmp620  %tmp10 = getelementptr inbounds i8, ptr %tmp4, i64 %tmp921  %tmp11 = getelementptr inbounds %0, ptr %arg, i64 0, i32 322  %tmp12 = load i64, ptr %tmp11, align 823  %tmp13 = getelementptr inbounds i8, ptr %tmp10, i64 %tmp1224  %tmp14 = getelementptr inbounds %0, ptr %arg, i64 0, i32 625  %tmp15 = load i64, ptr %tmp14, align 826  %tmp16 = add i64 %tmp15, 127  %tmp17 = icmp eq i64 %tmp16, %tmp628  br i1 %tmp17, label %bb51, label %bb1829 30bb18:                                             ; preds = %bb31  %tmp19 = getelementptr inbounds %0, ptr %arg, i64 0, i32 232  %tmp20 = load i64, ptr %tmp19, align 833  %tmp21 = mul i64 %tmp20, %tmp834  %tmp22 = getelementptr inbounds i8, ptr %tmp13, i64 %tmp2135  %tmp23 = getelementptr inbounds i8, ptr %tmp22, i64 %tmp936  %tmp24 = getelementptr inbounds i8, ptr %tmp23, i64 %tmp1237  %tmp26 = load ptr, ptr %arg1, align 838  %tmp27 = load i64, ptr %tmp, align 839  %tmp28 = getelementptr inbounds %0, ptr %arg1, i64 0, i32 440  %tmp29 = load i64, ptr %tmp28, align 841  %tmp30 = mul i64 %tmp27, %tmp2942  %tmp31 = getelementptr inbounds i16, ptr %tmp26, i64 %tmp3043  %tmp32 = getelementptr inbounds %0, ptr %arg1, i64 0, i32 344  %tmp33 = load i64, ptr %tmp32, align 845  %tmp34 = getelementptr inbounds i16, ptr %tmp31, i64 %tmp3346  %tmp35 = getelementptr inbounds %0, ptr %arg, i64 0, i32 547  %tmp36 = load i64, ptr %tmp35, align 848  br label %bb3749 50bb37:                                             ; preds = %bb57, %bb1851  %tmp38 = phi i64 [ %tmp6, %bb18 ], [ %tmp58, %bb57 ]52  %tmp39 = phi i64 [ %tmp15, %bb18 ], [ %tmp59, %bb57 ]53  %tmp40 = phi i64 [ %tmp27, %bb18 ], [ %tmp60, %bb57 ]54  %tmp41 = phi i64 [ %tmp8, %bb18 ], [ %tmp61, %bb57 ]55  %tmp42 = phi i64 [ %tmp12, %bb18 ], [ %tmp62, %bb57 ]56  %tmp43 = phi i64 [ %tmp36, %bb18 ], [ %tmp63, %bb57 ]57  %tmp44 = phi ptr [ %tmp34, %bb18 ], [ %tmp69, %bb57 ]58  %tmp45 = phi ptr [ %tmp13, %bb18 ], [ %tmp64, %bb57 ]59  %tmp46 = phi ptr [ %tmp24, %bb18 ], [ %tmp68, %bb57 ]60  %tmp47 = phi i64 [ 0, %bb18 ], [ %tmp70, %bb57 ]61  %tmp48 = add i64 %tmp43, 162  %tmp49 = sub i64 %tmp48, %tmp4263  %tmp50 = icmp eq i64 %tmp49, 064  br i1 %tmp50, label %bb57, label %bb7465 66bb51:                                             ; preds = %bb57, %bb67  ret void68 69bb52:                                             ; preds = %bb17670  %tmp53 = load i64, ptr %tmp7, align 871  %tmp54 = load i64, ptr %tmp, align 872  %tmp55 = load i64, ptr %tmp14, align 873  %tmp56 = load i64, ptr %tmp5, align 874  br label %bb5775 76bb57:                                             ; preds = %bb52, %bb3777  %tmp58 = phi i64 [ %tmp56, %bb52 ], [ %tmp38, %bb37 ]78  %tmp59 = phi i64 [ %tmp55, %bb52 ], [ %tmp39, %bb37 ]79  %tmp60 = phi i64 [ %tmp54, %bb52 ], [ %tmp40, %bb37 ]80  %tmp61 = phi i64 [ %tmp53, %bb52 ], [ %tmp41, %bb37 ]81  %tmp62 = phi i64 [ %tmp179, %bb52 ], [ %tmp42, %bb37 ]82  %tmp63 = phi i64 [ %tmp178, %bb52 ], [ %tmp43, %bb37 ]83  %tmp64 = getelementptr inbounds i8, ptr %tmp45, i64 %tmp6184  %tmp65 = and i64 %tmp47, 185  %tmp66 = icmp eq i64 %tmp65, 086  %tmp67 = getelementptr inbounds i8, ptr %tmp46, i64 %tmp6187  %tmp68 = select i1 %tmp66, ptr %tmp46, ptr %tmp6788  %tmp69 = getelementptr inbounds i16, ptr %tmp44, i64 %tmp6089  %tmp70 = add i64 %tmp47, 190  %tmp71 = add i64 %tmp59, 191  %tmp72 = sub i64 %tmp71, %tmp5892  %tmp73 = icmp ult i64 %tmp70, %tmp7293  br i1 %tmp73, label %bb37, label %bb5194 95bb74:                                             ; preds = %bb176, %bb3796  %tmp75 = phi i64 [ %tmp181, %bb176 ], [ %tmp49, %bb37 ]97  %tmp76 = phi i64 [ %tmp177, %bb176 ], [ 0, %bb37 ]98  %tmp77 = getelementptr inbounds i8, ptr %tmp45, i64 %tmp7699  %tmp78 = load i8, ptr %tmp77, align 1100  %tmp79 = zext i8 %tmp78 to i32101  %tmp80 = or i64 %tmp76, 1102  %tmp81 = getelementptr inbounds i8, ptr %tmp45, i64 %tmp80103  %tmp82 = load i8, ptr %tmp81, align 1104  %tmp83 = zext i8 %tmp82 to i32105  %tmp84 = getelementptr inbounds i8, ptr %tmp46, i64 %tmp76106  %tmp85 = load i8, ptr %tmp84, align 1107  %tmp86 = zext i8 %tmp85 to i32108  %tmp87 = getelementptr inbounds i8, ptr %tmp46, i64 %tmp80109  %tmp88 = load i8, ptr %tmp87, align 1110  %tmp89 = zext i8 %tmp88 to i32111  %tmp90 = mul nuw nsw i32 %tmp86, 517112  %tmp91 = add nsw i32 %tmp90, -66176113  %tmp92 = sub nsw i32 128, %tmp86114  %tmp93 = mul nsw i32 %tmp92, 100115  %tmp94 = sub nsw i32 128, %tmp89116  %tmp95 = mul nsw i32 %tmp94, 208117  %tmp96 = mul nuw nsw i32 %tmp89, 409118  %tmp97 = add nsw i32 %tmp96, -52352119  %tmp98 = mul nuw nsw i32 %tmp79, 298120  %tmp99 = add nsw i32 %tmp98, -4768121  %tmp100 = add nsw i32 %tmp91, %tmp99122  %tmp101 = sdiv i32 %tmp100, 256123  %tmp102 = tail call { i32, i1 } @llvm.sadd.with.overflow.i32(i32 %tmp99, i32 %tmp95)124  %tmp103 = extractvalue { i32, i1 } %tmp102, 1125  br i1 %tmp103, label %bb104, label %bb105126 127bb104:                                            ; preds = %bb120, %bb109, %bb105, %bb74128  tail call void @llvm.trap()129  unreachable130 131bb105:                                            ; preds = %bb74132  %tmp106 = extractvalue { i32, i1 } %tmp102, 0133  %tmp107 = tail call { i32, i1 } @llvm.sadd.with.overflow.i32(i32 %tmp106, i32 %tmp93)134  %tmp108 = extractvalue { i32, i1 } %tmp107, 1135  br i1 %tmp108, label %bb104, label %bb109136 137bb109:                                            ; preds = %bb105138  %tmp110 = extractvalue { i32, i1 } %tmp107, 0139  %tmp111 = sdiv i32 %tmp110, 256140  %tmp112 = add nsw i32 %tmp97, %tmp99141  %tmp113 = sdiv i32 %tmp112, 256142  %tmp114 = mul nuw nsw i32 %tmp83, 298143  %tmp115 = add nsw i32 %tmp114, -4768144  %tmp116 = add nsw i32 %tmp91, %tmp115145  %tmp117 = sdiv i32 %tmp116, 256146  %tmp118 = tail call { i32, i1 } @llvm.sadd.with.overflow.i32(i32 %tmp115, i32 %tmp95)147  %tmp119 = extractvalue { i32, i1 } %tmp118, 1148  br i1 %tmp119, label %bb104, label %bb120149 150bb120:                                            ; preds = %bb109151  %tmp121 = extractvalue { i32, i1 } %tmp118, 0152  %tmp122 = tail call { i32, i1 } @llvm.sadd.with.overflow.i32(i32 %tmp121, i32 %tmp93)153  %tmp123 = extractvalue { i32, i1 } %tmp122, 1154  br i1 %tmp123, label %bb104, label %bb124155 156bb124:                                            ; preds = %bb120157  %tmp125 = sext i32 %tmp101 to i64158  %tmp126 = getelementptr inbounds i8, ptr %arg2, i64 %tmp125159  %tmp127 = load i8, ptr %tmp126, align 1160  %tmp128 = zext i8 %tmp127 to i32161  %tmp129 = lshr i32 %tmp128, 3162  %tmp130 = shl nuw nsw i32 %tmp129, 11163  %tmp131 = sext i32 %tmp111 to i64164  %tmp132 = getelementptr inbounds i8, ptr %arg2, i64 %tmp131165  %tmp133 = load i8, ptr %tmp132, align 1166  %tmp134 = zext i8 %tmp133 to i32167  %tmp135 = lshr i32 %tmp134, 2168  %tmp136 = shl nuw nsw i32 %tmp135, 5169  %tmp137 = or i32 %tmp136, %tmp130170  %tmp138 = sext i32 %tmp113 to i64171  %tmp139 = getelementptr inbounds i8, ptr %arg2, i64 %tmp138172  %tmp140 = load i8, ptr %tmp139, align 1173  %tmp141 = zext i8 %tmp140 to i32174  %tmp142 = lshr i32 %tmp141, 3175  %tmp143 = or i32 %tmp137, %tmp142176  %tmp144 = icmp ult i64 %tmp80, %tmp75177  br i1 %tmp144, label %bb145, label %bb173178 179bb145:                                            ; preds = %bb124180  %tmp146 = add nsw i32 %tmp97, %tmp115181  %tmp147 = sdiv i32 %tmp146, 256182  %tmp148 = sext i32 %tmp147 to i64183  %tmp149 = getelementptr inbounds i8, ptr %arg2, i64 %tmp148184  %tmp150 = load i8, ptr %tmp149, align 1185  %tmp151 = extractvalue { i32, i1 } %tmp122, 0186  %tmp152 = sdiv i32 %tmp151, 256187  %tmp153 = sext i32 %tmp152 to i64188  %tmp154 = getelementptr inbounds i8, ptr %arg2, i64 %tmp153189  %tmp155 = load i8, ptr %tmp154, align 1190  %tmp156 = sext i32 %tmp117 to i64191  %tmp157 = getelementptr inbounds i8, ptr %arg2, i64 %tmp156192  %tmp158 = load i8, ptr %tmp157, align 1193  %tmp159 = zext i8 %tmp158 to i32194  %tmp160 = lshr i32 %tmp159, 3195  %tmp161 = shl nuw nsw i32 %tmp160, 11196  %tmp162 = zext i8 %tmp155 to i32197  %tmp163 = lshr i32 %tmp162, 2198  %tmp164 = shl nuw nsw i32 %tmp163, 5199  %tmp165 = zext i8 %tmp150 to i32200  %tmp166 = lshr i32 %tmp165, 3201  %tmp167 = or i32 %tmp164, %tmp166202  %tmp168 = or i32 %tmp167, %tmp161203  %tmp169 = shl nuw i32 %tmp168, 16204  %tmp170 = or i32 %tmp169, %tmp143205  %tmp171 = getelementptr inbounds i16, ptr %tmp44, i64 %tmp76206  store i32 %tmp170, ptr %tmp171, align 4207  br label %bb176208 209bb173:                                            ; preds = %bb124210  %tmp174 = trunc i32 %tmp143 to i16211  %tmp175 = getelementptr inbounds i16, ptr %tmp44, i64 %tmp76212  store i16 %tmp174, ptr %tmp175, align 2213  br label %bb176214 215bb176:                                            ; preds = %bb173, %bb145216  %tmp177 = add i64 %tmp76, 2217  %tmp178 = load i64, ptr %tmp35, align 8218  %tmp179 = load i64, ptr %tmp11, align 8219  %tmp180 = add i64 %tmp178, 1220  %tmp181 = sub i64 %tmp180, %tmp179221  %tmp182 = icmp ult i64 %tmp177, %tmp181222  br i1 %tmp182, label %bb74, label %bb52223}224 225; Function Attrs: noreturn nounwind226declare void @llvm.trap() #0227 228; Function Attrs: nounwind readnone speculatable229declare { i32, i1 } @llvm.sadd.with.overflow.i32(i32, i32) #1230 231attributes #0 = { noreturn nounwind }232attributes #1 = { nounwind readnone speculatable }233