; LLVM IR from tangjz/acm-icpc :: lydsy (2891)

; 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"

@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@tot = external dso_local global i32, align 4
@all = external dso_local global i32, align 4
@w = external dso_local global [3763 x i32], align 16
@go = external dso_local global [65 x [3763 x i32]], align 16
@mat = external dso_local global [101 x [7 x double]], align 16
@f = external dso_local global [2 x [3763 x double]], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [6 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z4initv() #0

; 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 norecurse uwtable
define dso_local noundef i32 @main() #2 {
  %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 i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca double, align 8
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca double, align 8
  %16 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %17 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n, ptr noundef @m)
  %18 = load i32, ptr @n, align 4, !tbaa !5
  %19 = shl i32 1, %18
  store i32 %19, ptr @all, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %20

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

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

25:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 0, ptr %4, align 4, !tbaa !5
  br label %26

26:                                               ; preds = %40, %25
  %27 = load i32, ptr %4, align 4, !tbaa !5
  %28 = load i32, ptr @m, align 4, !tbaa !5
  %29 = icmp slt i32 %27, %28
  br i1 %29, label %31, label %30

30:                                               ; preds = %26
  store i32 5, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  br label %43

31:                                               ; preds = %26
  %32 = load i32, ptr %4, align 4, !tbaa !5
  %33 = sext i32 %32 to i64
  %34 = getelementptr inbounds [101 x [7 x double]], ptr @mat, i64 0, i64 %33
  %35 = getelementptr inbounds [7 x double], ptr %34, i64 0, i64 0
  %36 = load i32, ptr %2, align 4, !tbaa !5
  %37 = sext i32 %36 to i64
  %38 = getelementptr inbounds double, ptr %35, i64 %37
  %39 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %38)
  br label %40

40:                                               ; preds = %31
  %41 = load i32, ptr %4, align 4, !tbaa !5
  %42 = add nsw i32 %41, 1
  store i32 %42, ptr %4, align 4, !tbaa !5
  br label %26, !llvm.loop !9

43:                                               ; preds = %30
  br label %44

44:                                               ; preds = %43
  %45 = load i32, ptr %2, align 4, !tbaa !5
  %46 = add nsw i32 %45, 1
  store i32 %46, ptr %2, align 4, !tbaa !5
  br label %20, !llvm.loop !11

47:                                               ; preds = %24
  call void @_Z4initv()
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  store i32 0, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #6
  store i32 1, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  store i32 0, ptr %7, align 4, !tbaa !5
  br label %48

48:                                               ; preds = %64, %47
  %49 = load i32, ptr %7, align 4, !tbaa !5
  %50 = load i32, ptr @tot, align 4, !tbaa !5
  %51 = icmp slt i32 %49, %50
  br i1 %51, label %53, label %52

52:                                               ; preds = %48
  store i32 8, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %67

53:                                               ; preds = %48
  %54 = load i32, ptr %7, align 4, !tbaa !5
  %55 = icmp ne i32 %54, 0
  %56 = xor i1 %55, true
  %57 = uitofp i1 %56 to double
  %58 = load i32, ptr %5, align 4, !tbaa !5
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %59
  %61 = load i32, ptr %7, align 4, !tbaa !5
  %62 = sext i32 %61 to i64
  %63 = getelementptr inbounds [3763 x double], ptr %60, i64 0, i64 %62
  store double %57, ptr %63, align 8, !tbaa !12
  br label %64

64:                                               ; preds = %53
  %65 = load i32, ptr %7, align 4, !tbaa !5
  %66 = add nsw i32 %65, 1
  store i32 %66, ptr %7, align 4, !tbaa !5
  br label %48, !llvm.loop !14

67:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  store i32 0, ptr %8, align 4, !tbaa !5
  br label %68

68:                                               ; preds = %168, %67
  %69 = load i32, ptr %8, align 4, !tbaa !5
  %70 = load i32, ptr @m, align 4, !tbaa !5
  %71 = icmp slt i32 %69, %70
  br i1 %71, label %73, label %72

72:                                               ; preds = %68
  store i32 11, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  br label %171

73:                                               ; preds = %68
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  %74 = load i32, ptr %8, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds [101 x [7 x double]], ptr @mat, i64 0, i64 %75
  %77 = getelementptr inbounds [7 x double], ptr %76, i64 0, i64 0
  store ptr %77, ptr %9, align 8, !tbaa !15
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %78

78:                                               ; preds = %90, %73
  %79 = load i32, ptr %10, align 4, !tbaa !5
  %80 = load i32, ptr @tot, align 4, !tbaa !5
  %81 = icmp slt i32 %79, %80
  br i1 %81, label %83, label %82

82:                                               ; preds = %78
  store i32 14, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  br label %93

83:                                               ; preds = %78
  %84 = load i32, ptr %5, align 4, !tbaa !5
  %85 = sext i32 %84 to i64
  %86 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %85
  %87 = load i32, ptr %10, align 4, !tbaa !5
  %88 = sext i32 %87 to i64
  %89 = getelementptr inbounds [3763 x double], ptr %86, i64 0, i64 %88
  store double 0.000000e+00, ptr %89, align 8, !tbaa !12
  br label %90

90:                                               ; preds = %83
  %91 = load i32, ptr %10, align 4, !tbaa !5
  %92 = add nsw i32 %91, 1
  store i32 %92, ptr %10, align 4, !tbaa !5
  br label %78, !llvm.loop !17

93:                                               ; preds = %82
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %94

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

98:                                               ; preds = %94
  store i32 17, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  br label %167

99:                                               ; preds = %94
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  store double 1.000000e+00, ptr %12, align 8, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %100

100:                                              ; preds = %128, %99
  %101 = load i32, ptr %13, align 4, !tbaa !5
  %102 = load i32, ptr @n, align 4, !tbaa !5
  %103 = icmp slt i32 %101, %102
  br i1 %103, label %105, label %104

104:                                              ; preds = %100
  store i32 20, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  br label %131

105:                                              ; preds = %100
  %106 = load i32, ptr %11, align 4, !tbaa !5
  %107 = load i32, ptr %13, align 4, !tbaa !5
  %108 = ashr i32 %106, %107
  %109 = and i32 %108, 1
  %110 = icmp ne i32 %109, 0
  br i1 %110, label %111, label %117

111:                                              ; preds = %105
  %112 = load ptr, ptr %9, align 8, !tbaa !15
  %113 = load i32, ptr %13, align 4, !tbaa !5
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds double, ptr %112, i64 %114
  %116 = load double, ptr %115, align 8, !tbaa !12
  br label %124

117:                                              ; preds = %105
  %118 = load ptr, ptr %9, align 8, !tbaa !15
  %119 = load i32, ptr %13, align 4, !tbaa !5
  %120 = sext i32 %119 to i64
  %121 = getelementptr inbounds double, ptr %118, i64 %120
  %122 = load double, ptr %121, align 8, !tbaa !12
  %123 = fsub double 1.000000e+00, %122
  br label %124

124:                                              ; preds = %117, %111
  %125 = phi double [ %116, %111 ], [ %123, %117 ]
  %126 = load double, ptr %12, align 8, !tbaa !12
  %127 = fmul double %126, %125
  store double %127, ptr %12, align 8, !tbaa !12
  br label %128

128:                                              ; preds = %124
  %129 = load i32, ptr %13, align 4, !tbaa !5
  %130 = add nsw i32 %129, 1
  store i32 %130, ptr %13, align 4, !tbaa !5
  br label %100, !llvm.loop !18

131:                                              ; preds = %104
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #6
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %132

132:                                              ; preds = %160, %131
  %133 = load i32, ptr %14, align 4, !tbaa !5
  %134 = load i32, ptr @tot, align 4, !tbaa !5
  %135 = icmp slt i32 %133, %134
  br i1 %135, label %137, label %136

136:                                              ; preds = %132
  store i32 23, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  br label %163

137:                                              ; preds = %132
  %138 = load double, ptr %12, align 8, !tbaa !12
  %139 = load i32, ptr %6, align 4, !tbaa !5
  %140 = sext i32 %139 to i64
  %141 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %140
  %142 = load i32, ptr %14, align 4, !tbaa !5
  %143 = sext i32 %142 to i64
  %144 = getelementptr inbounds [3763 x double], ptr %141, i64 0, i64 %143
  %145 = load double, ptr %144, align 8, !tbaa !12
  %146 = load i32, ptr %5, align 4, !tbaa !5
  %147 = sext i32 %146 to i64
  %148 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %147
  %149 = load i32, ptr %11, align 4, !tbaa !5
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %150
  %152 = load i32, ptr %14, align 4, !tbaa !5
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds [3763 x i32], ptr %151, i64 0, i64 %153
  %155 = load i32, ptr %154, align 4, !tbaa !5
  %156 = sext i32 %155 to i64
  %157 = getelementptr inbounds [3763 x double], ptr %148, i64 0, i64 %156
  %158 = load double, ptr %157, align 8, !tbaa !12
  %159 = call double @llvm.fmuladd.f64(double %138, double %145, double %158)
  store double %159, ptr %157, align 8, !tbaa !12
  br label %160

160:                                              ; preds = %137
  %161 = load i32, ptr %14, align 4, !tbaa !5
  %162 = add nsw i32 %161, 1
  store i32 %162, ptr %14, align 4, !tbaa !5
  br label %132, !llvm.loop !19

163:                                              ; preds = %136
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  br label %164

164:                                              ; preds = %163
  %165 = load i32, ptr %11, align 4, !tbaa !5
  %166 = add nsw i32 %165, 1
  store i32 %166, ptr %11, align 4, !tbaa !5
  br label %94, !llvm.loop !20

167:                                              ; preds = %98
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  br label %168

168:                                              ; preds = %167
  %169 = load i32, ptr %8, align 4, !tbaa !5
  %170 = add nsw i32 %169, 1
  store i32 %170, ptr %8, align 4, !tbaa !5
  br label %68, !llvm.loop !21

171:                                              ; preds = %72
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #6
  store double 0.000000e+00, ptr %15, align 8, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %172

172:                                              ; preds = %192, %171
  %173 = load i32, ptr %16, align 4, !tbaa !5
  %174 = load i32, ptr @tot, align 4, !tbaa !5
  %175 = icmp slt i32 %173, %174
  br i1 %175, label %177, label %176

176:                                              ; preds = %172
  store i32 26, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  br label %195

177:                                              ; preds = %172
  %178 = load i32, ptr %16, align 4, !tbaa !5
  %179 = sext i32 %178 to i64
  %180 = getelementptr inbounds [3763 x i32], ptr @w, i64 0, i64 %179
  %181 = load i32, ptr %180, align 4, !tbaa !5
  %182 = sitofp i32 %181 to double
  %183 = load i32, ptr %5, align 4, !tbaa !5
  %184 = sext i32 %183 to i64
  %185 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %184
  %186 = load i32, ptr %16, align 4, !tbaa !5
  %187 = sext i32 %186 to i64
  %188 = getelementptr inbounds [3763 x double], ptr %185, i64 0, i64 %187
  %189 = load double, ptr %188, align 8, !tbaa !12
  %190 = load double, ptr %15, align 8, !tbaa !12
  %191 = call double @llvm.fmuladd.f64(double %182, double %189, double %190)
  store double %191, ptr %15, align 8, !tbaa !12
  br label %192

192:                                              ; preds = %177
  %193 = load i32, ptr %16, align 4, !tbaa !5
  %194 = add nsw i32 %193, 1
  store i32 %194, ptr %16, align 4, !tbaa !5
  br label %172, !llvm.loop !22

195:                                              ; preds = %176
  %196 = load double, ptr %15, align 8, !tbaa !12
  %197 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, double noundef %196)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  %198 = load i32, ptr %1, align 4
  ret i32 %198
}

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #4

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

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { "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 #4 = { inlinehint 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 #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { 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 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = !{!13, !13, i64 0}
!13 = !{!"double", !7, i64 0}
!14 = distinct !{!14, !10}
!15 = !{!16, !16, i64 0}
!16 = !{!"any pointer", !7, i64 0}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10}


; 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"

@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@tot = external dso_local local_unnamed_addr global i32, align 4
@all = external dso_local local_unnamed_addr global i32, align 4
@w = external dso_local local_unnamed_addr global [3763 x i32], align 16
@go = external dso_local local_unnamed_addr global [65 x [3763 x i32]], align 16
@mat = external dso_local global [101 x [7 x double]], align 16
@f = external dso_local local_unnamed_addr global [2 x [3763 x double]], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [6 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z4initv() local_unnamed_addr #0

; 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 norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n, ptr noundef nonnull @m)
  %4 = load i32, ptr @n, align 4, !tbaa !5
  %5 = shl nuw i32 1, %4
  store i32 %5, ptr @all, align 4, !tbaa !5
  %6 = icmp sgt i32 %4, 0
  %7 = load i32, ptr @m, align 4
  %8 = icmp sgt i32 %7, 0
  %or.cond = select i1 %6, i1 %8, i1 false
  br i1 %or.cond, label %.preheader54, label %._crit_edge57

.preheader54:                                     ; preds = %0, %._crit_edge
  %9 = phi i32 [ %15, %._crit_edge ], [ %4, %0 ]
  %10 = phi i32 [ %16, %._crit_edge ], [ %7, %0 ]
  %indvars.iv89 = phi i64 [ %indvars.iv.next90, %._crit_edge ], [ 0, %0 ]
  %11 = icmp sgt i32 %10, 0
  br i1 %11, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %.preheader54
  %invariant.gep = getelementptr inbounds double, ptr @mat, i64 %indvars.iv89
  br label %19

._crit_edge57:                                    ; preds = %._crit_edge, %0
  tail call void @_Z4initv()
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #7
  store i32 0, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #7
  store i32 1, ptr %2, align 4, !tbaa !5
  %12 = load i32, ptr @tot, align 4, !tbaa !5
  %13 = icmp sgt i32 %12, 0
  br i1 %13, label %.lr.ph60.preheader, label %.preheader53

.lr.ph60.preheader:                               ; preds = %._crit_edge57
  %wide.trip.count = zext nneg i32 %12 to i64
  %xtraiter = and i64 %wide.trip.count, 3
  %14 = icmp ult i32 %12, 4
  br i1 %14, label %.preheader53.loopexit.unr-lcssa, label %.lr.ph60.preheader.new

.lr.ph60.preheader.new:                           ; preds = %.lr.ph60.preheader
  %unroll_iter = and i64 %wide.trip.count, 2147483644
  br label %.lr.ph60

._crit_edge.loopexit:                             ; preds = %19
  %.pre = load i32, ptr @n, align 4, !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit, %.preheader54
  %15 = phi i32 [ %.pre, %._crit_edge.loopexit ], [ %9, %.preheader54 ]
  %16 = phi i32 [ %21, %._crit_edge.loopexit ], [ %10, %.preheader54 ]
  %indvars.iv.next90 = add nuw nsw i64 %indvars.iv89, 1
  %17 = sext i32 %15 to i64
  %18 = icmp slt i64 %indvars.iv.next90, %17
  br i1 %18, label %.preheader54, label %._crit_edge57, !llvm.loop !9

19:                                               ; preds = %.lr.ph, %19
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %19 ]
  %gep = getelementptr inbounds [101 x [7 x double]], ptr %invariant.gep, i64 0, i64 %indvars.iv
  %20 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %gep)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %21 = load i32, ptr @m, align 4, !tbaa !5
  %22 = sext i32 %21 to i64
  %23 = icmp slt i64 %indvars.iv.next, %22
  br i1 %23, label %19, label %._crit_edge.loopexit, !llvm.loop !12

.preheader53.loopexit.unr-lcssa:                  ; preds = %.lr.ph60, %.lr.ph60.preheader
  %indvars.iv92.unr = phi i64 [ 0, %.lr.ph60.preheader ], [ %indvars.iv.next93.3, %.lr.ph60 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.preheader53, label %.lr.ph60.epil

.lr.ph60.epil:                                    ; preds = %.preheader53.loopexit.unr-lcssa, %.lr.ph60.epil
  %indvars.iv92.epil = phi i64 [ %indvars.iv.next93.epil, %.lr.ph60.epil ], [ %indvars.iv92.unr, %.preheader53.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph60.epil ], [ 0, %.preheader53.loopexit.unr-lcssa ]
  %.not49.epil = icmp eq i64 %indvars.iv92.epil, 0
  %24 = uitofp i1 %.not49.epil to double
  %25 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 0, i64 %indvars.iv92.epil
  store double %24, ptr %25, align 8, !tbaa !13
  %indvars.iv.next93.epil = add nuw nsw i64 %indvars.iv92.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.preheader53, label %.lr.ph60.epil, !llvm.loop !15

.preheader53:                                     ; preds = %.preheader53.loopexit.unr-lcssa, %.lr.ph60.epil, %._crit_edge57
  %26 = load i32, ptr @m, align 4, !tbaa !5
  %27 = icmp sgt i32 %26, 0
  br i1 %27, label %.lr.ph79, label %.preheader

.lr.ph60:                                         ; preds = %.lr.ph60, %.lr.ph60.preheader.new
  %indvars.iv92 = phi i64 [ 0, %.lr.ph60.preheader.new ], [ %indvars.iv.next93.3, %.lr.ph60 ]
  %niter = phi i64 [ 0, %.lr.ph60.preheader.new ], [ %niter.next.3, %.lr.ph60 ]
  %.not49 = icmp eq i64 %indvars.iv92, 0
  %28 = uitofp i1 %.not49 to double
  %29 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 0, i64 %indvars.iv92
  store double %28, ptr %29, align 16, !tbaa !13
  %indvars.iv.next93 = or disjoint i64 %indvars.iv92, 1
  %30 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 0, i64 %indvars.iv.next93
  store double 0.000000e+00, ptr %30, align 8, !tbaa !13
  %indvars.iv.next93.1 = or disjoint i64 %indvars.iv92, 2
  %31 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 0, i64 %indvars.iv.next93.1
  store double 0.000000e+00, ptr %31, align 16, !tbaa !13
  %indvars.iv.next93.2 = or disjoint i64 %indvars.iv92, 3
  %32 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 0, i64 %indvars.iv.next93.2
  store double 0.000000e+00, ptr %32, align 8, !tbaa !13
  %indvars.iv.next93.3 = add nuw nsw i64 %indvars.iv92, 4
  %niter.next.3 = add i64 %niter, 4
  %niter.ncmp.3 = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3, label %.preheader53.loopexit.unr-lcssa, label %.lr.ph60, !llvm.loop !17

.preheader:                                       ; preds = %._crit_edge72, %.preheader53
  %33 = phi i32 [ %12, %.preheader53 ], [ %39, %._crit_edge72 ]
  %34 = icmp sgt i32 %33, 0
  br i1 %34, label %.lr.ph82, label %._crit_edge83

.lr.ph82:                                         ; preds = %.preheader
  %35 = load i32, ptr %1, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %wide.trip.count129 = zext nneg i32 %33 to i64
  %xtraiter162 = and i64 %wide.trip.count129, 1
  %37 = icmp eq i32 %33, 1
  br i1 %37, label %._crit_edge83.loopexit.unr-lcssa, label %.lr.ph82.new

.lr.ph82.new:                                     ; preds = %.lr.ph82
  %unroll_iter166 = and i64 %wide.trip.count129, 2147483646
  br label %140

.lr.ph79:                                         ; preds = %.preheader53, %._crit_edge72
  %indvars.iv123 = phi i64 [ %indvars.iv.next124, %._crit_edge72 ], [ 0, %.preheader53 ]
  %38 = getelementptr inbounds [101 x [7 x double]], ptr @mat, i64 0, i64 %indvars.iv123
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %1, ptr noundef nonnull align 4 dereferenceable(4) %2) #7
  %39 = load i32, ptr @tot, align 4, !tbaa !5
  %40 = icmp sgt i32 %39, 0
  br i1 %40, label %.lr.ph63, label %.preheader52

.lr.ph63:                                         ; preds = %.lr.ph79
  %41 = load i32, ptr %1, align 4, !tbaa !5
  %42 = sext i32 %41 to i64
  %43 = mul nsw i64 %42, 30104
  %scevgep = getelementptr i8, ptr @f, i64 %43
  %44 = zext nneg i32 %39 to i64
  %45 = shl nuw nsw i64 %44, 3
  call void @llvm.memset.p0.i64(ptr align 8 %scevgep, i8 0, i64 %45, i1 false), !tbaa !13
  br label %.preheader52

.preheader52:                                     ; preds = %.lr.ph63, %.lr.ph79
  %46 = load i32, ptr @all, align 4, !tbaa !5
  %47 = icmp sgt i32 %46, 0
  br i1 %47, label %.preheader51.lr.ph, label %._crit_edge72

.preheader51.lr.ph:                               ; preds = %.preheader52
  %48 = load i32, ptr @n, align 4, !tbaa !5
  %49 = icmp sgt i32 %48, 0
  %50 = load i32, ptr %2, align 4
  %51 = sext i32 %50 to i64
  %52 = load i32, ptr %1, align 4
  %53 = sext i32 %52 to i64
  br i1 %49, label %.preheader51.us.preheader, label %.preheader51.lr.ph.split

.preheader51.us.preheader:                        ; preds = %.preheader51.lr.ph
  %wide.trip.count121 = zext nneg i32 %46 to i64
  %wide.trip.count111 = zext nneg i32 %48 to i64
  %wide.trip.count116 = zext i32 %39 to i64
  %xtraiter150 = and i64 %wide.trip.count111, 1
  %54 = icmp eq i32 %48, 1
  %unroll_iter154 = and i64 %wide.trip.count111, 2147483646
  %lcmp.mod152.not = icmp eq i64 %xtraiter150, 0
  %xtraiter156 = and i64 %wide.trip.count116, 1
  %55 = icmp eq i32 %39, 1
  %unroll_iter159 = and i64 %wide.trip.count116, 2147483646
  %lcmp.mod158.not = icmp eq i64 %xtraiter156, 0
  br label %.preheader51.us

.preheader51.us:                                  ; preds = %.preheader51.us.preheader, %._crit_edge70.us
  %indvars.iv118 = phi i64 [ 0, %.preheader51.us.preheader ], [ %indvars.iv.next119, %._crit_edge70.us ]
  %56 = trunc nuw nsw i64 %indvars.iv118 to i32
  br i1 %54, label %..preheader50_crit_edge.us.unr-lcssa, label %.preheader51.us.new

._crit_edge70.us.loopexit.unr-lcssa:              ; preds = %.lr.ph69.us, %.lr.ph69.us.preheader
  %indvars.iv113.unr = phi i64 [ 0, %.lr.ph69.us.preheader ], [ %indvars.iv.next114.1, %.lr.ph69.us ]
  br i1 %lcmp.mod158.not, label %._crit_edge70.us, label %.lr.ph69.us.epil

.lr.ph69.us.epil:                                 ; preds = %._crit_edge70.us.loopexit.unr-lcssa
  %57 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %51, i64 %indvars.iv113.unr
  %58 = load double, ptr %57, align 8, !tbaa !13
  %59 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %indvars.iv118, i64 %indvars.iv113.unr
  %60 = load i32, ptr %59, align 4, !tbaa !5
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %53, i64 %61
  %63 = load double, ptr %62, align 8, !tbaa !13
  %64 = call double @llvm.fmuladd.f64(double %.lcssa141, double %58, double %63)
  store double %64, ptr %62, align 8, !tbaa !13
  br label %._crit_edge70.us

._crit_edge70.us:                                 ; preds = %.lr.ph69.us.epil, %._crit_edge70.us.loopexit.unr-lcssa, %..preheader50_crit_edge.us
  %indvars.iv.next119 = add nuw nsw i64 %indvars.iv118, 1
  %exitcond122.not = icmp eq i64 %indvars.iv.next119, %wide.trip.count121
  br i1 %exitcond122.not, label %._crit_edge72, label %.preheader51.us, !llvm.loop !18

.lr.ph69.us:                                      ; preds = %.lr.ph69.us.preheader, %.lr.ph69.us
  %indvars.iv113 = phi i64 [ %indvars.iv.next114.1, %.lr.ph69.us ], [ 0, %.lr.ph69.us.preheader ]
  %niter160 = phi i64 [ %niter160.next.1, %.lr.ph69.us ], [ 0, %.lr.ph69.us.preheader ]
  %65 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %51, i64 %indvars.iv113
  %66 = load double, ptr %65, align 8, !tbaa !13
  %67 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %indvars.iv118, i64 %indvars.iv113
  %68 = load i32, ptr %67, align 4, !tbaa !5
  %69 = sext i32 %68 to i64
  %70 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %53, i64 %69
  %71 = load double, ptr %70, align 8, !tbaa !13
  %72 = call double @llvm.fmuladd.f64(double %.lcssa141, double %66, double %71)
  store double %72, ptr %70, align 8, !tbaa !13
  %indvars.iv.next114 = or disjoint i64 %indvars.iv113, 1
  %73 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %51, i64 %indvars.iv.next114
  %74 = load double, ptr %73, align 8, !tbaa !13
  %75 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %indvars.iv118, i64 %indvars.iv.next114
  %76 = load i32, ptr %75, align 4, !tbaa !5
  %77 = sext i32 %76 to i64
  %78 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %53, i64 %77
  %79 = load double, ptr %78, align 8, !tbaa !13
  %80 = call double @llvm.fmuladd.f64(double %.lcssa141, double %74, double %79)
  store double %80, ptr %78, align 8, !tbaa !13
  %indvars.iv.next114.1 = add nuw nsw i64 %indvars.iv113, 2
  %niter160.next.1 = add i64 %niter160, 2
  %niter160.ncmp.1 = icmp eq i64 %niter160.next.1, %unroll_iter159
  br i1 %niter160.ncmp.1, label %._crit_edge70.us.loopexit.unr-lcssa, label %.lr.ph69.us, !llvm.loop !19

.preheader51.us.new:                              ; preds = %.preheader51.us, %.preheader51.us.new
  %indvars.iv108 = phi i64 [ %indvars.iv.next109.1, %.preheader51.us.new ], [ 0, %.preheader51.us ]
  %.04264.us = phi double [ %96, %.preheader51.us.new ], [ 1.000000e+00, %.preheader51.us ]
  %niter155 = phi i64 [ %niter155.next.1, %.preheader51.us.new ], [ 0, %.preheader51.us ]
  %81 = trunc nuw nsw i64 %indvars.iv108 to i32
  %82 = shl nuw i32 1, %81
  %83 = and i32 %82, %56
  %.not.us = icmp eq i32 %83, 0
  %84 = getelementptr inbounds double, ptr %38, i64 %indvars.iv108
  %85 = load double, ptr %84, align 8, !tbaa !13
  %86 = fsub double 1.000000e+00, %85
  %87 = select i1 %.not.us, double %86, double %85
  %88 = fmul double %.04264.us, %87
  %indvars.iv.next109 = or disjoint i64 %indvars.iv108, 1
  %89 = trunc nuw nsw i64 %indvars.iv.next109 to i32
  %90 = shl nuw i32 1, %89
  %91 = and i32 %90, %56
  %.not.us.1 = icmp eq i32 %91, 0
  %92 = getelementptr inbounds double, ptr %38, i64 %indvars.iv.next109
  %93 = load double, ptr %92, align 8, !tbaa !13
  %94 = fsub double 1.000000e+00, %93
  %95 = select i1 %.not.us.1, double %94, double %93
  %96 = fmul double %88, %95
  %indvars.iv.next109.1 = add nuw nsw i64 %indvars.iv108, 2
  %niter155.next.1 = add i64 %niter155, 2
  %niter155.ncmp.1 = icmp eq i64 %niter155.next.1, %unroll_iter154
  br i1 %niter155.ncmp.1, label %..preheader50_crit_edge.us.unr-lcssa, label %.preheader51.us.new, !llvm.loop !20

..preheader50_crit_edge.us.unr-lcssa:             ; preds = %.preheader51.us.new, %.preheader51.us
  %.lcssa141.ph = phi double [ poison, %.preheader51.us ], [ %96, %.preheader51.us.new ]
  %indvars.iv108.unr = phi i64 [ 0, %.preheader51.us ], [ %indvars.iv.next109.1, %.preheader51.us.new ]
  %.04264.us.unr = phi double [ 1.000000e+00, %.preheader51.us ], [ %96, %.preheader51.us.new ]
  br i1 %lcmp.mod152.not, label %..preheader50_crit_edge.us, label %..preheader50_crit_edge.us.epilog-lcssa

..preheader50_crit_edge.us.epilog-lcssa:          ; preds = %..preheader50_crit_edge.us.unr-lcssa
  %97 = trunc nuw nsw i64 %indvars.iv108.unr to i32
  %98 = shl nuw i32 1, %97
  %99 = and i32 %98, %56
  %.not.us.epil = icmp eq i32 %99, 0
  %100 = getelementptr inbounds double, ptr %38, i64 %indvars.iv108.unr
  %101 = load double, ptr %100, align 8, !tbaa !13
  %102 = fsub double 1.000000e+00, %101
  %103 = select i1 %.not.us.epil, double %102, double %101
  %104 = fmul double %.04264.us.unr, %103
  br label %..preheader50_crit_edge.us

..preheader50_crit_edge.us:                       ; preds = %..preheader50_crit_edge.us.unr-lcssa, %..preheader50_crit_edge.us.epilog-lcssa
  %.lcssa141 = phi double [ %.lcssa141.ph, %..preheader50_crit_edge.us.unr-lcssa ], [ %104, %..preheader50_crit_edge.us.epilog-lcssa ]
  br i1 %40, label %.lr.ph69.us.preheader, label %._crit_edge70.us

.lr.ph69.us.preheader:                            ; preds = %..preheader50_crit_edge.us
  br i1 %55, label %._crit_edge70.us.loopexit.unr-lcssa, label %.lr.ph69.us

.preheader51.lr.ph.split:                         ; preds = %.preheader51.lr.ph
  br i1 %40, label %.preheader51.us73.preheader, label %._crit_edge72

.preheader51.us73.preheader:                      ; preds = %.preheader51.lr.ph.split
  %wide.trip.count106 = zext nneg i32 %46 to i64
  %wide.trip.count101 = zext nneg i32 %39 to i64
  %xtraiter144 = and i64 %wide.trip.count101, 1
  %105 = icmp eq i32 %39, 1
  %unroll_iter147 = and i64 %wide.trip.count101, 2147483646
  %lcmp.mod146.not = icmp eq i64 %xtraiter144, 0
  br label %.preheader51.us73

.preheader51.us73:                                ; preds = %.preheader51.us73.preheader, %._crit_edge70.us77
  %indvars.iv103 = phi i64 [ 0, %.preheader51.us73.preheader ], [ %indvars.iv.next104, %._crit_edge70.us77 ]
  br i1 %105, label %._crit_edge70.us77.unr-lcssa, label %.preheader51.us73.new

.preheader51.us73.new:                            ; preds = %.preheader51.us73, %.preheader51.us73.new
  %indvars.iv98 = phi i64 [ %indvars.iv.next99.1, %.preheader51.us73.new ], [ 0, %.preheader51.us73 ]
  %niter148 = phi i64 [ %niter148.next.1, %.preheader51.us73.new ], [ 0, %.preheader51.us73 ]
  %106 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %51, i64 %indvars.iv98
  %107 = load double, ptr %106, align 8, !tbaa !13
  %108 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %indvars.iv103, i64 %indvars.iv98
  %109 = load i32, ptr %108, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %53, i64 %110
  %112 = load double, ptr %111, align 8, !tbaa !13
  %113 = fadd double %107, %112
  store double %113, ptr %111, align 8, !tbaa !13
  %indvars.iv.next99 = or disjoint i64 %indvars.iv98, 1
  %114 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %51, i64 %indvars.iv.next99
  %115 = load double, ptr %114, align 8, !tbaa !13
  %116 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %indvars.iv103, i64 %indvars.iv.next99
  %117 = load i32, ptr %116, align 4, !tbaa !5
  %118 = sext i32 %117 to i64
  %119 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %53, i64 %118
  %120 = load double, ptr %119, align 8, !tbaa !13
  %121 = fadd double %115, %120
  store double %121, ptr %119, align 8, !tbaa !13
  %indvars.iv.next99.1 = add nuw nsw i64 %indvars.iv98, 2
  %niter148.next.1 = add i64 %niter148, 2
  %niter148.ncmp.1 = icmp eq i64 %niter148.next.1, %unroll_iter147
  br i1 %niter148.ncmp.1, label %._crit_edge70.us77.unr-lcssa, label %.preheader51.us73.new, !llvm.loop !19

._crit_edge70.us77.unr-lcssa:                     ; preds = %.preheader51.us73.new, %.preheader51.us73
  %indvars.iv98.unr = phi i64 [ 0, %.preheader51.us73 ], [ %indvars.iv.next99.1, %.preheader51.us73.new ]
  br i1 %lcmp.mod146.not, label %._crit_edge70.us77, label %._crit_edge70.us77.epilog-lcssa

._crit_edge70.us77.epilog-lcssa:                  ; preds = %._crit_edge70.us77.unr-lcssa
  %122 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %51, i64 %indvars.iv98.unr
  %123 = load double, ptr %122, align 8, !tbaa !13
  %124 = getelementptr inbounds [65 x [3763 x i32]], ptr @go, i64 0, i64 %indvars.iv103, i64 %indvars.iv98.unr
  %125 = load i32, ptr %124, align 4, !tbaa !5
  %126 = sext i32 %125 to i64
  %127 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %53, i64 %126
  %128 = load double, ptr %127, align 8, !tbaa !13
  %129 = fadd double %123, %128
  store double %129, ptr %127, align 8, !tbaa !13
  br label %._crit_edge70.us77

._crit_edge70.us77:                               ; preds = %._crit_edge70.us77.unr-lcssa, %._crit_edge70.us77.epilog-lcssa
  %indvars.iv.next104 = add nuw nsw i64 %indvars.iv103, 1
  %exitcond107.not = icmp eq i64 %indvars.iv.next104, %wide.trip.count106
  br i1 %exitcond107.not, label %._crit_edge72, label %.preheader51.us73, !llvm.loop !18

._crit_edge72:                                    ; preds = %._crit_edge70.us77, %._crit_edge70.us, %.preheader51.lr.ph.split, %.preheader52
  %indvars.iv.next124 = add nuw nsw i64 %indvars.iv123, 1
  %130 = load i32, ptr @m, align 4, !tbaa !5
  %131 = sext i32 %130 to i64
  %132 = icmp slt i64 %indvars.iv.next124, %131
  br i1 %132, label %.lr.ph79, label %.preheader, !llvm.loop !21

._crit_edge83.loopexit.unr-lcssa:                 ; preds = %140, %.lr.ph82
  %.lcssa.ph = phi double [ poison, %.lr.ph82 ], [ %152, %140 ]
  %indvars.iv126.unr = phi i64 [ 0, %.lr.ph82 ], [ %indvars.iv.next127.1, %140 ]
  %.03980.unr = phi double [ 0.000000e+00, %.lr.ph82 ], [ %152, %140 ]
  %lcmp.mod164.not = icmp eq i64 %xtraiter162, 0
  br i1 %lcmp.mod164.not, label %._crit_edge83, label %._crit_edge83.loopexit.epilog-lcssa

._crit_edge83.loopexit.epilog-lcssa:              ; preds = %._crit_edge83.loopexit.unr-lcssa
  %133 = getelementptr inbounds [3763 x i32], ptr @w, i64 0, i64 %indvars.iv126.unr
  %134 = load i32, ptr %133, align 4, !tbaa !5
  %135 = sitofp i32 %134 to double
  %136 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %36, i64 %indvars.iv126.unr
  %137 = load double, ptr %136, align 8, !tbaa !13
  %138 = call double @llvm.fmuladd.f64(double %135, double %137, double %.03980.unr)
  br label %._crit_edge83

._crit_edge83:                                    ; preds = %._crit_edge83.loopexit.epilog-lcssa, %._crit_edge83.loopexit.unr-lcssa, %.preheader
  %.039.lcssa = phi double [ 0.000000e+00, %.preheader ], [ %.lcssa.ph, %._crit_edge83.loopexit.unr-lcssa ], [ %138, %._crit_edge83.loopexit.epilog-lcssa ]
  %139 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, double noundef %.039.lcssa)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #7
  ret i32 0

140:                                              ; preds = %140, %.lr.ph82.new
  %indvars.iv126 = phi i64 [ 0, %.lr.ph82.new ], [ %indvars.iv.next127.1, %140 ]
  %.03980 = phi double [ 0.000000e+00, %.lr.ph82.new ], [ %152, %140 ]
  %niter167 = phi i64 [ 0, %.lr.ph82.new ], [ %niter167.next.1, %140 ]
  %141 = getelementptr inbounds [3763 x i32], ptr @w, i64 0, i64 %indvars.iv126
  %142 = load i32, ptr %141, align 8, !tbaa !5
  %143 = sitofp i32 %142 to double
  %144 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %36, i64 %indvars.iv126
  %145 = load double, ptr %144, align 8, !tbaa !13
  %146 = call double @llvm.fmuladd.f64(double %143, double %145, double %.03980)
  %indvars.iv.next127 = or disjoint i64 %indvars.iv126, 1
  %147 = getelementptr inbounds [3763 x i32], ptr @w, i64 0, i64 %indvars.iv.next127
  %148 = load i32, ptr %147, align 4, !tbaa !5
  %149 = sitofp i32 %148 to double
  %150 = getelementptr inbounds [2 x [3763 x double]], ptr @f, i64 0, i64 %36, i64 %indvars.iv.next127
  %151 = load double, ptr %150, align 8, !tbaa !13
  %152 = call double @llvm.fmuladd.f64(double %149, double %151, double %146)
  %indvars.iv.next127.1 = add nuw nsw i64 %indvars.iv126, 2
  %niter167.next.1 = add i64 %niter167, 2
  %niter167.ncmp.1 = icmp eq i64 %niter167.next.1, %unroll_iter166
  br i1 %niter167.ncmp.1, label %._crit_edge83.loopexit.unr-lcssa, label %140, !llvm.loop !22
}

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

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

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

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { 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 #4 = { inlinehint 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 #5 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 = distinct !{!9, !10, !11}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!"llvm.loop.unswitch.partial.disable"}
!12 = distinct !{!12, !10}
!13 = !{!14, !14, i64 0}
!14 = !{!"double", !7, i64 0}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.unroll.disable"}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}
!22 = distinct !{!22, !10}


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