; LLVM IR from lzyrapx/Competitive-Programming :: Codeforces/Math/1257G.ll (Z9poly_sqrt4polyi)

; 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.poly = type <{ %"class.std::vector", i32, [4 x i8] }>
%"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 }

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_Z5mypowii(i32 noundef, i32 noundef) #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 uwtable
declare dso_local void @_Z3add4polyS_(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

; 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) #0 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3ext4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, i32 noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z10scalar_mul4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, i32 noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3mul4polyS_(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, ptr noundef) #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28), ptr noundef nonnull align 8 dereferenceable(28)) unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(28) ptr @_ZN4polyaSEOS_(ptr noundef nonnull align 8 dereferenceable(28), ptr noundef nonnull align 8 dereferenceable(28)) #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z8poly_inv4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, i32 noundef) #2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z9poly_sqrt4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8 %0, ptr noundef %1, i32 noundef %2) #2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca [21 x i32], align 16
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i1, align 1
  %12 = alloca [21 x %struct.poly], align 16
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca %struct.poly, align 8
  %16 = alloca %struct.poly, align 8
  %17 = alloca %struct.poly, align 8
  %18 = alloca %struct.poly, align 8
  %19 = alloca %struct.poly, align 8
  %20 = alloca %struct.poly, align 8
  %21 = alloca %struct.poly, align 8
  %22 = alloca %struct.poly, align 8
  %23 = alloca %struct.poly, align 8
  %24 = alloca %struct.poly, align 8
  %25 = alloca %struct.poly, align 8
  store ptr %0, ptr %4, align 8
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i32 %2, ptr %6, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 84, ptr %8) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  %26 = call noundef i32 @_Z5mypowii(i32 noundef 2, i32 noundef 998244351)
  store i32 %26, ptr %10, align 4, !tbaa !9
  store i1 false, ptr %11, align 1
  call void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %0)
  call void @llvm.lifetime.start.p0(i64 672, ptr %12) #5
  %27 = getelementptr inbounds [21 x %struct.poly], ptr %12, i32 0, i32 0
  %28 = getelementptr inbounds %struct.poly, ptr %27, i64 21
  br label %29

29:                                               ; preds = %31, %3
  %30 = phi ptr [ %27, %3 ], [ %32, %31 ]
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %30)
          to label %31 unwind label %62

31:                                               ; preds = %29
  %32 = getelementptr inbounds %struct.poly, ptr %30, i64 1
  %33 = icmp eq ptr %32, %28
  br i1 %33, label %34, label %29

34:                                               ; preds = %31
  br label %35

35:                                               ; preds = %42, %34
  %36 = load i32, ptr %6, align 4, !tbaa !9
  %37 = icmp ne i32 %36, 1
  br i1 %37, label %38, label %81

38:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 32, ptr %15) #5
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %16, ptr noundef nonnull align 8 dereferenceable(28) %1)
          to label %39 unwind label %72

39:                                               ; preds = %38
  %40 = load i32, ptr %6, align 4, !tbaa !9
  %41 = sub nsw i32 %40, 1
  invoke void @_Z3ext4polyi(ptr dead_on_unwind writable sret(%struct.poly) align 8 %15, ptr noundef %16, i32 noundef %41)
          to label %42 unwind label %76

42:                                               ; preds = %39
  %43 = load i32, ptr %9, align 4, !tbaa !9
  %44 = add nsw i32 %43, 1
  store i32 %44, ptr %9, align 4, !tbaa !9
  %45 = sext i32 %44 to i64
  %46 = getelementptr inbounds [21 x %struct.poly], ptr %12, i64 0, i64 %45
  %47 = call noundef nonnull align 8 dereferenceable(28) ptr @_ZN4polyaSEOS_(ptr noundef nonnull align 8 dereferenceable(28) %46, ptr noundef nonnull align 8 dereferenceable(28) %15) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %15) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %16) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %15) #5
  %48 = load i32, ptr %6, align 4, !tbaa !9
  %49 = load i32, ptr %9, align 4, !tbaa !9
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds [21 x i32], ptr %8, i64 0, i64 %50
  store i32 %48, ptr %51, align 4, !tbaa !9
  %52 = load i32, ptr %6, align 4, !tbaa !9
  %53 = sdiv i32 %52, 2
  %54 = load i32, ptr %6, align 4, !tbaa !9
  %55 = and i32 %54, 1
  %56 = add nsw i32 %53, %55
  store i32 %56, ptr %6, align 4, !tbaa !9
  %57 = load i32, ptr %9, align 4, !tbaa !9
  %58 = sext i32 %57 to i64
  %59 = getelementptr inbounds [21 x %struct.poly], ptr %12, i64 0, i64 %58
  %60 = getelementptr inbounds %struct.poly, ptr %59, i32 0, i32 0
  %61 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef 0) #5
  store i32 1, ptr %61, align 4, !tbaa !9
  br label %35, !llvm.loop !11

