; LLVM IR from DionysiosB/CodeForces :: 0300-0399 (350C-Bombs)

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

%struct.point = type { i64, i64, i64 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<point, std::allocator<point>>::_Vector_impl" }
%"struct.std::_Vector_base<point, std::allocator<point>>::_Vector_impl" = type { %"struct.std::_Vector_base<point, std::allocator<point>>::_Vector_impl_data" }
%"struct.std::_Vector_base<point, std::allocator<point>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z12pointCompare5pointS_(ptr noundef byval(%struct.point) align 8, ptr noundef byval(%struct.point) align 8) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #1 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i64, align 8
  %3 = alloca %"class.std::vector", align 8
  %4 = alloca %"class.std::allocator", align 1
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %13 = alloca i32, align 4
  %14 = alloca i8, align 1
  %15 = alloca i8, align 1
  %16 = alloca i8, align 1
  %17 = alloca i8, align 1
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #7
  %20 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2)
  call void @llvm.lifetime.start.p0(i64 24, ptr %3) #7
  %21 = load i64, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %4) #7
  call void @_ZNSaI5pointEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #7
  invoke void @_ZNSt6vectorI5pointSaIS0_EEC2EmRKS1_(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %21, ptr noundef nonnull align 1 dereferenceable(1) %4)
          to label %22 unwind label %28

22:                                               ; preds = %0
  call void @_ZNSt15__new_allocatorI5pointED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %4) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #7
  store i64 0, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #7
  store i64 0, ptr %8, align 8, !tbaa !5
  br label %23

23:                                               ; preds = %64, %22
  %24 = load i64, ptr %8, align 8, !tbaa !5
  %25 = load i64, ptr %2, align 8, !tbaa !5
  %26 = icmp slt i64 %24, %25
  br i1 %26, label %32, label %27

27:                                               ; preds = %23
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #7
  br label %71

28:                                               ; preds = %0
  %29 = landingpad { ptr, i32 }
          cleanup
  %30 = extractvalue { ptr, i32 } %29, 0
  store ptr %30, ptr %5, align 8
  %31 = extractvalue { ptr, i32 } %29, 1
  store i32 %31, ptr %6, align 4
  call void @_ZNSt15__new_allocatorI5pointED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %4) #7
  br label %175

32:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #7
  %33 = invoke i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %9, ptr noundef %10)
          to label %34 unwind label %67

34:                                               ; preds = %32
  %35 = load i64, ptr %9, align 8, !tbaa !5
  %36 = load i64, ptr %8, align 8, !tbaa !5
  %37 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %36) #7
  %38 = getelementptr inbounds %struct.point, ptr %37, i32 0, i32 0
  store i64 %35, ptr %38, align 8, !tbaa !9
  %39 = load i64, ptr %10, align 8, !tbaa !5
  %40 = load i64, ptr %8, align 8, !tbaa !5
  %41 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %40) #7
  %42 = getelementptr inbounds %struct.point, ptr %41, i32 0, i32 1
  store i64 %39, ptr %42, align 8, !tbaa !11
  %43 = load i64, ptr %9, align 8, !tbaa !5
  %44 = call i64 @llvm.abs.i64(i64 %43, i1 true)
  %45 = load i64, ptr %10, align 8, !tbaa !5
  %46 = call i64 @llvm.abs.i64(i64 %45, i1 true)
  %47 = add nsw i64 %44, %46
  %48 = load i64, ptr %8, align 8, !tbaa !5
  %49 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %48) #7
  %50 = getelementptr inbounds %struct.point, ptr %49, i32 0, i32 2
  store i64 %47, ptr %50, align 8, !tbaa !12
  %51 = load i64, ptr %9, align 8, !tbaa !5
  %52 = icmp ne i64 %51, 0
  %53 = zext i1 %52 to i32
  %54 = mul nsw i32 2, %53
  %55 = load i64, ptr %10, align 8, !tbaa !5
  %56 = icmp ne i64 %55, 0
  %57 = zext i1 %56 to i32
  %58 = mul nsw i32 2, %57
  %59 = add nsw i32 %54, %58
  %60 = add nsw i32 %59, 2
  %61 = sext i32 %60 to i64
  %62 = load i64, ptr %7, align 8, !tbaa !5
  %63 = add nsw i64 %62, %61
  store i64 %63, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  br label %64

