; LLVM IR from bqi343/cp-notebook :: Contests/USACO Training/Ch 5/5.1 fc (main)

; 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<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::basic_ifstream" = type { %"class.std::basic_istream.base", %"class.std::basic_filebuf", %"class.std::basic_ios" }
%"class.std::basic_istream.base" = type { ptr, i64 }
%"class.std::basic_filebuf" = type { %"class.std::basic_streambuf", %union.pthread_mutex_t, %"class.std::__basic_file", i32, %struct.__mbstate_t, %struct.__mbstate_t, %struct.__mbstate_t, ptr, i64, i8, i8, i8, i8, ptr, ptr, i8, ptr, ptr, i64, ptr, ptr }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.std::__basic_file" = type <{ ptr, i8, [7 x i8] }>
%struct.__mbstate_t = type { i32, %union.anon }
%union.anon = type { i32 }
%"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::basic_ofstream" = type { %"class.std::basic_ostream.base", %"class.std::basic_filebuf", %"class.std::basic_ios" }
%"class.std::basic_ostream.base" = type { ptr }
%"struct.std::pair.0" = type { i32, i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"struct.std::pair" = type { double, double }
%"struct.std::_Setprecision" = type { i32 }

@points = external dso_local global %"class.std::vector", align 8
@.str = external hidden unnamed_addr constant [6 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z4compSt4pairIddES0_(double, double, double, double) #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 nounwind uwtable
declare dso_local noundef double @_Z3ccwSt4pairIddES0_S0_(double, double, double, double, double, double) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_Z4distSt4pairIddES0_(double, double, double, double) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca %"class.std::basic_ifstream", align 8
  %3 = alloca %"class.std::basic_ofstream", align 8
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca %"struct.std::pair.0", align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca %"struct.std::pair", align 8
  %20 = alloca %"struct.std::pair", align 8
  %21 = alloca %"struct.std::pair", align 8
  %22 = alloca double, align 8
  %23 = alloca i32, align 4
  %24 = alloca %"struct.std::pair", align 8
  %25 = alloca %"struct.std::pair", align 8
  %26 = alloca %"struct.std::pair", align 8
  %27 = alloca %"struct.std::pair", align 8
  %28 = alloca %"struct.std::_Setprecision", align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 520, ptr %2) #8
  call void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(256) %2, ptr noundef @.str, i32 noundef 8)
  call void @llvm.lifetime.start.p0(i64 512, ptr %3) #8
  invoke void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248) %3, ptr noundef @.str.2, i32 noundef 16)
          to label %29 unwind label %42

29:                                               ; preds = %0
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #8
  %30 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %2, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %31 unwind label %46

31:                                               ; preds = %29
  %32 = load i32, ptr %6, align 4, !tbaa !5
  %33 = add nsw i32 %32, 1
  %34 = sext i32 %33 to i64
  invoke void @_ZNSt6vectorISt4pairIddESaIS1_EE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %34)
          to label %35 unwind label %46

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

36:                                               ; preds = %63, %35
  %37 = load i32, ptr %7, align 4, !tbaa !5
  %38 = load i32, ptr %6, align 4, !tbaa !5
  %39 = add nsw i32 %38, 1
  %40 = icmp slt i32 %37, %39
  br i1 %40, label %50, label %41

41:                                               ; preds = %36
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  br label %70

42:                                               ; preds = %0
  %43 = landingpad { ptr, i32 }
          cleanup
  %44 = extractvalue { ptr, i32 } %43, 0
  store ptr %44, ptr %4, align 8
  %45 = extractvalue { ptr, i32 } %43, 1
  store i32 %45, ptr %5, align 4
  br label %309

46:                                               ; preds = %161, %31, %29
  %47 = landingpad { ptr, i32 }
          cleanup
  %48 = extractvalue { ptr, i32 } %47, 0
  store ptr %48, ptr %4, align 8
  %49 = extractvalue { ptr, i32 } %47, 1
  store i32 %49, ptr %5, align 4
  br label %308

50:                                               ; preds = %36
  %51 = load i32, ptr %7, align 4, !tbaa !5
  %52 = sext i32 %51 to i64
  %53 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %52) #8
  %54 = getelementptr inbounds %"struct.std::pair", ptr %53, i32 0, i32 0
  %55 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %2, ptr noundef nonnull align 8 dereferenceable(8) %54)
          to label %56 unwind label %66

56:                                               ; preds = %50
  %57 = load i32, ptr %7, align 4, !tbaa !5
  %58 = sext i32 %57 to i64
  %59 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %58) #8
  %60 = getelementptr inbounds %"struct.std::pair", ptr %59, i32 0, i32 1
  %61 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %55, ptr noundef nonnull align 8 dereferenceable(8) %60)
          to label %62 unwind label %66

62:                                               ; preds = %56
  br label %63

63:                                               ; preds = %62
  %64 = load i32, ptr %7, align 4, !tbaa !5
  %65 = add nsw i32 %64, 1
  store i32 %65, ptr %7, align 4, !tbaa !5
  br label %36, !llvm.loop !9

66:                                               ; preds = %56, %50
  %67 = landingpad { ptr, i32 }
          cleanup
  %68 = extractvalue { ptr, i32 } %67, 0
  store ptr %68, ptr %4, align 8
  %69 = extractvalue { ptr, i32 } %67, 1
  store i32 %69, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  br label %308

70:                                               ; preds = %41
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #8
  store i32 2, ptr %8, align 4, !tbaa !5
  br label %71

71:                                               ; preds = %113, %70
  %72 = load i32, ptr %8, align 4, !tbaa !5
  %73 = load i32, ptr %6, align 4, !tbaa !5
  %74 = add nsw i32 %73, 1
  %75 = icmp slt i32 %72, %74
  br i1 %75, label %77, label %76

76:                                               ; preds = %71
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #8
  br label %116

77:                                               ; preds = %71
  %78 = load i32, ptr %8, align 4, !tbaa !5
  %79 = sext i32 %78 to i64
  %80 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %79) #8
  %81 = getelementptr inbounds %"struct.std::pair", ptr %80, i32 0, i32 1
  %82 = load double, ptr %81, align 8, !tbaa !11
  %83 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %84 = getelementptr inbounds %"struct.std::pair", ptr %83, i32 0, i32 1
  %85 = load double, ptr %84, align 8, !tbaa !11
  %86 = fcmp olt double %82, %85
  br i1 %86, label %107, label %87

87:                                               ; preds = %77
  %88 = load i32, ptr %8, align 4, !tbaa !5
  %89 = sext i32 %88 to i64
  %90 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %89) #8
  %91 = getelementptr inbounds %"struct.std::pair", ptr %90, i32 0, i32 1
  %92 = load double, ptr %91, align 8, !tbaa !11
  %93 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %94 = getelementptr inbounds %"struct.std::pair", ptr %93, i32 0, i32 1
  %95 = load double, ptr %94, align 8, !tbaa !11
  %96 = fcmp oeq double %92, %95
  br i1 %96, label %97, label %112

97:                                               ; preds = %87
  %98 = load i32, ptr %8, align 4, !tbaa !5
  %99 = sext i32 %98 to i64
  %100 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %99) #8
  %101 = getelementptr inbounds %"struct.std::pair", ptr %100, i32 0, i32 0
  %102 = load double, ptr %101, align 8, !tbaa !14
  %103 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %104 = getelementptr inbounds %"struct.std::pair", ptr %103, i32 0, i32 0
  %105 = load double, ptr %104, align 8, !tbaa !14
  %106 = fcmp olt double %102, %105
  br i1 %106, label %107, label %112

107:                                              ; preds = %97, %77
  %108 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %109 = load i32, ptr %8, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %110) #8
  call void @_ZSt4swapIddENSt9enable_ifIXsr6__and_ISt14__is_swappableIT_ES1_IT0_EEE5valueEvE4typeERSt4pairIS2_S4_ESA_(ptr noundef nonnull align 8 dereferenceable(16) %108, ptr noundef nonnull align 8 dereferenceable(16) %111) #8
  br label %112

112:                                              ; preds = %107, %97, %87
  br label %113

113:                                              ; preds = %112
  %114 = load i32, ptr %8, align 4, !tbaa !5
  %115 = add nsw i32 %114, 1
  store i32 %115, ptr %8, align 4, !tbaa !5
  br label %71, !llvm.loop !15

116:                                              ; preds = %76
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #8
  store i32 2, ptr %9, align 4, !tbaa !5
  br label %117

117:                                              ; preds = %142, %116
  %118 = load i32, ptr %9, align 4, !tbaa !5
  %119 = load i32, ptr %6, align 4, !tbaa !5
  %120 = add nsw i32 %119, 1
  %121 = icmp slt i32 %118, %120
  br i1 %121, label %123, label %122

122:                                              ; preds = %117
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #8
  br label %145

123:                                              ; preds = %117
  %124 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %125 = getelementptr inbounds %"struct.std::pair", ptr %124, i32 0, i32 0
  %126 = load double, ptr %125, align 8, !tbaa !14
  %127 = load i32, ptr %9, align 4, !tbaa !5
  %128 = sext i32 %127 to i64
  %129 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %128) #8
  %130 = getelementptr inbounds %"struct.std::pair", ptr %129, i32 0, i32 0
  %131 = load double, ptr %130, align 8, !tbaa !14
  %132 = fsub double %131, %126
  store double %132, ptr %130, align 8, !tbaa !14
  %133 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %134 = getelementptr inbounds %"struct.std::pair", ptr %133, i32 0, i32 1
  %135 = load double, ptr %134, align 8, !tbaa !11
  %136 = load i32, ptr %9, align 4, !tbaa !5
  %137 = sext i32 %136 to i64
  %138 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %137) #8
  %139 = getelementptr inbounds %"struct.std::pair", ptr %138, i32 0, i32 1
  %140 = load double, ptr %139, align 8, !tbaa !11
  %141 = fsub double %140, %135
  store double %141, ptr %139, align 8, !tbaa !11
  br label %142

142:                                              ; preds = %123
  %143 = load i32, ptr %9, align 4, !tbaa !5
  %144 = add nsw i32 %143, 1
  store i32 %144, ptr %9, align 4, !tbaa !5
  br label %117, !llvm.loop !16

145:                                              ; preds = %122
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #8
  store i32 0, ptr %11, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #8
  store i32 0, ptr %12, align 4, !tbaa !5
  %146 = invoke i64 @_ZSt9make_pairIiiESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS1_INS2_IT0_E4typeEE6__typeEEOS3_OS8_(ptr noundef nonnull align 4 dereferenceable(4) %11, ptr noundef nonnull align 4 dereferenceable(4) %12)
          to label %147 unwind label %174

147:                                              ; preds = %145
  store i64 %146, ptr %10, align 4
  %148 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #8
  %149 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt4pairIddEaSIiiEENSt9enable_ifIXsr6__and_ISt13is_assignableIRdOT_ES3_IS4_OT0_EEE5valueERS0_E4typeEOS_IS5_S8_E(ptr noundef nonnull align 8 dereferenceable(16) %148, ptr noundef nonnull align 4 dereferenceable(8) %10)
          to label %150 unwind label %174

150:                                              ; preds = %147
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  %151 = call ptr @_ZNSt6vectorISt4pairIddESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) @points) #8
  %152 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  store ptr %151, ptr %152, align 8
  %153 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIddESt6vectorIS2_SaIS2_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %14, i64 noundef 2) #8
  %154 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %13, i32 0, i32 0
  store ptr %153, ptr %154, align 8
  %155 = call ptr @_ZNSt6vectorISt4pairIddESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) @points) #8
  %156 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  store ptr %155, ptr %156, align 8
  %157 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %13, i32 0, i32 0
  %158 = load ptr, ptr %157, align 8
  %159 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  %160 = load ptr, ptr %159, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIddESt6vectorIS3_SaIS3_EEEEPFbS3_S3_EEvT_SB_T0_(ptr %158, ptr %160, ptr noundef @_Z4compSt4pairIddES0_)
          to label %161 unwind label %178

161:                                              ; preds = %150
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  %162 = load i32, ptr %6, align 4, !tbaa !5
  %163 = sext i32 %162 to i64
  %164 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %163) #8
  %165 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 0) #8
  %166 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt4pairIddEaSERKS0_(ptr noundef nonnull align 8 dereferenceable(16) %165, ptr noundef nonnull align 8 dereferenceable(16) %164)
          to label %167 unwind label %46

167:                                              ; preds = %161
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #8
  store i32 1, ptr %16, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #8
  store i32 2, ptr %17, align 4, !tbaa !5
  br label %168

168:                                              ; preds = %234, %167
  %169 = load i32, ptr %17, align 4, !tbaa !5
  %170 = load i32, ptr %6, align 4, !tbaa !5
  %171 = add nsw i32 %170, 1
  %172 = icmp slt i32 %169, %171
  br i1 %172, label %182, label %173

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

174:                                              ; preds = %147, %145
  %175 = landingpad { ptr, i32 }
          cleanup
  %176 = extractvalue { ptr, i32 } %175, 0
  store ptr %176, ptr %4, align 8
  %177 = extractvalue { ptr, i32 } %175, 1
  store i32 %177, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #8
  br label %308

178:                                              ; preds = %150
  %179 = landingpad { ptr, i32 }
          cleanup
  %180 = extractvalue { ptr, i32 } %179, 0
  store ptr %180, ptr %4, align 8
  %181 = extractvalue { ptr, i32 } %179, 1
  store i32 %181, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  br label %308

182:                                              ; preds = %168
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #8
  %183 = load i32, ptr %17, align 4, !tbaa !5
  store i32 %183, ptr %18, align 4, !tbaa !5
  br label %184

184:                                              ; preds = %224, %212, %182
  %185 = load i32, ptr %16, align 4, !tbaa !5
  %186 = sub nsw i32 %185, 1
  %187 = sext i32 %186 to i64
  %188 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %187) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %19, ptr align 8 %188, i64 16, i1 false)
  %189 = load i32, ptr %16, align 4, !tbaa !5
  %190 = sext i32 %189 to i64
  %191 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %190) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %20, ptr align 8 %191, i64 16, i1 false)
  %192 = load i32, ptr %18, align 4, !tbaa !5
  %193 = sext i32 %192 to i64
  %194 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %193) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %21, ptr align 8 %194, i64 16, i1 false)
  %195 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 0
  %196 = load double, ptr %195, align 8
  %197 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 1
  %198 = load double, ptr %197, align 8
  %199 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 0
  %200 = load double, ptr %199, align 8
  %201 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 1
  %202 = load double, ptr %201, align 8
  %203 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 0
  %204 = load double, ptr %203, align 8
  %205 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 1
  %206 = load double, ptr %205, align 8
  %207 = call noundef double @_Z3ccwSt4pairIddES0_S0_(double %196, double %198, double %200, double %202, double %204, double %206)
  %208 = fcmp ole double %207, 0.000000e+00
  br i1 %208, label %209, label %225

209:                                              ; preds = %184
  %210 = load i32, ptr %16, align 4, !tbaa !5
  %211 = icmp sgt i32 %210, 1
  br i1 %211, label %212, label %215

212:                                              ; preds = %209
  %213 = load i32, ptr %16, align 4, !tbaa !5
  %214 = add nsw i32 %213, -1
  store i32 %214, ptr %16, align 4, !tbaa !5
  br label %184, !llvm.loop !17

215:                                              ; preds = %209
  %216 = load i32, ptr %18, align 4, !tbaa !5
  %217 = load i32, ptr %6, align 4, !tbaa !5
  %218 = icmp eq i32 %216, %217
  br i1 %218, label %219, label %220

219:                                              ; preds = %215
  br label %225

220:                                              ; preds = %215
  %221 = load i32, ptr %18, align 4, !tbaa !5
  %222 = add nsw i32 %221, 1
  store i32 %222, ptr %18, align 4, !tbaa !5
  br label %223

223:                                              ; preds = %220
  br label %224

224:                                              ; preds = %223
  br label %184, !llvm.loop !17

225:                                              ; preds = %219, %184
  %226 = load i32, ptr %16, align 4, !tbaa !5
  %227 = add nsw i32 %226, 1
  store i32 %227, ptr %16, align 4, !tbaa !5
  %228 = load i32, ptr %16, align 4, !tbaa !5
  %229 = sext i32 %228 to i64
  %230 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %229) #8
  %231 = load i32, ptr %18, align 4, !tbaa !5
  %232 = sext i32 %231 to i64
  %233 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %232) #8
  call void @_ZSt4swapIddENSt9enable_ifIXsr6__and_ISt14__is_swappableIT_ES1_IT0_EEE5valueEvE4typeERSt4pairIS2_S4_ESA_(ptr noundef nonnull align 8 dereferenceable(16) %230, ptr noundef nonnull align 8 dereferenceable(16) %233) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  br label %234

234:                                              ; preds = %225
  %235 = load i32, ptr %17, align 4, !tbaa !5
  %236 = add nsw i32 %235, 1
  store i32 %236, ptr %17, align 4, !tbaa !5
  br label %168, !llvm.loop !18

237:                                              ; preds = %173
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #8
  store double 0.000000e+00, ptr %22, align 8, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #8
  store i32 0, ptr %23, align 4, !tbaa !5
  br label %238

238:                                              ; preds = %285, %237
  %239 = load i32, ptr %23, align 4, !tbaa !5
  %240 = load i32, ptr %16, align 4, !tbaa !5
  %241 = icmp slt i32 %239, %240
  br i1 %241, label %243, label %242

242:                                              ; preds = %238
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #8
  br label %288

243:                                              ; preds = %238
  %244 = load i32, ptr %23, align 4, !tbaa !5
  %245 = icmp ne i32 %244, 0
  br i1 %245, label %246, label %265

246:                                              ; preds = %243
  %247 = load i32, ptr %23, align 4, !tbaa !5
  %248 = sext i32 %247 to i64
  %249 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %248) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %24, ptr align 8 %249, i64 16, i1 false)
  %250 = load i32, ptr %23, align 4, !tbaa !5
  %251 = add nsw i32 %250, 1
  %252 = sext i32 %251 to i64
  %253 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %252) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %25, ptr align 8 %253, i64 16, i1 false)
  %254 = getelementptr inbounds { double, double }, ptr %24, i32 0, i32 0
  %255 = load double, ptr %254, align 8
  %256 = getelementptr inbounds { double, double }, ptr %24, i32 0, i32 1
  %257 = load double, ptr %256, align 8
  %258 = getelementptr inbounds { double, double }, ptr %25, i32 0, i32 0
  %259 = load double, ptr %258, align 8
  %260 = getelementptr inbounds { double, double }, ptr %25, i32 0, i32 1
  %261 = load double, ptr %260, align 8
  %262 = call noundef double @_Z4distSt4pairIddES0_(double %255, double %257, double %259, double %261)
  %263 = load double, ptr %22, align 8, !tbaa !19
  %264 = fadd double %263, %262
  store double %264, ptr %22, align 8, !tbaa !19
  br label %284

265:                                              ; preds = %243
  %266 = load i32, ptr %16, align 4, !tbaa !5
  %267 = sext i32 %266 to i64
  %268 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %267) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %26, ptr align 8 %268, i64 16, i1 false)
  %269 = load i32, ptr %23, align 4, !tbaa !5
  %270 = add nsw i32 %269, 1
  %271 = sext i32 %270 to i64
  %272 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %271) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %27, ptr align 8 %272, i64 16, i1 false)
  %273 = getelementptr inbounds { double, double }, ptr %26, i32 0, i32 0
  %274 = load double, ptr %273, align 8
  %275 = getelementptr inbounds { double, double }, ptr %26, i32 0, i32 1
  %276 = load double, ptr %275, align 8
  %277 = getelementptr inbounds { double, double }, ptr %27, i32 0, i32 0
  %278 = load double, ptr %277, align 8
  %279 = getelementptr inbounds { double, double }, ptr %27, i32 0, i32 1
  %280 = load double, ptr %279, align 8
  %281 = call noundef double @_Z4distSt4pairIddES0_(double %274, double %276, double %278, double %280)
  %282 = load double, ptr %22, align 8, !tbaa !19
  %283 = fadd double %282, %281
  store double %283, ptr %22, align 8, !tbaa !19
  br label %284

284:                                              ; preds = %265, %246
  br label %285

285:                                              ; preds = %284
  %286 = load i32, ptr %23, align 4, !tbaa !5
  %287 = add nsw i32 %286, 1
  store i32 %287, ptr %23, align 4, !tbaa !5
  br label %238, !llvm.loop !20

288:                                              ; preds = %242
  %289 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef @_ZSt5fixedRSt8ios_base)
          to label %290 unwind label %304

290:                                              ; preds = %288
  %291 = invoke i32 @_ZSt12setprecisioni(i32 noundef 2)
          to label %292 unwind label %304

292:                                              ; preds = %290
  %293 = getelementptr inbounds %"struct.std::_Setprecision", ptr %28, i32 0, i32 0
  store i32 %291, ptr %293, align 4
  %294 = getelementptr inbounds %"struct.std::_Setprecision", ptr %28, i32 0, i32 0
  %295 = load i32, ptr %294, align 4
  %296 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8) %289, i32 %295)
          to label %297 unwind label %304

297:                                              ; preds = %292
  %298 = load double, ptr %22, align 8, !tbaa !19
  %299 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %296, double noundef %298)
          to label %300 unwind label %304

300:                                              ; preds = %297
  %301 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %299, ptr noundef @.str.3)
          to label %302 unwind label %304

302:                                              ; preds = %300
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #8
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %3) #8
  call void @llvm.lifetime.end.p0(i64 512, ptr %3) #8
  call void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(256) %2) #8
  call void @llvm.lifetime.end.p0(i64 520, ptr %2) #8
  %303 = load i32, ptr %1, align 4
  ret i32 %303

304:                                              ; preds = %300, %297, %292, %290, %288
  %305 = landingpad { ptr, i32 }
          cleanup
  %306 = extractvalue { ptr, i32 } %305, 0
  store ptr %306, ptr %4, align 8
  %307 = extractvalue { ptr, i32 } %305, 1
  store i32 %307, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #8
  br label %308

308:                                              ; preds = %304, %178, %174, %66, %46
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #8
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %3) #8
  br label %309

309:                                              ; preds = %308, %42
  call void @llvm.lifetime.end.p0(i64 512, ptr %3) #8
  call void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(256) %2) #8
  call void @llvm.lifetime.end.p0(i64 520, ptr %2) #8
  br label %310

310:                                              ; preds = %309
  %311 = load ptr, ptr %4, align 8
  %312 = load i32, ptr %5, align 4
  %313 = insertvalue { ptr, i32 } poison, ptr %311, 0
  %314 = insertvalue { ptr, i32 } %313, i32 %312, 1
  resume { ptr, i32 } %314
}

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(256), ptr noundef, i32 noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248), ptr noundef, i32 noundef) unnamed_addr #3 align 2

declare i32 @__gxx_personality_v0(...)

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) #4

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

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIddENSt9enable_ifIXsr6__and_ISt14__is_swappableIT_ES1_IT0_EEE5valueEvE4typeERSt4pairIS2_S4_ESA_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) #5

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZSt9make_pairIiiESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS1_INS2_IT0_E4typeEE6__typeEEOS3_OS8_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt4pairIddEaSIiiEENSt9enable_ifIXsr6__and_ISt13is_assignableIRdOT_ES3_IS4_OT0_EEE5valueERS0_E4typeEOS_IS5_S8_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(8)) #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIddESt6vectorIS3_SaIS3_EEEEPFbS3_S3_EEvT_SB_T0_(ptr, ptr, ptr noundef) #6

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

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

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

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #7

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #6

; 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) #6

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #3 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)) #6

; 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 @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8), double noundef) #3 align 2

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

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

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 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 = { 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 = { "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 = { 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 #7 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #8 = { 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 = !{!12, !13, i64 8}
!12 = !{!"_ZTSSt4pairIddE", !13, i64 0, !13, i64 8}
!13 = !{!"double", !7, i64 0}
!14 = !{!12, !13, i64 0}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = !{!13, !13, i64 0}
!20 = distinct !{!20, !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::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<double, double>, std::allocator<std::pair<double, double>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::basic_ifstream" = type { %"class.std::basic_istream.base", %"class.std::basic_filebuf", %"class.std::basic_ios" }
%"class.std::basic_istream.base" = type { ptr, i64 }
%"class.std::basic_filebuf" = type { %"class.std::basic_streambuf", %union.pthread_mutex_t, %"class.std::__basic_file", i32, %struct.__mbstate_t, %struct.__mbstate_t, %struct.__mbstate_t, ptr, i64, i8, i8, i8, i8, ptr, ptr, i8, ptr, ptr, i64, ptr, ptr }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.std::__basic_file" = type <{ ptr, i8, [7 x i8] }>
%struct.__mbstate_t = type { i32, %union.anon }
%union.anon = type { i32 }
%"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::basic_ofstream" = type { %"class.std::basic_ostream.base", %"class.std::basic_filebuf", %"class.std::basic_ios" }
%"class.std::basic_ostream.base" = type { ptr }
%"struct.std::pair.0" = type { i32, i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@points = external dso_local global %"class.std::vector", align 8
@.str = external hidden unnamed_addr constant [6 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z4compSt4pairIddES0_(double, double, double, double) #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 nounwind uwtable
declare dso_local noundef double @_Z3ccwSt4pairIddES0_S0_(double, double, double, double, double, double) local_unnamed_addr #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_Z4distSt4pairIddES0_(double, double, double, double) local_unnamed_addr #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::basic_ifstream", align 8
  %2 = alloca %"class.std::basic_ofstream", align 8
  %3 = alloca i32, align 4
  %4 = alloca %"struct.std::pair.0", align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  call void @llvm.lifetime.start.p0(i64 520, ptr nonnull %1) #7
  call void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(256) %1, ptr noundef nonnull @.str, i32 noundef 8)
  call void @llvm.lifetime.start.p0(i64 512, ptr nonnull %2) #7
  invoke void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248) %2, ptr noundef nonnull @.str.2, i32 noundef 16)
          to label %8 unwind label %15

8:                                                ; preds = %0
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #7
  %9 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull align 4 dereferenceable(4) %3)
          to label %10 unwind label %17

10:                                               ; preds = %8
  %11 = load i32, ptr %3, align 4, !tbaa !5
  %12 = add nsw i32 %11, 1
  %13 = sext i32 %12 to i64
  invoke void @_ZNSt6vectorISt4pairIddESaIS1_EE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %13)
          to label %.preheader78 unwind label %17

.preheader78:                                     ; preds = %10
  %14 = load i32, ptr %3, align 4, !tbaa !5
  %.not82 = icmp slt i32 %14, 1
  br i1 %.not82, label %._crit_edge, label %.lr.ph

.preheader77:                                     ; preds = %25
  %.not6784 = icmp slt i32 %26, 2
  br i1 %.not6784, label %._crit_edge, label %.lr.ph86

15:                                               ; preds = %0
  %16 = landingpad { ptr, i32 }
          cleanup
  br label %130

17:                                               ; preds = %10, %8
  %18 = landingpad { ptr, i32 }
          cleanup
  br label %129

.lr.ph:                                           ; preds = %.preheader78, %25
  %indvars.iv = phi i64 [ %indvars.iv.next, %25 ], [ 1, %.preheader78 ]
  %19 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv) #7
  %20 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull align 8 dereferenceable(8) %19)
          to label %21 unwind label %28

21:                                               ; preds = %.lr.ph
  %22 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv) #7
  %23 = getelementptr inbounds i8, ptr %22, i64 8
  %24 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERd(ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef nonnull align 8 dereferenceable(8) %23)
          to label %25 unwind label %28

25:                                               ; preds = %21
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %26 = load i32, ptr %3, align 4, !tbaa !5
  %27 = sext i32 %26 to i64
  %.not.not = icmp slt i64 %indvars.iv, %27
  br i1 %.not.not, label %.lr.ph, label %.preheader77, !llvm.loop !9

28:                                               ; preds = %21, %.lr.ph
  %29 = landingpad { ptr, i32 }
          cleanup
  br label %129

.preheader76:                                     ; preds = %54
  %.not6887 = icmp slt i32 %55, 2
  br i1 %.not6887, label %._crit_edge, label %.lr.ph89

.lr.ph86:                                         ; preds = %.preheader77, %54
  %indvars.iv104 = phi i64 [ %indvars.iv.next105, %54 ], [ 2, %.preheader77 ]
  %30 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv104) #7
  %31 = getelementptr inbounds i8, ptr %30, i64 8
  %32 = load double, ptr %31, align 8, !tbaa !11
  %33 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %34 = getelementptr inbounds i8, ptr %33, i64 8
  %35 = load double, ptr %34, align 8, !tbaa !11
  %36 = fcmp olt double %32, %35
  br i1 %36, label %51, label %37

37:                                               ; preds = %.lr.ph86
  %38 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv104) #7
  %39 = getelementptr inbounds i8, ptr %38, i64 8
  %40 = load double, ptr %39, align 8, !tbaa !11
  %41 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %42 = getelementptr inbounds i8, ptr %41, i64 8
  %43 = load double, ptr %42, align 8, !tbaa !11
  %44 = fcmp oeq double %40, %43
  br i1 %44, label %45, label %54

45:                                               ; preds = %37
  %46 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv104) #7
  %47 = load double, ptr %46, align 8, !tbaa !14
  %48 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %49 = load double, ptr %48, align 8, !tbaa !14
  %50 = fcmp olt double %47, %49
  br i1 %50, label %51, label %54

51:                                               ; preds = %45, %.lr.ph86
  %52 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %53 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv104) #7
  call void @_ZSt4swapIddENSt9enable_ifIXsr6__and_ISt14__is_swappableIT_ES1_IT0_EEE5valueEvE4typeERSt4pairIS2_S4_ESA_(ptr noundef nonnull align 8 dereferenceable(16) %52, ptr noundef nonnull align 8 dereferenceable(16) %53) #7
  br label %54

54:                                               ; preds = %37, %45, %51
  %indvars.iv.next105 = add nuw nsw i64 %indvars.iv104, 1
  %55 = load i32, ptr %3, align 4, !tbaa !5
  %56 = sext i32 %55 to i64
  %.not67.not = icmp slt i64 %indvars.iv104, %56
  br i1 %.not67.not, label %.lr.ph86, label %.preheader76, !llvm.loop !15

._crit_edge:                                      ; preds = %.lr.ph89, %.preheader78, %.preheader77, %.preheader76
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #7
  store i32 0, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #7
  store i32 0, ptr %6, align 4, !tbaa !5
  %57 = invoke i64 @_ZSt9make_pairIiiESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS1_INS2_IT0_E4typeEE6__typeEEOS3_OS8_(ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %72 unwind label %90

.lr.ph89:                                         ; preds = %.preheader76, %.lr.ph89
  %indvars.iv107 = phi i64 [ %indvars.iv.next108, %.lr.ph89 ], [ 2, %.preheader76 ]
  %58 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %59 = load double, ptr %58, align 8, !tbaa !14
  %60 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv107) #7
  %61 = load double, ptr %60, align 8, !tbaa !14
  %62 = fsub double %61, %59
  store double %62, ptr %60, align 8, !tbaa !14
  %63 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %64 = getelementptr inbounds i8, ptr %63, i64 8
  %65 = load double, ptr %64, align 8, !tbaa !11
  %66 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv107) #7
  %67 = getelementptr inbounds i8, ptr %66, i64 8
  %68 = load double, ptr %67, align 8, !tbaa !11
  %69 = fsub double %68, %65
  store double %69, ptr %67, align 8, !tbaa !11
  %indvars.iv.next108 = add nuw nsw i64 %indvars.iv107, 1
  %70 = load i32, ptr %3, align 4, !tbaa !5
  %71 = sext i32 %70 to i64
  %.not68.not = icmp slt i64 %indvars.iv107, %71
  br i1 %.not68.not, label %.lr.ph89, label %._crit_edge, !llvm.loop !16

72:                                               ; preds = %._crit_edge
  store i64 %57, ptr %4, align 8
  %73 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %74 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt4pairIddEaSIiiEENSt9enable_ifIXsr6__and_ISt13is_assignableIRdOT_ES3_IS4_OT0_EEE5valueERS0_E4typeEOS_IS5_S8_E(ptr noundef nonnull align 8 dereferenceable(16) %73, ptr noundef nonnull align 4 dereferenceable(8) %4)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  %75 = call ptr @_ZNSt6vectorISt4pairIddESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) @points) #7
  store ptr %75, ptr %7, align 8
  %76 = call ptr @_ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIddESt6vectorIS2_SaIS2_EEEplEl(ptr noundef nonnull align 8 dereferenceable(8) %7, i64 noundef 2) #7
  %77 = call ptr @_ZNSt6vectorISt4pairIddESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) @points) #7
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIddESt6vectorIS3_SaIS3_EEEEPFbS3_S3_EEvT_SB_T0_(ptr %76, ptr %77, ptr noundef nonnull @_Z4compSt4pairIddES0_)
          to label %78 unwind label %92

78:                                               ; preds = %72
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  %79 = load i32, ptr %3, align 4, !tbaa !5
  %80 = sext i32 %79 to i64
  %81 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %80) #7
  %82 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 0) #7
  %83 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt4pairIddEaSERKS0_(ptr noundef nonnull align 8 dereferenceable(16) %82, ptr noundef nonnull align 8 dereferenceable(16) %81)
  %84 = load i32, ptr %3, align 4, !tbaa !5
  %.not6990 = icmp slt i32 %84, 2
  br i1 %.not6990, label %.preheader.thread, label %.preheader74

.preheader74:                                     ; preds = %78, %.loopexit
  %indvars.iv113 = phi i64 [ %indvars.iv.next114, %.loopexit ], [ 2, %78 ]
  %.06092 = phi i32 [ %109, %.loopexit ], [ 1, %78 ]
  %indvars118 = trunc i64 %indvars.iv113 to i32
  br label %.outer

.preheader:                                       ; preds = %.loopexit
  %85 = icmp sgt i32 %.161100, -1
  br i1 %85, label %.preheader.thread, label %._crit_edge96

.preheader.thread:                                ; preds = %78, %.preheader
  %.060.lcssa126 = phi i32 [ %109, %.preheader ], [ 1, %78 ]
  %86 = zext nneg i32 %.060.lcssa126 to i64
  %87 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %86) #7
  %.sroa.02.0.copyload.peel = load double, ptr %87, align 8
  %.sroa.23.0..sroa_idx.peel = getelementptr inbounds i8, ptr %87, i64 8
  %.sroa.23.0.copyload.peel = load double, ptr %.sroa.23.0..sroa_idx.peel, align 8
  %88 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef 1) #7
  %.sroa.01.0.copyload.peel = load double, ptr %88, align 8
  %.sroa.2.0..sroa_idx.peel = getelementptr inbounds i8, ptr %88, i64 8
  %.sroa.2.0.copyload.peel = load double, ptr %.sroa.2.0..sroa_idx.peel, align 8
  %89 = call noundef double @_Z4distSt4pairIddES0_(double %.sroa.02.0.copyload.peel, double %.sroa.23.0.copyload.peel, double %.sroa.01.0.copyload.peel, double %.sroa.2.0.copyload.peel)
  %.165.peel = fadd double %89, 0.000000e+00
  %exitcond.peel.not = icmp eq i32 %.060.lcssa126, 1
  br i1 %exitcond.peel.not, label %._crit_edge96, label %.peel.next

90:                                               ; preds = %._crit_edge
  %91 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  br label %129

92:                                               ; preds = %72
  %93 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  br label %129

94:                                               ; preds = %.outer, %100
  %indvars.iv110 = phi i64 [ %107, %.outer ], [ %indvars.iv.next111, %100 ]
  %indvars.iv.next111 = add nsw i64 %indvars.iv110, -1
  %95 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv.next111) #7
  %.sroa.019.0.copyload = load double, ptr %95, align 8
  %.sroa.220.0..sroa_idx = getelementptr inbounds i8, ptr %95, i64 8
  %.sroa.220.0.copyload = load double, ptr %.sroa.220.0..sroa_idx, align 8
  %96 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv110) #7
  %.sroa.017.0.copyload = load double, ptr %96, align 8
  %.sroa.218.0..sroa_idx = getelementptr inbounds i8, ptr %96, i64 8
  %.sroa.218.0.copyload = load double, ptr %.sroa.218.0..sroa_idx, align 8
  %97 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv115) #7
  %.sroa.015.0.copyload = load double, ptr %97, align 8
  %.sroa.216.0..sroa_idx = getelementptr inbounds i8, ptr %97, i64 8
  %.sroa.216.0.copyload = load double, ptr %.sroa.216.0..sroa_idx, align 8
  %98 = call noundef double @_Z3ccwSt4pairIddES0_S0_(double %.sroa.019.0.copyload, double %.sroa.220.0.copyload, double %.sroa.017.0.copyload, double %.sroa.218.0.copyload, double %.sroa.015.0.copyload, double %.sroa.216.0.copyload)
  %99 = fcmp ugt double %98, 0.000000e+00
  br i1 %99, label %.loopexit.loopexit, label %100

100:                                              ; preds = %94
  %101 = icmp sgt i64 %indvars.iv110, 1
  br i1 %101, label %94, label %102, !llvm.loop !17

102:                                              ; preds = %100
  %103 = trunc nsw i64 %indvars.iv110 to i32
  %104 = load i32, ptr %3, align 4, !tbaa !5
  %105 = zext i32 %104 to i64
  %106 = icmp eq i64 %indvars.iv115, %105
  %indvars.iv.next116 = add nuw nsw i64 %indvars.iv115, 1
  br i1 %106, label %.loopexit, label %.outer, !llvm.loop !17

.outer:                                           ; preds = %102, %.preheader74
  %indvars.iv115 = phi i64 [ %indvars.iv.next116, %102 ], [ %indvars.iv113, %.preheader74 ]
  %.161.ph = phi i32 [ %103, %102 ], [ %.06092, %.preheader74 ]
  %107 = sext i32 %.161.ph to i64
  br label %94

.loopexit.loopexit:                               ; preds = %94
  %108 = trunc nsw i64 %indvars.iv110 to i32
  br label %.loopexit

.loopexit:                                        ; preds = %102, %.loopexit.loopexit
  %.161100 = phi i32 [ %108, %.loopexit.loopexit ], [ %103, %102 ]
  %109 = add nsw i32 %.161100, 1
  %110 = sext i32 %109 to i64
  %111 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %110) #7
  %112 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv115) #7
  call void @_ZSt4swapIddENSt9enable_ifIXsr6__and_ISt14__is_swappableIT_ES1_IT0_EEE5valueEvE4typeERSt4pairIS2_S4_ESA_(ptr noundef nonnull align 8 dereferenceable(16) %111, ptr noundef nonnull align 8 dereferenceable(16) %112) #7
  %indvars.iv.next114 = add nuw nsw i64 %indvars.iv113, 1
  %113 = load i32, ptr %3, align 4, !tbaa !5
  %.not69.not = icmp sgt i32 %113, %indvars118
  br i1 %.not69.not, label %.preheader74, label %.preheader, !llvm.loop !18

._crit_edge96:                                    ; preds = %.peel.next, %.preheader.thread, %.preheader
  %.064.lcssa = phi double [ 0.000000e+00, %.preheader ], [ %.165.peel, %.preheader.thread ], [ %.165, %.peel.next ]
  %114 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSt8ios_baseS0_E(ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull @_ZSt5fixedRSt8ios_base)
          to label %119 unwind label %127

.peel.next:                                       ; preds = %.preheader.thread, %.peel.next
  %indvars.iv119 = phi i64 [ %116, %.peel.next ], [ 1, %.preheader.thread ]
  %.06494 = phi double [ %.165, %.peel.next ], [ %.165.peel, %.preheader.thread ]
  %115 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %indvars.iv119) #7
  %.sroa.06.0.copyload = load double, ptr %115, align 8
  %.sroa.27.0..sroa_idx = getelementptr inbounds i8, ptr %115, i64 8
  %.sroa.27.0.copyload = load double, ptr %.sroa.27.0..sroa_idx, align 8
  %116 = add nuw nsw i64 %indvars.iv119, 1
  %117 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorISt4pairIddESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @points, i64 noundef %116) #7
  %.sroa.04.0.copyload = load double, ptr %117, align 8
  %.sroa.25.0..sroa_idx = getelementptr inbounds i8, ptr %117, i64 8
  %.sroa.25.0.copyload = load double, ptr %.sroa.25.0..sroa_idx, align 8
  %118 = call noundef double @_Z4distSt4pairIddES0_(double %.sroa.06.0.copyload, double %.sroa.27.0.copyload, double %.sroa.04.0.copyload, double %.sroa.25.0.copyload)
  %.165 = fadd double %.06494, %118
  %exitcond.not = icmp eq i64 %116, %86
  br i1 %exitcond.not, label %._crit_edge96, label %.peel.next, !llvm.loop !19

119:                                              ; preds = %._crit_edge96
  %120 = call i32 @_ZSt12setprecisioni(i32 noundef 2)
  %121 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_St13_Setprecision(ptr noundef nonnull align 8 dereferenceable(8) %114, i32 %120)
          to label %122 unwind label %127

122:                                              ; preds = %119
  %123 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEd(ptr noundef nonnull align 8 dereferenceable(8) %121, double noundef %.064.lcssa)
          to label %124 unwind label %127

124:                                              ; preds = %122
  %125 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %123, ptr noundef nonnull @.str.3)
          to label %126 unwind label %127

126:                                              ; preds = %124
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %2) #7
  call void @llvm.lifetime.end.p0(i64 512, ptr nonnull %2) #7
  call void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(256) %1) #7
  call void @llvm.lifetime.end.p0(i64 520, ptr nonnull %1) #7
  ret i32 0

127:                                              ; preds = %124, %122, %119, %._crit_edge96
  %128 = landingpad { ptr, i32 }
          cleanup
  br label %129

129:                                              ; preds = %127, %92, %90, %28, %17
  %.pn71 = phi { ptr, i32 } [ %29, %28 ], [ %128, %127 ], [ %93, %92 ], [ %91, %90 ], [ %18, %17 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %2) #7
  br label %130

130:                                              ; preds = %129, %15
  %.pn71.pn = phi { ptr, i32 } [ %.pn71, %129 ], [ %16, %15 ]
  call void @llvm.lifetime.end.p0(i64 512, ptr nonnull %2) #7
  call void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(256) %1) #7
  call void @llvm.lifetime.end.p0(i64 520, ptr nonnull %1) #7
  resume { ptr, i32 } %.pn71.pn
}

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(256), ptr noundef, i32 noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248), ptr noundef, i32 noundef) unnamed_addr #3 align 2

declare i32 @__gxx_personality_v0(...)

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZSt4swapIddENSt9enable_ifIXsr6__and_ISt14__is_swappableIT_ES1_IT0_EEE5valueEvE4typeERSt4pairIS2_S4_ESA_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZSt9make_pairIiiESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS1_INS2_IT0_E4typeEE6__typeEEOS3_OS8_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt4pairIddEaSIiiEENSt9enable_ifIXsr6__and_ISt13is_assignableIRdOT_ES3_IS4_OT0_EEE5valueERS0_E4typeEOS_IS5_S8_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #0 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIddESt6vectorIS3_SaIS3_EEEEPFbS3_S3_EEvT_SB_T0_(ptr, ptr, ptr noundef) local_unnamed_addr #6

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

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

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

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

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

; 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 #6

; 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 #3 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)) #6

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

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

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

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

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 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 = { 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 = { "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 = { 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 #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}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !13, i64 8}
!12 = !{!"_ZTSSt4pairIddE", !13, i64 0, !13, i64 8}
!13 = !{!"double", !7, i64 0}
!14 = !{!12, !13, i64 0}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10, !20}
!20 = !{!"llvm.loop.peeled.count", i32 1}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopFullUnrollPass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SCCPPass,SROAPass,SimplifyCFGPass