; LLVM IR from tangjz/acm-icpc :: codeforces/gym (103957G)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@t = external dso_local global i32, align 4
@n = external dso_local global i32, align 4
@q = external dso_local global i32, align 4
@kk = external dso_local global i32, align 4
@w = external dso_local global [201 x i32], align 16
@sw = external dso_local global i32, align 4
@p = external dso_local global [201 x i32], align 16
@size = external dso_local global i32, align 4
@c = external dso_local global [51 x [51 x double]], align 16
@pp = external dso_local global [51 x double], align 16
@qq = external dso_local global [51 x double], align 16
@s = external dso_local global [50001 x double], align 16
@e = external dso_local global [201 x %"class.std::vector"], align 16
@vis = external dso_local global [201 x i8], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [17 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z5solvei(i32 noundef) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #4 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca %"class.std::vector", align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca double, align 8
  %16 = alloca i32, align 4
  %17 = alloca double, align 8
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #7
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %20

20:                                               ; preds = %69, %0
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = icmp slt i32 %21, 51
  br i1 %22, label %24, label %23

23:                                               ; preds = %20
  store i32 2, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #7
  br label %72

24:                                               ; preds = %20
  %25 = load i32, ptr %2, align 4, !tbaa !5
  %26 = sext i32 %25 to i64
  %27 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %26
  %28 = load i32, ptr %2, align 4, !tbaa !5
  %29 = sext i32 %28 to i64
  %30 = getelementptr inbounds [51 x double], ptr %27, i64 0, i64 %29
  store double 1.000000e+00, ptr %30, align 8, !tbaa !9
  %31 = load i32, ptr %2, align 4, !tbaa !5
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %32
  %34 = getelementptr inbounds [51 x double], ptr %33, i64 0, i64 0
  store double 1.000000e+00, ptr %34, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #7
  store i32 1, ptr %4, align 4, !tbaa !5
  br label %35

35:                                               ; preds = %65, %24
  %36 = load i32, ptr %4, align 4, !tbaa !5
  %37 = load i32, ptr %2, align 4, !tbaa !5
  %38 = icmp slt i32 %36, %37
  br i1 %38, label %40, label %39

39:                                               ; preds = %35
  store i32 5, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #7
  br label %68

40:                                               ; preds = %35
  %41 = load i32, ptr %2, align 4, !tbaa !5
  %42 = sub nsw i32 %41, 1
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %43
  %45 = load i32, ptr %4, align 4, !tbaa !5
  %46 = sub nsw i32 %45, 1
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds [51 x double], ptr %44, i64 0, i64 %47
  %49 = load double, ptr %48, align 8, !tbaa !9
  %50 = load i32, ptr %2, align 4, !tbaa !5
  %51 = sub nsw i32 %50, 1
  %52 = sext i32 %51 to i64
  %53 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %52
  %54 = load i32, ptr %4, align 4, !tbaa !5
  %55 = sext i32 %54 to i64
  %56 = getelementptr inbounds [51 x double], ptr %53, i64 0, i64 %55
  %57 = load double, ptr %56, align 8, !tbaa !9
  %58 = fadd double %49, %57
  %59 = load i32, ptr %2, align 4, !tbaa !5
  %60 = sext i32 %59 to i64
  %61 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %60
  %62 = load i32, ptr %4, align 4, !tbaa !5
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds [51 x double], ptr %61, i64 0, i64 %63
  store double %58, ptr %64, align 8, !tbaa !9
  br label %65

65:                                               ; preds = %40
  %66 = load i32, ptr %4, align 4, !tbaa !5
  %67 = add nsw i32 %66, 1
  store i32 %67, ptr %4, align 4, !tbaa !5
  br label %35, !llvm.loop !11

68:                                               ; preds = %39
  br label %69

69:                                               ; preds = %68
  %70 = load i32, ptr %2, align 4, !tbaa !5
  %71 = add nsw i32 %70, 1
  store i32 %71, ptr %2, align 4, !tbaa !5
  br label %20, !llvm.loop !13

72:                                               ; preds = %23
  %73 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @t)
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #7
  store i32 1, ptr %5, align 4, !tbaa !5
  br label %74

74:                                               ; preds = %271, %72
  %75 = load i32, ptr %5, align 4, !tbaa !5
  %76 = load i32, ptr @t, align 4, !tbaa !5
  %77 = icmp sle i32 %75, %76
  br i1 %77, label %79, label %78

78:                                               ; preds = %74
  store i32 8, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #7
  br label %274

79:                                               ; preds = %74
  %80 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef @n, ptr noundef @q, ptr noundef @kk)
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #7
  store i32 1, ptr %6, align 4, !tbaa !5
  br label %81

81:                                               ; preds = %90, %79
  %82 = load i32, ptr %6, align 4, !tbaa !5
  %83 = load i32, ptr @n, align 4, !tbaa !5
  %84 = icmp sle i32 %82, %83
  br i1 %84, label %86, label %85

85:                                               ; preds = %81
  store i32 11, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  br label %93

86:                                               ; preds = %81
  call void @llvm.lifetime.start.p0(i64 24, ptr %7) #7
  call void @llvm.memset.p0.i64(ptr align 8 %7, i8 0, i64 24, i1 false)
  call void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  %87 = load i32, ptr %6, align 4, !tbaa !5
  %88 = sext i32 %87 to i64
  %89 = getelementptr inbounds [201 x %"class.std::vector"], ptr @e, i64 0, i64 %88
  call void @_ZNSt6vectorIiSaIiEE4swapERS1_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %89) #7
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %7) #7
  br label %90

90:                                               ; preds = %86
  %91 = load i32, ptr %6, align 4, !tbaa !5
  %92 = add nsw i32 %91, 1
  store i32 %92, ptr %6, align 4, !tbaa !5
  br label %81, !llvm.loop !14