62:                                               ; preds = %29
  %63 = landingpad { ptr, i32 }
          cleanup
  %64 = extractvalue { ptr, i32 } %63, 0
  store ptr %64, ptr %13, align 8
  %65 = extractvalue { ptr, i32 } %63, 1
  store i32 %65, ptr %14, align 4
  %66 = icmp eq ptr %27, %30
  br i1 %66, label %71, label %67

67:                                               ; preds = %67, %62
  %68 = phi ptr [ %30, %62 ], [ %69, %67 ]
  %69 = getelementptr inbounds %struct.poly, ptr %68, i64 -1
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %69) #5
  %70 = icmp eq ptr %69, %27
  br i1 %70, label %71, label %67

71:                                               ; preds = %67, %62
  br label %175

72:                                               ; preds = %38
  %73 = landingpad { ptr, i32 }
          cleanup
  %74 = extractvalue { ptr, i32 } %73, 0
  store ptr %74, ptr %13, align 8
  %75 = extractvalue { ptr, i32 } %73, 1
  store i32 %75, ptr %14, align 4
  br label %80

76:                                               ; preds = %39
  %77 = landingpad { ptr, i32 }
          cleanup
  %78 = extractvalue { ptr, i32 } %77, 0
  store ptr %78, ptr %13, align 8
  %79 = extractvalue { ptr, i32 } %77, 1
  store i32 %79, ptr %14, align 4
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %16) #5
  br label %80

80:                                               ; preds = %76, %72
  call void @llvm.lifetime.end.p0(i64 32, ptr %15) #5
  br label %167

81:                                               ; preds = %35
  %82 = getelementptr inbounds %struct.poly, ptr %0, i32 0, i32 0
  %83 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %82, i64 noundef 0) #5
  store i32 1, ptr %83, align 4, !tbaa !9
  %84 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %84, ptr %7, align 4, !tbaa !9
  br label %85

85:                                               ; preds = %111, %81
  %86 = load i32, ptr %7, align 4, !tbaa !9
  %87 = icmp sgt i32 %86, 0
  br i1 %87, label %88, label %158

88:                                               ; preds = %85
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #5
  %89 = load i32, ptr %7, align 4, !tbaa !9
  %90 = sext i32 %89 to i64
  %91 = getelementptr inbounds [21 x %struct.poly], ptr %12, i64 0, i64 %90
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %20, ptr noundef nonnull align 8 dereferenceable(28) %91)
          to label %92 unwind label %114

92:                                               ; preds = %88
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %23, ptr noundef nonnull align 8 dereferenceable(28) %0)
          to label %93 unwind label %118

93:                                               ; preds = %92
  invoke void @_Z10scalar_mul4polyi(ptr dead_on_unwind writable sret(%struct.poly) align 8 %22, ptr noundef %23, i32 noundef 2)
          to label %94 unwind label %122

94:                                               ; preds = %93
  %95 = load i32, ptr %7, align 4, !tbaa !9
  %96 = sext i32 %95 to i64
  %97 = getelementptr inbounds [21 x i32], ptr %8, i64 0, i64 %96
  %98 = load i32, ptr %97, align 4, !tbaa !9
  invoke void @_Z8poly_inv4polyi(ptr dead_on_unwind writable sret(%struct.poly) align 8 %21, ptr noundef %22, i32 noundef %98)
          to label %99 unwind label %126

99:                                               ; preds = %94
  invoke void @_Z3mul4polyS_(ptr dead_on_unwind writable sret(%struct.poly) align 8 %19, ptr noundef %20, ptr noundef %21)
          to label %100 unwind label %130

100:                                              ; preds = %99
  %101 = load i32, ptr %7, align 4, !tbaa !9
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds [21 x i32], ptr %8, i64 0, i64 %102
  %104 = load i32, ptr %103, align 4, !tbaa !9
  invoke void @_Z3ext4polyi(ptr dead_on_unwind writable sret(%struct.poly) align 8 %18, ptr noundef %19, i32 noundef %104)
          to label %105 unwind label %134

105:                                              ; preds = %100
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %25, ptr noundef nonnull align 8 dereferenceable(28) %0)
          to label %106 unwind label %138

106:                                              ; preds = %105
  %107 = load i32, ptr %10, align 4, !tbaa !9
  invoke void @_Z10scalar_mul4polyi(ptr dead_on_unwind writable sret(%struct.poly) align 8 %24, ptr noundef %25, i32 noundef %107)
          to label %108 unwind label %142

108:                                              ; preds = %106
  invoke void @_Z3add4polyS_(ptr dead_on_unwind writable sret(%struct.poly) align 8 %17, ptr noundef %18, ptr noundef %24)
          to label %109 unwind label %146

109:                                              ; preds = %108
  %110 = call noundef nonnull align 8 dereferenceable(28) ptr @_ZN4polyaSEOS_(ptr noundef nonnull align 8 dereferenceable(28) %0, ptr noundef nonnull align 8 dereferenceable(28) %17) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %17) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %24) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %25) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %18) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %19) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %21) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %22) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %23) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %20) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #5
  br label %111

111:                                              ; preds = %109
  %112 = load i32, ptr %7, align 4, !tbaa !9
  %113 = add nsw i32 %112, -1
  store i32 %113, ptr %7, align 4, !tbaa !9
  br label %85, !llvm.loop !13

114:                                              ; preds = %88
  %115 = landingpad { ptr, i32 }
          cleanup
  %116 = extractvalue { ptr, i32 } %115, 0
  store ptr %116, ptr %13, align 8
  %117 = extractvalue { ptr, i32 } %115, 1
  store i32 %117, ptr %14, align 4
  br label %157

118:                                              ; preds = %92
  %119 = landingpad { ptr, i32 }
          cleanup
  %120 = extractvalue { ptr, i32 } %119, 0
  store ptr %120, ptr %13, align 8
  %121 = extractvalue { ptr, i32 } %119, 1
  store i32 %121, ptr %14, align 4
  br label %156

122:                                              ; preds = %93
  %123 = landingpad { ptr, i32 }
          cleanup
  %124 = extractvalue { ptr, i32 } %123, 0
  store ptr %124, ptr %13, align 8
  %125 = extractvalue { ptr, i32 } %123, 1
  store i32 %125, ptr %14, align 4
  br label %155

126:                                              ; preds = %94
  %127 = landingpad { ptr, i32 }
          cleanup
  %128 = extractvalue { ptr, i32 } %127, 0
  store ptr %128, ptr %13, align 8
  %129 = extractvalue { ptr, i32 } %127, 1
  store i32 %129, ptr %14, align 4
  br label %154

130:                                              ; preds = %99
  %131 = landingpad { ptr, i32 }
          cleanup
  %132 = extractvalue { ptr, i32 } %131, 0
  store ptr %132, ptr %13, align 8
  %133 = extractvalue { ptr, i32 } %131, 1
  store i32 %133, ptr %14, align 4
  br label %153

134:                                              ; preds = %100
  %135 = landingpad { ptr, i32 }
          cleanup
  %136 = extractvalue { ptr, i32 } %135, 0
  store ptr %136, ptr %13, align 8
  %137 = extractvalue { ptr, i32 } %135, 1
  store i32 %137, ptr %14, align 4
  br label %152

138:                                              ; preds = %105
  %139 = landingpad { ptr, i32 }
          cleanup
  %140 = extractvalue { ptr, i32 } %139, 0
  store ptr %140, ptr %13, align 8
  %141 = extractvalue { ptr, i32 } %139, 1
  store i32 %141, ptr %14, align 4
  br label %151

142:                                              ; preds = %106
  %143 = landingpad { ptr, i32 }
          cleanup
  %144 = extractvalue { ptr, i32 } %143, 0
  store ptr %144, ptr %13, align 8
  %145 = extractvalue { ptr, i32 } %143, 1
  store i32 %145, ptr %14, align 4
  br label %150

146:                                              ; preds = %108
  %147 = landingpad { ptr, i32 }
          cleanup
  %148 = extractvalue { ptr, i32 } %147, 0
  store ptr %148, ptr %13, align 8
  %149 = extractvalue { ptr, i32 } %147, 1
  store i32 %149, ptr %14, align 4
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %24) #5
  br label %150

150:                                              ; preds = %146, %142
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %25) #5
  br label %151

151:                                              ; preds = %150, %138
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %18) #5
  br label %152

152:                                              ; preds = %151, %134
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %19) #5
  br label %153

153:                                              ; preds = %152, %130
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %21) #5
  br label %154

154:                                              ; preds = %153, %126
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %22) #5
  br label %155

155:                                              ; preds = %154, %122
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %23) #5
  br label %156

156:                                              ; preds = %155, %118
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %20) #5
  br label %157

157:                                              ; preds = %156, %114
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #5
  br label %167

158:                                              ; preds = %85
  store i1 true, ptr %11, align 1
  %159 = getelementptr inbounds [21 x %struct.poly], ptr %12, i32 0, i32 0
  %160 = getelementptr inbounds %struct.poly, ptr %159, i64 21
  br label %161

161:                                              ; preds = %161, %158
  %162 = phi ptr [ %160, %158 ], [ %163, %161 ]
  %163 = getelementptr inbounds %struct.poly, ptr %162, i64 -1
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %163) #5
  %164 = icmp eq ptr %163, %159
  br i1 %164, label %165, label %161

165:                                              ; preds = %161
  call void @llvm.lifetime.end.p0(i64 672, ptr %12) #5
  %166 = load i1, ptr %11, align 1
  br i1 %166, label %177, label %176

167:                                              ; preds = %157, %80
  %168 = getelementptr inbounds [21 x %struct.poly], ptr %12, i32 0, i32 0
  %169 = getelementptr inbounds %struct.poly, ptr %168, i64 21
  br label %170

170:                                              ; preds = %170, %167
  %171 = phi ptr [ %169, %167 ], [ %172, %170 ]
  %172 = getelementptr inbounds %struct.poly, ptr %171, i64 -1
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %172) #5
  %173 = icmp eq ptr %172, %168
  br i1 %173, label %174, label %170

174:                                              ; preds = %170
  br label %175

175:                                              ; preds = %174, %71
  call void @llvm.lifetime.end.p0(i64 672, ptr %12) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %0) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 84, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  br label %178

176:                                              ; preds = %165
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %0) #5
  br label %177

177:                                              ; preds = %176, %165
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 84, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  ret void

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

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 uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress 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 = { 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 #5 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !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"

%struct.poly = type <{ %"class.std::vector", i32, [4 x i8] }>
%"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 }

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_Z5mypowii(i32 noundef, i32 noundef) local_unnamed_addr #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 uwtable
declare dso_local void @_Z3add4polyS_(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

; 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 #0 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3ext4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, i32 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z10scalar_mul4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, i32 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z3mul4polyS_(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28), ptr noundef nonnull align 8 dereferenceable(28)) unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(28) ptr @_ZN4polyaSEOS_(ptr noundef nonnull align 8 dereferenceable(28), ptr noundef nonnull align 8 dereferenceable(28)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z8poly_inv4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8, ptr noundef, i32 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z9poly_sqrt4polyi(ptr dead_on_unwind noalias writable sret(%struct.poly) align 8 %0, ptr noundef %1, i32 noundef %2) local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %4 = alloca [21 x i32], align 16
  %5 = alloca [21 x %struct.poly], align 16
  %6 = alloca %struct.poly, align 8
  %7 = alloca %struct.poly, align 8
  %8 = alloca %struct.poly, align 8
  %9 = alloca %struct.poly, align 8
  %10 = alloca %struct.poly, align 8
  %11 = alloca %struct.poly, align 8
  %12 = alloca %struct.poly, align 8
  %13 = alloca %struct.poly, align 8
  %14 = alloca %struct.poly, align 8
  %15 = alloca %struct.poly, align 8
  %16 = alloca %struct.poly, align 8
  call void @llvm.lifetime.start.p0(i64 84, ptr nonnull %4) #5
  %17 = tail call noundef i32 @_Z5mypowii(i32 noundef 2, i32 noundef 998244351)
  tail call void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %0)
  call void @llvm.lifetime.start.p0(i64 672, ptr nonnull %5) #5
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %5)
          to label %18 unwind label %49

18:                                               ; preds = %3
  %.ptr.1 = getelementptr inbounds i8, ptr %5, i64 32
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.1)
          to label %19 unwind label %.preheader48.preheader

19:                                               ; preds = %18
  %.ptr.2 = getelementptr inbounds i8, ptr %5, i64 64
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.2)
          to label %20 unwind label %.preheader48.preheader

20:                                               ; preds = %19
  %.ptr.3 = getelementptr inbounds i8, ptr %5, i64 96
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.3)
          to label %21 unwind label %.preheader48.preheader

21:                                               ; preds = %20
  %.ptr.4 = getelementptr inbounds i8, ptr %5, i64 128
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.4)
          to label %22 unwind label %.preheader48.preheader

22:                                               ; preds = %21
  %.ptr.5 = getelementptr inbounds i8, ptr %5, i64 160
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.5)
          to label %23 unwind label %.preheader48.preheader

23:                                               ; preds = %22
  %.ptr.6 = getelementptr inbounds i8, ptr %5, i64 192
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.6)
          to label %24 unwind label %.preheader48.preheader

24:                                               ; preds = %23
  %.ptr.7 = getelementptr inbounds i8, ptr %5, i64 224
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.7)
          to label %25 unwind label %.preheader48.preheader

25:                                               ; preds = %24
  %.ptr.8 = getelementptr inbounds i8, ptr %5, i64 256
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.8)
          to label %26 unwind label %.preheader48.preheader

26:                                               ; preds = %25
  %.ptr.9 = getelementptr inbounds i8, ptr %5, i64 288
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.9)
          to label %27 unwind label %.preheader48.preheader

27:                                               ; preds = %26
  %.ptr.10 = getelementptr inbounds i8, ptr %5, i64 320
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.10)
          to label %28 unwind label %.preheader48.preheader

28:                                               ; preds = %27
  %.ptr.11 = getelementptr inbounds i8, ptr %5, i64 352
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.11)
          to label %29 unwind label %.preheader48.preheader

29:                                               ; preds = %28
  %.ptr.12 = getelementptr inbounds i8, ptr %5, i64 384
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.12)
          to label %30 unwind label %.preheader48.preheader

30:                                               ; preds = %29
  %.ptr.13 = getelementptr inbounds i8, ptr %5, i64 416
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.13)
          to label %31 unwind label %.preheader48.preheader

31:                                               ; preds = %30
  %.ptr.14 = getelementptr inbounds i8, ptr %5, i64 448
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.14)
          to label %32 unwind label %.preheader48.preheader

32:                                               ; preds = %31
  %.ptr.15 = getelementptr inbounds i8, ptr %5, i64 480
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.15)
          to label %33 unwind label %.preheader48.preheader

33:                                               ; preds = %32
  %.ptr.16 = getelementptr inbounds i8, ptr %5, i64 512
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.16)
          to label %34 unwind label %.preheader48.preheader

34:                                               ; preds = %33
  %.ptr.17 = getelementptr inbounds i8, ptr %5, i64 544
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.17)
          to label %35 unwind label %.preheader48.preheader

35:                                               ; preds = %34
  %.ptr.18 = getelementptr inbounds i8, ptr %5, i64 576
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.18)
          to label %36 unwind label %.preheader48.preheader

36:                                               ; preds = %35
  %.ptr.19 = getelementptr inbounds i8, ptr %5, i64 608
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.19)
          to label %37 unwind label %.preheader48.preheader

37:                                               ; preds = %36
  %.ptr.20 = getelementptr inbounds i8, ptr %5, i64 640
  invoke void @_ZN4polyC2Ev(ptr noundef nonnull align 8 dereferenceable(28) %.ptr.20)
          to label %.preheader47 unwind label %.preheader48.preheader

.preheader47:                                     ; preds = %37
  %.not54 = icmp eq i32 %2, 1
  br i1 %.not54, label %._crit_edge.thread, label %.lr.ph

._crit_edge.thread:                               ; preds = %.preheader47
  %38 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef 0) #5
  store i32 1, ptr %38, align 4, !tbaa !5
  br label %.preheader

.lr.ph:                                           ; preds = %.preheader47, %41
  %indvars.iv = phi i64 [ %indvars.iv.next, %41 ], [ 0, %.preheader47 ]
  %.02856 = phi i32 [ %47, %41 ], [ %2, %.preheader47 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #5
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %7, ptr noundef nonnull align 8 dereferenceable(28) %1)
          to label %39 unwind label %53

39:                                               ; preds = %.lr.ph
  %40 = add nsw i32 %.02856, -1
  invoke void @_Z3ext4polyi(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %6, ptr noundef nonnull %7, i32 noundef %40)
          to label %41 unwind label %55

41:                                               ; preds = %39
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %42 = getelementptr inbounds [21 x %struct.poly], ptr %5, i64 0, i64 %indvars.iv.next
  %43 = call noundef nonnull align 8 dereferenceable(28) ptr @_ZN4polyaSEOS_(ptr noundef nonnull align 8 dereferenceable(28) %42, ptr noundef nonnull align 8 dereferenceable(28) %6) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %6) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %7) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #5
  %44 = getelementptr inbounds [21 x i32], ptr %4, i64 0, i64 %indvars.iv.next
  store i32 %.02856, ptr %44, align 4, !tbaa !5
  %45 = sdiv i32 %.02856, 2
  %46 = and i32 %.02856, 1
  %47 = add nsw i32 %45, %46
  %48 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %42, i64 noundef 0) #5
  store i32 1, ptr %48, align 4, !tbaa !5
  %.not = icmp eq i32 %47, 1
  br i1 %.not, label %._crit_edge, label %.lr.ph, !llvm.loop !9

49:                                               ; preds = %3
  %lpad.thr_comm.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %.loopexit

.preheader48.preheader:                           ; preds = %18, %19, %20, %21, %22, %23, %24, %25, %26, %27, %28, %29, %30, %31, %32, %33, %34, %35, %36, %37
  %.ptr.lcssa.ph = phi ptr [ %.ptr.20, %37 ], [ %.ptr.19, %36 ], [ %.ptr.18, %35 ], [ %.ptr.17, %34 ], [ %.ptr.16, %33 ], [ %.ptr.15, %32 ], [ %.ptr.14, %31 ], [ %.ptr.13, %30 ], [ %.ptr.12, %29 ], [ %.ptr.11, %28 ], [ %.ptr.10, %27 ], [ %.ptr.9, %26 ], [ %.ptr.8, %25 ], [ %.ptr.7, %24 ], [ %.ptr.6, %23 ], [ %.ptr.5, %22 ], [ %.ptr.4, %21 ], [ %.ptr.3, %20 ], [ %.ptr.2, %19 ], [ %.ptr.1, %18 ]
  %lpad.thr_comm = landingpad { ptr, i32 }
          cleanup
  br label %.preheader48

.preheader48:                                     ; preds = %.preheader48.preheader, %.preheader48
  %50 = phi ptr [ %51, %.preheader48 ], [ %.ptr.lcssa.ph, %.preheader48.preheader ]
  %51 = getelementptr inbounds i8, ptr %50, i64 -32
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %51) #5
  %52 = icmp eq ptr %51, %5
  br i1 %52, label %.loopexit, label %.preheader48

53:                                               ; preds = %.lr.ph
  %54 = landingpad { ptr, i32 }
          cleanup
  br label %57

55:                                               ; preds = %39
  %56 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %7) #5
  br label %57

57:                                               ; preds = %55, %53
  %.pn43 = phi { ptr, i32 } [ %56, %55 ], [ %54, %53 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #5
  br label %.loopexit.loopexit

._crit_edge:                                      ; preds = %41
  %58 = trunc nuw i64 %indvars.iv.next to i32
  %59 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %0, i64 noundef 0) #5
  store i32 1, ptr %59, align 4, !tbaa !5
  %60 = icmp sgt i32 %58, 0
  br i1 %60, label %.lr.ph59.preheader, label %.preheader

.lr.ph59.preheader:                               ; preds = %._crit_edge
  %61 = and i64 %indvars.iv.next, 2147483647
  br label %.lr.ph59

.preheader:                                       ; preds = %93, %._crit_edge.thread, %._crit_edge
  %62 = getelementptr inbounds i8, ptr %5, i64 640
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %62) #5
  %63 = getelementptr inbounds i8, ptr %5, i64 608
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %63) #5
  %64 = getelementptr inbounds i8, ptr %5, i64 576
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %64) #5
  %65 = getelementptr inbounds i8, ptr %5, i64 544
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %65) #5
  %66 = getelementptr inbounds i8, ptr %5, i64 512
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %66) #5
  %67 = getelementptr inbounds i8, ptr %5, i64 480
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %67) #5
  %68 = getelementptr inbounds i8, ptr %5, i64 448
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %68) #5
  %69 = getelementptr inbounds i8, ptr %5, i64 416
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %69) #5
  %70 = getelementptr inbounds i8, ptr %5, i64 384
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %70) #5
  %71 = getelementptr inbounds i8, ptr %5, i64 352
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %71) #5
  %72 = getelementptr inbounds i8, ptr %5, i64 320
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %72) #5
  %73 = getelementptr inbounds i8, ptr %5, i64 288
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %73) #5
  %74 = getelementptr inbounds i8, ptr %5, i64 256
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %74) #5
  %75 = getelementptr inbounds i8, ptr %5, i64 224
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %75) #5
  %76 = getelementptr inbounds i8, ptr %5, i64 192
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %76) #5
  %77 = getelementptr inbounds i8, ptr %5, i64 160
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %77) #5
  %78 = getelementptr inbounds i8, ptr %5, i64 128
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %78) #5
  %79 = getelementptr inbounds i8, ptr %5, i64 96
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %79) #5
  %80 = getelementptr inbounds i8, ptr %5, i64 64
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %80) #5
  %81 = getelementptr inbounds i8, ptr %5, i64 32
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %81) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %5) #5
  call void @llvm.lifetime.end.p0(i64 672, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 84, ptr nonnull %4) #5
  ret void

.lr.ph59:                                         ; preds = %.lr.ph59.preheader, %93
  %indvars.iv64 = phi i64 [ %61, %.lr.ph59.preheader ], [ %indvars.iv.next65, %93 ]
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #5
  %82 = getelementptr inbounds [21 x %struct.poly], ptr %5, i64 0, i64 %indvars.iv64
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %11, ptr noundef nonnull align 8 dereferenceable(28) %82)
          to label %83 unwind label %96

83:                                               ; preds = %.lr.ph59
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %14, ptr noundef nonnull align 8 dereferenceable(28) %0)
          to label %84 unwind label %98

84:                                               ; preds = %83
  invoke void @_Z10scalar_mul4polyi(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %13, ptr noundef nonnull %14, i32 noundef 2)
          to label %85 unwind label %100

85:                                               ; preds = %84
  %86 = getelementptr inbounds [21 x i32], ptr %4, i64 0, i64 %indvars.iv64
  %87 = load i32, ptr %86, align 4, !tbaa !5
  invoke void @_Z8poly_inv4polyi(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %12, ptr noundef nonnull %13, i32 noundef %87)
          to label %88 unwind label %102

88:                                               ; preds = %85
  invoke void @_Z3mul4polyS_(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %10, ptr noundef nonnull %11, ptr noundef nonnull %12)
          to label %89 unwind label %104

89:                                               ; preds = %88
  invoke void @_Z3ext4polyi(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %9, ptr noundef nonnull %10, i32 noundef %87)
          to label %90 unwind label %106

90:                                               ; preds = %89
  invoke void @_ZN4polyC2ERKS_(ptr noundef nonnull align 8 dereferenceable(28) %16, ptr noundef nonnull align 8 dereferenceable(28) %0)
          to label %91 unwind label %108

91:                                               ; preds = %90
  invoke void @_Z10scalar_mul4polyi(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %15, ptr noundef nonnull %16, i32 noundef %17)
          to label %92 unwind label %110

92:                                               ; preds = %91
  invoke void @_Z3add4polyS_(ptr dead_on_unwind nonnull writable sret(%struct.poly) align 8 %8, ptr noundef nonnull %9, ptr noundef nonnull %15)
          to label %93 unwind label %112

93:                                               ; preds = %92
  %94 = call noundef nonnull align 8 dereferenceable(28) ptr @_ZN4polyaSEOS_(ptr noundef nonnull align 8 dereferenceable(28) %0, ptr noundef nonnull align 8 dereferenceable(28) %8) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %8) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %15) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %16) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %9) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %10) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %12) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %13) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %14) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %11) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #5
  %indvars.iv.next65 = add nsw i64 %indvars.iv64, -1
  %95 = icmp sgt i64 %indvars.iv64, 1
  br i1 %95, label %.lr.ph59, label %.preheader, !llvm.loop !11

96:                                               ; preds = %.lr.ph59
  %97 = landingpad { ptr, i32 }
          cleanup
  br label %121

98:                                               ; preds = %83
  %99 = landingpad { ptr, i32 }
          cleanup
  br label %120

100:                                              ; preds = %84
  %101 = landingpad { ptr, i32 }
          cleanup
  br label %119

102:                                              ; preds = %85
  %103 = landingpad { ptr, i32 }
          cleanup
  br label %118

104:                                              ; preds = %88
  %105 = landingpad { ptr, i32 }
          cleanup
  br label %117

106:                                              ; preds = %89
  %107 = landingpad { ptr, i32 }
          cleanup
  br label %116

108:                                              ; preds = %90
  %109 = landingpad { ptr, i32 }
          cleanup
  br label %115

110:                                              ; preds = %91
  %111 = landingpad { ptr, i32 }
          cleanup
  br label %114

112:                                              ; preds = %92
  %113 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %15) #5
  br label %114

114:                                              ; preds = %112, %110
  %.pn = phi { ptr, i32 } [ %113, %112 ], [ %111, %110 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %16) #5
  br label %115

115:                                              ; preds = %114, %108
  %.pn.pn = phi { ptr, i32 } [ %.pn, %114 ], [ %109, %108 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %9) #5
  br label %116

116:                                              ; preds = %115, %106
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %115 ], [ %107, %106 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %10) #5
  br label %117

117:                                              ; preds = %116, %104
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %116 ], [ %105, %104 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %12) #5
  br label %118

118:                                              ; preds = %117, %102
  %.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn.pn, %117 ], [ %103, %102 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %13) #5
  br label %119

119:                                              ; preds = %118, %100
  %.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn.pn.pn, %118 ], [ %101, %100 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %14) #5
  br label %120

120:                                              ; preds = %119, %98
  %.pn.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn.pn.pn.pn, %119 ], [ %99, %98 ]
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %11) #5
  br label %121

121:                                              ; preds = %120, %96
  %.pn.pn.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn.pn.pn.pn.pn, %120 ], [ %97, %96 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #5
  br label %.loopexit.loopexit

.loopexit.loopexit:                               ; preds = %121, %57
  %.pn43.pn = phi { ptr, i32 } [ %.pn43, %57 ], [ %.pn.pn.pn.pn.pn.pn.pn.pn, %121 ]
  %122 = getelementptr inbounds i8, ptr %5, i64 640
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %122) #5
  %123 = getelementptr inbounds i8, ptr %5, i64 608
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %123) #5
  %124 = getelementptr inbounds i8, ptr %5, i64 576
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %124) #5
  %125 = getelementptr inbounds i8, ptr %5, i64 544
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %125) #5
  %126 = getelementptr inbounds i8, ptr %5, i64 512
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %126) #5
  %127 = getelementptr inbounds i8, ptr %5, i64 480
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %127) #5
  %128 = getelementptr inbounds i8, ptr %5, i64 448
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %128) #5
  %129 = getelementptr inbounds i8, ptr %5, i64 416
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %129) #5
  %130 = getelementptr inbounds i8, ptr %5, i64 384
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %130) #5
  %131 = getelementptr inbounds i8, ptr %5, i64 352
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %131) #5
  %132 = getelementptr inbounds i8, ptr %5, i64 320
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %132) #5
  %133 = getelementptr inbounds i8, ptr %5, i64 288
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %133) #5
  %134 = getelementptr inbounds i8, ptr %5, i64 256
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %134) #5
  %135 = getelementptr inbounds i8, ptr %5, i64 224
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %135) #5
  %136 = getelementptr inbounds i8, ptr %5, i64 192
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %136) #5
  %137 = getelementptr inbounds i8, ptr %5, i64 160
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %137) #5
  %138 = getelementptr inbounds i8, ptr %5, i64 128
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %138) #5
  %139 = getelementptr inbounds i8, ptr %5, i64 96
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %139) #5
  %140 = getelementptr inbounds i8, ptr %5, i64 64
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %140) #5
  %141 = getelementptr inbounds i8, ptr %5, i64 32
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %141) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %5) #5
  br label %.loopexit

.loopexit:                                        ; preds = %.preheader48, %49, %.loopexit.loopexit
  %.pn43.pn.pn = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %49 ], [ %.pn43.pn, %.loopexit.loopexit ], [ %lpad.thr_comm, %.preheader48 ]
  call void @llvm.lifetime.end.p0(i64 672, ptr nonnull %5) #5
  call void @_ZN4polyD2Ev(ptr noundef nonnull align 8 dereferenceable(28) %0) #5
  call void @llvm.lifetime.end.p0(i64 84, ptr nonnull %4) #5
  resume { ptr, i32 } %.pn43.pn.pn
}

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 uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress 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 = { 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 #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 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}


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