64:                                               ; preds = %34
  %65 = load i64, ptr %8, align 8, !tbaa !5
  %66 = add nsw i64 %65, 1
  store i64 %66, ptr %8, align 8, !tbaa !5
  br label %23, !llvm.loop !13

67:                                               ; preds = %32
  %68 = landingpad { ptr, i32 }
          cleanup
  %69 = extractvalue { ptr, i32 } %68, 0
  store ptr %69, ptr %5, align 8
  %70 = extractvalue { ptr, i32 } %68, 1
  store i32 %70, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #7
  br label %174

71:                                               ; preds = %27
  %72 = load i64, ptr %7, align 8, !tbaa !5
  %73 = invoke i32 (ptr, ...) @printf(ptr noundef @.str, i64 noundef %72)
          to label %74 unwind label %90

74:                                               ; preds = %71
  %75 = call ptr @_ZNSt6vectorI5pointSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %76 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %11, i32 0, i32 0
  store ptr %75, ptr %76, align 8
  %77 = call ptr @_ZNSt6vectorI5pointSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  %78 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %12, i32 0, i32 0
  store ptr %77, ptr %78, align 8
  %79 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %11, i32 0, i32 0
  %80 = load ptr, ptr %79, align 8
  %81 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %12, i32 0, i32 0
  %82 = load ptr, ptr %81, align 8
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP5pointSt6vectorIS2_SaIS2_EEEEPFbS2_S2_EEvT_SA_T0_(ptr %80, ptr %82, ptr noundef @_Z12pointCompare5pointS_)
          to label %83 unwind label %90

83:                                               ; preds = %74
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  store i32 0, ptr %13, align 4, !tbaa !15
  br label %84

84:                                               ; preds = %169, %83
  %85 = load i32, ptr %13, align 4, !tbaa !15
  %86 = sext i32 %85 to i64
  %87 = load i64, ptr %2, align 8, !tbaa !5
  %88 = icmp slt i64 %86, %87
  br i1 %88, label %94, label %89

89:                                               ; preds = %84
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %172

90:                                               ; preds = %74, %71
  %91 = landingpad { ptr, i32 }
          cleanup
  %92 = extractvalue { ptr, i32 } %91, 0
  store ptr %92, ptr %5, align 8
  %93 = extractvalue { ptr, i32 } %91, 1
  store i32 %93, ptr %6, align 4
  br label %174

94:                                               ; preds = %84
  call void @llvm.lifetime.start.p0(i64 1, ptr %14) #7
  call void @llvm.lifetime.start.p0(i64 1, ptr %15) #7
  call void @llvm.lifetime.start.p0(i64 1, ptr %16) #7
  call void @llvm.lifetime.start.p0(i64 1, ptr %17) #7
  %95 = load i32, ptr %13, align 4, !tbaa !15
  %96 = sext i32 %95 to i64
  %97 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %96) #7
  %98 = getelementptr inbounds %struct.point, ptr %97, i32 0, i32 0
  %99 = load i64, ptr %98, align 8, !tbaa !9
  %100 = icmp sgt i64 %99, 0
  br i1 %100, label %101, label %102

101:                                              ; preds = %94
  store i8 82, ptr %14, align 1, !tbaa !17
  store i8 76, ptr %15, align 1, !tbaa !17
  br label %103

102:                                              ; preds = %94
  store i8 76, ptr %14, align 1, !tbaa !17
  store i8 82, ptr %15, align 1, !tbaa !17
  br label %103

103:                                              ; preds = %102, %101
  %104 = load i32, ptr %13, align 4, !tbaa !15
  %105 = sext i32 %104 to i64
  %106 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %105) #7
  %107 = getelementptr inbounds %struct.point, ptr %106, i32 0, i32 1
  %108 = load i64, ptr %107, align 8, !tbaa !11
  %109 = icmp sgt i64 %108, 0
  br i1 %109, label %110, label %111

110:                                              ; preds = %103
  store i8 85, ptr %16, align 1, !tbaa !17
  store i8 68, ptr %17, align 1, !tbaa !17
  br label %112

111:                                              ; preds = %103
  store i8 68, ptr %16, align 1, !tbaa !17
  store i8 85, ptr %17, align 1, !tbaa !17
  br label %112

112:                                              ; preds = %111, %110
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #7
  %113 = load i32, ptr %13, align 4, !tbaa !15
  %114 = sext i32 %113 to i64
  %115 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %114) #7
  %116 = getelementptr inbounds %struct.point, ptr %115, i32 0, i32 0
  %117 = load i64, ptr %116, align 8, !tbaa !9
  %118 = call i64 @llvm.abs.i64(i64 %117, i1 true)
  store i64 %118, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #7
  %119 = load i32, ptr %13, align 4, !tbaa !15
  %120 = sext i32 %119 to i64
  %121 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %120) #7
  %122 = getelementptr inbounds %struct.point, ptr %121, i32 0, i32 1
  %123 = load i64, ptr %122, align 8, !tbaa !11
  %124 = call i64 @llvm.abs.i64(i64 %123, i1 true)
  store i64 %124, ptr %19, align 8, !tbaa !5
  %125 = load i64, ptr %18, align 8, !tbaa !5
  %126 = icmp sgt i64 %125, 0
  br i1 %126, label %127, label %137

127:                                              ; preds = %112
  %128 = load i64, ptr %18, align 8, !tbaa !5
  %129 = load i8, ptr %14, align 1, !tbaa !17
  %130 = sext i8 %129 to i32
  %131 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %128, i32 noundef %130)
          to label %132 unwind label %133

132:                                              ; preds = %127
  br label %137

133:                                              ; preds = %166, %160, %151, %146, %140, %127
  %134 = landingpad { ptr, i32 }
          cleanup
  %135 = extractvalue { ptr, i32 } %134, 0
  store ptr %135, ptr %5, align 8
  %136 = extractvalue { ptr, i32 } %134, 1
  store i32 %136, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %174

137:                                              ; preds = %132, %112
  %138 = load i64, ptr %19, align 8, !tbaa !5
  %139 = icmp sgt i64 %138, 0
  br i1 %139, label %140, label %146

140:                                              ; preds = %137
  %141 = load i64, ptr %19, align 8, !tbaa !5
  %142 = load i8, ptr %16, align 1, !tbaa !17
  %143 = sext i8 %142 to i32
  %144 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %141, i32 noundef %143)
          to label %145 unwind label %133

145:                                              ; preds = %140
  br label %146

146:                                              ; preds = %145, %137
  %147 = invoke i32 @puts(ptr noundef @.str.3)
          to label %148 unwind label %133

148:                                              ; preds = %146
  %149 = load i64, ptr %18, align 8, !tbaa !5
  %150 = icmp sgt i64 %149, 0
  br i1 %150, label %151, label %157

151:                                              ; preds = %148
  %152 = load i64, ptr %18, align 8, !tbaa !5
  %153 = load i8, ptr %15, align 1, !tbaa !17
  %154 = sext i8 %153 to i32
  %155 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %152, i32 noundef %154)
          to label %156 unwind label %133

156:                                              ; preds = %151
  br label %157

157:                                              ; preds = %156, %148
  %158 = load i64, ptr %19, align 8, !tbaa !5
  %159 = icmp sgt i64 %158, 0
  br i1 %159, label %160, label %166

160:                                              ; preds = %157
  %161 = load i64, ptr %19, align 8, !tbaa !5
  %162 = load i8, ptr %17, align 1, !tbaa !17
  %163 = sext i8 %162 to i32
  %164 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %161, i32 noundef %163)
          to label %165 unwind label %133

165:                                              ; preds = %160
  br label %166

166:                                              ; preds = %165, %157
  %167 = invoke i32 @puts(ptr noundef @.str.4)
          to label %168 unwind label %133

168:                                              ; preds = %166
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #7
  br label %169

169:                                              ; preds = %168
  %170 = load i32, ptr %13, align 4, !tbaa !15
  %171 = add nsw i32 %170, 1
  store i32 %171, ptr %13, align 4, !tbaa !15
  br label %84, !llvm.loop !18

172:                                              ; preds = %89
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #7
  call void @_ZNSt6vectorI5pointSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #7
  %173 = load i32, ptr %1, align 4
  ret i32 %173

174:                                              ; preds = %133, %90, %67
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #7
  call void @_ZNSt6vectorI5pointSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #7
  br label %175

175:                                              ; preds = %174, %28
  call void @llvm.lifetime.end.p0(i64 24, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #7
  br label %176

176:                                              ; preds = %175
  %177 = load ptr, ptr %5, align 8
  %178 = load i32, ptr %6, align 4
  %179 = insertvalue { ptr, i32 } poison, ptr %177, 0
  %180 = insertvalue { ptr, i32 } %179, i32 %178, 1
  resume { ptr, i32 } %180
}

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.abs.i64(i64, i1 immarg) #5

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

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

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

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

declare i32 @puts(ptr noundef) #3

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

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


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

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

@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_Z12pointCompare5pointS_(ptr noundef byval(%struct.point) align 8, ptr noundef byval(%struct.point) align 8) #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #1 personality ptr @__gxx_personality_v0 {
  %1 = alloca i64, align 8
  %2 = alloca %"class.std::vector", align 8
  %3 = alloca %"class.std::allocator", align 1
  %4 = alloca i64, align 8
  %5 = alloca i64, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #7
  %6 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull %1)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %2) #7
  %7 = load i64, ptr %1, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %3) #7
  call void @_ZNSaI5pointEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %3) #7
  invoke void @_ZNSt6vectorI5pointSaIS0_EEC2EmRKS1_(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %7, ptr noundef nonnull align 1 dereferenceable(1) %3)
          to label %8 unwind label %16

8:                                                ; preds = %0
  call void @_ZNSt15__new_allocatorI5pointED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %3) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %3) #7
  %9 = load i64, ptr %1, align 8, !tbaa !5
  %10 = icmp sgt i64 %9, 0
  br i1 %10, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph, %8
  %.034.lcssa = phi i64 [ 0, %8 ], [ %37, %.lr.ph ]
  %11 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str, i64 noundef %.034.lcssa)
  %12 = call ptr @_ZNSt6vectorI5pointSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #7
  %13 = call ptr @_ZNSt6vectorI5pointSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #7
  invoke void @_ZSt4sortIN9__gnu_cxx17__normal_iteratorIP5pointSt6vectorIS2_SaIS2_EEEEPFbS2_S2_EEvT_SA_T0_(ptr %12, ptr %13, ptr noundef nonnull @_Z12pointCompare5pointS_)
          to label %.preheader unwind label %41

.preheader:                                       ; preds = %._crit_edge
  %14 = load i64, ptr %1, align 8, !tbaa !5
  %15 = icmp sgt i64 %14, 0
  br i1 %15, label %.lr.ph48, label %._crit_edge49

16:                                               ; preds = %0
  %17 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorI5pointED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %3) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %3) #7
  br label %73

.lr.ph:                                           ; preds = %8, %.lr.ph
  %.03446 = phi i64 [ %37, %.lr.ph ], [ 0, %8 ]
  %.03545 = phi i64 [ %38, %.lr.ph ], [ 0, %8 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #7
  %18 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %4, ptr noundef nonnull %5)
  %19 = load i64, ptr %4, align 8, !tbaa !5
  %20 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03545) #7
  store i64 %19, ptr %20, align 8, !tbaa !9
  %21 = load i64, ptr %5, align 8, !tbaa !5
  %22 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03545) #7
  %23 = getelementptr inbounds i8, ptr %22, i64 8
  store i64 %21, ptr %23, align 8, !tbaa !11
  %24 = load i64, ptr %4, align 8, !tbaa !5
  %25 = call i64 @llvm.abs.i64(i64 %24, i1 true)
  %26 = load i64, ptr %5, align 8, !tbaa !5
  %27 = call i64 @llvm.abs.i64(i64 %26, i1 true)
  %28 = add nuw nsw i64 %27, %25
  %29 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03545) #7
  %30 = getelementptr inbounds i8, ptr %29, i64 16
  store i64 %28, ptr %30, align 8, !tbaa !12
  %31 = load i64, ptr %4, align 8, !tbaa !5
  %.not42 = icmp eq i64 %31, 0
  %32 = select i1 %.not42, i64 0, i64 2
  %33 = load i64, ptr %5, align 8, !tbaa !5
  %.not43 = icmp eq i64 %33, 0
  %34 = select i1 %.not43, i64 0, i64 2
  %35 = add nuw nsw i64 %.03446, 2
  %36 = add nuw nsw i64 %35, %32
  %37 = add nuw nsw i64 %36, %34
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  %38 = add nuw nsw i64 %.03545, 1
  %39 = load i64, ptr %1, align 8, !tbaa !5
  %40 = icmp slt i64 %38, %39
  br i1 %40, label %.lr.ph, label %._crit_edge, !llvm.loop !13

._crit_edge49:                                    ; preds = %69, %.preheader
  call void @_ZNSt6vectorI5pointSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #7
  ret i32 0

41:                                               ; preds = %._crit_edge
  %42 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorI5pointSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #7
  br label %73

.lr.ph48:                                         ; preds = %.preheader, %69
  %indvars.iv = phi i64 [ %indvars.iv.next, %69 ], [ 0, %.preheader ]
  %43 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %indvars.iv) #7
  %44 = load i64, ptr %43, align 8, !tbaa !9
  %45 = icmp sgt i64 %44, 0
  %.44 = select i1 %45, i32 76, i32 82
  %46 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %indvars.iv) #7
  %47 = getelementptr inbounds i8, ptr %46, i64 8
  %48 = load i64, ptr %47, align 8, !tbaa !11
  %49 = icmp sgt i64 %48, 0
  %.029 = select i1 %49, i32 85, i32 68
  %.028 = select i1 %49, i32 68, i32 85
  %50 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %indvars.iv) #7
  %51 = load i64, ptr %50, align 8, !tbaa !9
  %52 = call i64 @llvm.abs.i64(i64 %51, i1 true)
  %53 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorI5pointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %indvars.iv) #7
  %54 = getelementptr inbounds i8, ptr %53, i64 8
  %55 = load i64, ptr %54, align 8, !tbaa !11
  %56 = call i64 @llvm.abs.i64(i64 %55, i1 true)
  %.not = icmp eq i64 %51, 0
  br i1 %.not, label %59, label %57

57:                                               ; preds = %.lr.ph48
  %. = select i1 %45, i32 82, i32 76
  %58 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %52, i32 noundef %.)
  br label %59

59:                                               ; preds = %57, %.lr.ph48
  %.not41 = icmp eq i64 %55, 0
  br i1 %.not41, label %62, label %60

60:                                               ; preds = %59
  %61 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %56, i32 noundef %.029)
  br label %62

62:                                               ; preds = %60, %59
  %63 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  br i1 %.not, label %66, label %64

64:                                               ; preds = %62
  %65 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %52, i32 noundef %.44)
  br label %66

66:                                               ; preds = %64, %62
  br i1 %.not41, label %69, label %67

67:                                               ; preds = %66
  %68 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %56, i32 noundef %.028)
  br label %69

69:                                               ; preds = %67, %66
  %70 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.4)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %71 = load i64, ptr %1, align 8, !tbaa !5
  %72 = icmp sgt i64 %71, %indvars.iv.next
  br i1 %72, label %.lr.ph48, label %._crit_edge49, !llvm.loop !15

73:                                               ; preds = %41, %16
  %.pn = phi { ptr, i32 } [ %42, %41 ], [ %17, %16 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #7
  resume { ptr, i32 } %.pn
}

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

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

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

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.abs.i64(i64, i1 immarg) #5

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

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

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

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

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

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

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


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass