; LLVM IR from ayush-tulsyan/ACM-ICPC-Handbook :: code/ConvexHull.ll (Z10ConvexHullRSt6vectorI2PTSaIS0_EE)

; 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.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.__gnu_cxx::__normal_iterator.0" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl" }
%"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl" = type { %"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl_data" }
%"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%struct.PT = type { double, double }

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z10ConvexHullRSt6vectorI2PTSaIS0_EE(ptr noundef nonnull align 8 dereferenceable(24) %0) #2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %4 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %5 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %6 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %7 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %10 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %11 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %12 = alloca %"class.std::vector", align 8
  %13 = alloca %"class.std::vector", align 8
  %14 = alloca i32, align 4
  %15 = alloca %struct.PT, align 8
  %16 = alloca %struct.PT, align 8
  %17 = alloca %struct.PT, align 8
  %18 = alloca %struct.PT, align 8
  %19 = alloca %struct.PT, align 8
  %20 = alloca %struct.PT, align 8
  %21 = alloca ptr, align 8
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  store ptr %0, ptr %2, align 8, !tbaa !5
  %26 = load ptr, ptr %2, align 8, !tbaa !5
  %27 = call ptr @_ZNSt6vectorI2PTSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %26) #5
  %28 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %3, i32 0, i32 0
  store ptr %27, ptr %28, align 8
  %29 = load ptr, ptr %2, align 8, !tbaa !5
  %30 = call ptr @_ZNSt6vectorI2PTSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %29) #5
  %31 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %4, i32 0, i32 0
  store ptr %30, ptr %31, align 8
  %32 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %3, i32 0, i32 0
  %33 = load ptr, ptr %32, align 8
  %34 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %4, i32 0, i32 0
  %35 = load ptr, ptr %34, align 8
  call void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEEvT_S8_(ptr %33, ptr %35)
  %36 = load ptr, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %37 = load ptr, ptr %2, align 8, !tbaa !5
  %38 = call ptr @_ZNSt6vectorI2PTSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %37) #5
  %39 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %7, i32 0, i32 0
  store ptr %38, ptr %39, align 8
  %40 = load ptr, ptr %2, align 8, !tbaa !5
  %41 = call ptr @_ZNSt6vectorI2PTSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #5
  %42 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  store ptr %41, ptr %42, align 8
  %43 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %7, i32 0, i32 0
  %44 = load ptr, ptr %43, align 8
  %45 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  %46 = load ptr, ptr %45, align 8
  %47 = call ptr @_ZSt6uniqueIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEET_S8_S8_(ptr %44, ptr %46)
  %48 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %6, i32 0, i32 0
  store ptr %47, ptr %48, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPK2PTSt6vectorIS1_SaIS1_EEEC2IPS1_vEERKNS0_IT_S6_EE(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %49 = load ptr, ptr %2, align 8, !tbaa !5
  %50 = call ptr @_ZNSt6vectorI2PTSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %49) #5
  %51 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %10, i32 0, i32 0
  store ptr %50, ptr %51, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPK2PTSt6vectorIS1_SaIS1_EEEC2IPS1_vEERKNS0_IT_S6_EE(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  %52 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %5, i32 0, i32 0
  %53 = load ptr, ptr %52, align 8
  %54 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.0", ptr %9, i32 0, i32 0
  %55 = load ptr, ptr %54, align 8
  %56 = call ptr @_ZNSt6vectorI2PTSaIS0_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS0_S2_EES7_(ptr noundef nonnull align 8 dereferenceable(24) %36, ptr %53, ptr %55)
  %57 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %11, i32 0, i32 0
  store ptr %56, ptr %57, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #5
  call void @_ZNSt6vectorI2PTSaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #5
  call void @_ZNSt6vectorI2PTSaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !9
  br label %58

58:                                               ; preds = %136, %1
  %59 = load i32, ptr %14, align 4, !tbaa !9
  %60 = sext i32 %59 to i64
  %61 = load ptr, ptr %2, align 8, !tbaa !5
  %62 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %61) #5
  %63 = icmp ult i64 %60, %62
  br i1 %63, label %65, label %64

64:                                               ; preds = %58
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %143

65:                                               ; preds = %58
  br label %66

66:                                               ; preds = %94, %65
  %67 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  %68 = icmp ugt i64 %67, 1
  br i1 %68, label %69, label %92

69:                                               ; preds = %66
  %70 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  %71 = sub i64 %70, 2
  %72 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %71) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %15, ptr align 8 %72, i64 16, i1 false), !tbaa.struct !11
  %73 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %16, ptr align 8 %73, i64 16, i1 false), !tbaa.struct !11
  %74 = load ptr, ptr %2, align 8, !tbaa !5
  %75 = load i32, ptr %14, align 4, !tbaa !9
  %76 = sext i32 %75 to i64
  %77 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %74, i64 noundef %76) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %17, ptr align 8 %77, i64 16, i1 false), !tbaa.struct !11
  %78 = getelementptr inbounds { double, double }, ptr %15, i32 0, i32 0
  %79 = load double, ptr %78, align 8
  %80 = getelementptr inbounds { double, double }, ptr %15, i32 0, i32 1
  %81 = load double, ptr %80, align 8
  %82 = getelementptr inbounds { double, double }, ptr %16, i32 0, i32 0
  %83 = load double, ptr %82, align 8
  %84 = getelementptr inbounds { double, double }, ptr %16, i32 0, i32 1
  %85 = load double, ptr %84, align 8
  %86 = getelementptr inbounds { double, double }, ptr %17, i32 0, i32 0
  %87 = load double, ptr %86, align 8
  %88 = getelementptr inbounds { double, double }, ptr %17, i32 0, i32 1
  %89 = load double, ptr %88, align 8
  %90 = call noundef double @_Z5area22PTS_S_(double %79, double %81, double %83, double %85, double %87, double %89)
  %91 = fcmp oge double %90, 0.000000e+00
  br label %92

92:                                               ; preds = %69, %66
  %93 = phi i1 [ false, %66 ], [ %91, %69 ]
  br i1 %93, label %94, label %95

94:                                               ; preds = %92
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  br label %66, !llvm.loop !14

95:                                               ; preds = %92
  br label %96

96:                                               ; preds = %124, %95
  %97 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %98 = icmp ugt i64 %97, 1
  br i1 %98, label %99, label %122

99:                                               ; preds = %96
  %100 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %101 = sub i64 %100, 2
  %102 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef %101) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %18, ptr align 8 %102, i64 16, i1 false), !tbaa.struct !11
  %103 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %19, ptr align 8 %103, i64 16, i1 false), !tbaa.struct !11
  %104 = load ptr, ptr %2, align 8, !tbaa !5
  %105 = load i32, ptr %14, align 4, !tbaa !9
  %106 = sext i32 %105 to i64
  %107 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %104, i64 noundef %106) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %20, ptr align 8 %107, i64 16, i1 false), !tbaa.struct !11
  %108 = getelementptr inbounds { double, double }, ptr %18, i32 0, i32 0
  %109 = load double, ptr %108, align 8
  %110 = getelementptr inbounds { double, double }, ptr %18, i32 0, i32 1
  %111 = load double, ptr %110, align 8
  %112 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 0
  %113 = load double, ptr %112, align 8
  %114 = getelementptr inbounds { double, double }, ptr %19, i32 0, i32 1
  %115 = load double, ptr %114, align 8
  %116 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 0
  %117 = load double, ptr %116, align 8
  %118 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 1
  %119 = load double, ptr %118, align 8
  %120 = call noundef double @_Z5area22PTS_S_(double %109, double %111, double %113, double %115, double %117, double %119)
  %121 = fcmp ole double %120, 0.000000e+00
  br label %122

122:                                              ; preds = %99, %96
  %123 = phi i1 [ false, %96 ], [ %121, %99 ]
  br i1 %123, label %124, label %125

124:                                              ; preds = %122
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  br label %96, !llvm.loop !16

125:                                              ; preds = %122
  %126 = load ptr, ptr %2, align 8, !tbaa !5
  %127 = load i32, ptr %14, align 4, !tbaa !9
  %128 = sext i32 %127 to i64
  %129 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %126, i64 noundef %128) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %12, ptr noundef nonnull align 8 dereferenceable(16) %129)
          to label %130 unwind label %139

130:                                              ; preds = %125
  %131 = load ptr, ptr %2, align 8, !tbaa !5
  %132 = load i32, ptr %14, align 4, !tbaa !9
  %133 = sext i32 %132 to i64
  %134 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %131, i64 noundef %133) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(16) %134)
          to label %135 unwind label %139

135:                                              ; preds = %130
  br label %136

136:                                              ; preds = %135
  %137 = load i32, ptr %14, align 4, !tbaa !9
  %138 = add nsw i32 %137, 1
  store i32 %138, ptr %14, align 4, !tbaa !9
  br label %58, !llvm.loop !17

139:                                              ; preds = %130, %125
  %140 = landingpad { ptr, i32 }
          cleanup
  %141 = extractvalue { ptr, i32 } %140, 0
  store ptr %141, ptr %21, align 8
  %142 = extractvalue { ptr, i32 } %140, 1
  store i32 %142, ptr %22, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %234

143:                                              ; preds = %64
  %144 = load ptr, ptr %2, align 8, !tbaa !5
  %145 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI2PTSaIS0_EEaSERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %144, ptr noundef nonnull align 8 dereferenceable(24) %13)
          to label %146 unwind label %154

146:                                              ; preds = %143
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #5
  %147 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  %148 = trunc i64 %147 to i32
  %149 = sub nsw i32 %148, 2
  store i32 %149, ptr %23, align 4, !tbaa !9
  br label %150

150:                                              ; preds = %164, %146
  %151 = load i32, ptr %23, align 4, !tbaa !9
  %152 = icmp sge i32 %151, 1
  br i1 %152, label %158, label %153

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

154:                                              ; preds = %227, %179, %176, %143
  %155 = landingpad { ptr, i32 }
          cleanup
  %156 = extractvalue { ptr, i32 } %155, 0
  store ptr %156, ptr %21, align 8
  %157 = extractvalue { ptr, i32 } %155, 1
  store i32 %157, ptr %22, align 4
  br label %234

158:                                              ; preds = %150
  %159 = load ptr, ptr %2, align 8, !tbaa !5
  %160 = load i32, ptr %23, align 4, !tbaa !9
  %161 = sext i32 %160 to i64
  %162 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %161) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %159, ptr noundef nonnull align 8 dereferenceable(16) %162)
          to label %163 unwind label %167

163:                                              ; preds = %158
  br label %164

164:                                              ; preds = %163
  %165 = load i32, ptr %23, align 4, !tbaa !9
  %166 = add nsw i32 %165, -1
  store i32 %166, ptr %23, align 4, !tbaa !9
  br label %150, !llvm.loop !18

167:                                              ; preds = %158
  %168 = landingpad { ptr, i32 }
          cleanup
  %169 = extractvalue { ptr, i32 } %168, 0
  store ptr %169, ptr %21, align 8
  %170 = extractvalue { ptr, i32 } %168, 1
  store i32 %170, ptr %22, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #5
  br label %234

171:                                              ; preds = %153
  %172 = load ptr, ptr %2, align 8, !tbaa !5
  %173 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %172) #5
  %174 = icmp ule i64 %173, 2
  br i1 %174, label %175, label %176

175:                                              ; preds = %171
  store i32 1, ptr %24, align 4
  br label %231

176:                                              ; preds = %171
  call void @_ZNSt6vectorI2PTSaIS0_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %177 = load ptr, ptr %2, align 8, !tbaa !5
  %178 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %177, i64 noundef 0) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(16) %178)
          to label %179 unwind label %154

179:                                              ; preds = %176
  %180 = load ptr, ptr %2, align 8, !tbaa !5
  %181 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %180, i64 noundef 1) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(16) %181)
          to label %182 unwind label %154

182:                                              ; preds = %179
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #5
  store i32 2, ptr %25, align 4, !tbaa !9
  br label %183

183:                                              ; preds = %209, %182
  %184 = load i32, ptr %25, align 4, !tbaa !9
  %185 = sext i32 %184 to i64
  %186 = load ptr, ptr %2, align 8, !tbaa !5
  %187 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %186) #5
  %188 = icmp ult i64 %185, %187
  br i1 %188, label %190, label %189