93:                                               ; preds = %85
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #7
  store i32 1, ptr %8, align 4, !tbaa !5
  br label %94

94:                                               ; preds = %107, %93
  %95 = load i32, ptr %8, align 4, !tbaa !5
  %96 = load i32, ptr @n, align 4, !tbaa !5
  %97 = icmp slt i32 %95, %96
  br i1 %97, label %99, label %98

98:                                               ; preds = %94
  store i32 14, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #7
  br label %110

99:                                               ; preds = %94
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #7
  %100 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.2, ptr noundef %9, ptr noundef %10)
  %101 = load i32, ptr %9, align 4, !tbaa !5
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds [201 x %"class.std::vector"], ptr @e, i64 0, i64 %102
  call void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %103, ptr noundef nonnull align 4 dereferenceable(4) %10)
  %104 = load i32, ptr %10, align 4, !tbaa !5
  %105 = sext i32 %104 to i64
  %106 = getelementptr inbounds [201 x %"class.std::vector"], ptr @e, i64 0, i64 %105
  call void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %106, ptr noundef nonnull align 4 dereferenceable(4) %9)
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #7
  br label %107

107:                                              ; preds = %99
  %108 = load i32, ptr %8, align 4, !tbaa !5
  %109 = add nsw i32 %108, 1
  store i32 %109, ptr %8, align 4, !tbaa !5
  br label %94, !llvm.loop !15

110:                                              ; preds = %98
  store i32 0, ptr @sw, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #7
  store i32 1, ptr %11, align 4, !tbaa !5
  br label %111

111:                                              ; preds = %127, %110
  %112 = load i32, ptr %11, align 4, !tbaa !5
  %113 = load i32, ptr @n, align 4, !tbaa !5
  %114 = icmp sle i32 %112, %113
  br i1 %114, label %116, label %115

115:                                              ; preds = %111
  store i32 17, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #7
  br label %130

116:                                              ; preds = %111
  %117 = load i32, ptr %11, align 4, !tbaa !5
  %118 = sext i32 %117 to i64
  %119 = getelementptr inbounds i32, ptr @w, i64 %118
  %120 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %119)
  %121 = load i32, ptr %11, align 4, !tbaa !5
  %122 = sext i32 %121 to i64
  %123 = getelementptr inbounds [201 x i32], ptr @w, i64 0, i64 %122
  %124 = load i32, ptr %123, align 4, !tbaa !5
  %125 = load i32, ptr @sw, align 4, !tbaa !5
  %126 = add nsw i32 %125, %124
  store i32 %126, ptr @sw, align 4, !tbaa !5
  br label %127

127:                                              ; preds = %116
  %128 = load i32, ptr %11, align 4, !tbaa !5
  %129 = add nsw i32 %128, 1
  store i32 %129, ptr %11, align 4, !tbaa !5
  br label %111, !llvm.loop !16

130:                                              ; preds = %115
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #7
  store i32 1, ptr %12, align 4, !tbaa !5
  br label %131

131:                                              ; preds = %141, %130
  %132 = load i32, ptr %12, align 4, !tbaa !5
  %133 = load i32, ptr @n, align 4, !tbaa !5
  %134 = icmp sle i32 %132, %133
  br i1 %134, label %136, label %135

135:                                              ; preds = %131
  store i32 20, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  br label %144

136:                                              ; preds = %131
  %137 = load i32, ptr %12, align 4, !tbaa !5
  %138 = sext i32 %137 to i64
  %139 = getelementptr inbounds i32, ptr @p, i64 %138
  %140 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %139)
  br label %141

141:                                              ; preds = %136
  %142 = load i32, ptr %12, align 4, !tbaa !5
  %143 = add nsw i32 %142, 1
  store i32 %143, ptr %12, align 4, !tbaa !5
  br label %131, !llvm.loop !17

144:                                              ; preds = %135
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %145

145:                                              ; preds = %154, %144
  %146 = load i32, ptr %13, align 4, !tbaa !5
  %147 = load i32, ptr @sw, align 4, !tbaa !5
  %148 = icmp sle i32 %146, %147
  br i1 %148, label %150, label %149

149:                                              ; preds = %145
  store i32 23, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %157

150:                                              ; preds = %145
  %151 = load i32, ptr %13, align 4, !tbaa !5
  %152 = sext i32 %151 to i64
  %153 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %152
  store double 0.000000e+00, ptr %153, align 8, !tbaa !9
  br label %154

154:                                              ; preds = %150
  %155 = load i32, ptr %13, align 4, !tbaa !5
  %156 = add nsw i32 %155, 1
  store i32 %156, ptr %13, align 4, !tbaa !5
  br label %145, !llvm.loop !18

157:                                              ; preds = %149
  %158 = load i32, ptr @n, align 4, !tbaa !5
  %159 = sext i32 %158 to i64
  %160 = mul i64 %159, 1
  call void @llvm.memset.p0.i64(ptr align 1 getelementptr inbounds (i8, ptr @vis, i64 1), i8 0, i64 %160, i1 false)
  %161 = load i32, ptr @n, align 4, !tbaa !5
  store i32 %161, ptr @size, align 4, !tbaa !5
  call void @_Z5solvei(i32 noundef 1)
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #7
  %162 = load i32, ptr @sw, align 4, !tbaa !5
  store i32 %162, ptr %14, align 4, !tbaa !5
  br label %163

163:                                              ; preds = %178, %157
  %164 = load i32, ptr %14, align 4, !tbaa !5
  %165 = icmp sgt i32 %164, 0
  br i1 %165, label %167, label %166

166:                                              ; preds = %163
  store i32 26, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #7
  br label %181

