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

; 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.Vector = type { i32, i32, i32 }
%struct.Point = type { i32, i32 }

@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@a = external dso_local global [2 x [651 x i32]], align 16
@f = external dso_local global [2 x [651 x [651 x i32]]], align 16
@ord = external dso_local global [651 x i32], align 16
@ans = external dso_local global [651 x i32], align 16
@que = external dso_local global [651 x %struct.Vector], align 16
@tot = external dso_local global i32, align 4
@p = external dso_local global [651 x %struct.Point], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

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

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

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca i32, align 4
  %29 = alloca i32, align 4
  %30 = alloca i32, align 4
  %31 = alloca i32, align 4
  %32 = alloca i32, align 4
  %33 = alloca i32, align 4
  %34 = alloca i32, align 4
  %35 = alloca i32, align 4
  %36 = alloca i32, align 4
  %37 = alloca i32, align 4
  %38 = alloca i32, align 4
  %39 = alloca i32, align 4
  %40 = alloca i32, align 4
  %41 = alloca i32, align 4
  %42 = alloca i32, align 4
  %43 = alloca i32, align 4
  %44 = alloca i32, align 4
  %45 = alloca i32, align 4
  %46 = alloca i32, align 4
  %47 = alloca i32, align 4
  %48 = alloca i32, align 4
  %49 = alloca i32, align 4
  %50 = alloca i32, align 4
  %51 = alloca i32, align 4
  %52 = alloca %struct.Point, align 4
  %53 = alloca %struct.Point, align 4
  %54 = alloca %struct.Point, align 4
  %55 = alloca i32, align 4
  %56 = alloca i32, align 4
  %57 = alloca i32, align 4
  %58 = alloca i32, align 4
  %59 = alloca i32, align 4
  %60 = alloca i32, align 4
  %61 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  %62 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n, ptr noundef @m)
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #9
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %63

63:                                               ; preds = %86, %0
  %64 = load i32, ptr %2, align 4, !tbaa !5
  %65 = icmp slt i32 %64, 2
  br i1 %65, label %67, label %66

66:                                               ; preds = %63
  store i32 2, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #9
  br label %89

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

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

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

73:                                               ; preds = %68
  %74 = load i32, ptr %2, align 4, !tbaa !5
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds [2 x [651 x i32]], ptr @a, i64 0, i64 %75
  %77 = getelementptr inbounds [651 x i32], ptr %76, i64 0, i64 0
  %78 = load i32, ptr %4, align 4, !tbaa !5
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds i32, ptr %77, i64 %79
  %81 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.1, ptr noundef %80)
  br label %82

82:                                               ; preds = %73
  %83 = load i32, ptr %4, align 4, !tbaa !5
  %84 = add nsw i32 %83, 1
  store i32 %84, ptr %4, align 4, !tbaa !5
  br label %68, !llvm.loop !9

85:                                               ; preds = %72
  br label %86

86:                                               ; preds = %85
  %87 = load i32, ptr %2, align 4, !tbaa !5
  %88 = add nsw i32 %87, 1
  store i32 %88, ptr %2, align 4, !tbaa !5
  br label %63, !llvm.loop !11

89:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #9
  store i32 0, ptr %5, align 4, !tbaa !5
  br label %90

90:                                               ; preds = %106, %89
  %91 = load i32, ptr %5, align 4, !tbaa !5
  %92 = load i32, ptr @m, align 4, !tbaa !5
  %93 = icmp slt i32 %91, %92
  br i1 %93, label %95, label %94

94:                                               ; preds = %90
  store i32 8, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #9
  br label %109

95:                                               ; preds = %90
  %96 = load i32, ptr %5, align 4, !tbaa !5
  %97 = sext i32 %96 to i64
  %98 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %97
  call void @_ZN6Vector4readEv(ptr noundef nonnull align 4 dereferenceable(12) %98)
  %99 = load i32, ptr %5, align 4, !tbaa !5
  %100 = load i32, ptr %5, align 4, !tbaa !5
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds [651 x i32], ptr @ord, i64 0, i64 %101
  store i32 %99, ptr %102, align 4, !tbaa !5
  %103 = load i32, ptr %5, align 4, !tbaa !5
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %104
  store i32 -1061109567, ptr %105, align 4, !tbaa !5
  br label %106

106:                                              ; preds = %95
  %107 = load i32, ptr %5, align 4, !tbaa !5
  %108 = add nsw i32 %107, 1
  store i32 %108, ptr %5, align 4, !tbaa !5
  br label %90, !llvm.loop !12

109:                                              ; preds = %94
  %110 = load i32, ptr @m, align 4, !tbaa !5
  %111 = sext i32 %110 to i64
  %112 = getelementptr inbounds i32, ptr @ord, i64 %111
  call void @_ZSt4sortIPiPFbRKiS2_EEvT_S5_T0_(ptr noundef @ord, ptr noundef %112, ptr noundef @_Z3cmpRKiS0_)
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #9
  store i32 1, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #9
  store i32 0, ptr %11, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #9
  store i32 0, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #9
  store i32 0, ptr %13, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #9
  store i32 0, ptr %14, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #9
  store i32 0, ptr %15, align 4, !tbaa !5
  %113 = load i32, ptr %11, align 4, !tbaa !5
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %114
  %116 = getelementptr inbounds [651 x [651 x i32]], ptr %115, i64 0, i64 0
  %117 = getelementptr inbounds [651 x i32], ptr %116, i64 0, i64 0
  store i32 0, ptr %117, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #9
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %118

118:                                              ; preds = %361, %109
  %119 = load i32, ptr %16, align 4, !tbaa !5
  %120 = load i32, ptr @n, align 4, !tbaa !5
  %121 = icmp slt i32 %119, %120
  br i1 %121, label %123, label %122

122:                                              ; preds = %118
  store i32 11, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #9
  br label %364

123:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #9
  %124 = load i32, ptr %16, align 4, !tbaa !5
  %125 = sext i32 %124 to i64
  %126 = getelementptr inbounds [651 x i32], ptr @a, i64 0, i64 %125
  %127 = load i32, ptr %126, align 4, !tbaa !5
  store i32 %127, ptr %17, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #9
  %128 = load i32, ptr %17, align 4, !tbaa !5
  %129 = call i32 @llvm.abs.i32(i32 %128, i1 true)
  store i32 %129, ptr %18, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #9
  %130 = load i32, ptr %17, align 4, !tbaa !5
  %131 = sdiv i32 %130, 4
  store i32 %131, ptr %19, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #9
  %132 = load i32, ptr %17, align 4, !tbaa !5
  %133 = sdiv i32 %132, 6
  store i32 %133, ptr %20, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #9
  %134 = load i32, ptr %16, align 4, !tbaa !5
  %135 = sext i32 %134 to i64
  %136 = getelementptr inbounds [651 x i32], ptr getelementptr inbounds ([2 x [651 x i32]], ptr @a, i64 0, i64 1), i64 0, i64 %135
  %137 = load i32, ptr %136, align 4, !tbaa !5
  store i32 %137, ptr %21, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #9
  %138 = load i32, ptr %21, align 4, !tbaa !5
  %139 = call i32 @llvm.abs.i32(i32 %138, i1 true)
  store i32 %139, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #9
  %140 = load i32, ptr %21, align 4, !tbaa !5
  %141 = sdiv i32 %140, 3
  store i32 %141, ptr %23, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #9
  %142 = load i32, ptr %21, align 4, !tbaa !5
  %143 = sdiv i32 %142, 6
  store i32 %143, ptr %24, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #9
  %144 = load i32, ptr %21, align 4, !tbaa !5
  %145 = sdiv i32 %144, 9
  store i32 %145, ptr %25, align 4, !tbaa !5
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %11, ptr noundef nonnull align 4 dereferenceable(4) %6) #9
  %146 = load i32, ptr %12, align 4, !tbaa !5
  store i32 %146, ptr %7, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #9
  store i32 -1, ptr %26, align 4, !tbaa !5
  %147 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %26, ptr noundef nonnull align 4 dereferenceable(4) %24)
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #9
  %148 = load i32, ptr %25, align 4, !tbaa !5
  %149 = add nsw i32 -1, %148
  store i32 %149, ptr %27, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #9
  %150 = load i32, ptr %23, align 4, !tbaa !5
  %151 = add nsw i32 2, %150
  store i32 %151, ptr %28, align 4, !tbaa !5
  %152 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %27, ptr noundef nonnull align 4 dereferenceable(4) %28)
  %153 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %147, ptr noundef nonnull align 4 dereferenceable(4) %152)
  %154 = load i32, ptr %153, align 4, !tbaa !5
  %155 = load i32, ptr %12, align 4, !tbaa !5
  %156 = add nsw i32 %155, %154
  store i32 %156, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #9
  %157 = load i32, ptr %13, align 4, !tbaa !5
  store i32 %157, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #9
  store i32 -1, ptr %29, align 4, !tbaa !5
  %158 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %29, ptr noundef nonnull align 4 dereferenceable(4) %24)
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #9
  %159 = load i32, ptr %25, align 4, !tbaa !5
  %160 = add nsw i32 -1, %159
  store i32 %160, ptr %30, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #9
  %161 = load i32, ptr %23, align 4, !tbaa !5
  %162 = add nsw i32 2, %161
  store i32 %162, ptr %31, align 4, !tbaa !5
  %163 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %30, ptr noundef nonnull align 4 dereferenceable(4) %31)
  %164 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %158, ptr noundef nonnull align 4 dereferenceable(4) %163)
  %165 = load i32, ptr %164, align 4, !tbaa !5
  %166 = load i32, ptr %13, align 4, !tbaa !5
  %167 = add nsw i32 %166, %165
  store i32 %167, ptr %13, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #9
  %168 = load i32, ptr %14, align 4, !tbaa !5
  store i32 %168, ptr %9, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %32) #9
  store i32 -1, ptr %32, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %33) #9
  %169 = load i32, ptr %19, align 4, !tbaa !5
  %170 = sub nsw i32 0, %169
  store i32 %170, ptr %33, align 4, !tbaa !5
  %171 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %32, ptr noundef nonnull align 4 dereferenceable(4) %33)
  call void @llvm.lifetime.start.p0(i64 4, ptr %34) #9
  %172 = load i32, ptr %19, align 4, !tbaa !5
  %173 = add nsw i32 3, %172
  store i32 %173, ptr %34, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %35) #9
  %174 = load i32, ptr %20, align 4, !tbaa !5
  %175 = add nsw i32 -1, %174
  store i32 %175, ptr %35, align 4, !tbaa !5
  %176 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %34, ptr noundef nonnull align 4 dereferenceable(4) %35)
  %177 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %171, ptr noundef nonnull align 4 dereferenceable(4) %176)
  %178 = load i32, ptr %177, align 4, !tbaa !5
  %179 = load i32, ptr %14, align 4, !tbaa !5
  %180 = add nsw i32 %179, %178
  store i32 %180, ptr %14, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %35) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %32) #9
  %181 = load i32, ptr %15, align 4, !tbaa !5
  store i32 %181, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %36) #9
  store i32 -1, ptr %36, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %37) #9
  %182 = load i32, ptr %19, align 4, !tbaa !5
  %183 = sub nsw i32 0, %182
  store i32 %183, ptr %37, align 4, !tbaa !5
  %184 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %36, ptr noundef nonnull align 4 dereferenceable(4) %37)
  call void @llvm.lifetime.start.p0(i64 4, ptr %38) #9
  %185 = load i32, ptr %19, align 4, !tbaa !5
  %186 = add nsw i32 3, %185
  store i32 %186, ptr %38, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %39) #9
  %187 = load i32, ptr %20, align 4, !tbaa !5
  %188 = add nsw i32 -1, %187
  store i32 %188, ptr %39, align 4, !tbaa !5
  %189 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %38, ptr noundef nonnull align 4 dereferenceable(4) %39)
  %190 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %184, ptr noundef nonnull align 4 dereferenceable(4) %189)
  %191 = load i32, ptr %190, align 4, !tbaa !5
  %192 = load i32, ptr %15, align 4, !tbaa !5
  %193 = add nsw i32 %192, %191
  store i32 %193, ptr %15, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %39) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %38) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %37) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %40) #9
  store i32 0, ptr %40, align 4, !tbaa !5
  br label %194

194:                                              ; preds = %223, %123
  %195 = load i32, ptr %40, align 4, !tbaa !5
  %196 = load i32, ptr %13, align 4, !tbaa !5
  %197 = load i32, ptr %12, align 4, !tbaa !5
  %198 = sub nsw i32 %196, %197
  %199 = icmp sle i32 %195, %198
  br i1 %199, label %201, label %200

200:                                              ; preds = %194
  store i32 14, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %40) #9
  br label %226

201:                                              ; preds = %194
  call void @llvm.lifetime.start.p0(i64 4, ptr %41) #9
  store i32 0, ptr %41, align 4, !tbaa !5
  br label %202

202:                                              ; preds = %219, %201
  %203 = load i32, ptr %41, align 4, !tbaa !5
  %204 = load i32, ptr %15, align 4, !tbaa !5
  %205 = load i32, ptr %14, align 4, !tbaa !5
  %206 = sub nsw i32 %204, %205
  %207 = icmp sle i32 %203, %206
  br i1 %207, label %209, label %208

208:                                              ; preds = %202
  store i32 17, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %41) #9
  br label %222

209:                                              ; preds = %202
  %210 = load i32, ptr %11, align 4, !tbaa !5
  %211 = sext i32 %210 to i64
  %212 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %211
  %213 = load i32, ptr %40, align 4, !tbaa !5
  %214 = sext i32 %213 to i64
  %215 = getelementptr inbounds [651 x [651 x i32]], ptr %212, i64 0, i64 %214
  %216 = load i32, ptr %41, align 4, !tbaa !5
  %217 = sext i32 %216 to i64
  %218 = getelementptr inbounds [651 x i32], ptr %215, i64 0, i64 %217
  store i32 -1061109567, ptr %218, align 4, !tbaa !5
  br label %219

219:                                              ; preds = %209
  %220 = load i32, ptr %41, align 4, !tbaa !5
  %221 = add nsw i32 %220, 1
  store i32 %221, ptr %41, align 4, !tbaa !5
  br label %202, !llvm.loop !13

222:                                              ; preds = %208
  br label %223

223:                                              ; preds = %222
  %224 = load i32, ptr %40, align 4, !tbaa !5
  %225 = add nsw i32 %224, 1
  store i32 %225, ptr %40, align 4, !tbaa !5
  br label %194, !llvm.loop !14

226:                                              ; preds = %200
  call void @llvm.lifetime.start.p0(i64 4, ptr %42) #9
  store i32 0, ptr %42, align 4, !tbaa !5
  br label %227

227:                                              ; preds = %357, %226
  %228 = load i32, ptr %42, align 4, !tbaa !5
  %229 = load i32, ptr %8, align 4, !tbaa !5
  %230 = load i32, ptr %7, align 4, !tbaa !5
  %231 = sub nsw i32 %229, %230
  %232 = icmp sle i32 %228, %231
  br i1 %232, label %234, label %233

233:                                              ; preds = %227
  store i32 20, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %42) #9
  br label %360

234:                                              ; preds = %227
  call void @llvm.lifetime.start.p0(i64 4, ptr %43) #9
  store i32 0, ptr %43, align 4, !tbaa !5
  br label %235

235:                                              ; preds = %353, %234
  %236 = load i32, ptr %43, align 4, !tbaa !5
  %237 = load i32, ptr %10, align 4, !tbaa !5
  %238 = load i32, ptr %9, align 4, !tbaa !5
  %239 = sub nsw i32 %237, %238
  %240 = icmp sle i32 %236, %239
  br i1 %240, label %242, label %241

241:                                              ; preds = %235
  store i32 23, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %43) #9
  br label %356

242:                                              ; preds = %235
  call void @llvm.lifetime.start.p0(i64 4, ptr %44) #9
  %243 = load i32, ptr %6, align 4, !tbaa !5
  %244 = sext i32 %243 to i64
  %245 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %244
  %246 = load i32, ptr %42, align 4, !tbaa !5
  %247 = sext i32 %246 to i64
  %248 = getelementptr inbounds [651 x [651 x i32]], ptr %245, i64 0, i64 %247
  %249 = load i32, ptr %43, align 4, !tbaa !5
  %250 = sext i32 %249 to i64
  %251 = getelementptr inbounds [651 x i32], ptr %248, i64 0, i64 %250
  %252 = load i32, ptr %251, align 4, !tbaa !5
  store i32 %252, ptr %44, align 4, !tbaa !5
  %253 = load i32, ptr %44, align 4, !tbaa !5
  %254 = icmp eq i32 %253, -1061109567
  br i1 %254, label %255, label %256

255:                                              ; preds = %242
  store i32 25, ptr %3, align 4
  br label %350

256:                                              ; preds = %242
  call void @llvm.lifetime.start.p0(i64 4, ptr %45) #9
  %257 = load i32, ptr %42, align 4, !tbaa !5
  %258 = load i32, ptr %7, align 4, !tbaa !5
  %259 = add nsw i32 %257, %258
  store i32 %259, ptr %45, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %46) #9
  %260 = load i32, ptr %45, align 4, !tbaa !5
  %261 = load i32, ptr %12, align 4, !tbaa !5
  %262 = sub nsw i32 %260, %261
  store i32 %262, ptr %46, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %47) #9
  %263 = load i32, ptr %43, align 4, !tbaa !5
  %264 = load i32, ptr %9, align 4, !tbaa !5
  %265 = add nsw i32 %263, %264
  store i32 %265, ptr %47, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %48) #9
  %266 = load i32, ptr %47, align 4, !tbaa !5
  %267 = load i32, ptr %14, align 4, !tbaa !5
  %268 = sub nsw i32 %266, %267
  store i32 %268, ptr %48, align 4, !tbaa !5
  %269 = load i32, ptr %11, align 4, !tbaa !5
  %270 = sext i32 %269 to i64
  %271 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %270
  %272 = load i32, ptr %46, align 4, !tbaa !5
  %273 = sub nsw i32 %272, 1
  %274 = sext i32 %273 to i64
  %275 = getelementptr inbounds [651 x [651 x i32]], ptr %271, i64 0, i64 %274
  %276 = load i32, ptr %48, align 4, !tbaa !5
  %277 = sub nsw i32 %276, 1
  %278 = sext i32 %277 to i64
  %279 = getelementptr inbounds [651 x i32], ptr %275, i64 0, i64 %278
  %280 = load i32, ptr %44, align 4, !tbaa !5
  %281 = mul nsw i32 %280, 4
  %282 = sdiv i32 %281, 5
  %283 = add nsw i32 %282, 3
  %284 = load i32, ptr %45, align 4, !tbaa !5
  %285 = sdiv i32 %284, 6
  %286 = add nsw i32 %283, %285
  %287 = load i32, ptr %47, align 4, !tbaa !5
  %288 = sdiv i32 %287, 6
  %289 = add nsw i32 %286, %288
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %279, i32 noundef %289)
  %290 = load i32, ptr %11, align 4, !tbaa !5
  %291 = sext i32 %290 to i64
  %292 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %291
  %293 = load i32, ptr %46, align 4, !tbaa !5
  %294 = load i32, ptr %24, align 4, !tbaa !5
  %295 = add nsw i32 %293, %294
  %296 = sext i32 %295 to i64
  %297 = getelementptr inbounds [651 x [651 x i32]], ptr %292, i64 0, i64 %296
  %298 = load i32, ptr %48, align 4, !tbaa !5
  %299 = load i32, ptr %19, align 4, !tbaa !5
  %300 = sub nsw i32 %298, %299
  %301 = sext i32 %300 to i64
  %302 = getelementptr inbounds [651 x i32], ptr %297, i64 0, i64 %301
  %303 = load i32, ptr %44, align 4, !tbaa !5
  %304 = load i32, ptr %17, align 4, !tbaa !5
  %305 = add nsw i32 %303, %304
  %306 = load i32, ptr %21, align 4, !tbaa !5
  %307 = sub nsw i32 %305, %306
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %302, i32 noundef %307)
  %308 = load i32, ptr %11, align 4, !tbaa !5
  %309 = sext i32 %308 to i64
  %310 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %309
  %311 = load i32, ptr %46, align 4, !tbaa !5
  %312 = sub nsw i32 %311, 1
  %313 = load i32, ptr %25, align 4, !tbaa !5
  %314 = add nsw i32 %312, %313
  %315 = sext i32 %314 to i64
  %316 = getelementptr inbounds [651 x [651 x i32]], ptr %310, i64 0, i64 %315
  %317 = load i32, ptr %48, align 4, !tbaa !5
  %318 = add nsw i32 %317, 3
  %319 = load i32, ptr %19, align 4, !tbaa !5
  %320 = add nsw i32 %318, %319
  %321 = sext i32 %320 to i64
  %322 = getelementptr inbounds [651 x i32], ptr %316, i64 0, i64 %321
  %323 = load i32, ptr %44, align 4, !tbaa !5
  %324 = load i32, ptr %22, align 4, !tbaa !5
  %325 = sub nsw i32 %323, %324
  %326 = load i32, ptr %45, align 4, !tbaa !5
  %327 = sdiv i32 %326, 4
  %328 = sub nsw i32 %325, %327
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %322, i32 noundef %328)
  %329 = load i32, ptr %11, align 4, !tbaa !5
  %330 = sext i32 %329 to i64
  %331 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %330
  %332 = load i32, ptr %46, align 4, !tbaa !5
  %333 = add nsw i32 %332, 2
  %334 = load i32, ptr %23, align 4, !tbaa !5
  %335 = add nsw i32 %333, %334
  %336 = sext i32 %335 to i64
  %337 = getelementptr inbounds [651 x [651 x i32]], ptr %331, i64 0, i64 %336
  %338 = load i32, ptr %48, align 4, !tbaa !5
  %339 = sub nsw i32 %338, 1
  %340 = load i32, ptr %20, align 4, !tbaa !5
  %341 = add nsw i32 %339, %340
  %342 = sext i32 %341 to i64
  %343 = getelementptr inbounds [651 x i32], ptr %337, i64 0, i64 %342
  %344 = load i32, ptr %44, align 4, !tbaa !5
  %345 = load i32, ptr %18, align 4, !tbaa !5
  %346 = sub nsw i32 %344, %345
  %347 = load i32, ptr %47, align 4, !tbaa !5
  %348 = sdiv i32 %347, 4
  %349 = sub nsw i32 %346, %348
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %343, i32 noundef %349)
  call void @llvm.lifetime.end.p0(i64 4, ptr %48) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %47) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %46) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %45) #9
  store i32 0, ptr %3, align 4
  br label %350

350:                                              ; preds = %256, %255
  call void @llvm.lifetime.end.p0(i64 4, ptr %44) #9
  %351 = load i32, ptr %3, align 4
  switch i32 %351, label %560 [
    i32 0, label %352
    i32 25, label %353
  ]

352:                                              ; preds = %350
  br label %353

353:                                              ; preds = %352, %350
  %354 = load i32, ptr %43, align 4, !tbaa !5
  %355 = add nsw i32 %354, 1
  store i32 %355, ptr %43, align 4, !tbaa !5
  br label %235, !llvm.loop !15

356:                                              ; preds = %241
  br label %357

357:                                              ; preds = %356
  %358 = load i32, ptr %42, align 4, !tbaa !5
  %359 = add nsw i32 %358, 1
  store i32 %359, ptr %42, align 4, !tbaa !5
  br label %227, !llvm.loop !16

360:                                              ; preds = %233
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #9
  br label %361

361:                                              ; preds = %360
  %362 = load i32, ptr %16, align 4, !tbaa !5
  %363 = add nsw i32 %362, 1
  store i32 %363, ptr %16, align 4, !tbaa !5
  br label %118, !llvm.loop !17

364:                                              ; preds = %122
  call void @llvm.lifetime.start.p0(i64 4, ptr %49) #9
  store i32 0, ptr %49, align 4, !tbaa !5
  br label %365

365:                                              ; preds = %540, %364
  %366 = load i32, ptr %49, align 4, !tbaa !5
  %367 = load i32, ptr %13, align 4, !tbaa !5
  %368 = load i32, ptr %12, align 4, !tbaa !5
  %369 = sub nsw i32 %367, %368
  %370 = icmp sle i32 %366, %369
  br i1 %370, label %372, label %371

371:                                              ; preds = %365
  store i32 26, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %49) #9
  br label %543

372:                                              ; preds = %365
  store i32 0, ptr @tot, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %50) #9
  store i32 0, ptr %50, align 4, !tbaa !5
  br label %373

373:                                              ; preds = %435, %372
  %374 = load i32, ptr %50, align 4, !tbaa !5
  %375 = load i32, ptr %15, align 4, !tbaa !5
  %376 = load i32, ptr %14, align 4, !tbaa !5
  %377 = sub nsw i32 %375, %376
  %378 = icmp sle i32 %374, %377
  br i1 %378, label %380, label %379

379:                                              ; preds = %373
  store i32 29, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %50) #9
  br label %438

380:                                              ; preds = %373
  call void @llvm.lifetime.start.p0(i64 4, ptr %51) #9
  %381 = load i32, ptr %11, align 4, !tbaa !5
  %382 = sext i32 %381 to i64
  %383 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %382
  %384 = load i32, ptr %49, align 4, !tbaa !5
  %385 = sext i32 %384 to i64
  %386 = getelementptr inbounds [651 x [651 x i32]], ptr %383, i64 0, i64 %385
  %387 = load i32, ptr %50, align 4, !tbaa !5
  %388 = sext i32 %387 to i64
  %389 = getelementptr inbounds [651 x i32], ptr %386, i64 0, i64 %388
  %390 = load i32, ptr %389, align 4, !tbaa !5
  store i32 %390, ptr %51, align 4, !tbaa !5
  %391 = load i32, ptr %51, align 4, !tbaa !5
  %392 = icmp eq i32 %391, -1061109567
  br i1 %392, label %393, label %394

393:                                              ; preds = %380
  store i32 31, ptr %3, align 4
  br label %432

394:                                              ; preds = %380
  call void @llvm.lifetime.start.p0(i64 8, ptr %52) #9
  %395 = getelementptr inbounds %struct.Point, ptr %52, i32 0, i32 0
  %396 = load i32, ptr %50, align 4, !tbaa !5
  %397 = load i32, ptr %14, align 4, !tbaa !5
  %398 = add nsw i32 %396, %397
  store i32 %398, ptr %395, align 4, !tbaa !18
  %399 = getelementptr inbounds %struct.Point, ptr %52, i32 0, i32 1
  %400 = load i32, ptr %51, align 4, !tbaa !5
  store i32 %400, ptr %399, align 4, !tbaa !20
  br label %401

401:                                              ; preds = %424, %394
  %402 = load i32, ptr @tot, align 4, !tbaa !5
  %403 = icmp sgt i32 %402, 1
  call void @llvm.lifetime.start.p0(i64 8, ptr %53) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %54) #9
  br i1 %403, label %404, label %421

404:                                              ; preds = %401
  %405 = load i32, ptr @tot, align 4, !tbaa !5
  %406 = sub nsw i32 %405, 1
  %407 = sext i32 %406 to i64
  %408 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %407
  %409 = load i32, ptr @tot, align 4, !tbaa !5
  %410 = sub nsw i32 %409, 2
  %411 = sext i32 %410 to i64
  %412 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %411
  %413 = call i64 @_ZNK5PointmiERKS_(ptr noundef nonnull align 4 dereferenceable(8) %408, ptr noundef nonnull align 4 dereferenceable(8) %412)
  store i64 %413, ptr %53, align 4
  %414 = load i32, ptr @tot, align 4, !tbaa !5
  %415 = sub nsw i32 %414, 1
  %416 = sext i32 %415 to i64
  %417 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %416
  %418 = call i64 @_ZNK5PointmiERKS_(ptr noundef nonnull align 4 dereferenceable(8) %52, ptr noundef nonnull align 4 dereferenceable(8) %417)
  store i64 %418, ptr %54, align 4
  %419 = call noundef i32 @_ZNK5Point3detERKS_(ptr noundef nonnull align 4 dereferenceable(8) %53, ptr noundef nonnull align 4 dereferenceable(8) %54)
  %420 = icmp sge i32 %419, 0
  br label %421

421:                                              ; preds = %404, %401
  %422 = phi i1 [ false, %401 ], [ %420, %404 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr %54) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %53) #9
  br i1 %422, label %423, label %427

423:                                              ; preds = %421
  br label %424

424:                                              ; preds = %423
  %425 = load i32, ptr @tot, align 4, !tbaa !5
  %426 = add nsw i32 %425, -1
  store i32 %426, ptr @tot, align 4, !tbaa !5
  br label %401, !llvm.loop !21

427:                                              ; preds = %421
  %428 = load i32, ptr @tot, align 4, !tbaa !5
  %429 = add nsw i32 %428, 1
  store i32 %429, ptr @tot, align 4, !tbaa !5
  %430 = sext i32 %428 to i64
  %431 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %430
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %431, ptr align 4 %52, i64 8, i1 false), !tbaa.struct !22
  call void @llvm.lifetime.end.p0(i64 8, ptr %52) #9
  store i32 0, ptr %3, align 4
  br label %432

432:                                              ; preds = %427, %393
  call void @llvm.lifetime.end.p0(i64 4, ptr %51) #9
  %433 = load i32, ptr %3, align 4
  switch i32 %433, label %560 [
    i32 0, label %434
    i32 31, label %435
  ]

434:                                              ; preds = %432
  br label %435

435:                                              ; preds = %434, %432
  %436 = load i32, ptr %50, align 4, !tbaa !5
  %437 = add nsw i32 %436, 1
  store i32 %437, ptr %50, align 4, !tbaa !5
  br label %373, !llvm.loop !23

438:                                              ; preds = %379
  %439 = load i32, ptr @tot, align 4, !tbaa !5
  %440 = icmp ne i32 %439, 0
  br i1 %440, label %442, label %441

441:                                              ; preds = %438
  br label %540

442:                                              ; preds = %438
  call void @llvm.lifetime.start.p0(i64 4, ptr %55) #9
  store i32 0, ptr %55, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %56) #9
  store i32 0, ptr %56, align 4, !tbaa !5
  br label %443

443:                                              ; preds = %536, %442
  %444 = load i32, ptr %55, align 4, !tbaa !5
  %445 = load i32, ptr @m, align 4, !tbaa !5
  %446 = icmp slt i32 %444, %445
  br i1 %446, label %448, label %447

447:                                              ; preds = %443
  store i32 35, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %56) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %55) #9
  br label %539

448:                                              ; preds = %443
  call void @llvm.lifetime.start.p0(i64 4, ptr %57) #9
  %449 = load i32, ptr %55, align 4, !tbaa !5
  %450 = sext i32 %449 to i64
  %451 = getelementptr inbounds [651 x i32], ptr @ord, i64 0, i64 %450
  %452 = load i32, ptr %451, align 4, !tbaa !5
  store i32 %452, ptr %57, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %58) #9
  %453 = load i32, ptr %57, align 4, !tbaa !5
  %454 = sext i32 %453 to i64
  %455 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %454
  %456 = getelementptr inbounds %struct.Vector, ptr %455, i32 0, i32 0
  %457 = load i32, ptr %456, align 4, !tbaa !24
  %458 = load i32, ptr %56, align 4, !tbaa !5
  %459 = sext i32 %458 to i64
  %460 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %459
  %461 = getelementptr inbounds %struct.Point, ptr %460, i32 0, i32 0
  %462 = load i32, ptr %461, align 8, !tbaa !18
  %463 = mul nsw i32 %457, %462
  %464 = load i32, ptr %57, align 4, !tbaa !5
  %465 = sext i32 %464 to i64
  %466 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %465
  %467 = getelementptr inbounds %struct.Vector, ptr %466, i32 0, i32 1
  %468 = load i32, ptr %467, align 4, !tbaa !26
  %469 = load i32, ptr %56, align 4, !tbaa !5
  %470 = sext i32 %469 to i64
  %471 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %470
  %472 = getelementptr inbounds %struct.Point, ptr %471, i32 0, i32 1
  %473 = load i32, ptr %472, align 4, !tbaa !20
  %474 = mul nsw i32 %468, %473
  %475 = add nsw i32 %463, %474
  store i32 %475, ptr %58, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %59) #9
  br label %476

476:                                              ; preds = %512, %448
  %477 = load i32, ptr %56, align 4, !tbaa !5
  %478 = add nsw i32 %477, 1
  %479 = load i32, ptr @tot, align 4, !tbaa !5
  %480 = icmp slt i32 %478, %479
  br i1 %480, label %481, label %509

481:                                              ; preds = %476
  %482 = load i32, ptr %57, align 4, !tbaa !5
  %483 = sext i32 %482 to i64
  %484 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %483
  %485 = getelementptr inbounds %struct.Vector, ptr %484, i32 0, i32 0
  %486 = load i32, ptr %485, align 4, !tbaa !24
  %487 = load i32, ptr %56, align 4, !tbaa !5
  %488 = add nsw i32 %487, 1
  %489 = sext i32 %488 to i64
  %490 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %489
  %491 = getelementptr inbounds %struct.Point, ptr %490, i32 0, i32 0
  %492 = load i32, ptr %491, align 8, !tbaa !18
  %493 = mul nsw i32 %486, %492
  %494 = load i32, ptr %57, align 4, !tbaa !5
  %495 = sext i32 %494 to i64
  %496 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %495
  %497 = getelementptr inbounds %struct.Vector, ptr %496, i32 0, i32 1
  %498 = load i32, ptr %497, align 4, !tbaa !26
  %499 = load i32, ptr %56, align 4, !tbaa !5
  %500 = add nsw i32 %499, 1
  %501 = sext i32 %500 to i64
  %502 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %501
  %503 = getelementptr inbounds %struct.Point, ptr %502, i32 0, i32 1
  %504 = load i32, ptr %503, align 4, !tbaa !20
  %505 = mul nsw i32 %498, %504
  %506 = add nsw i32 %493, %505
  store i32 %506, ptr %59, align 4, !tbaa !5
  %507 = load i32, ptr %58, align 4, !tbaa !5
  %508 = icmp sgt i32 %506, %507
  br label %509

509:                                              ; preds = %481, %476
  %510 = phi i1 [ false, %476 ], [ %508, %481 ]
  br i1 %510, label %511, label %516

511:                                              ; preds = %509
  br label %512

512:                                              ; preds = %511
  %513 = load i32, ptr %56, align 4, !tbaa !5
  %514 = add nsw i32 %513, 1
  store i32 %514, ptr %56, align 4, !tbaa !5
  %515 = load i32, ptr %59, align 4, !tbaa !5
  store i32 %515, ptr %58, align 4, !tbaa !5
  br label %476, !llvm.loop !27

516:                                              ; preds = %509
  %517 = load i32, ptr %57, align 4, !tbaa !5
  %518 = sext i32 %517 to i64
  %519 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %518
  call void @llvm.lifetime.start.p0(i64 4, ptr %60) #9
  %520 = load i32, ptr %58, align 4, !tbaa !5
  %521 = load i32, ptr %57, align 4, !tbaa !5
  %522 = sext i32 %521 to i64
  %523 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %522
  %524 = getelementptr inbounds %struct.Vector, ptr %523, i32 0, i32 2
  %525 = load i32, ptr %524, align 4, !tbaa !28
  %526 = load i32, ptr %49, align 4, !tbaa !5
  %527 = load i32, ptr %12, align 4, !tbaa !5
  %528 = add nsw i32 %526, %527
  %529 = mul nsw i32 %525, %528
  %530 = add nsw i32 %520, %529
  store i32 %530, ptr %60, align 4, !tbaa !5
  %531 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %519, ptr noundef nonnull align 4 dereferenceable(4) %60)
  %532 = load i32, ptr %531, align 4, !tbaa !5
  %533 = load i32, ptr %57, align 4, !tbaa !5
  %534 = sext i32 %533 to i64
  %535 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %534
  store i32 %532, ptr %535, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %60) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %59) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %58) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %57) #9
  br label %536

536:                                              ; preds = %516
  %537 = load i32, ptr %55, align 4, !tbaa !5
  %538 = add nsw i32 %537, 1
  store i32 %538, ptr %55, align 4, !tbaa !5
  br label %443, !llvm.loop !29

539:                                              ; preds = %447
  br label %540

540:                                              ; preds = %539, %441
  %541 = load i32, ptr %49, align 4, !tbaa !5
  %542 = add nsw i32 %541, 1
  store i32 %542, ptr %49, align 4, !tbaa !5
  br label %365, !llvm.loop !30

543:                                              ; preds = %371
  call void @llvm.lifetime.start.p0(i64 4, ptr %61) #9
  store i32 0, ptr %61, align 4, !tbaa !5
  br label %544

544:                                              ; preds = %555, %543
  %545 = load i32, ptr %61, align 4, !tbaa !5
  %546 = load i32, ptr @m, align 4, !tbaa !5
  %547 = icmp slt i32 %545, %546
  br i1 %547, label %549, label %548

548:                                              ; preds = %544
  store i32 41, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %61) #9
  br label %558

549:                                              ; preds = %544
  %550 = load i32, ptr %61, align 4, !tbaa !5
  %551 = sext i32 %550 to i64
  %552 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %551
  %553 = load i32, ptr %552, align 4, !tbaa !5
  %554 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, i32 noundef %553)
  br label %555

555:                                              ; preds = %549
  %556 = load i32, ptr %61, align 4, !tbaa !5
  %557 = add nsw i32 %556, 1
  store i32 %557, ptr %61, align 4, !tbaa !5
  br label %544, !llvm.loop !31

558:                                              ; preds = %548
  store i32 0, ptr %1, align 4
  store i32 1, ptr %3, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #9
  %559 = load i32, ptr %1, align 4
  ret i32 %559

560:                                              ; preds = %432, %350
  unreachable
}

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6Vector4readEv(ptr noundef nonnull align 4 dereferenceable(12)) #4 align 2

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK5Point3detERKS_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(8)) #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) #8

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

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 = { "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 = { 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 #6 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #7 = { 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 #8 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #9 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}
!18 = !{!19, !6, i64 0}
!19 = !{!"_ZTS5Point", !6, i64 0, !6, i64 4}
!20 = !{!19, !6, i64 4}
!21 = distinct !{!21, !10}
!22 = !{i64 0, i64 4, !5, i64 4, i64 4, !5}
!23 = distinct !{!23, !10}
!24 = !{!25, !6, i64 0}
!25 = !{!"_ZTS6Vector", !6, i64 0, !6, i64 4, !6, i64 8}
!26 = !{!25, !6, i64 4}
!27 = distinct !{!27, !10}
!28 = !{!25, !6, i64 8}
!29 = distinct !{!29, !10}
!30 = distinct !{!30, !10}
!31 = distinct !{!31, !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"

%struct.Vector = type { i32, i32, i32 }
%struct.Point = type { i32, i32 }

@n = external dso_local global i32, align 4
@m = external dso_local global i32, align 4
@a = external dso_local global [2 x [651 x i32]], align 16
@f = external dso_local global [2 x [651 x [651 x i32]]], align 16
@ord = external dso_local global [651 x i32], align 16
@ans = external dso_local global [651 x i32], align 16
@que = external dso_local global [651 x %struct.Vector], align 16
@tot = external dso_local local_unnamed_addr global i32, align 4
@p = external dso_local global [651 x %struct.Point], align 16
@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1

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

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

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca %struct.Point, align 8
  %19 = alloca %struct.Point, align 8
  %20 = alloca %struct.Point, align 8
  %21 = alloca i32, align 4
  %22 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n, ptr noundef nonnull @m)
  %23 = load i32, ptr @n, align 4, !tbaa !5
  %24 = icmp sgt i32 %23, 0
  br i1 %24, label %.lr.ph, label %.preheader174

.preheader174:                                    ; preds = %.lr.ph.1, %._crit_edge, %0
  %25 = load i32, ptr @m, align 4, !tbaa !5
  %26 = icmp sgt i32 %25, 0
  br i1 %26, label %.lr.ph179, label %.preheader174.._crit_edge180_crit_edge

.preheader174.._crit_edge180_crit_edge:           ; preds = %.preheader174
  %.pre281 = sext i32 %25 to i64
  br label %._crit_edge180

._crit_edge:                                      ; preds = %.lr.ph
  %27 = icmp sgt i32 %35, 0
  br i1 %27, label %.lr.ph.1, label %.preheader174

.lr.ph.1:                                         ; preds = %._crit_edge, %.lr.ph.1
  %indvars.iv.1 = phi i64 [ %indvars.iv.next.1, %.lr.ph.1 ], [ 0, %._crit_edge ]
  %28 = getelementptr inbounds i32, ptr getelementptr inbounds (i8, ptr @a, i64 2604), i64 %indvars.iv.1
  %29 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.1, ptr noundef nonnull %28)
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv.1, 1
  %30 = load i32, ptr @n, align 4, !tbaa !5
  %31 = sext i32 %30 to i64
  %32 = icmp slt i64 %indvars.iv.next.1, %31
  br i1 %32, label %.lr.ph.1, label %.preheader174, !llvm.loop !9

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

._crit_edge180:                                   ; preds = %.lr.ph179, %.preheader174.._crit_edge180_crit_edge
  %.pre-phi = phi i64 [ %.pre281, %.preheader174.._crit_edge180_crit_edge ], [ %46, %.lr.ph179 ]
  %38 = getelementptr inbounds i32, ptr @ord, i64 %.pre-phi
  tail call void @_ZSt4sortIPiPFbRKiS2_EEvT_S5_T0_(ptr noundef nonnull @ord, ptr noundef nonnull %38, ptr noundef nonnull @_Z3cmpRKiS0_)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #9
  store i32 1, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #9
  store i32 0, ptr %2, align 4, !tbaa !5
  store i32 0, ptr @f, align 16, !tbaa !5
  %39 = load i32, ptr @n, align 4, !tbaa !5
  %40 = icmp sgt i32 %39, 0
  br i1 %40, label %.lr.ph200, label %.lr.ph218

.lr.ph179:                                        ; preds = %.preheader174, %.lr.ph179
  %indvars.iv235 = phi i64 [ %indvars.iv.next236, %.lr.ph179 ], [ 0, %.preheader174 ]
  %41 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %indvars.iv235
  tail call void @_ZN6Vector4readEv(ptr noundef nonnull align 4 dereferenceable(12) %41)
  %42 = getelementptr inbounds [651 x i32], ptr @ord, i64 0, i64 %indvars.iv235
  %43 = trunc nuw nsw i64 %indvars.iv235 to i32
  store i32 %43, ptr %42, align 4, !tbaa !5
  %44 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %indvars.iv235
  store i32 -1061109567, ptr %44, align 4, !tbaa !5
  %indvars.iv.next236 = add nuw nsw i64 %indvars.iv235, 1
  %45 = load i32, ptr @m, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = icmp slt i64 %indvars.iv.next236, %46
  br i1 %47, label %.lr.ph179, label %._crit_edge180, !llvm.loop !11

.preheader170:                                    ; preds = %._crit_edge193
  %.not215 = icmp slt i32 %75, %70
  br i1 %.not215, label %.preheader170..preheader_crit_edge, label %.lr.ph218

.preheader170..preheader_crit_edge:               ; preds = %.preheader170
  %.pre280 = load i32, ptr @m, align 4, !tbaa !5
  br label %.preheader

.lr.ph218:                                        ; preds = %._crit_edge180, %.preheader170
  %.0144.lcssa290 = phi i32 [ %70, %.preheader170 ], [ 0, %._crit_edge180 ]
  %.0145.lcssa289 = phi i32 [ %75, %.preheader170 ], [ 0, %._crit_edge180 ]
  %.0146.lcssa288 = phi i32 [ %83, %.preheader170 ], [ 0, %._crit_edge180 ]
  %.0151.lcssa287 = phi i32 [ %88, %.preheader170 ], [ 0, %._crit_edge180 ]
  %.not158207 = icmp slt i32 %.0151.lcssa287, %.0146.lcssa288
  %48 = getelementptr inbounds i8, ptr %18, i64 4
  %49 = add i32 %.0151.lcssa287, 1
  %50 = sub i32 %49, %.0146.lcssa288
  %51 = add i32 %.0145.lcssa289, 1
  %52 = sub i32 %51, %.0144.lcssa290
  %wide.trip.count273 = zext i32 %52 to i64
  %wide.trip.count262 = zext i32 %50 to i64
  br label %168

.lr.ph200:                                        ; preds = %._crit_edge180, %._crit_edge193
  %indvars.iv256 = phi i64 [ %indvars.iv.next257, %._crit_edge193 ], [ 0, %._crit_edge180 ]
  %.0144198 = phi i32 [ %70, %._crit_edge193 ], [ 0, %._crit_edge180 ]
  %.0145197 = phi i32 [ %75, %._crit_edge193 ], [ 0, %._crit_edge180 ]
  %.0146196 = phi i32 [ %83, %._crit_edge193 ], [ 0, %._crit_edge180 ]
  %.0151195 = phi i32 [ %88, %._crit_edge193 ], [ 0, %._crit_edge180 ]
  %53 = getelementptr inbounds [651 x i32], ptr @a, i64 0, i64 %indvars.iv256
  %54 = load i32, ptr %53, align 4, !tbaa !5
  %55 = call i32 @llvm.abs.i32(i32 %54, i1 true)
  %56 = sdiv i32 %54, 4
  %57 = sdiv i32 %54, 6
  %58 = getelementptr inbounds [651 x i32], ptr getelementptr inbounds (i8, ptr @a, i64 2604), i64 0, i64 %indvars.iv256
  %59 = load i32, ptr %58, align 4, !tbaa !5
  %60 = call i32 @llvm.abs.i32(i32 %59, i1 true)
  %61 = sdiv i32 %59, 3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #9
  %62 = sdiv i32 %59, 6
  store i32 %62, ptr %3, align 4, !tbaa !5
  %63 = sdiv i32 %59, 9
  call void @_ZSt4swapIiENSt9enable_ifIXsr6__and_ISt6__not_ISt15__is_tuple_likeIT_EESt21is_move_constructibleIS3_ESt18is_move_assignableIS3_EEE5valueEvE4typeERS3_SC_(ptr noundef nonnull align 4 dereferenceable(4) %2, ptr noundef nonnull align 4 dereferenceable(4) %1) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #9
  store i32 -1, ptr %4, align 4, !tbaa !5
  %64 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %3)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #9
  %65 = add nsw i32 %63, -1
  store i32 %65, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #9
  %66 = add nsw i32 %61, 2
  store i32 %66, ptr %6, align 4, !tbaa !5
  %67 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6)
  %68 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %64, ptr noundef nonnull align 4 dereferenceable(4) %67)
  %69 = load i32, ptr %68, align 4, !tbaa !5
  %70 = add i32 %69, %.0144198
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #9
  store i32 -1, ptr %7, align 4, !tbaa !5
  %71 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %7, ptr noundef nonnull align 4 dereferenceable(4) %3)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #9
  store i32 %65, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #9
  store i32 %66, ptr %9, align 4, !tbaa !5
  %72 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %8, ptr noundef nonnull align 4 dereferenceable(4) %9)
  %73 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %71, ptr noundef nonnull align 4 dereferenceable(4) %72)
  %74 = load i32, ptr %73, align 4, !tbaa !5
  %75 = add nsw i32 %74, %.0145197
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #9
  store i32 -1, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #9
  %76 = sub nsw i32 0, %56
  store i32 %76, ptr %11, align 4, !tbaa !5
  %77 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %10, ptr noundef nonnull align 4 dereferenceable(4) %11)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #9
  %78 = add nsw i32 %56, 3
  store i32 %78, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %13) #9
  %79 = add nsw i32 %57, -1
  store i32 %79, ptr %13, align 4, !tbaa !5
  %80 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %12, ptr noundef nonnull align 4 dereferenceable(4) %13)
  %81 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %77, ptr noundef nonnull align 4 dereferenceable(4) %80)
  %82 = load i32, ptr %81, align 4, !tbaa !5
  %83 = add i32 %82, %.0146196
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %13) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %14) #9
  store i32 -1, ptr %14, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %15) #9
  store i32 %76, ptr %15, align 4, !tbaa !5
  %84 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %14, ptr noundef nonnull align 4 dereferenceable(4) %15)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %16) #9
  store i32 %78, ptr %16, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %17) #9
  store i32 %79, ptr %17, align 4, !tbaa !5
  %85 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %16, ptr noundef nonnull align 4 dereferenceable(4) %17)
  %86 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %84, ptr noundef nonnull align 4 dereferenceable(4) %85)
  %87 = load i32, ptr %86, align 4, !tbaa !5
  %88 = add nsw i32 %87, %.0151195
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %17) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %16) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %15) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %14) #9
  %.not160185 = icmp slt i32 %75, %70
  br i1 %.not160185, label %.preheader173, label %.preheader172.lr.ph

.preheader172.lr.ph:                              ; preds = %.lr.ph200
  %.not164181 = icmp slt i32 %88, %83
  %89 = load i32, ptr %2, align 4
  %90 = sext i32 %89 to i64
  br i1 %.not164181, label %.preheader173, label %.preheader172.preheader

.preheader172.preheader:                          ; preds = %.preheader172.lr.ph
  %91 = add i32 %.0151195, 1
  %92 = add i32 %91, %87
  %93 = sub i32 %92, %83
  %94 = add i32 %.0145197, 1
  %95 = add i32 %94, %74
  %96 = sub i32 %95, %70
  %wide.trip.count244 = zext i32 %96 to i64
  %wide.trip.count = zext i32 %93 to i64
  %min.iters.check = icmp ult i32 %93, 8
  %n.vec = and i64 %wide.trip.count, 4294967288
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br label %.preheader172

.preheader173:                                    ; preds = %._crit_edge184, %.preheader172.lr.ph, %.lr.ph200
  %.not161191 = icmp slt i32 %.0145197, %.0144198
  br i1 %.not161191, label %._crit_edge193, label %.preheader171.lr.ph

.preheader171.lr.ph:                              ; preds = %.preheader173
  %.not162187 = icmp slt i32 %.0151195, %.0146196
  %97 = sub i32 %54, %59
  br i1 %.not162187, label %._crit_edge193, label %.preheader171.preheader

.preheader171.preheader:                          ; preds = %.preheader171.lr.ph
  %98 = add i32 %.0151195, 1
  %99 = sub i32 %98, %.0146196
  %100 = add i32 %.0145197, 1
  %101 = sub i32 %100, %.0144198
  %wide.trip.count254 = zext i32 %101 to i64
  %wide.trip.count249 = zext i32 %99 to i64
  br label %.preheader171

.preheader172:                                    ; preds = %.preheader172.preheader, %._crit_edge184
  %indvars.iv241 = phi i64 [ 0, %.preheader172.preheader ], [ %indvars.iv.next242, %._crit_edge184 ]
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.body

scalar.ph.preheader:                              ; preds = %middle.block, %.preheader172
  %indvars.iv238.ph = phi i64 [ 0, %.preheader172 ], [ %n.vec, %middle.block ]
  br label %scalar.ph

vector.body:                                      ; preds = %.preheader172, %vector.body
  %index = phi i64 [ %index.next, %vector.body ], [ 0, %.preheader172 ]
  %102 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %90, i64 %indvars.iv241, i64 %index
  %103 = getelementptr inbounds i8, ptr %102, i64 16
  store <4 x i32> <i32 -1061109567, i32 -1061109567, i32 -1061109567, i32 -1061109567>, ptr %102, align 4, !tbaa !5
  store <4 x i32> <i32 -1061109567, i32 -1061109567, i32 -1061109567, i32 -1061109567>, ptr %103, align 4, !tbaa !5
  %index.next = add nuw i64 %index, 8
  %104 = icmp eq i64 %index.next, %n.vec
  br i1 %104, label %middle.block, label %vector.body, !llvm.loop !12

middle.block:                                     ; preds = %vector.body
  br i1 %cmp.n, label %._crit_edge184, label %scalar.ph.preheader

._crit_edge184:                                   ; preds = %scalar.ph, %middle.block
  %indvars.iv.next242 = add nuw nsw i64 %indvars.iv241, 1
  %exitcond245.not = icmp eq i64 %indvars.iv.next242, %wide.trip.count244
  br i1 %exitcond245.not, label %.preheader173, label %.preheader172, !llvm.loop !15

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %indvars.iv238 = phi i64 [ %indvars.iv.next239, %scalar.ph ], [ %indvars.iv238.ph, %scalar.ph.preheader ]
  %105 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %90, i64 %indvars.iv241, i64 %indvars.iv238
  store i32 -1061109567, ptr %105, align 4, !tbaa !5
  %indvars.iv.next239 = add nuw nsw i64 %indvars.iv238, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next239, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge184, label %scalar.ph, !llvm.loop !16

.preheader171:                                    ; preds = %.preheader171.preheader, %._crit_edge190
  %indvars.iv251 = phi i64 [ 0, %.preheader171.preheader ], [ %indvars.iv.next252, %._crit_edge190 ]
  %106 = trunc nuw nsw i64 %indvars.iv251 to i32
  %107 = sub i32 %106, %69
  %108 = add nsw i32 %107, -1
  %109 = sext i32 %108 to i64
  %110 = trunc i64 %indvars.iv251 to i32
  %111 = add i32 %.0144198, %110
  %112 = sdiv i32 %111, 6
  %113 = add nsw i32 %112, 3
  %114 = add nsw i32 %108, %63
  %115 = sext i32 %114 to i64
  %.neg = sdiv i32 %111, -4
  %116 = sub i32 %.neg, %60
  %117 = add i32 %66, %107
  %118 = sext i32 %117 to i64
  br label %122

._crit_edge193:                                   ; preds = %._crit_edge190, %.preheader171.lr.ph, %.preheader173
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #9
  %indvars.iv.next257 = add nuw nsw i64 %indvars.iv256, 1
  %119 = load i32, ptr @n, align 4, !tbaa !5
  %120 = sext i32 %119 to i64
  %121 = icmp slt i64 %indvars.iv.next257, %120
  br i1 %121, label %.lr.ph200, label %.preheader170, !llvm.loop !17

._crit_edge190:                                   ; preds = %165
  %indvars.iv.next252 = add nuw nsw i64 %indvars.iv251, 1
  %exitcond255.not = icmp eq i64 %indvars.iv.next252, %wide.trip.count254
  br i1 %exitcond255.not, label %._crit_edge193, label %.preheader171, !llvm.loop !18

122:                                              ; preds = %.preheader171, %165
  %indvars.iv246 = phi i64 [ 0, %.preheader171 ], [ %indvars.iv.next247, %165 ]
  %123 = load i32, ptr %1, align 4, !tbaa !5
  %124 = sext i32 %123 to i64
  %125 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %124, i64 %indvars.iv251, i64 %indvars.iv246
  %126 = load i32, ptr %125, align 4, !tbaa !5
  %127 = icmp eq i32 %126, -1061109567
  br i1 %127, label %165, label %128

128:                                              ; preds = %122
  %129 = trunc nuw nsw i64 %indvars.iv246 to i32
  %130 = sub i32 %129, %82
  %131 = load i32, ptr %2, align 4, !tbaa !5
  %132 = sext i32 %131 to i64
  %133 = add nsw i32 %130, -1
  %134 = sext i32 %133 to i64
  %135 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %132, i64 %109, i64 %134
  %136 = shl nsw i32 %126, 2
  %137 = sdiv i32 %136, 5
  %138 = trunc i64 %indvars.iv246 to i32
  %139 = add i32 %.0146196, %138
  %140 = sdiv i32 %139, 6
  %141 = add nsw i32 %113, %140
  %142 = add nsw i32 %141, %137
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %135, i32 noundef %142)
  %143 = load i32, ptr %2, align 4, !tbaa !5
  %144 = sext i32 %143 to i64
  %145 = load i32, ptr %3, align 4, !tbaa !5
  %146 = add nsw i32 %145, %107
  %147 = sext i32 %146 to i64
  %148 = sub nsw i32 %130, %56
  %149 = sext i32 %148 to i64
  %150 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %144, i64 %147, i64 %149
  %151 = add i32 %97, %126
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %150, i32 noundef %151)
  %152 = load i32, ptr %2, align 4, !tbaa !5
  %153 = sext i32 %152 to i64
  %154 = add i32 %78, %130
  %155 = sext i32 %154 to i64
  %156 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %153, i64 %115, i64 %155
  %157 = add i32 %116, %126
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %156, i32 noundef %157)
  %158 = load i32, ptr %2, align 4, !tbaa !5
  %159 = sext i32 %158 to i64
  %160 = add nsw i32 %133, %57
  %161 = sext i32 %160 to i64
  %162 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %159, i64 %118, i64 %161
  %.neg163 = sdiv i32 %139, -4
  %163 = sub i32 %.neg163, %55
  %164 = add i32 %163, %126
  call void @_Z7upd_maxRii(ptr noundef nonnull align 4 dereferenceable(4) %162, i32 noundef %164)
  br label %165

165:                                              ; preds = %122, %128
  %indvars.iv.next247 = add nuw nsw i64 %indvars.iv246, 1
  %exitcond250.not = icmp eq i64 %indvars.iv.next247, %wide.trip.count249
  br i1 %exitcond250.not, label %._crit_edge190, label %122, !llvm.loop !19

.preheader:                                       ; preds = %.loopexit169, %.preheader170..preheader_crit_edge
  %166 = phi i32 [ %.pre280, %.preheader170..preheader_crit_edge ], [ %251, %.loopexit169 ]
  %167 = icmp sgt i32 %166, 0
  br i1 %167, label %.lr.ph220, label %._crit_edge221

168:                                              ; preds = %.lr.ph218, %.loopexit169
  %indvars.iv270 = phi i64 [ 0, %.lr.ph218 ], [ %indvars.iv.next271, %.loopexit169 ]
  store i32 0, ptr @tot, align 4, !tbaa !5
  br i1 %.not158207, label %._crit_edge211.thread, label %.lr.ph210

._crit_edge211.thread:                            ; preds = %168
  %169 = load i32, ptr @m, align 4
  br label %.loopexit169

._crit_edge211:                                   ; preds = %208
  %.not159 = icmp ne i32 %.pr279, 0
  %170 = load i32, ptr @m, align 4
  %171 = icmp sgt i32 %170, 0
  %or.cond = select i1 %.not159, i1 %171, i1 false
  br i1 %or.cond, label %.lr.ph214, label %.loopexit169

.lr.ph214:                                        ; preds = %._crit_edge211
  %172 = trunc i64 %indvars.iv270 to i32
  %173 = add i32 %.0144.lcssa290, %172
  br label %209

.lr.ph210:                                        ; preds = %168, %208
  %.pr = phi i32 [ %.pr279, %208 ], [ 0, %168 ]
  %indvars.iv259 = phi i64 [ %indvars.iv.next260, %208 ], [ 0, %168 ]
  %174 = load i32, ptr %2, align 4, !tbaa !5
  %175 = sext i32 %174 to i64
  %176 = getelementptr inbounds [2 x [651 x [651 x i32]]], ptr @f, i64 0, i64 %175, i64 %indvars.iv270, i64 %indvars.iv259
  %177 = load i32, ptr %176, align 4, !tbaa !5
  %178 = icmp eq i32 %177, -1061109567
  br i1 %178, label %208, label %179

179:                                              ; preds = %.lr.ph210
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #9
  %180 = trunc i64 %indvars.iv259 to i32
  %181 = add i32 %.0146.lcssa288, %180
  store i32 %181, ptr %18, align 8, !tbaa !20
  store i32 %177, ptr %48, align 4, !tbaa !22
  %182 = icmp sgt i32 %.pr, 1
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %19) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %20) #9
  br i1 %182, label %.lr.ph206, label %.critedge

.lr.ph206:                                        ; preds = %179, %199
  %183 = phi i32 [ %200, %199 ], [ %.pr, %179 ]
  %184 = add nsw i32 %183, -1
  %185 = zext nneg i32 %184 to i64
  %186 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %185
  %187 = add nsw i32 %183, -2
  %188 = zext nneg i32 %187 to i64
  %189 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %188
  %190 = call i64 @_ZNK5PointmiERKS_(ptr noundef nonnull align 4 dereferenceable(8) %186, ptr noundef nonnull align 4 dereferenceable(8) %189)
  store i64 %190, ptr %19, align 8
  %191 = load i32, ptr @tot, align 4, !tbaa !5
  %192 = add nsw i32 %191, -1
  %193 = sext i32 %192 to i64
  %194 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %193
  %195 = call i64 @_ZNK5PointmiERKS_(ptr noundef nonnull align 4 dereferenceable(8) %18, ptr noundef nonnull align 4 dereferenceable(8) %194)
  store i64 %195, ptr %20, align 8
  %196 = call noundef i32 @_ZNK5Point3detERKS_(ptr noundef nonnull align 4 dereferenceable(8) %19, ptr noundef nonnull align 4 dereferenceable(8) %20)
  %197 = icmp sgt i32 %196, -1
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #9
  %198 = load i32, ptr @tot, align 4, !tbaa !5
  br i1 %197, label %199, label %.loopexit

199:                                              ; preds = %.lr.ph206
  %200 = add nsw i32 %198, -1
  store i32 %200, ptr @tot, align 4, !tbaa !5
  %201 = icmp sgt i32 %198, 2
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %19) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %20) #9
  br i1 %201, label %.lr.ph206, label %.critedge, !llvm.loop !23

.critedge:                                        ; preds = %199, %179
  %202 = phi i32 [ %.pr, %179 ], [ %200, %199 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #9
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph206, %.critedge
  %203 = phi i32 [ %202, %.critedge ], [ %198, %.lr.ph206 ]
  %204 = add nsw i32 %203, 1
  store i32 %204, ptr @tot, align 4, !tbaa !5
  %205 = sext i32 %203 to i64
  %206 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %205
  %207 = load i64, ptr %18, align 8
  store i64 %207, ptr %206, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #9
  br label %208

208:                                              ; preds = %.lr.ph210, %.loopexit
  %.pr279 = phi i32 [ %.pr, %.lr.ph210 ], [ %204, %.loopexit ]
  %indvars.iv.next260 = add nuw nsw i64 %indvars.iv259, 1
  %exitcond263.not = icmp eq i64 %indvars.iv.next260, %wide.trip.count262
  br i1 %exitcond263.not, label %._crit_edge211, label %.lr.ph210, !llvm.loop !24

209:                                              ; preds = %.lr.ph214, %.critedge2
  %indvars.iv267 = phi i64 [ 0, %.lr.ph214 ], [ %indvars.iv.next268, %.critedge2 ]
  %.0138213 = phi i32 [ 0, %.lr.ph214 ], [ %.1.lcssa, %.critedge2 ]
  %210 = getelementptr inbounds [651 x i32], ptr @ord, i64 0, i64 %indvars.iv267
  %211 = load i32, ptr %210, align 4, !tbaa !5
  %212 = sext i32 %211 to i64
  %213 = getelementptr inbounds [651 x %struct.Vector], ptr @que, i64 0, i64 %212
  %214 = load i32, ptr %213, align 4, !tbaa !25
  %215 = sext i32 %.0138213 to i64
  %216 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %215
  %217 = load i32, ptr %216, align 8, !tbaa !20
  %218 = mul nsw i32 %217, %214
  %219 = getelementptr inbounds i8, ptr %213, i64 4
  %220 = load i32, ptr %219, align 4, !tbaa !27
  %221 = getelementptr inbounds i8, ptr %216, i64 4
  %222 = load i32, ptr %221, align 4, !tbaa !22
  %223 = mul nsw i32 %222, %220
  %224 = add nsw i32 %223, %218
  %225 = load i32, ptr @tot, align 4, !tbaa !5
  %226 = sext i32 %225 to i64
  %227 = add nsw i32 %.0138213, 1
  %smax = call i32 @llvm.smax.i32(i32 %225, i32 %227)
  %228 = add nsw i32 %smax, -1
  br label %229

229:                                              ; preds = %231, %209
  %indvars.iv264 = phi i64 [ %indvars.iv.next265, %231 ], [ %215, %209 ]
  %.0136 = phi i32 [ %238, %231 ], [ %224, %209 ]
  %indvars.iv.next265 = add nsw i64 %indvars.iv264, 1
  %230 = icmp slt i64 %indvars.iv.next265, %226
  br i1 %230, label %231, label %.critedge2

231:                                              ; preds = %229
  %232 = getelementptr inbounds [651 x %struct.Point], ptr @p, i64 0, i64 %indvars.iv.next265
  %233 = load i32, ptr %232, align 8, !tbaa !20
  %234 = mul nsw i32 %233, %214
  %235 = getelementptr inbounds i8, ptr %232, i64 4
  %236 = load i32, ptr %235, align 4, !tbaa !22
  %237 = mul nsw i32 %236, %220
  %238 = add nsw i32 %237, %234
  %239 = icmp sgt i32 %238, %.0136
  br i1 %239, label %229, label %.critedge2.split.loop.exit301, !llvm.loop !28

.critedge2.split.loop.exit301:                    ; preds = %231
  %240 = trunc nsw i64 %indvars.iv264 to i32
  br label %.critedge2

.critedge2:                                       ; preds = %229, %.critedge2.split.loop.exit301
  %.1.lcssa = phi i32 [ %240, %.critedge2.split.loop.exit301 ], [ %228, %229 ]
  %241 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %212
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %21) #9
  %242 = getelementptr inbounds i8, ptr %213, i64 8
  %243 = load i32, ptr %242, align 4, !tbaa !29
  %244 = mul nsw i32 %243, %173
  %245 = add nsw i32 %244, %.0136
  store i32 %245, ptr %21, align 4, !tbaa !5
  %246 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %241, ptr noundef nonnull align 4 dereferenceable(4) %21)
  %247 = load i32, ptr %246, align 4, !tbaa !5
  store i32 %247, ptr %241, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %21) #9
  %indvars.iv.next268 = add nuw nsw i64 %indvars.iv267, 1
  %248 = load i32, ptr @m, align 4, !tbaa !5
  %249 = sext i32 %248 to i64
  %250 = icmp slt i64 %indvars.iv.next268, %249
  br i1 %250, label %209, label %.loopexit169, !llvm.loop !30

.loopexit169:                                     ; preds = %.critedge2, %._crit_edge211.thread, %._crit_edge211
  %251 = phi i32 [ %170, %._crit_edge211 ], [ %169, %._crit_edge211.thread ], [ %248, %.critedge2 ]
  %indvars.iv.next271 = add nuw nsw i64 %indvars.iv270, 1
  %exitcond274.not = icmp eq i64 %indvars.iv.next271, %wide.trip.count273
  br i1 %exitcond274.not, label %.preheader, label %168, !llvm.loop !31

._crit_edge221:                                   ; preds = %.lr.ph220, %.preheader
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #9
  ret i32 0

.lr.ph220:                                        ; preds = %.preheader, %.lr.ph220
  %indvars.iv275 = phi i64 [ %indvars.iv.next276, %.lr.ph220 ], [ 0, %.preheader ]
  %252 = getelementptr inbounds [651 x i32], ptr @ans, i64 0, i64 %indvars.iv275
  %253 = load i32, ptr %252, align 4, !tbaa !5
  %254 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i32 noundef %253)
  %indvars.iv.next276 = add nuw nsw i64 %indvars.iv275, 1
  %255 = load i32, ptr @m, align 4, !tbaa !5
  %256 = sext i32 %255 to i64
  %257 = icmp slt i64 %indvars.iv.next276, %256
  br i1 %257, label %.lr.ph220, label %._crit_edge221, !llvm.loop !32
}

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6Vector4readEv(ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #4 align 2

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

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

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

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

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

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

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smax.i32(i32, i32) #8

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 = { 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 = { 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 #6 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #7 = { 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 #8 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #9 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10, !13, !14}
!13 = !{!"llvm.loop.isvectorized", i32 1}
!14 = !{!"llvm.loop.unroll.runtime.disable"}
!15 = distinct !{!15, !10}
!16 = distinct !{!16, !10, !14, !13}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = !{!21, !6, i64 0}
!21 = !{!"_ZTS5Point", !6, i64 0, !6, i64 4}
!22 = !{!21, !6, i64 4}
!23 = distinct !{!23, !10}
!24 = distinct !{!24, !10}
!25 = !{!26, !6, i64 0}
!26 = !{!"_ZTS6Vector", !6, i64 0, !6, i64 4, !6, i64 8}
!27 = !{!26, !6, i64 4}
!28 = distinct !{!28, !10}
!29 = !{!26, !6, i64 8}
!30 = distinct !{!30, !10}
!31 = distinct !{!31, !10}
!32 = distinct !{!32, !10}


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