189:                                              ; preds = %183
  store i32 12, ptr %24, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #5
  br label %216

190:                                              ; preds = %183
  %191 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %192 = sub i64 %191, 2
  %193 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef %192) #5
  %194 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %195 = sub i64 %194, 1
  %196 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef %195) #5
  %197 = load ptr, ptr %2, align 8, !tbaa !5
  %198 = load i32, ptr %25, align 4, !tbaa !9
  %199 = sext i32 %198 to i64
  %200 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %197, i64 noundef %199) #5
  %201 = call noundef zeroext i1 @_Z7betweenRK2PTS1_S1_(ptr noundef nonnull align 8 dereferenceable(16) %193, ptr noundef nonnull align 8 dereferenceable(16) %196, ptr noundef nonnull align 8 dereferenceable(16) %200)
  br i1 %201, label %202, label %203

202:                                              ; preds = %190
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  br label %203

203:                                              ; preds = %202, %190
  %204 = load ptr, ptr %2, align 8, !tbaa !5
  %205 = load i32, ptr %25, align 4, !tbaa !9
  %206 = sext i32 %205 to i64
  %207 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %204, i64 noundef %206) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(16) %207)
          to label %208 unwind label %212

208:                                              ; preds = %203
  br label %209

209:                                              ; preds = %208
  %210 = load i32, ptr %25, align 4, !tbaa !9
  %211 = add nsw i32 %210, 1
  store i32 %211, ptr %25, align 4, !tbaa !9
  br label %183, !llvm.loop !19

212:                                              ; preds = %203
  %213 = landingpad { ptr, i32 }
          cleanup
  %214 = extractvalue { ptr, i32 } %213, 0
  store ptr %214, ptr %21, align 8
  %215 = extractvalue { ptr, i32 } %213, 1
  store i32 %215, ptr %22, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #5
  br label %234

216:                                              ; preds = %189
  %217 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %218 = icmp uge i64 %217, 3
  br i1 %218, label %219, label %227

219:                                              ; preds = %216
  %220 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %221 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef 0) #5
  %222 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef 1) #5
  %223 = call noundef zeroext i1 @_Z7betweenRK2PTS1_S1_(ptr noundef nonnull align 8 dereferenceable(16) %220, ptr noundef nonnull align 8 dereferenceable(16) %221, ptr noundef nonnull align 8 dereferenceable(16) %222)
  br i1 %223, label %224, label %227

224:                                              ; preds = %219
  %225 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  %226 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef 0) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %226, ptr align 8 %225, i64 16, i1 false), !tbaa.struct !11
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  br label %227

227:                                              ; preds = %224, %219, %216
  %228 = load ptr, ptr %2, align 8, !tbaa !5
  %229 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI2PTSaIS0_EEaSERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %228, ptr noundef nonnull align 8 dereferenceable(24) %13)
          to label %230 unwind label %154

230:                                              ; preds = %227
  store i32 0, ptr %24, align 4
  br label %231

231:                                              ; preds = %230, %175
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #5
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #5
  %232 = load i32, ptr %24, align 4
  switch i32 %232, label %240 [
    i32 0, label %233
    i32 1, label %233
  ]

233:                                              ; preds = %231, %231
  ret void

234:                                              ; preds = %212, %167, %154, %139
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #5
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #5
  br label %235

235:                                              ; preds = %234
  %236 = load ptr, ptr %21, align 8
  %237 = load i32, ptr %22, align 4
  %238 = insertvalue { ptr, i32 } poison, ptr %236, 0
  %239 = insertvalue { ptr, i32 } %238, i32 %237, 1
  resume { ptr, i32 } %239

240:                                              ; preds = %231
  unreachable
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEEvT_S8_(ptr, ptr) #3

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local ptr @_ZSt6uniqueIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEET_S8_S8_(ptr, ptr) #3

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(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 @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #0 align 2

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) 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 nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{i64 0, i64 8, !12, i64 8, i64 8, !12}
!12 = !{!13, !13, i64 0}
!13 = !{!"double", !7, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = distinct !{!16, !15}
!17 = distinct !{!17, !15}
!18 = distinct !{!18, !15}
!19 = distinct !{!19, !15}


; 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.__gnu_cxx::__normal_iterator.0" = type { ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl" }
%"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl" = type { %"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl_data" }
%"struct.std::_Vector_base<PT, std::allocator<PT>>::_Vector_impl_data" = type { ptr, ptr, ptr }

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

; Function Attrs: mustprogress 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) #1

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

; Function Attrs: mustprogress uwtable
define dso_local void @_Z10ConvexHullRSt6vectorI2PTSaIS0_EE(ptr noundef nonnull align 8 dereferenceable(24) %0) local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %3 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %4 = alloca %"class.__gnu_cxx::__normal_iterator.0", align 8
  %5 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %6 = alloca %"class.std::vector", align 8
  %7 = alloca %"class.std::vector", align 8
  %8 = tail call ptr @_ZNSt6vectorI2PTSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %9 = tail call ptr @_ZNSt6vectorI2PTSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  tail call void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEEvT_S8_(ptr %8, ptr %9)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  %10 = tail call ptr @_ZNSt6vectorI2PTSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %11 = tail call ptr @_ZNSt6vectorI2PTSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %12 = tail call ptr @_ZSt6uniqueIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEET_S8_S8_(ptr %10, ptr %11)
  store ptr %12, ptr %3, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPK2PTSt6vectorIS1_SaIS1_EEEC2IPS1_vEERKNS0_IT_S6_EE(ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %13 = call ptr @_ZNSt6vectorI2PTSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  store ptr %13, ptr %5, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPK2PTSt6vectorIS1_SaIS1_EEEC2IPS1_vEERKNS0_IT_S6_EE(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  %14 = load ptr, ptr %2, align 8
  %15 = load ptr, ptr %4, align 8
  %16 = call ptr @_ZNSt6vectorI2PTSaIS0_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS0_S2_EES7_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr %14, ptr %15)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #5
  call void @_ZNSt6vectorI2PTSaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #5
  call void @_ZNSt6vectorI2PTSaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %17 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %.not = icmp eq i64 %17, 0
  br i1 %.not, label %._crit_edge, label %.preheader57

.preheader57:                                     ; preds = %1, %46
  %indvars.iv = phi i64 [ %indvars.iv.next, %46 ], [ 0, %1 ]
  %18 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  %19 = icmp ugt i64 %18, 1
  br i1 %19, label %.lr.ph, label %.critedge

._crit_edge:                                      ; preds = %46, %1
  %20 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI2PTSaIS0_EEaSERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %7)
          to label %51 unwind label %59

.lr.ph:                                           ; preds = %.preheader57, %28
  %21 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  %22 = add i64 %21, -2
  %23 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %22) #5
  %.sroa.018.0.copyload = load double, ptr %23, align 8, !tbaa !5
  %.sroa.219.0..sroa_idx = getelementptr inbounds i8, ptr %23, i64 8
  %.sroa.219.0.copyload = load double, ptr %.sroa.219.0..sroa_idx, align 8, !tbaa !5
  %24 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  %.sroa.016.0.copyload = load double, ptr %24, align 8, !tbaa !5
  %.sroa.217.0..sroa_idx = getelementptr inbounds i8, ptr %24, i64 8
  %.sroa.217.0.copyload = load double, ptr %.sroa.217.0..sroa_idx, align 8, !tbaa !5
  %25 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %indvars.iv) #5
  %.sroa.014.0.copyload = load double, ptr %25, align 8, !tbaa !5
  %.sroa.215.0..sroa_idx = getelementptr inbounds i8, ptr %25, i64 8
  %.sroa.215.0.copyload = load double, ptr %.sroa.215.0..sroa_idx, align 8, !tbaa !5
  %26 = call noundef double @_Z5area22PTS_S_(double %.sroa.018.0.copyload, double %.sroa.219.0.copyload, double %.sroa.016.0.copyload, double %.sroa.217.0.copyload, double %.sroa.014.0.copyload, double %.sroa.215.0.copyload)
  %27 = fcmp ult double %26, 0.000000e+00
  br i1 %27, label %.critedge, label %28

28:                                               ; preds = %.lr.ph
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  %29 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  %30 = icmp ugt i64 %29, 1
  br i1 %30, label %.lr.ph, label %.critedge, !llvm.loop !9

.critedge:                                        ; preds = %.lr.ph, %28, %.preheader57
  %31 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %32 = icmp ugt i64 %31, 1
  br i1 %32, label %.lr.ph59, label %.critedge2

.lr.ph59:                                         ; preds = %.critedge, %40
  %33 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %34 = add i64 %33, -2
  %35 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %34) #5
  %.sroa.012.0.copyload = load double, ptr %35, align 8, !tbaa !5
  %.sroa.213.0..sroa_idx = getelementptr inbounds i8, ptr %35, i64 8
  %.sroa.213.0.copyload = load double, ptr %.sroa.213.0..sroa_idx, align 8, !tbaa !5
  %36 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %.sroa.010.0.copyload = load double, ptr %36, align 8, !tbaa !5
  %.sroa.211.0..sroa_idx = getelementptr inbounds i8, ptr %36, i64 8
  %.sroa.211.0.copyload = load double, ptr %.sroa.211.0..sroa_idx, align 8, !tbaa !5
  %37 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %indvars.iv) #5
  %.sroa.0.0.copyload = load double, ptr %37, align 8, !tbaa !5
  %.sroa.2.0..sroa_idx = getelementptr inbounds i8, ptr %37, i64 8
  %.sroa.2.0.copyload = load double, ptr %.sroa.2.0..sroa_idx, align 8, !tbaa !5
  %38 = call noundef double @_Z5area22PTS_S_(double %.sroa.012.0.copyload, double %.sroa.213.0.copyload, double %.sroa.010.0.copyload, double %.sroa.211.0.copyload, double %.sroa.0.0.copyload, double %.sroa.2.0.copyload)
  %39 = fcmp ugt double %38, 0.000000e+00
  br i1 %39, label %.critedge2, label %40

40:                                               ; preds = %.lr.ph59
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %41 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %42 = icmp ugt i64 %41, 1
  br i1 %42, label %.lr.ph59, label %.critedge2, !llvm.loop !11

.critedge2:                                       ; preds = %.lr.ph59, %40, %.critedge
  %43 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %indvars.iv) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(16) %43)
          to label %44 unwind label %49

44:                                               ; preds = %.critedge2
  %45 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %indvars.iv) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(16) %45)
          to label %46 unwind label %49

46:                                               ; preds = %44
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %47 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %48 = icmp ugt i64 %47, %indvars.iv.next
  br i1 %48, label %.preheader57, label %._crit_edge, !llvm.loop !12

49:                                               ; preds = %44, %.critedge2
  %50 = landingpad { ptr, i32 }
          cleanup
  br label %101

51:                                               ; preds = %._crit_edge
  %52 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  %53 = trunc i64 %52 to i32
  %54 = icmp sgt i32 %53, 2
  br i1 %54, label %.lr.ph64.preheader, label %._crit_edge65

.lr.ph64.preheader:                               ; preds = %51
  %55 = add i64 %52, 4294967294
  %56 = and i64 %55, 4294967295
  br label %.lr.ph64

._crit_edge65:                                    ; preds = %62, %51
  %57 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %58 = icmp ult i64 %57, 3
  br i1 %58, label %100, label %66

59:                                               ; preds = %98, %68, %66, %._crit_edge
  %60 = landingpad { ptr, i32 }
          cleanup
  br label %101

.lr.ph64:                                         ; preds = %.lr.ph64.preheader, %62
  %indvars.iv70 = phi i64 [ %56, %.lr.ph64.preheader ], [ %indvars.iv.next71, %62 ]
  %61 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %6, i64 noundef %indvars.iv70) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(16) %61)
          to label %62 unwind label %64

62:                                               ; preds = %.lr.ph64
  %indvars.iv.next71 = add nsw i64 %indvars.iv70, -1
  %63 = icmp sgt i64 %indvars.iv70, 1
  br i1 %63, label %.lr.ph64, label %._crit_edge65, !llvm.loop !13

64:                                               ; preds = %.lr.ph64
  %65 = landingpad { ptr, i32 }
          cleanup
  br label %101

66:                                               ; preds = %._crit_edge65
  call void @_ZNSt6vectorI2PTSaIS0_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %67 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef 0) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(16) %67)
          to label %68 unwind label %59

68:                                               ; preds = %66
  %69 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef 1) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(16) %69)
          to label %.preheader unwind label %59

.preheader:                                       ; preds = %68
  %70 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %71 = icmp ugt i64 %70, 2
  br i1 %71, label %.lr.ph67, label %._crit_edge68

._crit_edge68:                                    ; preds = %85, %.preheader
  %72 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %73 = icmp ugt i64 %72, 2
  br i1 %73, label %90, label %98

.lr.ph67:                                         ; preds = %.preheader, %85
  %indvars.iv73 = phi i64 [ %indvars.iv.next74, %85 ], [ 2, %.preheader ]
  %74 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %75 = add i64 %74, -2
  %76 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %75) #5
  %77 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %78 = add i64 %77, -1
  %79 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %78) #5
  %80 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %indvars.iv73) #5
  %81 = call noundef zeroext i1 @_Z7betweenRK2PTS1_S1_(ptr noundef nonnull align 8 dereferenceable(16) %76, ptr noundef nonnull align 8 dereferenceable(16) %79, ptr noundef nonnull align 8 dereferenceable(16) %80)
  br i1 %81, label %82, label %83

82:                                               ; preds = %.lr.ph67
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  br label %83

83:                                               ; preds = %82, %.lr.ph67
  %84 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef %indvars.iv73) #5
  invoke void @_ZNSt6vectorI2PTSaIS0_EE9push_backERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(16) %84)
          to label %85 unwind label %88

85:                                               ; preds = %83
  %indvars.iv.next74 = add nuw nsw i64 %indvars.iv73, 1
  %86 = call noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #5
  %87 = icmp ugt i64 %86, %indvars.iv.next74
  br i1 %87, label %.lr.ph67, label %._crit_edge68, !llvm.loop !14

88:                                               ; preds = %83
  %89 = landingpad { ptr, i32 }
          cleanup
  br label %101

90:                                               ; preds = %._crit_edge68
  %91 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %92 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef 0) #5
  %93 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef 1) #5
  %94 = call noundef zeroext i1 @_Z7betweenRK2PTS1_S1_(ptr noundef nonnull align 8 dereferenceable(16) %91, ptr noundef nonnull align 8 dereferenceable(16) %92, ptr noundef nonnull align 8 dereferenceable(16) %93)
  br i1 %94, label %95, label %98

95:                                               ; preds = %90
  %96 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  %97 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef 0) #5
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %97, ptr noundef nonnull align 8 dereferenceable(16) %96, i64 16, i1 false), !tbaa.struct !15
  call void @_ZNSt6vectorI2PTSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  br label %98

98:                                               ; preds = %95, %90, %._crit_edge68
  %99 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI2PTSaIS0_EEaSERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %7)
          to label %100 unwind label %59

100:                                              ; preds = %98, %._crit_edge65
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #5
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #5
  ret void

101:                                              ; preds = %88, %64, %59, %49
  %.pn = phi { ptr, i32 } [ %50, %49 ], [ %65, %64 ], [ %89, %88 ], [ %60, %59 ]
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #5
  call void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #5
  resume { ptr, i32 } %.pn
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEEvT_S8_(ptr, ptr) local_unnamed_addr #3

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local ptr @_ZSt6uniqueIN9__gnu_cxx17__normal_iteratorIP2PTSt6vectorIS2_SaIS2_EEEEET_S8_S8_(ptr, ptr) local_unnamed_addr #3

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorI2PTSaIS0_EE4sizeEv(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 @_ZNSt6vectorI2PTSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #0 align 2

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorI2PTSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) 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 nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { 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 = !{!"double", !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 = distinct !{!12, !10}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = !{i64 0, i64 8, !5, i64 8, i64 8, !5}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass