; LLVM IR from DionysiosB/CodeForces :: 1100-1199 (1152B-NekoPerformsCatFurrierTransform)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl" }
%"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl" = type { %"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl_data" = type { ptr, ptr, ptr }

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i64, align 8
  %3 = alloca %"class.std::vector", align 8
  %4 = alloca i32, align 4
  %5 = alloca %"class.std::allocator", align 1
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i64, align 8
  %9 = alloca %"class.std::vector.0", align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca i8, align 1
  %15 = alloca i64, align 8
  %16 = alloca i32, align 4
  %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) #5
  %20 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %2)
  call void @llvm.lifetime.start.p0(i64 24, ptr %3) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  store i32 0, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %5) #5
  call void @_ZNSaIiEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  invoke void @_ZNSt6vectorIiSaIiEEC2EmRKiRKS0_(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef 35, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 1 dereferenceable(1) %5)
          to label %21 unwind label %26

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

22:                                               ; preds = %38, %21
  %23 = load i64, ptr %8, align 8, !tbaa !9
  %24 = icmp slt i64 %23, 35
  br i1 %24, label %30, label %25

25:                                               ; preds = %22
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br label %41

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

30:                                               ; preds = %22
  %31 = load i64, ptr %2, align 8, !tbaa !9
  %32 = srem i64 %31, 2
  %33 = trunc i64 %32 to i32
  %34 = load i64, ptr %8, align 8, !tbaa !9
  %35 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %34) #5
  store i32 %33, ptr %35, align 4, !tbaa !5
  %36 = load i64, ptr %2, align 8, !tbaa !9
  %37 = sdiv i64 %36, 2
  store i64 %37, ptr %2, align 8, !tbaa !9
  br label %38

38:                                               ; preds = %30
  %39 = load i64, ptr %8, align 8, !tbaa !9
  %40 = add nsw i64 %39, 1
  store i64 %40, ptr %8, align 8, !tbaa !9
  br label %22, !llvm.loop !11

41:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 24, ptr %9) #5
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  store i64 0, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  store i64 34, ptr %11, align 8, !tbaa !9
  br label %42

42:                                               ; preds = %48, %41
  %43 = load i64, ptr %11, align 8, !tbaa !9
  %44 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %43) #5
  %45 = load i32, ptr %44, align 4, !tbaa !5
  %46 = icmp ne i32 %45, 0
  %47 = xor i1 %46, true
  br i1 %47, label %48, label %51

48:                                               ; preds = %42
  %49 = load i64, ptr %11, align 8, !tbaa !9
  %50 = add nsw i64 %49, -1
  store i64 %50, ptr %11, align 8, !tbaa !9
  br label %42, !llvm.loop !13

51:                                               ; preds = %42
  br label %52

52:                                               ; preds = %143, %51
  %53 = load i64, ptr %11, align 8, !tbaa !9
  %54 = icmp sge i64 %53, 0
  br i1 %54, label %55, label %146

55:                                               ; preds = %52
  %56 = load i64, ptr %11, align 8, !tbaa !9
  %57 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %56) #5
  %58 = load i32, ptr %57, align 4, !tbaa !5
  %59 = icmp ne i32 %58, 0
  br i1 %59, label %60, label %61

60:                                               ; preds = %55
  br label %143

61:                                               ; preds = %55
  %62 = load i64, ptr %10, align 8, !tbaa !9
  %63 = add nsw i64 %62, 1
  store i64 %63, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %64 = load i64, ptr %11, align 8, !tbaa !9
  %65 = add nsw i64 %64, 1
  store i64 %65, ptr %12, align 8, !tbaa !9
  invoke void @_ZNSt6vectorIlSaIlEE9push_backEOl(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(8) %12)
          to label %66 unwind label %72

66:                                               ; preds = %61
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  store i64 0, ptr %13, align 8, !tbaa !9
  br label %67

67:                                               ; preds = %83, %66
  %68 = load i64, ptr %13, align 8, !tbaa !9
  %69 = load i64, ptr %11, align 8, !tbaa !9
  %70 = icmp sle i64 %68, %69
  br i1 %70, label %76, label %71

71:                                               ; preds = %67
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  br label %86

72:                                               ; preds = %61
  %73 = landingpad { ptr, i32 }
          cleanup
  %74 = extractvalue { ptr, i32 } %73, 0
  store ptr %74, ptr %6, align 8
  %75 = extractvalue { ptr, i32 } %73, 1
  store i32 %75, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  br label %176

76:                                               ; preds = %67
  %77 = load i64, ptr %13, align 8, !tbaa !9
  %78 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %77) #5
  %79 = load i32, ptr %78, align 4, !tbaa !5
  %80 = sub nsw i32 1, %79
  %81 = load i64, ptr %13, align 8, !tbaa !9
  %82 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %81) #5
  store i32 %80, ptr %82, align 4, !tbaa !5
  br label %83

83:                                               ; preds = %76
  %84 = load i64, ptr %13, align 8, !tbaa !9
  %85 = add nsw i64 %84, 1
  store i64 %85, ptr %13, align 8, !tbaa !9
  br label %67, !llvm.loop !14

86:                                               ; preds = %71
  %87 = load i64, ptr %11, align 8, !tbaa !9
  %88 = icmp eq i64 %87, 0
  br i1 %88, label %89, label %90

89:                                               ; preds = %86
  br label %146

90:                                               ; preds = %86
  call void @llvm.lifetime.start.p0(i64 1, ptr %14) #5
  store i8 1, ptr %14, align 1, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %91

91:                                               ; preds = %103, %90
  %92 = load i64, ptr %15, align 8, !tbaa !9
  %93 = load i64, ptr %11, align 8, !tbaa !9
  %94 = icmp slt i64 %92, %93
  br i1 %94, label %96, label %95

95:                                               ; preds = %91
  store i32 13, ptr %16, align 4
  br label %106

96:                                               ; preds = %91
  %97 = load i64, ptr %15, align 8, !tbaa !9
  %98 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %97) #5
  %99 = load i32, ptr %98, align 4, !tbaa !5
  %100 = icmp eq i32 %99, 0
  br i1 %100, label %101, label %102

101:                                              ; preds = %96
  store i8 0, ptr %14, align 1, !tbaa !15
  store i32 13, ptr %16, align 4
  br label %106

102:                                              ; preds = %96
  br label %103

103:                                              ; preds = %102
  %104 = load i64, ptr %15, align 8, !tbaa !9
  %105 = add nsw i64 %104, 1
  store i64 %105, ptr %15, align 8, !tbaa !9
  br label %91, !llvm.loop !17

106:                                              ; preds = %101, %95
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  br label %107

107:                                              ; preds = %106
  %108 = load i8, ptr %14, align 1, !tbaa !15, !range !18, !noundef !19
  %109 = trunc i8 %108 to i1
  br i1 %109, label %110, label %111

110:                                              ; preds = %107
  store i32 7, ptr %16, align 4
  br label %140

111:                                              ; preds = %107
  %112 = load i64, ptr %10, align 8, !tbaa !9
  %113 = add nsw i64 %112, 1
  store i64 %113, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 1, ptr %17) #5
  store i8 1, ptr %17, align 1, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  store i64 0, ptr %18, align 8, !tbaa !9
  br label %114

114:                                              ; preds = %136, %111
  %115 = load i64, ptr %18, align 8, !tbaa !9
  %116 = load i64, ptr %11, align 8, !tbaa !9
  %117 = icmp slt i64 %115, %116
  br i1 %117, label %119, label %118

118:                                              ; preds = %114
  store i32 16, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  br label %139

119:                                              ; preds = %114
  %120 = load i8, ptr %17, align 1, !tbaa !15, !range !18, !noundef !19
  %121 = trunc i8 %120 to i1
  %122 = zext i1 %121 to i32
  %123 = load i64, ptr %18, align 8, !tbaa !9
  %124 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %123) #5
  %125 = load i32, ptr %124, align 4, !tbaa !5
  %126 = add nsw i32 %125, %122
  store i32 %126, ptr %124, align 4, !tbaa !5
  %127 = load i64, ptr %18, align 8, !tbaa !9
  %128 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %127) #5
  %129 = load i32, ptr %128, align 4, !tbaa !5
  %130 = icmp sgt i32 %129, 1
  %131 = zext i1 %130 to i8
  store i8 %131, ptr %17, align 1, !tbaa !15
  %132 = load i64, ptr %18, align 8, !tbaa !9
  %133 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef %132) #5
  %134 = load i32, ptr %133, align 4, !tbaa !5
  %135 = srem i32 %134, 2
  store i32 %135, ptr %133, align 4, !tbaa !5
  br label %136

136:                                              ; preds = %119
  %137 = load i64, ptr %18, align 8, !tbaa !9
  %138 = add nsw i64 %137, 1
  store i64 %138, ptr %18, align 8, !tbaa !9
  br label %114, !llvm.loop !20

139:                                              ; preds = %118
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #5
  store i32 0, ptr %16, align 4
  br label %140

140:                                              ; preds = %139, %110
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #5
  %141 = load i32, ptr %16, align 4
  switch i32 %141, label %183 [
    i32 0, label %142
    i32 7, label %146
  ]

142:                                              ; preds = %140
  br label %143

143:                                              ; preds = %142, %60
  %144 = load i64, ptr %11, align 8, !tbaa !9
  %145 = add nsw i64 %144, -1
  store i64 %145, ptr %11, align 8, !tbaa !9
  br label %52, !llvm.loop !21

146:                                              ; preds = %140, %89, %52
  %147 = load i64, ptr %10, align 8, !tbaa !9
  %148 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1, i64 noundef %147)
          to label %149 unwind label %155

149:                                              ; preds = %146
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  store i64 0, ptr %19, align 8, !tbaa !9
  br label %150

150:                                              ; preds = %165, %149
  %151 = load i64, ptr %19, align 8, !tbaa !9
  %152 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  %153 = icmp ult i64 %151, %152
  br i1 %153, label %159, label %154

154:                                              ; preds = %150
  store i32 19, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %172

155:                                              ; preds = %172, %146
  %156 = landingpad { ptr, i32 }
          cleanup
  %157 = extractvalue { ptr, i32 } %156, 0
  store ptr %157, ptr %6, align 8
  %158 = extractvalue { ptr, i32 } %156, 1
  store i32 %158, ptr %7, align 4
  br label %176

159:                                              ; preds = %150
  %160 = load i64, ptr %19, align 8, !tbaa !9
  %161 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %9, i64 noundef %160) #5
  %162 = load i64, ptr %161, align 8, !tbaa !9
  %163 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.2, i64 noundef %162)
          to label %164 unwind label %168

164:                                              ; preds = %159
  br label %165

165:                                              ; preds = %164
  %166 = load i64, ptr %19, align 8, !tbaa !9
  %167 = add nsw i64 %166, 1
  store i64 %167, ptr %19, align 8, !tbaa !9
  br label %150, !llvm.loop !22

168:                                              ; preds = %159
  %169 = landingpad { ptr, i32 }
          cleanup
  %170 = extractvalue { ptr, i32 } %169, 0
  store ptr %170, ptr %6, align 8
  %171 = extractvalue { ptr, i32 } %169, 1
  store i32 %171, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %176

172:                                              ; preds = %154
  %173 = invoke i32 @puts(ptr noundef @.str.3)
          to label %174 unwind label %155

174:                                              ; preds = %172
  store i32 0, ptr %1, align 4
  store i32 1, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #5
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  %175 = load i32, ptr %1, align 4
  ret i32 %175

176:                                              ; preds = %168, %155, %72
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #5
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %3) #5
  br label %177

177:                                              ; preds = %176, %26
  call void @llvm.lifetime.end.p0(i64 24, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  br label %178

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

183:                                              ; preds = %140
  unreachable
}

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEEC2EmRKiRKS0_(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef, ptr noundef nonnull align 4 dereferenceable(4), 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) #1

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

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

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

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

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

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

declare i32 @puts(ptr noundef) #2

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

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

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress 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 #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 = { 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 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = !{!16, !16, i64 0}
!16 = !{!"bool", !7, i64 0}
!17 = distinct !{!17, !12}
!18 = !{i8 0, i8 2}
!19 = !{}
!20 = distinct !{!20, !12}
!21 = distinct !{!21, !12}
!22 = distinct !{!22, !12}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::allocator" = type { i8 }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl" }
%"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl" = type { %"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<long, std::allocator<long>>::_Vector_impl_data" = type { ptr, ptr, ptr }

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

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

8:                                                ; preds = %0
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #5
  %.pre = load i64, ptr %1, align 8, !tbaa !9
  br label %12

9:                                                ; preds = %12
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #5
  call void @_ZNSt6vectorIlSaIlEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  br label %20

10:                                               ; preds = %0
  %11 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIiED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #5
  br label %68

12:                                               ; preds = %8, %12
  %13 = phi i64 [ %.pre, %8 ], [ %18, %12 ]
  %.04558 = phi i64 [ 0, %8 ], [ %19, %12 ]
  %14 = srem i64 %13, 2
  %15 = trunc nsw i64 %14 to i32
  %16 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.04558) #5
  store i32 %15, ptr %16, align 4, !tbaa !5
  %17 = load i64, ptr %1, align 8, !tbaa !9
  %18 = sdiv i64 %17, 2
  store i64 %18, ptr %1, align 8, !tbaa !9
  %19 = add nuw nsw i64 %.04558, 1
  %exitcond.not = icmp eq i64 %19, 35
  br i1 %exitcond.not, label %9, label %12, !llvm.loop !11

20:                                               ; preds = %20, %9
  %indvars.iv = phi i64 [ %indvars.iv.next, %20 ], [ 35, %9 ]
  %.042 = phi i64 [ %23, %20 ], [ 34, %9 ]
  %21 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.042) #5
  %22 = load i32, ptr %21, align 4, !tbaa !5
  %.not = icmp eq i32 %22, 0
  %23 = add nsw i64 %.042, -1
  %indvars.iv.next = add nsw i64 %indvars.iv, -1
  br i1 %.not, label %20, label %.preheader55, !llvm.loop !13

.preheader55:                                     ; preds = %20
  %24 = icmp sgt i64 %.042, -1
  br i1 %24, label %.lr.ph76, label %.critedge

.lr.ph76:                                         ; preds = %.preheader55, %.critedge.thread
  %indvars.iv85 = phi i64 [ %indvars.iv.next86, %.critedge.thread ], [ %indvars.iv, %.preheader55 ]
  %.174 = phi i64 [ %55, %.critedge.thread ], [ %.042, %.preheader55 ]
  %.04373 = phi i64 [ %.2, %.critedge.thread ], [ 0, %.preheader55 ]
  %25 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.174) #5
  %26 = load i32, ptr %25, align 4, !tbaa !5
  %.not48 = icmp eq i32 %26, 0
  br i1 %.not48, label %27, label %.critedge.thread

27:                                               ; preds = %.lr.ph76
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  %28 = add nuw nsw i64 %.174, 1
  store i64 %28, ptr %6, align 8, !tbaa !9
  invoke void @_ZNSt6vectorIlSaIlEE9push_backEOl(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(8) %6)
          to label %.lr.ph.preheader unwind label %30

.lr.ph.preheader:                                 ; preds = %27
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph
  %29 = icmp eq i64 %.174, 0
  br i1 %29, label %.critedge.loopexit56.split.loop.exit69, label %.lr.ph63

30:                                               ; preds = %27
  %31 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #5
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #5
  br label %68

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %.04160 = phi i64 [ %36, %.lr.ph ], [ 0, %.lr.ph.preheader ]
  %32 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.04160) #5
  %33 = load i32, ptr %32, align 4, !tbaa !5
  %34 = sub nsw i32 1, %33
  %35 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.04160) #5
  store i32 %34, ptr %35, align 4, !tbaa !5
  %36 = add nuw i64 %.04160, 1
  %exitcond87.not = icmp eq i64 %36, %indvars.iv85
  br i1 %exitcond87.not, label %._crit_edge, label %.lr.ph, !llvm.loop !14

37:                                               ; preds = %.lr.ph63
  %38 = add nuw nsw i64 %.03962, 1
  %.not51 = icmp ult i64 %38, %.174
  br i1 %.not51, label %.lr.ph63, label %..critedge.loopexit_crit_edge, !llvm.loop !15

.lr.ph63:                                         ; preds = %._crit_edge, %37
  %.03962 = phi i64 [ %38, %37 ], [ 0, %._crit_edge ]
  %39 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03962) #5
  %40 = load i32, ptr %39, align 4, !tbaa !5
  %41 = icmp eq i32 %40, 0
  br i1 %41, label %.lr.ph68.preheader, label %37

.lr.ph68.preheader:                               ; preds = %.lr.ph63
  %42 = add nsw i64 %.04373, 2
  br label %.lr.ph68

.lr.ph68:                                         ; preds = %.lr.ph68.preheader, %.lr.ph68
  %.03666 = phi i64 [ %53, %.lr.ph68 ], [ 0, %.lr.ph68.preheader ]
  %.03765 = phi i1 [ %49, %.lr.ph68 ], [ true, %.lr.ph68.preheader ]
  %43 = zext i1 %.03765 to i32
  %44 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03666) #5
  %45 = load i32, ptr %44, align 4, !tbaa !5
  %46 = add nsw i32 %45, %43
  store i32 %46, ptr %44, align 4, !tbaa !5
  %47 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03666) #5
  %48 = load i32, ptr %47, align 4, !tbaa !5
  %49 = icmp sgt i32 %48, 1
  %50 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %.03666) #5
  %51 = load i32, ptr %50, align 4, !tbaa !5
  %52 = srem i32 %51, 2
  store i32 %52, ptr %50, align 4, !tbaa !5
  %53 = add nuw nsw i64 %.03666, 1
  %54 = icmp ult i64 %53, %.174
  br i1 %54, label %.lr.ph68, label %.critedge.thread, !llvm.loop !16

.critedge.thread:                                 ; preds = %.lr.ph68, %.lr.ph76
  %.2 = phi i64 [ %.04373, %.lr.ph76 ], [ %42, %.lr.ph68 ]
  %55 = add nsw i64 %.174, -1
  %56 = icmp sgt i64 %.174, 0
  %indvars.iv.next86 = add nsw i64 %indvars.iv85, -1
  br i1 %56, label %.lr.ph76, label %.critedge, !llvm.loop !17

..critedge.loopexit_crit_edge:                    ; preds = %37
  %57 = add nsw i64 %.04373, 1
  br label %.critedge

.critedge.loopexit56.split.loop.exit69:           ; preds = %._crit_edge
  %58 = add nsw i64 %.04373, 1
  br label %.critedge

.critedge:                                        ; preds = %.critedge.thread, %.critedge.loopexit56.split.loop.exit69, %.preheader55, %..critedge.loopexit_crit_edge
  %.3 = phi i64 [ %57, %..critedge.loopexit_crit_edge ], [ %58, %.critedge.loopexit56.split.loop.exit69 ], [ 0, %.preheader55 ], [ %.2, %.critedge.thread ]
  %59 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, i64 noundef %.3)
  %60 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  %.not80 = icmp eq i64 %60, 0
  br i1 %.not80, label %._crit_edge79, label %.lr.ph78

._crit_edge79:                                    ; preds = %.lr.ph78, %.critedge
  %61 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.3)
  call void @_ZNSt6vectorIlSaIlEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #5
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %2) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #5
  ret i32 0

.lr.ph78:                                         ; preds = %.critedge, %.lr.ph78
  %.077 = phi i64 [ %65, %.lr.ph78 ], [ 0, %.critedge ]
  %62 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIlSaIlEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %.077) #5
  %63 = load i64, ptr %62, align 8, !tbaa !9
  %64 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i64 noundef %63)
  %65 = add nuw nsw i64 %.077, 1
  %66 = call noundef i64 @_ZNKSt6vectorIlSaIlEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #5
  %67 = icmp ult i64 %65, %66
  br i1 %67, label %.lr.ph78, label %._crit_edge79, !llvm.loop !18

68:                                               ; preds = %30, %10
  %.pn = phi { ptr, i32 } [ %31, %30 ], [ %11, %10 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #5
  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) #1

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEEC2EmRKiRKS0_(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef, ptr noundef nonnull align 4 dereferenceable(4), 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) #1

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

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

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

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

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

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

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

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

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

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #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 = { 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 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}


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