167:                                              ; preds = %163
  %168 = load i32, ptr %14, align 4, !tbaa !5
  %169 = sext i32 %168 to i64
  %170 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %169
  %171 = load double, ptr %170, align 8, !tbaa !9
  %172 = load i32, ptr %14, align 4, !tbaa !5
  %173 = sub nsw i32 %172, 1
  %174 = sext i32 %173 to i64
  %175 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %174
  %176 = load double, ptr %175, align 8, !tbaa !9
  %177 = fadd double %176, %171
  store double %177, ptr %175, align 8, !tbaa !9
  br label %178

178:                                              ; preds = %167
  %179 = load i32, ptr %14, align 4, !tbaa !5
  %180 = add nsw i32 %179, -1
  store i32 %180, ptr %14, align 4, !tbaa !5
  br label %163, !llvm.loop !19

181:                                              ; preds = %166
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  store double 0.000000e+00, ptr %15, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #7
  store i32 1, ptr %16, align 4, !tbaa !5
  br label %182

182:                                              ; preds = %264, %181
  %183 = load i32, ptr %16, align 4, !tbaa !5
  %184 = load i32, ptr @sw, align 4, !tbaa !5
  %185 = icmp sle i32 %183, %184
  br i1 %185, label %187, label %186

186:                                              ; preds = %182
  store i32 29, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #7
  br label %267

187:                                              ; preds = %182
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #7
  store double 0.000000e+00, ptr %17, align 8, !tbaa !9
  %188 = load double, ptr @s, align 16, !tbaa !9
  %189 = load i32, ptr %16, align 4, !tbaa !5
  %190 = sext i32 %189 to i64
  %191 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %190
  %192 = load double, ptr %191, align 8, !tbaa !9
  %193 = fdiv double %192, %188
  store double %193, ptr %191, align 8, !tbaa !9
  store double 1.000000e+00, ptr @qq, align 16, !tbaa !9
  store double 1.000000e+00, ptr @pp, align 16, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #7
  store i32 1, ptr %18, align 4, !tbaa !5
  br label %194

194:                                              ; preds = %227, %187
  %195 = load i32, ptr %18, align 4, !tbaa !5
  %196 = load i32, ptr @q, align 4, !tbaa !5
  %197 = icmp sle i32 %195, %196
  br i1 %197, label %199, label %198

198:                                              ; preds = %194
  store i32 32, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #7
  br label %230

199:                                              ; preds = %194
  %200 = load i32, ptr %18, align 4, !tbaa !5
  %201 = sub nsw i32 %200, 1
  %202 = sext i32 %201 to i64
  %203 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %202
  %204 = load double, ptr %203, align 8, !tbaa !9
  %205 = load i32, ptr %16, align 4, !tbaa !5
  %206 = sext i32 %205 to i64
  %207 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %206
  %208 = load double, ptr %207, align 8, !tbaa !9
  %209 = fmul double %204, %208
  %210 = load i32, ptr %18, align 4, !tbaa !5
  %211 = sext i32 %210 to i64
  %212 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %211
  store double %209, ptr %212, align 8, !tbaa !9
  %213 = load i32, ptr %18, align 4, !tbaa !5
  %214 = sub nsw i32 %213, 1
  %215 = sext i32 %214 to i64
  %216 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %215
  %217 = load double, ptr %216, align 8, !tbaa !9
  %218 = load i32, ptr %16, align 4, !tbaa !5
  %219 = sext i32 %218 to i64
  %220 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %219
  %221 = load double, ptr %220, align 8, !tbaa !9
  %222 = fsub double 1.000000e+00, %221
  %223 = fmul double %217, %222
  %224 = load i32, ptr %18, align 4, !tbaa !5
  %225 = sext i32 %224 to i64
  %226 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %225
  store double %223, ptr %226, align 8, !tbaa !9
  br label %227

227:                                              ; preds = %199
  %228 = load i32, ptr %18, align 4, !tbaa !5
  %229 = add nsw i32 %228, 1
  store i32 %229, ptr %18, align 4, !tbaa !5
  br label %194, !llvm.loop !20

230:                                              ; preds = %198
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #7
  store i32 0, ptr %19, align 4, !tbaa !5
  br label %231

231:                                              ; preds = %257, %230
  %232 = load i32, ptr %19, align 4, !tbaa !5
  %233 = load i32, ptr @kk, align 4, !tbaa !5
  %234 = icmp slt i32 %232, %233
  br i1 %234, label %236, label %235

235:                                              ; preds = %231
  store i32 35, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #7
  br label %260

236:                                              ; preds = %231
  %237 = load i32, ptr @q, align 4, !tbaa !5
  %238 = load i32, ptr %19, align 4, !tbaa !5
  %239 = sub nsw i32 %237, %238
  %240 = sext i32 %239 to i64
  %241 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %240
  %242 = load double, ptr %241, align 8, !tbaa !9
  %243 = load i32, ptr %19, align 4, !tbaa !5
  %244 = sext i32 %243 to i64
  %245 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %244
  %246 = load double, ptr %245, align 8, !tbaa !9
  %247 = fmul double %242, %246
  %248 = load i32, ptr @q, align 4, !tbaa !5
  %249 = sext i32 %248 to i64
  %250 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %249
  %251 = load i32, ptr %19, align 4, !tbaa !5
  %252 = sext i32 %251 to i64
  %253 = getelementptr inbounds [51 x double], ptr %250, i64 0, i64 %252
  %254 = load double, ptr %253, align 8, !tbaa !9
  %255 = load double, ptr %17, align 8, !tbaa !9
  %256 = call double @llvm.fmuladd.f64(double %247, double %254, double %255)
  store double %256, ptr %17, align 8, !tbaa !9
  br label %257

257:                                              ; preds = %236
  %258 = load i32, ptr %19, align 4, !tbaa !5
  %259 = add nsw i32 %258, 1
  store i32 %259, ptr %19, align 4, !tbaa !5
  br label %231, !llvm.loop !21

260:                                              ; preds = %235
  %261 = load double, ptr %17, align 8, !tbaa !9
  %262 = load double, ptr %15, align 8, !tbaa !9
  %263 = fadd double %262, %261
  store double %263, ptr %15, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #7
  br label %264

264:                                              ; preds = %260
  %265 = load i32, ptr %16, align 4, !tbaa !5
  %266 = add nsw i32 %265, 1
  store i32 %266, ptr %16, align 4, !tbaa !5
  br label %182, !llvm.loop !22

267:                                              ; preds = %186
  %268 = load i32, ptr %5, align 4, !tbaa !5
  %269 = load double, ptr %15, align 8, !tbaa !9
  %270 = call i32 (ptr, ...) @printf(ptr noundef @.str.3, i32 noundef %268, double noundef %269)
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  br label %271

271:                                              ; preds = %267
  %272 = load i32, ptr %5, align 4, !tbaa !5
  %273 = add nsw i32 %272, 1
  store i32 %273, ptr %5, align 4, !tbaa !5
  br label %74, !llvm.loop !23

274:                                              ; preds = %78
  ret i32 0
}

declare i32 @__isoc99_scanf(ptr noundef, ...) #5

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE4swapERS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(4)) #2 align 2

declare i32 @printf(ptr noundef, ...) #5

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"double", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}
!19 = distinct !{!19, !12}
!20 = distinct !{!20, !12}
!21 = distinct !{!21, !12}
!22 = distinct !{!22, !12}
!23 = distinct !{!23, !12}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@t = external dso_local global i32, align 4
@n = external dso_local global i32, align 4
@q = external dso_local global i32, align 4
@kk = external dso_local global i32, align 4
@w = external dso_local global [201 x i32], align 16
@sw = external dso_local local_unnamed_addr global i32, align 4
@p = external dso_local global [201 x i32], align 16
@size = external dso_local local_unnamed_addr global i32, align 4
@c = external dso_local local_unnamed_addr global [51 x [51 x double]], align 16
@pp = external dso_local local_unnamed_addr global [51 x double], align 16
@qq = external dso_local local_unnamed_addr global [51 x double], align 16
@s = external dso_local local_unnamed_addr global [50001 x double], align 16
@e = external dso_local global [201 x %"class.std::vector"], align 16
@vis = external dso_local local_unnamed_addr global [201 x i8], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [17 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z5solvei(i32 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #4 {
  %1 = alloca %"class.std::vector", align 8
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  br label %7

4:                                                ; preds = %._crit_edge
  %5 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @t)
  %6 = load i32, ptr @t, align 4, !tbaa !5
  %.not118 = icmp slt i32 %6, 1
  br i1 %.not118, label %._crit_edge122, label %.lr.ph121

7:                                                ; preds = %0, %._crit_edge
  %indvars.iv127 = phi i64 [ 0, %0 ], [ %indvars.iv.next128, %._crit_edge ]
  %8 = add nsw i64 %indvars.iv127, -1
  %9 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %indvars.iv127
  %10 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %indvars.iv127, i64 %indvars.iv127
  store double 1.000000e+00, ptr %10, align 8, !tbaa !9
  store double 1.000000e+00, ptr %9, align 8, !tbaa !9
  %11 = icmp ugt i64 %indvars.iv127, 1
  br i1 %11, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %7
  %12 = add nsw i64 %indvars.iv127, -1
  %.phi.trans.insert = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %12, i64 0
  %.pre = load double, ptr %.phi.trans.insert, align 8, !tbaa !9
  %min.iters.check = icmp ult i64 %indvars.iv127, 5
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.ph

scalar.ph.preheader:                              ; preds = %middle.block, %.lr.ph
  %.ph = phi double [ %.pre, %.lr.ph ], [ %vector.recur.extract, %middle.block ]
  %indvars.iv.ph = phi i64 [ 1, %.lr.ph ], [ %ind.end, %middle.block ]
  br label %scalar.ph

vector.ph:                                        ; preds = %.lr.ph
  %n.vec = and i64 %8, -4
  %ind.end = or disjoint i64 %n.vec, 1
  %vector.recur.init = insertelement <2 x double> poison, double %.pre, i64 1
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vector.recur = phi <2 x double> [ %vector.recur.init, %vector.ph ], [ %wide.load184, %vector.body ]
  %offset.idx = or disjoint i64 %index, 1
  %13 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %12, i64 %offset.idx
  %14 = getelementptr inbounds i8, ptr %13, i64 16
  %wide.load = load <2 x double>, ptr %13, align 8, !tbaa !9
  %wide.load184 = load <2 x double>, ptr %14, align 8, !tbaa !9
  %15 = shufflevector <2 x double> %vector.recur, <2 x double> %wide.load, <2 x i32> <i32 1, i32 2>
  %16 = shufflevector <2 x double> %wide.load, <2 x double> %wide.load184, <2 x i32> <i32 1, i32 2>
  %17 = fadd <2 x double> %15, %wide.load
  %18 = fadd <2 x double> %16, %wide.load184
  %19 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %indvars.iv127, i64 %offset.idx
  %20 = getelementptr inbounds i8, ptr %19, i64 16
  store <2 x double> %17, ptr %19, align 8, !tbaa !9
  store <2 x double> %18, ptr %20, align 8, !tbaa !9
  %index.next = add nuw i64 %index, 4
  %21 = icmp eq i64 %index.next, %n.vec
  br i1 %21, label %middle.block, label %vector.body, !llvm.loop !11

middle.block:                                     ; preds = %vector.body
  %vector.recur.extract = extractelement <2 x double> %wide.load184, i64 1
  %cmp.n = icmp eq i64 %8, %n.vec
  br i1 %cmp.n, label %._crit_edge, label %scalar.ph.preheader

._crit_edge:                                      ; preds = %scalar.ph, %middle.block, %7
  %indvars.iv.next128 = add nuw nsw i64 %indvars.iv127, 1
  %exitcond130.not = icmp eq i64 %indvars.iv.next128, 51
  br i1 %exitcond130.not, label %4, label %7, !llvm.loop !15

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %22 = phi double [ %24, %scalar.ph ], [ %.ph, %scalar.ph.preheader ]
  %indvars.iv = phi i64 [ %indvars.iv.next, %scalar.ph ], [ %indvars.iv.ph, %scalar.ph.preheader ]
  %23 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %12, i64 %indvars.iv
  %24 = load double, ptr %23, align 8, !tbaa !9
  %25 = fadd double %22, %24
  %26 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %indvars.iv127, i64 %indvars.iv
  store double %25, ptr %26, align 8, !tbaa !9
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %indvars.iv127
  br i1 %exitcond.not, label %._crit_edge, label %scalar.ph, !llvm.loop !16

._crit_edge122:                                   ; preds = %._crit_edge116, %4
  ret i32 0

.lr.ph121:                                        ; preds = %4, %._crit_edge116
  %.065119 = phi i32 [ %94, %._crit_edge116 ], [ 1, %4 ]
  %27 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull @n, ptr noundef nonnull @q, ptr noundef nonnull @kk)
  %28 = load i32, ptr @n, align 4, !tbaa !5
  %.not6881 = icmp slt i32 %28, 1
  br i1 %.not6881, label %._crit_edge87.thread, label %.lr.ph84

._crit_edge87.thread:                             ; preds = %.lr.ph121
  store i32 0, ptr @sw, align 4, !tbaa !5
  br label %.lr.ph97.preheader

.preheader77:                                     ; preds = %.lr.ph84
  %29 = icmp sgt i32 %31, 1
  br i1 %29, label %.lr.ph86, label %._crit_edge87

.lr.ph84:                                         ; preds = %.lr.ph121, %.lr.ph84
  %indvars.iv131 = phi i64 [ %indvars.iv.next132, %.lr.ph84 ], [ 1, %.lr.ph121 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %1) #7
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %1, i8 0, i64 24, i1 false)
  call void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  %30 = getelementptr inbounds [201 x %"class.std::vector"], ptr @e, i64 0, i64 %indvars.iv131
  call void @_ZNSt6vectorIiSaIiEE4swapERS1_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(24) %30) #7
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %1) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %1) #7
  %indvars.iv.next132 = add nuw nsw i64 %indvars.iv131, 1
  %31 = load i32, ptr @n, align 4, !tbaa !5
  %32 = sext i32 %31 to i64
  %.not68.not = icmp slt i64 %indvars.iv131, %32
  br i1 %.not68.not, label %.lr.ph84, label %.preheader77, !llvm.loop !17

._crit_edge87:                                    ; preds = %.lr.ph86, %.preheader77
  %33 = phi i32 [ %31, %.preheader77 ], [ %42, %.lr.ph86 ]
  store i32 0, ptr @sw, align 4, !tbaa !5
  %.not6988 = icmp slt i32 %33, 1
  br i1 %.not6988, label %.lr.ph97.preheader, label %.lr.ph91

.lr.ph86:                                         ; preds = %.preheader77, %.lr.ph86
  %.06385 = phi i32 [ %41, %.lr.ph86 ], [ 1, %.preheader77 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #7
  %34 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.2, ptr noundef nonnull %2, ptr noundef nonnull %3)
  %35 = load i32, ptr %2, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds [201 x %"class.std::vector"], ptr @e, i64 0, i64 %36
  call void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %37, ptr noundef nonnull align 4 dereferenceable(4) %3)
  %38 = load i32, ptr %3, align 4, !tbaa !5
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [201 x %"class.std::vector"], ptr @e, i64 0, i64 %39
  call void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24) %40, ptr noundef nonnull align 4 dereferenceable(4) %2)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #7
  %41 = add nuw nsw i32 %.06385, 1
  %42 = load i32, ptr @n, align 4, !tbaa !5
  %43 = icmp slt i32 %41, %42
  br i1 %43, label %.lr.ph86, label %._crit_edge87, !llvm.loop !18

.preheader76:                                     ; preds = %.lr.ph91
  %.not7092 = icmp slt i32 %49, 1
  br i1 %.not7092, label %.preheader75, label %.lr.ph94

.lr.ph91:                                         ; preds = %._crit_edge87, %.lr.ph91
  %indvars.iv134 = phi i64 [ %indvars.iv.next135, %.lr.ph91 ], [ 1, %._crit_edge87 ]
  %44 = getelementptr inbounds i32, ptr @w, i64 %indvars.iv134
  %45 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %44)
  %46 = load i32, ptr %44, align 4, !tbaa !5
  %47 = load i32, ptr @sw, align 4, !tbaa !5
  %48 = add nsw i32 %47, %46
  store i32 %48, ptr @sw, align 4, !tbaa !5
  %indvars.iv.next135 = add nuw nsw i64 %indvars.iv134, 1
  %49 = load i32, ptr @n, align 4, !tbaa !5
  %50 = sext i32 %49 to i64
  %.not69.not = icmp slt i64 %indvars.iv134, %50
  br i1 %.not69.not, label %.lr.ph91, label %.preheader76, !llvm.loop !19

.preheader75.loopexit:                            ; preds = %.lr.ph94
  %.pre160 = load i32, ptr @sw, align 4, !tbaa !5
  br label %.preheader75

.preheader75:                                     ; preds = %.preheader75.loopexit, %.preheader76
  %51 = phi i32 [ %48, %.preheader76 ], [ %.pre160, %.preheader75.loopexit ]
  %.lcssa = phi i32 [ %49, %.preheader76 ], [ %58, %.preheader75.loopexit ]
  %.not7195 = icmp slt i32 %51, 0
  br i1 %.not7195, label %._crit_edge98, label %.lr.ph97.preheader

.lr.ph97.preheader:                               ; preds = %._crit_edge87, %._crit_edge87.thread, %.preheader75
  %.lcssa167 = phi i32 [ %.lcssa, %.preheader75 ], [ %28, %._crit_edge87.thread ], [ %33, %._crit_edge87 ]
  %52 = phi i32 [ %51, %.preheader75 ], [ 0, %._crit_edge87.thread ], [ 0, %._crit_edge87 ]
  %53 = add nuw i32 %52, 1
  %54 = zext i32 %53 to i64
  %55 = shl nuw nsw i64 %54, 3
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(1) @s, i8 0, i64 %55, i1 false), !tbaa !9
  br label %._crit_edge98

.lr.ph94:                                         ; preds = %.preheader76, %.lr.ph94
  %indvars.iv137 = phi i64 [ %indvars.iv.next138, %.lr.ph94 ], [ 1, %.preheader76 ]
  %56 = getelementptr inbounds i32, ptr @p, i64 %indvars.iv137
  %57 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %56)
  %indvars.iv.next138 = add nuw nsw i64 %indvars.iv137, 1
  %58 = load i32, ptr @n, align 4, !tbaa !5
  %59 = sext i32 %58 to i64
  %.not70.not = icmp slt i64 %indvars.iv137, %59
  br i1 %.not70.not, label %.lr.ph94, label %.preheader75.loopexit, !llvm.loop !20

._crit_edge98:                                    ; preds = %.lr.ph97.preheader, %.preheader75
  %.lcssa168 = phi i32 [ %.lcssa167, %.lr.ph97.preheader ], [ %.lcssa, %.preheader75 ]
  %60 = sext i32 %.lcssa168 to i64
  call void @llvm.memset.p0.i64(ptr nonnull align 1 getelementptr inbounds (i8, ptr @vis, i64 1), i8 0, i64 %60, i1 false)
  store i32 %.lcssa168, ptr @size, align 4, !tbaa !5
  call void @_Z5solvei(i32 noundef 1)
  %61 = load i32, ptr @sw, align 4, !tbaa !5
  %62 = icmp sgt i32 %61, 0
  br i1 %62, label %.lr.ph101.preheader, label %._crit_edge116

.lr.ph101.preheader:                              ; preds = %._crit_edge98
  %63 = zext nneg i32 %61 to i64
  %.phi.trans.insert161 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %63
  %.pre162 = load double, ptr %.phi.trans.insert161, align 8, !tbaa !9
  %xtraiter = and i64 %63, 3
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.lr.ph101.prol.loopexit, label %.lr.ph101.prol

.lr.ph101.prol:                                   ; preds = %.lr.ph101.preheader, %.lr.ph101.prol
  %64 = phi double [ %67, %.lr.ph101.prol ], [ %.pre162, %.lr.ph101.preheader ]
  %indvars.iv143.prol = phi i64 [ %indvars.iv.next144.prol, %.lr.ph101.prol ], [ %63, %.lr.ph101.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %.lr.ph101.prol ], [ 0, %.lr.ph101.preheader ]
  %indvars.iv.next144.prol = add nsw i64 %indvars.iv143.prol, -1
  %65 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %indvars.iv.next144.prol
  %66 = load double, ptr %65, align 8, !tbaa !9
  %67 = fadd double %64, %66
  store double %67, ptr %65, align 8, !tbaa !9
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter
  br i1 %prol.iter.cmp.not, label %.lr.ph101.prol.loopexit, label %.lr.ph101.prol, !llvm.loop !21

.lr.ph101.prol.loopexit:                          ; preds = %.lr.ph101.prol, %.lr.ph101.preheader
  %.unr = phi double [ %.pre162, %.lr.ph101.preheader ], [ %67, %.lr.ph101.prol ]
  %indvars.iv143.unr = phi i64 [ %63, %.lr.ph101.preheader ], [ %indvars.iv.next144.prol, %.lr.ph101.prol ]
  %68 = icmp ult i32 %61, 4
  br i1 %68, label %.lr.ph115, label %.lr.ph101

.lr.ph115:                                        ; preds = %.lr.ph101, %.lr.ph101.prol.loopexit
  %69 = load double, ptr @s, align 16, !tbaa !9
  %70 = load i32, ptr @q, align 4, !tbaa !5
  %.not73102 = icmp slt i32 %70, 1
  %71 = load i32, ptr @kk, align 4, !tbaa !5
  %72 = icmp sgt i32 %71, 0
  %73 = sext i32 %70 to i64
  %74 = add i32 %70, 1
  %75 = add nuw i32 %61, 1
  %wide.trip.count158 = zext i32 %75 to i64
  %wide.trip.count = zext i32 %74 to i64
  %wide.trip.count153 = zext i32 %71 to i64
  %76 = add nsw i64 %wide.trip.count, -1
  %xtraiter192 = and i64 %76, 1
  %77 = icmp eq i32 %74, 2
  %unroll_iter = and i64 %76, -2
  %lcmp.mod195.not = icmp eq i64 %xtraiter192, 0
  %xtraiter196 = and i64 %wide.trip.count153, 1
  %78 = icmp eq i32 %71, 1
  %unroll_iter199 = and i64 %wide.trip.count153, 2147483646
  %lcmp.mod197.not = icmp eq i64 %xtraiter196, 0
  br label %96

.lr.ph101:                                        ; preds = %.lr.ph101.prol.loopexit, %.lr.ph101
  %79 = phi double [ %91, %.lr.ph101 ], [ %.unr, %.lr.ph101.prol.loopexit ]
  %indvars.iv143 = phi i64 [ %indvars.iv.next144.3, %.lr.ph101 ], [ %indvars.iv143.unr, %.lr.ph101.prol.loopexit ]
  %indvars.iv.next144 = add nsw i64 %indvars.iv143, -1
  %80 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %indvars.iv.next144
  %81 = load double, ptr %80, align 8, !tbaa !9
  %82 = fadd double %79, %81
  store double %82, ptr %80, align 8, !tbaa !9
  %indvars.iv.next144.1 = add nsw i64 %indvars.iv143, -2
  %83 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %indvars.iv.next144.1
  %84 = load double, ptr %83, align 8, !tbaa !9
  %85 = fadd double %82, %84
  store double %85, ptr %83, align 8, !tbaa !9
  %indvars.iv.next144.2 = add nsw i64 %indvars.iv143, -3
  %86 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %indvars.iv.next144.2
  %87 = load double, ptr %86, align 8, !tbaa !9
  %88 = fadd double %85, %87
  store double %88, ptr %86, align 8, !tbaa !9
  %indvars.iv.next144.3 = add nsw i64 %indvars.iv143, -4
  %89 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %indvars.iv.next144.3
  %90 = load double, ptr %89, align 8, !tbaa !9
  %91 = fadd double %88, %90
  store double %91, ptr %89, align 8, !tbaa !9
  %92 = icmp ugt i64 %indvars.iv.next144.2, 1
  br i1 %92, label %.lr.ph101, label %.lr.ph115, !llvm.loop !23

._crit_edge116:                                   ; preds = %._crit_edge110, %._crit_edge98
  %.058.lcssa = phi double [ 0.000000e+00, %._crit_edge98 ], [ %124, %._crit_edge110 ]
  %93 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i32 noundef %.065119, double noundef %.058.lcssa)
  %94 = add nuw nsw i32 %.065119, 1
  %95 = load i32, ptr @t, align 4, !tbaa !5
  %.not.not = icmp slt i32 %.065119, %95
  br i1 %.not.not, label %.lr.ph121, label %._crit_edge122, !llvm.loop !24

96:                                               ; preds = %.lr.ph115, %._crit_edge110
  %indvars.iv155 = phi i64 [ 1, %.lr.ph115 ], [ %indvars.iv.next156, %._crit_edge110 ]
  %.058113 = phi double [ 0.000000e+00, %.lr.ph115 ], [ %124, %._crit_edge110 ]
  %97 = getelementptr inbounds [50001 x double], ptr @s, i64 0, i64 %indvars.iv155
  %98 = load double, ptr %97, align 8, !tbaa !9
  %99 = fdiv double %98, %69
  store double %99, ptr %97, align 8, !tbaa !9
  store double 1.000000e+00, ptr @qq, align 16, !tbaa !9
  store double 1.000000e+00, ptr @pp, align 16, !tbaa !9
  br i1 %.not73102, label %.preheader, label %.lr.ph105

.lr.ph105:                                        ; preds = %96
  %100 = fsub double 1.000000e+00, %99
  br i1 %77, label %.preheader.loopexit.unr-lcssa, label %.lr.ph105.new

.preheader.loopexit.unr-lcssa:                    ; preds = %.lr.ph105.new, %.lr.ph105
  %.unr193 = phi double [ 1.000000e+00, %.lr.ph105 ], [ %113, %.lr.ph105.new ]
  %.unr194 = phi double [ 1.000000e+00, %.lr.ph105 ], [ %111, %.lr.ph105.new ]
  %indvars.iv146.unr = phi i64 [ 1, %.lr.ph105 ], [ %indvars.iv.next147.1, %.lr.ph105.new ]
  br i1 %lcmp.mod195.not, label %.preheader, label %.preheader.loopexit.epilog-lcssa

.preheader.loopexit.epilog-lcssa:                 ; preds = %.preheader.loopexit.unr-lcssa
  %101 = fmul double %99, %.unr194
  %102 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %indvars.iv146.unr
  store double %101, ptr %102, align 8, !tbaa !9
  %103 = fmul double %100, %.unr193
  %104 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %indvars.iv146.unr
  store double %103, ptr %104, align 8, !tbaa !9
  br label %.preheader

.preheader:                                       ; preds = %.preheader.loopexit.epilog-lcssa, %.preheader.loopexit.unr-lcssa, %96
  br i1 %72, label %.lr.ph109.preheader, label %._crit_edge110

.lr.ph109.preheader:                              ; preds = %.preheader
  br i1 %78, label %._crit_edge110.loopexit.unr-lcssa, label %.lr.ph109

.lr.ph105.new:                                    ; preds = %.lr.ph105, %.lr.ph105.new
  %105 = phi double [ %113, %.lr.ph105.new ], [ 1.000000e+00, %.lr.ph105 ]
  %106 = phi double [ %111, %.lr.ph105.new ], [ 1.000000e+00, %.lr.ph105 ]
  %indvars.iv146 = phi i64 [ %indvars.iv.next147.1, %.lr.ph105.new ], [ 1, %.lr.ph105 ]
  %niter = phi i64 [ %niter.next.1, %.lr.ph105.new ], [ 0, %.lr.ph105 ]
  %107 = fmul double %99, %106
  %108 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %indvars.iv146
  store double %107, ptr %108, align 8, !tbaa !9
  %109 = fmul double %100, %105
  %110 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %indvars.iv146
  store double %109, ptr %110, align 8, !tbaa !9
  %indvars.iv.next147 = add nuw nsw i64 %indvars.iv146, 1
  %111 = fmul double %99, %107
  %112 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %indvars.iv.next147
  store double %111, ptr %112, align 8, !tbaa !9
  %113 = fmul double %100, %109
  %114 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %indvars.iv.next147
  store double %113, ptr %114, align 8, !tbaa !9
  %indvars.iv.next147.1 = add nuw nsw i64 %indvars.iv146, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %.preheader.loopexit.unr-lcssa, label %.lr.ph105.new, !llvm.loop !25

._crit_edge110.loopexit.unr-lcssa:                ; preds = %.lr.ph109, %.lr.ph109.preheader
  %.lcssa190.ph = phi double [ poison, %.lr.ph109.preheader ], [ %142, %.lr.ph109 ]
  %indvars.iv150.unr = phi i64 [ 0, %.lr.ph109.preheader ], [ %indvars.iv.next151.1, %.lr.ph109 ]
  %.056107.unr = phi double [ 0.000000e+00, %.lr.ph109.preheader ], [ %142, %.lr.ph109 ]
  br i1 %lcmp.mod197.not, label %._crit_edge110, label %.lr.ph109.epil

.lr.ph109.epil:                                   ; preds = %._crit_edge110.loopexit.unr-lcssa
  %115 = sub nsw i64 %73, %indvars.iv150.unr
  %116 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %115
  %117 = load double, ptr %116, align 8, !tbaa !9
  %118 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %indvars.iv150.unr
  %119 = load double, ptr %118, align 8, !tbaa !9
  %120 = fmul double %117, %119
  %121 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %73, i64 %indvars.iv150.unr
  %122 = load double, ptr %121, align 8, !tbaa !9
  %123 = call double @llvm.fmuladd.f64(double %120, double %122, double %.056107.unr)
  br label %._crit_edge110

._crit_edge110:                                   ; preds = %.lr.ph109.epil, %._crit_edge110.loopexit.unr-lcssa, %.preheader
  %.056.lcssa = phi double [ 0.000000e+00, %.preheader ], [ %.lcssa190.ph, %._crit_edge110.loopexit.unr-lcssa ], [ %123, %.lr.ph109.epil ]
  %124 = fadd double %.058113, %.056.lcssa
  %indvars.iv.next156 = add nuw nsw i64 %indvars.iv155, 1
  %exitcond159.not = icmp eq i64 %indvars.iv.next156, %wide.trip.count158
  br i1 %exitcond159.not, label %._crit_edge116, label %96, !llvm.loop !26

.lr.ph109:                                        ; preds = %.lr.ph109.preheader, %.lr.ph109
  %indvars.iv150 = phi i64 [ %indvars.iv.next151.1, %.lr.ph109 ], [ 0, %.lr.ph109.preheader ]
  %.056107 = phi double [ %142, %.lr.ph109 ], [ 0.000000e+00, %.lr.ph109.preheader ]
  %niter200 = phi i64 [ %niter200.next.1, %.lr.ph109 ], [ 0, %.lr.ph109.preheader ]
  %125 = sub nsw i64 %73, %indvars.iv150
  %126 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %125
  %127 = load double, ptr %126, align 8, !tbaa !9
  %128 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %indvars.iv150
  %129 = load double, ptr %128, align 16, !tbaa !9
  %130 = fmul double %127, %129
  %131 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %73, i64 %indvars.iv150
  %132 = load double, ptr %131, align 8, !tbaa !9
  %133 = call double @llvm.fmuladd.f64(double %130, double %132, double %.056107)
  %indvars.iv.next151 = or disjoint i64 %indvars.iv150, 1
  %134 = sub nsw i64 %73, %indvars.iv.next151
  %135 = getelementptr inbounds [51 x double], ptr @pp, i64 0, i64 %134
  %136 = load double, ptr %135, align 8, !tbaa !9
  %137 = getelementptr inbounds [51 x double], ptr @qq, i64 0, i64 %indvars.iv.next151
  %138 = load double, ptr %137, align 8, !tbaa !9
  %139 = fmul double %136, %138
  %140 = getelementptr inbounds [51 x [51 x double]], ptr @c, i64 0, i64 %73, i64 %indvars.iv.next151
  %141 = load double, ptr %140, align 8, !tbaa !9
  %142 = call double @llvm.fmuladd.f64(double %139, double %141, double %133)
  %indvars.iv.next151.1 = add nuw nsw i64 %indvars.iv150, 2
  %niter200.next.1 = add i64 %niter200, 2
  %niter200.ncmp.1 = icmp eq i64 %niter200.next.1, %unroll_iter199
  br i1 %niter200.ncmp.1, label %._crit_edge110.loopexit.unr-lcssa, label %.lr.ph109, !llvm.loop !27
}

; Function Attrs: nofree nounwind
declare noundef i32 @__isoc99_scanf(ptr nocapture noundef readonly, ...) local_unnamed_addr #5

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE4swapERS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE9push_backERKi(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2 align 2

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #5

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"double", !7, i64 0}
!11 = distinct !{!11, !12, !13, !14}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!"llvm.loop.isvectorized", i32 1}
!14 = !{!"llvm.loop.unroll.runtime.disable"}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12, !14, !13}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}
!19 = distinct !{!19, !12}
!20 = distinct !{!20, !12}
!21 = distinct !{!21, !22}
!22 = !{!"llvm.loop.unroll.disable"}
!23 = distinct !{!23, !12}
!24 = distinct !{!24, !12}
!25 = distinct !{!25, !12}
!26 = distinct !{!26, !12}
!27 = distinct !{!27, !12}


; Effective O3 passes: BDCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopInstSimplifyPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass