; LLVM IR from VastoLorde95/Competitive-Programming :: Codeforces/348 Division 1/Problem C (C)

; 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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"struct.std::_Setprecision" = type { i32 }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@n = external dso_local global i32, align 4
@a = external dso_local global [100100 x double], align 16
@b = external dso_local global [100100 x double], align 16
@x = external dso_local global [100100 x double], align 16
@y = external dso_local global [100100 x double], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local noundef x86_fp80 @_Z5solveee(x86_fp80 noundef, x86_fp80 noundef) #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 %"struct.std::_Setprecision", align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %9 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %10

10:                                               ; preds = %20, %0
  %11 = load i32, ptr %2, align 4, !tbaa !5
  %12 = load i32, ptr @n, align 4, !tbaa !5
  %13 = icmp slt i32 %11, %12
  br i1 %13, label %15, label %14

14:                                               ; preds = %10
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  br label %23

15:                                               ; preds = %10
  %16 = load i32, ptr %2, align 4, !tbaa !5
  %17 = sext i32 %16 to i64
  %18 = getelementptr inbounds double, ptr @a, i64 %17
  %19 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %18)
  br label %20

20:                                               ; preds = %15
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = add nsw i32 %21, 1
  store i32 %22, ptr %2, align 4, !tbaa !5
  br label %10, !llvm.loop !9

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

24:                                               ; preds = %34, %23
  %25 = load i32, ptr %3, align 4, !tbaa !5
  %26 = load i32, ptr @n, align 4, !tbaa !5
  %27 = icmp slt i32 %25, %26
  br i1 %27, label %29, label %28

28:                                               ; preds = %24
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  br label %37

29:                                               ; preds = %24
  %30 = load i32, ptr %3, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = getelementptr inbounds double, ptr @b, i64 %31
  %33 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %32)
  br label %34

34:                                               ; preds = %29
  %35 = load i32, ptr %3, align 4, !tbaa !5
  %36 = add nsw i32 %35, 1
  store i32 %36, ptr %3, align 4, !tbaa !5
  br label %24, !llvm.loop !11

37:                                               ; preds = %28
  %38 = load double, ptr @a, align 16, !tbaa !12
  %39 = fneg double %38
  %40 = load double, ptr @b, align 16, !tbaa !12
  %41 = fsub double %39, %40
  %42 = fpext double %41 to x86_fp80
  %43 = load double, ptr @a, align 16, !tbaa !12
  %44 = fpext double %43 to x86_fp80
  %45 = call noundef x86_fp80 @_Z5solveee(x86_fp80 noundef %42, x86_fp80 noundef %44)
  %46 = fptrunc x86_fp80 %45 to double
  store double %46, ptr @x, align 16, !tbaa !12
  %47 = load double, ptr @a, align 16, !tbaa !12
  %48 = load double, ptr @b, align 16, !tbaa !12
  %49 = fadd double %47, %48
  %50 = load double, ptr @x, align 16, !tbaa !12
  %51 = fsub double %49, %50
  store double %51, ptr @y, align 16, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 1, ptr %4, align 4, !tbaa !5
  br label %52

52:                                               ; preds = %116, %37
  %53 = load i32, ptr %4, align 4, !tbaa !5
  %54 = load i32, ptr @n, align 4, !tbaa !5
  %55 = icmp slt i32 %53, %54
  br i1 %55, label %57, label %56

56:                                               ; preds = %52
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  br label %119

57:                                               ; preds = %52
  %58 = load i32, ptr %4, align 4, !tbaa !5
  %59 = sub nsw i32 %58, 1
  %60 = sext i32 %59 to i64
  %61 = getelementptr inbounds [100100 x double], ptr @a, i64 0, i64 %60
  %62 = load double, ptr %61, align 8, !tbaa !12
  %63 = load i32, ptr %4, align 4, !tbaa !5
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds [100100 x double], ptr @a, i64 0, i64 %64
  %66 = load double, ptr %65, align 8, !tbaa !12
  %67 = fadd double %66, %62
  store double %67, ptr %65, align 8, !tbaa !12
  %68 = load i32, ptr %4, align 4, !tbaa !5
  %69 = sub nsw i32 %68, 1
  %70 = sext i32 %69 to i64
  %71 = getelementptr inbounds [100100 x double], ptr @b, i64 0, i64 %70
  %72 = load double, ptr %71, align 8, !tbaa !12
  %73 = load i32, ptr %4, align 4, !tbaa !5
  %74 = sext i32 %73 to i64
  %75 = getelementptr inbounds [100100 x double], ptr @b, i64 0, i64 %74
  %76 = load double, ptr %75, align 8, !tbaa !12
  %77 = fadd double %76, %72
  store double %77, ptr %75, align 8, !tbaa !12
  %78 = load i32, ptr %4, align 4, !tbaa !5
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds [100100 x double], ptr @a, i64 0, i64 %79
  %81 = load double, ptr %80, align 8, !tbaa !12
  %82 = fneg double %81
  %83 = load i32, ptr %4, align 4, !tbaa !5
  %84 = sext i32 %83 to i64
  %85 = getelementptr inbounds [100100 x double], ptr @b, i64 0, i64 %84
  %86 = load double, ptr %85, align 8, !tbaa !12
  %87 = fsub double %82, %86
  %88 = fpext double %87 to x86_fp80
  %89 = load i32, ptr %4, align 4, !tbaa !5
  %90 = sext i32 %89 to i64
  %91 = getelementptr inbounds [100100 x double], ptr @a, i64 0, i64 %90
  %92 = load double, ptr %91, align 8, !tbaa !12
  %93 = fpext double %92 to x86_fp80
  %94 = call noundef x86_fp80 @_Z5solveee(x86_fp80 noundef %88, x86_fp80 noundef %93)
  %95 = fptrunc x86_fp80 %94 to double
  %96 = load i32, ptr %4, align 4, !tbaa !5
  %97 = sext i32 %96 to i64
  %98 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %97
  store double %95, ptr %98, align 8, !tbaa !12
  %99 = load i32, ptr %4, align 4, !tbaa !5
  %100 = sext i32 %99 to i64
  %101 = getelementptr inbounds [100100 x double], ptr @a, i64 0, i64 %100
  %102 = load double, ptr %101, align 8, !tbaa !12
  %103 = load i32, ptr %4, align 4, !tbaa !5
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds [100100 x double], ptr @b, i64 0, i64 %104
  %106 = load double, ptr %105, align 8, !tbaa !12
  %107 = fadd double %102, %106
  %108 = load i32, ptr %4, align 4, !tbaa !5
  %109 = sext i32 %108 to i64
  %110 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %109
  %111 = load double, ptr %110, align 8, !tbaa !12
  %112 = fsub double %107, %111
  %113 = load i32, ptr %4, align 4, !tbaa !5
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %114
  store double %112, ptr %115, align 8, !tbaa !12
  br label %116

116:                                              ; preds = %57
  %117 = load i32, ptr %4, align 4, !tbaa !5
  %118 = add nsw i32 %117, 1
  store i32 %118, ptr %4, align 4, !tbaa !5
  br label %52, !llvm.loop !14

119:                                              ; preds = %56
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  %120 = load i32, ptr @n, align 4, !tbaa !5
  %121 = sub nsw i32 %120, 1
  store i32 %121, ptr %5, align 4, !tbaa !5
  br label %122

122:                                              ; preds = %147, %119
  %123 = load i32, ptr %5, align 4, !tbaa !5
  %124 = icmp sgt i32 %123, 0
  br i1 %124, label %126, label %125

125:                                              ; preds = %122
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  br label %150

126:                                              ; preds = %122
  %127 = load i32, ptr %5, align 4, !tbaa !5
  %128 = sub nsw i32 %127, 1
  %129 = sext i32 %128 to i64
  %130 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %129
  %131 = load double, ptr %130, align 8, !tbaa !12
  %132 = load i32, ptr %5, align 4, !tbaa !5
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %133
  %135 = load double, ptr %134, align 8, !tbaa !12
  %136 = fsub double %135, %131
  store double %136, ptr %134, align 8, !tbaa !12
  %137 = load i32, ptr %5, align 4, !tbaa !5
  %138 = sub nsw i32 %137, 1
  %139 = sext i32 %138 to i64
  %140 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %139
  %141 = load double, ptr %140, align 8, !tbaa !12
  %142 = load i32, ptr %5, align 4, !tbaa !5
  %143 = sext i32 %142 to i64
  %144 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %143
  %145 = load double, ptr %144, align 8, !tbaa !12
  %146 = fsub double %145, %141
  store double %146, ptr %144, align 8, !tbaa !12
  br label %147

147:                                              ; preds = %126
  %148 = load i32, ptr %5, align 4, !tbaa !5
  %149 = add nsw i32 %148, -1
  store i32 %149, ptr %5, align 4, !tbaa !5
  br label %122, !llvm.loop !15

150:                                              ; preds = %125
  %151 = call i32 @_ZSt12setprecisioni(i32 noundef 9)
  %152 = getelementptr inbounds %"struct.std::_Setprecision", ptr %6, i32 0, i32 0
  store i32 %151, ptr %152, align 4
  %153 = getelementptr inbounds %"struct.std::_Setprecision", ptr %6, i32 0, i32 0
  %154 = load i32, ptr %153, align 4
  %155 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 %154)
  %156 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %155, ptr noundef @_ZSt5fixedRSt8ios_base)
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  store i32 0, ptr %7, align 4, !tbaa !5
  br label %157

157:                                              ; preds = %168, %150
  %158 = load i32, ptr %7, align 4, !tbaa !5
  %159 = load i32, ptr @n, align 4, !tbaa !5
  %160 = icmp slt i32 %158, %159
  br i1 %160, label %162, label %161

161:                                              ; preds = %157
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %171

162:                                              ; preds = %157
  %163 = load i32, ptr %7, align 4, !tbaa !5
  %164 = sext i32 %163 to i64
  %165 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %164
  %166 = load double, ptr %165, align 8, !tbaa !12
  %167 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, double noundef %166)
  br label %168

168:                                              ; preds = %162
  %169 = load i32, ptr %7, align 4, !tbaa !5
  %170 = add nsw i32 %169, 1
  store i32 %170, ptr %7, align 4, !tbaa !5
  br label %157, !llvm.loop !16

171:                                              ; preds = %161
  %172 = call i32 @puts(ptr noundef @.str.3)
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  store i32 0, ptr %8, align 4, !tbaa !5
  br label %173

173:                                              ; preds = %184, %171
  %174 = load i32, ptr %8, align 4, !tbaa !5
  %175 = load i32, ptr @n, align 4, !tbaa !5
  %176 = icmp slt i32 %174, %175
  br i1 %176, label %178, label %177

177:                                              ; preds = %173
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  br label %187

178:                                              ; preds = %173
  %179 = load i32, ptr %8, align 4, !tbaa !5
  %180 = sext i32 %179 to i64
  %181 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %180
  %182 = load double, ptr %181, align 8, !tbaa !12
  %183 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, double noundef %182)
  br label %184

184:                                              ; preds = %178
  %185 = load i32, ptr %8, align 4, !tbaa !5
  %186 = add nsw i32 %185, 1
  store i32 %186, ptr %8, align 4, !tbaa !5
  br label %173, !llvm.loop !17

187:                                              ; preds = %177
  %188 = call i32 @puts(ptr noundef @.str.3)
  ret i32 0
}

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8), i32) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i32 @_ZSt12setprecisioni(i32 noundef) #5

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(216) ptr @_ZSt5fixedRSt8ios_base(ptr noundef nonnull align 8 dereferenceable(216)) #4

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

declare i32 @puts(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 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 = { 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 #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 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !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"

%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@n = external dso_local global i32, align 4
@a = external dso_local global [100100 x double], align 16
@b = external dso_local global [100100 x double], align 16
@x = external dso_local local_unnamed_addr global [100100 x double], align 16
@y = external dso_local local_unnamed_addr global [100100 x double], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local noundef x86_fp80 @_Z5solveee(x86_fp80 noundef, x86_fp80 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #1 {
  %1 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n)
  %2 = load i32, ptr @n, align 4, !tbaa !5
  %3 = icmp sgt i32 %2, 0
  br i1 %3, label %.lr.ph, label %._crit_edge

.preheader38:                                     ; preds = %.lr.ph
  %4 = icmp sgt i32 %7, 0
  br i1 %4, label %.lr.ph41, label %._crit_edge

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %0 ]
  %5 = getelementptr inbounds double, ptr @a, i64 %indvars.iv
  %6 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %5)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %7 = load i32, ptr @n, align 4, !tbaa !5
  %8 = sext i32 %7 to i64
  %9 = icmp slt i64 %indvars.iv.next, %8
  br i1 %9, label %.lr.ph, label %.preheader38, !llvm.loop !9

._crit_edge:                                      ; preds = %.lr.ph41, %0, %.preheader38
  %10 = load double, ptr @a, align 16, !tbaa !11
  %11 = fneg double %10
  %12 = load double, ptr @b, align 16, !tbaa !11
  %13 = fsub double %11, %12
  %14 = fpext double %13 to x86_fp80
  %15 = fpext double %10 to x86_fp80
  %16 = tail call noundef x86_fp80 @_Z5solveee(x86_fp80 noundef %14, x86_fp80 noundef %15)
  %17 = fptrunc x86_fp80 %16 to double
  store double %17, ptr @x, align 16, !tbaa !11
  %18 = load double, ptr @a, align 16, !tbaa !11
  %19 = load double, ptr @b, align 16, !tbaa !11
  %20 = fadd double %18, %19
  %21 = fsub double %20, %17
  store double %21, ptr @y, align 16, !tbaa !11
  %22 = load i32, ptr @n, align 4, !tbaa !5
  %23 = icmp sgt i32 %22, 1
  br i1 %23, label %.lr.ph44, label %._crit_edge47

.lr.ph41:                                         ; preds = %.preheader38, %.lr.ph41
  %indvars.iv58 = phi i64 [ %indvars.iv.next59, %.lr.ph41 ], [ 0, %.preheader38 ]
  %24 = getelementptr inbounds double, ptr @b, i64 %indvars.iv58
  %25 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %24)
  %indvars.iv.next59 = add nuw nsw i64 %indvars.iv58, 1
  %26 = load i32, ptr @n, align 4, !tbaa !5
  %27 = sext i32 %26 to i64
  %28 = icmp slt i64 %indvars.iv.next59, %27
  br i1 %28, label %.lr.ph41, label %._crit_edge, !llvm.loop !13

.preheader:                                       ; preds = %.lr.ph44
  %29 = icmp sgt i32 %57, 1
  br i1 %29, label %.lr.ph46.preheader, label %._crit_edge47

.lr.ph46.preheader:                               ; preds = %.preheader
  %30 = zext nneg i32 %57 to i64
  %31 = add nsw i64 %30, -1
  %min.iters.check = icmp eq i32 %57, 2
  br i1 %min.iters.check, label %.lr.ph46.preheader84, label %vector.ph

.lr.ph46.preheader84:                             ; preds = %middle.block, %.lr.ph46.preheader
  %indvars.iv64.ph = phi i64 [ %30, %.lr.ph46.preheader ], [ %ind.end, %middle.block ]
  br label %.lr.ph46

vector.ph:                                        ; preds = %.lr.ph46.preheader
  %n.vec = and i64 %31, -2
  %ind.end = sub nsw i64 %30, %n.vec
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %offset.idx = sub i64 %30, %index
  %32 = add nsw i64 %offset.idx, -1
  %33 = add nsw i64 %offset.idx, -2
  %gep = getelementptr [100100 x double], ptr getelementptr (i8, ptr @x, i64 -8), i64 0, i64 %33
  %wide.load = load <2 x double>, ptr %gep, align 8, !tbaa !11
  %gep87 = getelementptr [100100 x double], ptr getelementptr (i8, ptr @x, i64 -8), i64 0, i64 %32
  %wide.load76 = load <2 x double>, ptr %gep87, align 8, !tbaa !11
  %34 = fsub <2 x double> %wide.load76, %wide.load
  store <2 x double> %34, ptr %gep87, align 8, !tbaa !11
  %gep88 = getelementptr [100100 x double], ptr getelementptr (i8, ptr @y, i64 -8), i64 0, i64 %33
  %wide.load79 = load <2 x double>, ptr %gep88, align 8, !tbaa !11
  %gep89 = getelementptr [100100 x double], ptr getelementptr (i8, ptr @y, i64 -8), i64 0, i64 %32
  %wide.load81 = load <2 x double>, ptr %gep89, align 8, !tbaa !11
  %35 = fsub <2 x double> %wide.load81, %wide.load79
  store <2 x double> %35, ptr %gep89, align 8, !tbaa !11
  %index.next = add nuw i64 %index, 2
  %36 = icmp eq i64 %index.next, %n.vec
  br i1 %36, label %middle.block, label %vector.body, !llvm.loop !14

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %31, %n.vec
  br i1 %cmp.n, label %._crit_edge47, label %.lr.ph46.preheader84

.lr.ph44:                                         ; preds = %._crit_edge, %.lr.ph44
  %37 = phi double [ %53, %.lr.ph44 ], [ %19, %._crit_edge ]
  %38 = phi double [ %52, %.lr.ph44 ], [ %18, %._crit_edge ]
  %indvars.iv61 = phi i64 [ %indvars.iv.next62, %.lr.ph44 ], [ 1, %._crit_edge ]
  %39 = getelementptr inbounds [100100 x double], ptr @a, i64 0, i64 %indvars.iv61
  %40 = load double, ptr %39, align 8, !tbaa !11
  %41 = fadd double %38, %40
  store double %41, ptr %39, align 8, !tbaa !11
  %42 = getelementptr inbounds [100100 x double], ptr @b, i64 0, i64 %indvars.iv61
  %43 = load double, ptr %42, align 8, !tbaa !11
  %44 = fadd double %37, %43
  store double %44, ptr %42, align 8, !tbaa !11
  %45 = fneg double %41
  %46 = fsub double %45, %44
  %47 = fpext double %46 to x86_fp80
  %48 = fpext double %41 to x86_fp80
  %49 = tail call noundef x86_fp80 @_Z5solveee(x86_fp80 noundef %47, x86_fp80 noundef %48)
  %50 = fptrunc x86_fp80 %49 to double
  %51 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %indvars.iv61
  store double %50, ptr %51, align 8, !tbaa !11
  %52 = load double, ptr %39, align 8, !tbaa !11
  %53 = load double, ptr %42, align 8, !tbaa !11
  %54 = fadd double %52, %53
  %55 = fsub double %54, %50
  %56 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %indvars.iv61
  store double %55, ptr %56, align 8, !tbaa !11
  %indvars.iv.next62 = add nuw nsw i64 %indvars.iv61, 1
  %57 = load i32, ptr @n, align 4, !tbaa !5
  %58 = sext i32 %57 to i64
  %59 = icmp slt i64 %indvars.iv.next62, %58
  br i1 %59, label %.lr.ph44, label %.preheader, !llvm.loop !17

._crit_edge47:                                    ; preds = %.lr.ph46, %middle.block, %._crit_edge, %.preheader
  %60 = tail call i32 @_ZSt12setprecisioni(i32 noundef 9)
  %61 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 %60)
  %62 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %61, ptr noundef nonnull @_ZSt5fixedRSt8ios_base)
  %63 = load i32, ptr @n, align 4, !tbaa !5
  %64 = icmp sgt i32 %63, 0
  br i1 %64, label %.lr.ph50, label %._crit_edge51

.lr.ph46:                                         ; preds = %.lr.ph46.preheader84, %.lr.ph46
  %indvars.iv64 = phi i64 [ %indvars.iv.next65, %.lr.ph46 ], [ %indvars.iv64.ph, %.lr.ph46.preheader84 ]
  %indvars.iv.next65 = add nsw i64 %indvars.iv64, -1
  %65 = add nsw i64 %indvars.iv64, -2
  %66 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %65
  %67 = load double, ptr %66, align 8, !tbaa !11
  %68 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %indvars.iv.next65
  %69 = load double, ptr %68, align 8, !tbaa !11
  %70 = fsub double %69, %67
  store double %70, ptr %68, align 8, !tbaa !11
  %71 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %65
  %72 = load double, ptr %71, align 8, !tbaa !11
  %73 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %indvars.iv.next65
  %74 = load double, ptr %73, align 8, !tbaa !11
  %75 = fsub double %74, %72
  store double %75, ptr %73, align 8, !tbaa !11
  %76 = icmp ugt i64 %indvars.iv64, 2
  br i1 %76, label %.lr.ph46, label %._crit_edge47, !llvm.loop !18

._crit_edge51:                                    ; preds = %.lr.ph50, %._crit_edge47
  %77 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  %78 = load i32, ptr @n, align 4, !tbaa !5
  %79 = icmp sgt i32 %78, 0
  br i1 %79, label %.lr.ph54, label %._crit_edge55

.lr.ph50:                                         ; preds = %._crit_edge47, %.lr.ph50
  %indvars.iv67 = phi i64 [ %indvars.iv.next68, %.lr.ph50 ], [ 0, %._crit_edge47 ]
  %80 = getelementptr inbounds [100100 x double], ptr @x, i64 0, i64 %indvars.iv67
  %81 = load double, ptr %80, align 8, !tbaa !11
  %82 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, double noundef %81)
  %indvars.iv.next68 = add nuw nsw i64 %indvars.iv67, 1
  %83 = load i32, ptr @n, align 4, !tbaa !5
  %84 = sext i32 %83 to i64
  %85 = icmp slt i64 %indvars.iv.next68, %84
  br i1 %85, label %.lr.ph50, label %._crit_edge51, !llvm.loop !19

._crit_edge55:                                    ; preds = %.lr.ph54, %._crit_edge51
  %86 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  ret i32 0

.lr.ph54:                                         ; preds = %._crit_edge51, %.lr.ph54
  %indvars.iv70 = phi i64 [ %indvars.iv.next71, %.lr.ph54 ], [ 0, %._crit_edge51 ]
  %87 = getelementptr inbounds [100100 x double], ptr @y, i64 0, i64 %indvars.iv70
  %88 = load double, ptr %87, align 8, !tbaa !11
  %89 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, double noundef %88)
  %indvars.iv.next71 = add nuw nsw i64 %indvars.iv70, 1
  %90 = load i32, ptr @n, align 4, !tbaa !5
  %91 = sext i32 %90 to i64
  %92 = icmp slt i64 %indvars.iv.next71, %91
  br i1 %92, label %.lr.ph54, label %._crit_edge55, !llvm.loop !20
}

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8), i32) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local i32 @_ZSt12setprecisioni(i32 noundef) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(216) ptr @_ZSt5fixedRSt8ios_base(ptr noundef nonnull align 8 dereferenceable(216)) #3

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

; Function Attrs: nofree nounwind
declare noundef i32 @puts(ptr nocapture noundef readonly) local_unnamed_addr #2

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 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 #2 = { 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 #3 = { inlinehint 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 #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" }

!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 = !{!12, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10, !15, !16}
!15 = !{!"llvm.loop.isvectorized", i32 1}
!16 = !{!"llvm.loop.unroll.runtime.disable"}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10, !16, !15}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}


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