; LLVM IR from VastoLorde95/Competitive-Programming :: Codeforces/131 Division 1/Problem B (B)

; 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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }

@n = external dso_local global i32, align 4
@a = external dso_local global [10 x i32], align 16
@tot = external dso_local global i32, align 4
@MOD = external dso_local global i64, align 8
@c = external dso_local global [101 x [101 x i64]], align 16
@dp = external dso_local global [101 x [10 x i64]], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1

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

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

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #1 {
  %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 i64, align 8
  %12 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %13

13:                                               ; preds = %28, %0
  %14 = load i32, ptr %2, align 4, !tbaa !5
  %15 = icmp sle i32 %14, 100
  br i1 %15, label %17, label %16

16:                                               ; preds = %13
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  br label %31

17:                                               ; preds = %13
  %18 = load i32, ptr %2, align 4, !tbaa !5
  %19 = sext i32 %18 to i64
  %20 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %19
  %21 = load i32, ptr %2, align 4, !tbaa !5
  %22 = sext i32 %21 to i64
  %23 = getelementptr inbounds [101 x i64], ptr %20, i64 0, i64 %22
  store i64 1, ptr %23, align 8, !tbaa !9
  %24 = load i32, ptr %2, align 4, !tbaa !5
  %25 = sext i32 %24 to i64
  %26 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %25
  %27 = getelementptr inbounds [101 x i64], ptr %26, i64 0, i64 0
  store i64 1, ptr %27, align 8, !tbaa !9
  br label %28

28:                                               ; preds = %17
  %29 = load i32, ptr %2, align 4, !tbaa !5
  %30 = add nsw i32 %29, 1
  store i32 %30, ptr %2, align 4, !tbaa !5
  br label %13, !llvm.loop !11

31:                                               ; preds = %16
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  store i32 0, ptr %3, align 4, !tbaa !5
  br label %32

32:                                               ; preds = %73, %31
  %33 = load i32, ptr %3, align 4, !tbaa !5
  %34 = icmp sle i32 %33, 100
  br i1 %34, label %36, label %35

35:                                               ; preds = %32
  store i32 5, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  br label %76

36:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 1, ptr %5, align 4, !tbaa !5
  br label %37

37:                                               ; preds = %69, %36
  %38 = load i32, ptr %5, align 4, !tbaa !5
  %39 = load i32, ptr %3, align 4, !tbaa !5
  %40 = icmp slt i32 %38, %39
  br i1 %40, label %42, label %41

41:                                               ; preds = %37
  store i32 8, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  br label %72

42:                                               ; preds = %37
  %43 = load i32, ptr %3, align 4, !tbaa !5
  %44 = sub nsw i32 %43, 1
  %45 = sext i32 %44 to i64
  %46 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %45
  %47 = load i32, ptr %5, align 4, !tbaa !5
  %48 = sub nsw i32 %47, 1
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds [101 x i64], ptr %46, i64 0, i64 %49
  %51 = load i64, ptr %50, align 8, !tbaa !9
  %52 = load i32, ptr %3, align 4, !tbaa !5
  %53 = sub nsw i32 %52, 1
  %54 = sext i32 %53 to i64
  %55 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %54
  %56 = load i32, ptr %5, align 4, !tbaa !5
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds [101 x i64], ptr %55, i64 0, i64 %57
  %59 = load i64, ptr %58, align 8, !tbaa !9
  %60 = add nsw i64 %51, %59
  %61 = load i64, ptr @MOD, align 8, !tbaa !9
  %62 = srem i64 %60, %61
  %63 = load i32, ptr %3, align 4, !tbaa !5
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %64
  %66 = load i32, ptr %5, align 4, !tbaa !5
  %67 = sext i32 %66 to i64
  %68 = getelementptr inbounds [101 x i64], ptr %65, i64 0, i64 %67
  store i64 %62, ptr %68, align 8, !tbaa !9
  br label %69

69:                                               ; preds = %42
  %70 = load i32, ptr %5, align 4, !tbaa !5
  %71 = add nsw i32 %70, 1
  store i32 %71, ptr %5, align 4, !tbaa !5
  br label %37, !llvm.loop !13

72:                                               ; preds = %41
  br label %73

73:                                               ; preds = %72
  %74 = load i32, ptr %3, align 4, !tbaa !5
  %75 = add nsw i32 %74, 1
  store i32 %75, ptr %3, align 4, !tbaa !5
  br label %32, !llvm.loop !14

76:                                               ; preds = %35
  %77 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @n)
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  store i32 0, ptr %6, align 4, !tbaa !5
  br label %78

78:                                               ; preds = %93, %76
  %79 = load i32, ptr %6, align 4, !tbaa !5
  %80 = icmp slt i32 %79, 10
  br i1 %80, label %82, label %81

81:                                               ; preds = %78
  store i32 11, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #5
  br label %96

82:                                               ; preds = %78
  %83 = load i32, ptr %6, align 4, !tbaa !5
  %84 = sext i32 %83 to i64
  %85 = getelementptr inbounds [10 x i32], ptr @a, i64 0, i64 %84
  %86 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef %85)
  %87 = load i32, ptr %6, align 4, !tbaa !5
  %88 = sext i32 %87 to i64
  %89 = getelementptr inbounds [10 x i32], ptr @a, i64 0, i64 %88
  %90 = load i32, ptr %89, align 4, !tbaa !5
  %91 = load i32, ptr @tot, align 4, !tbaa !5
  %92 = add nsw i32 %91, %90
  store i32 %92, ptr @tot, align 4, !tbaa !5
  br label %93

93:                                               ; preds = %82
  %94 = load i32, ptr %6, align 4, !tbaa !5
  %95 = add nsw i32 %94, 1
  store i32 %95, ptr %6, align 4, !tbaa !5
  br label %78, !llvm.loop !15

96:                                               ; preds = %81
  %97 = load i32, ptr @tot, align 4, !tbaa !5
  %98 = load i32, ptr @n, align 4, !tbaa !5
  %99 = icmp sgt i32 %97, %98
  br i1 %99, label %100, label %103

100:                                              ; preds = %96
  %101 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef 0)
  %102 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %101, ptr noundef @.str.1)
  store i32 0, ptr %1, align 4
  br label %255

103:                                              ; preds = %96
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  %104 = load i32, ptr getelementptr inbounds ([10 x i32], ptr @a, i64 0, i64 9), align 4, !tbaa !5
  store i32 %104, ptr %7, align 4, !tbaa !5
  br label %105

105:                                              ; preds = %115, %103
  %106 = load i32, ptr %7, align 4, !tbaa !5
  %107 = load i32, ptr @n, align 4, !tbaa !5
  %108 = icmp sle i32 %106, %107
  br i1 %108, label %110, label %109

109:                                              ; preds = %105
  store i32 14, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  br label %118

110:                                              ; preds = %105
  %111 = load i32, ptr %7, align 4, !tbaa !5
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %112
  %114 = getelementptr inbounds [10 x i64], ptr %113, i64 0, i64 9
  store i64 1, ptr %114, align 8, !tbaa !9
  br label %115

115:                                              ; preds = %110
  %116 = load i32, ptr %7, align 4, !tbaa !5
  %117 = add nsw i32 %116, 1
  store i32 %117, ptr %7, align 4, !tbaa !5
  br label %105, !llvm.loop !16

118:                                              ; preds = %109
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  store i32 0, ptr %8, align 4, !tbaa !5
  br label %119

119:                                              ; preds = %228, %118
  %120 = load i32, ptr %8, align 4, !tbaa !5
  %121 = load i32, ptr @n, align 4, !tbaa !5
  %122 = icmp sle i32 %120, %121
  br i1 %122, label %124, label %123

123:                                              ; preds = %119
  store i32 17, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  br label %231

124:                                              ; preds = %119
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 8, ptr %9, align 4, !tbaa !5
  br label %125

125:                                              ; preds = %224, %124
  %126 = load i32, ptr %9, align 4, !tbaa !5
  %127 = icmp sge i32 %126, 0
  br i1 %127, label %129, label %128

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

129:                                              ; preds = %125
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  %130 = load i32, ptr %9, align 4, !tbaa !5
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds [10 x i32], ptr @a, i64 0, i64 %131
  %133 = load i32, ptr %132, align 4, !tbaa !5
  store i32 %133, ptr %10, align 4, !tbaa !5
  br label %134

134:                                              ; preds = %220, %129
  %135 = load i32, ptr %10, align 4, !tbaa !5
  %136 = load i32, ptr %8, align 4, !tbaa !5
  %137 = icmp sle i32 %135, %136
  br i1 %137, label %139, label %138

138:                                              ; preds = %134
  store i32 23, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  br label %223

139:                                              ; preds = %134
  %140 = load i32, ptr %9, align 4, !tbaa !5
  %141 = icmp sgt i32 %140, 0
  br i1 %141, label %142, label %180

142:                                              ; preds = %139
  %143 = load i32, ptr %8, align 4, !tbaa !5
  %144 = load i32, ptr %10, align 4, !tbaa !5
  %145 = sub nsw i32 %143, %144
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %146
  %148 = load i32, ptr %9, align 4, !tbaa !5
  %149 = add nsw i32 %148, 1
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds [10 x i64], ptr %147, i64 0, i64 %150
  %152 = load i64, ptr %151, align 8, !tbaa !9
  %153 = load i32, ptr %8, align 4, !tbaa !5
  %154 = sext i32 %153 to i64
  %155 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %154
  %156 = load i32, ptr %10, align 4, !tbaa !5
  %157 = sext i32 %156 to i64
  %158 = getelementptr inbounds [101 x i64], ptr %155, i64 0, i64 %157
  %159 = load i64, ptr %158, align 8, !tbaa !9
  %160 = mul nsw i64 %152, %159
  %161 = load i64, ptr @MOD, align 8, !tbaa !9
  %162 = srem i64 %160, %161
  %163 = load i32, ptr %8, align 4, !tbaa !5
  %164 = sext i32 %163 to i64
  %165 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %164
  %166 = load i32, ptr %9, align 4, !tbaa !5
  %167 = sext i32 %166 to i64
  %168 = getelementptr inbounds [10 x i64], ptr %165, i64 0, i64 %167
  %169 = load i64, ptr %168, align 8, !tbaa !9
  %170 = add nsw i64 %169, %162
  store i64 %170, ptr %168, align 8, !tbaa !9
  %171 = load i64, ptr @MOD, align 8, !tbaa !9
  %172 = load i32, ptr %8, align 4, !tbaa !5
  %173 = sext i32 %172 to i64
  %174 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %173
  %175 = load i32, ptr %9, align 4, !tbaa !5
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds [10 x i64], ptr %174, i64 0, i64 %176
  %178 = load i64, ptr %177, align 8, !tbaa !9
  %179 = srem i64 %178, %171
  store i64 %179, ptr %177, align 8, !tbaa !9
  br label %219

180:                                              ; preds = %139
  %181 = load i32, ptr %8, align 4, !tbaa !5
  %182 = load i32, ptr %10, align 4, !tbaa !5
  %183 = sub nsw i32 %181, %182
  %184 = sext i32 %183 to i64
  %185 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %184
  %186 = load i32, ptr %9, align 4, !tbaa !5
  %187 = add nsw i32 %186, 1
  %188 = sext i32 %187 to i64
  %189 = getelementptr inbounds [10 x i64], ptr %185, i64 0, i64 %188
  %190 = load i64, ptr %189, align 8, !tbaa !9
  %191 = load i32, ptr %8, align 4, !tbaa !5
  %192 = sub nsw i32 %191, 1
  %193 = sext i32 %192 to i64
  %194 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %193
  %195 = load i32, ptr %10, align 4, !tbaa !5
  %196 = sext i32 %195 to i64
  %197 = getelementptr inbounds [101 x i64], ptr %194, i64 0, i64 %196
  %198 = load i64, ptr %197, align 8, !tbaa !9
  %199 = mul nsw i64 %190, %198
  %200 = load i64, ptr @MOD, align 8, !tbaa !9
  %201 = srem i64 %199, %200
  %202 = load i32, ptr %8, align 4, !tbaa !5
  %203 = sext i32 %202 to i64
  %204 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %203
  %205 = load i32, ptr %9, align 4, !tbaa !5
  %206 = sext i32 %205 to i64
  %207 = getelementptr inbounds [10 x i64], ptr %204, i64 0, i64 %206
  %208 = load i64, ptr %207, align 8, !tbaa !9
  %209 = add nsw i64 %208, %201
  store i64 %209, ptr %207, align 8, !tbaa !9
  %210 = load i64, ptr @MOD, align 8, !tbaa !9
  %211 = load i32, ptr %8, align 4, !tbaa !5
  %212 = sext i32 %211 to i64
  %213 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %212
  %214 = load i32, ptr %9, align 4, !tbaa !5
  %215 = sext i32 %214 to i64
  %216 = getelementptr inbounds [10 x i64], ptr %213, i64 0, i64 %215
  %217 = load i64, ptr %216, align 8, !tbaa !9
  %218 = srem i64 %217, %210
  store i64 %218, ptr %216, align 8, !tbaa !9
  br label %219

219:                                              ; preds = %180, %142
  br label %220

220:                                              ; preds = %219
  %221 = load i32, ptr %10, align 4, !tbaa !5
  %222 = add nsw i32 %221, 1
  store i32 %222, ptr %10, align 4, !tbaa !5
  br label %134, !llvm.loop !17

223:                                              ; preds = %138
  br label %224

224:                                              ; preds = %223
  %225 = load i32, ptr %9, align 4, !tbaa !5
  %226 = add nsw i32 %225, -1
  store i32 %226, ptr %9, align 4, !tbaa !5
  br label %125, !llvm.loop !18

227:                                              ; preds = %128
  br label %228

228:                                              ; preds = %227
  %229 = load i32, ptr %8, align 4, !tbaa !5
  %230 = add nsw i32 %229, 1
  store i32 %230, ptr %8, align 4, !tbaa !5
  br label %119, !llvm.loop !19

231:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  store i64 0, ptr %11, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 1, ptr %12, align 4, !tbaa !5
  br label %232

232:                                              ; preds = %248, %231
  %233 = load i32, ptr %12, align 4, !tbaa !5
  %234 = load i32, ptr @n, align 4, !tbaa !5
  %235 = icmp sle i32 %233, %234
  br i1 %235, label %237, label %236

236:                                              ; preds = %232
  store i32 26, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %251

237:                                              ; preds = %232
  %238 = load i32, ptr %12, align 4, !tbaa !5
  %239 = sext i32 %238 to i64
  %240 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %239
  %241 = getelementptr inbounds [10 x i64], ptr %240, i64 0, i64 0
  %242 = load i64, ptr %241, align 16, !tbaa !9
  %243 = load i64, ptr %11, align 8, !tbaa !9
  %244 = add nsw i64 %243, %242
  store i64 %244, ptr %11, align 8, !tbaa !9
  %245 = load i64, ptr @MOD, align 8, !tbaa !9
  %246 = load i64, ptr %11, align 8, !tbaa !9
  %247 = srem i64 %246, %245
  store i64 %247, ptr %11, align 8, !tbaa !9
  br label %248

248:                                              ; preds = %237
  %249 = load i32, ptr %12, align 4, !tbaa !5
  %250 = add nsw i32 %249, 1
  store i32 %250, ptr %12, align 4, !tbaa !5
  br label %232, !llvm.loop !20

251:                                              ; preds = %236
  %252 = load i64, ptr %11, align 8, !tbaa !9
  %253 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %252)
  %254 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %253, ptr noundef @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  br label %255

255:                                              ; preds = %251, %100
  %256 = load i32, ptr %1, align 4
  ret i32 %256
}

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #3

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #3

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { mustprogress 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 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}
!19 = distinct !{!19, !12}
!20 = distinct !{!20, !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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }

@n = external dso_local global i32, align 4
@a = external dso_local global [10 x i32], align 16
@tot = external dso_local local_unnamed_addr global i32, align 4
@MOD = external dso_local local_unnamed_addr global i64, align 8
@c = external dso_local local_unnamed_addr global [101 x [101 x i64]], align 16
@dp = external dso_local local_unnamed_addr global [101 x [10 x i64]], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1
@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  br label %2

.preheader74:                                     ; preds = %2
  %1 = load i64, ptr @MOD, align 8
  br label %.preheader73

2:                                                ; preds = %5, %0
  %indvars.iv = phi i64 [ 0, %0 ], [ %indvars.iv.next.1, %5 ]
  %3 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv
  %4 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv, i64 %indvars.iv
  store i64 1, ptr %4, align 16, !tbaa !5
  store i64 1, ptr %3, align 16, !tbaa !5
  %exitcond.not = icmp eq i64 %indvars.iv, 100
  br i1 %exitcond.not, label %.preheader74, label %5, !llvm.loop !9

5:                                                ; preds = %2
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %6 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv.next
  %7 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv.next, i64 %indvars.iv.next
  store i64 1, ptr %7, align 16, !tbaa !5
  store i64 1, ptr %6, align 8, !tbaa !5
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2
  br label %2

.preheader73:                                     ; preds = %.preheader74, %._crit_edge
  %indvars.iv103 = phi i64 [ 0, %.preheader74 ], [ %indvars.iv.next104, %._crit_edge ]
  %8 = add nsw i64 %indvars.iv103, -1
  %9 = icmp ugt i64 %indvars.iv103, 1
  br i1 %9, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %.preheader73
  %10 = add nsw i64 %indvars.iv103, -1
  %.phi.trans.insert = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %10, i64 0
  %.pre = load i64, ptr %.phi.trans.insert, align 8, !tbaa !5
  %xtraiter = and i64 %8, 1
  %11 = icmp eq i64 %indvars.iv103, 2
  br i1 %11, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph.new

.lr.ph.new:                                       ; preds = %.lr.ph
  %unroll_iter = and i64 %8, -2
  br label %61

12:                                               ; preds = %._crit_edge
  %13 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @n)
  %14 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @a)
  %15 = load i32, ptr @a, align 16, !tbaa !11
  %16 = load i32, ptr @tot, align 4, !tbaa !11
  %17 = add nsw i32 %16, %15
  store i32 %17, ptr @tot, align 4, !tbaa !11
  %18 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 4))
  %19 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 4), align 4, !tbaa !11
  %20 = load i32, ptr @tot, align 4, !tbaa !11
  %21 = add nsw i32 %20, %19
  store i32 %21, ptr @tot, align 4, !tbaa !11
  %22 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 8))
  %23 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 8), align 8, !tbaa !11
  %24 = load i32, ptr @tot, align 4, !tbaa !11
  %25 = add nsw i32 %24, %23
  store i32 %25, ptr @tot, align 4, !tbaa !11
  %26 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 12))
  %27 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 12), align 4, !tbaa !11
  %28 = load i32, ptr @tot, align 4, !tbaa !11
  %29 = add nsw i32 %28, %27
  store i32 %29, ptr @tot, align 4, !tbaa !11
  %30 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 16))
  %31 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 16), align 16, !tbaa !11
  %32 = load i32, ptr @tot, align 4, !tbaa !11
  %33 = add nsw i32 %32, %31
  store i32 %33, ptr @tot, align 4, !tbaa !11
  %34 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 20))
  %35 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 20), align 4, !tbaa !11
  %36 = load i32, ptr @tot, align 4, !tbaa !11
  %37 = add nsw i32 %36, %35
  store i32 %37, ptr @tot, align 4, !tbaa !11
  %38 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 24))
  %39 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 24), align 8, !tbaa !11
  %40 = load i32, ptr @tot, align 4, !tbaa !11
  %41 = add nsw i32 %40, %39
  store i32 %41, ptr @tot, align 4, !tbaa !11
  %42 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 28))
  %43 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 28), align 4, !tbaa !11
  %44 = load i32, ptr @tot, align 4, !tbaa !11
  %45 = add nsw i32 %44, %43
  store i32 %45, ptr @tot, align 4, !tbaa !11
  %46 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 32))
  %47 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 32), align 16, !tbaa !11
  %48 = load i32, ptr @tot, align 4, !tbaa !11
  %49 = add nsw i32 %48, %47
  store i32 %49, ptr @tot, align 4, !tbaa !11
  %50 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull getelementptr inbounds (i8, ptr @a, i64 36))
  %51 = load i32, ptr getelementptr inbounds (i8, ptr @a, i64 36), align 4, !tbaa !11
  %52 = load i32, ptr @tot, align 4, !tbaa !11
  %53 = add nsw i32 %52, %51
  store i32 %53, ptr @tot, align 4, !tbaa !11
  %54 = load i32, ptr @n, align 4, !tbaa !11
  %55 = icmp sgt i32 %53, %54
  br i1 %55, label %73, label %76

._crit_edge.loopexit.unr-lcssa:                   ; preds = %61, %.lr.ph
  %.unr = phi i64 [ %.pre, %.lr.ph ], [ %69, %61 ]
  %indvars.iv99.unr = phi i64 [ 1, %.lr.ph ], [ %indvars.iv.next100.1, %61 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge, label %._crit_edge.loopexit.epilog-lcssa

._crit_edge.loopexit.epilog-lcssa:                ; preds = %._crit_edge.loopexit.unr-lcssa
  %56 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %10, i64 %indvars.iv99.unr
  %57 = load i64, ptr %56, align 8, !tbaa !5
  %58 = add nsw i64 %57, %.unr
  %59 = srem i64 %58, %1
  %60 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv103, i64 %indvars.iv99.unr
  store i64 %59, ptr %60, align 8, !tbaa !5
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit.epilog-lcssa, %._crit_edge.loopexit.unr-lcssa, %.preheader73
  %indvars.iv.next104 = add nuw nsw i64 %indvars.iv103, 1
  %exitcond106.not = icmp eq i64 %indvars.iv.next104, 101
  br i1 %exitcond106.not, label %12, label %.preheader73, !llvm.loop !13

61:                                               ; preds = %61, %.lr.ph.new
  %62 = phi i64 [ %.pre, %.lr.ph.new ], [ %69, %61 ]
  %indvars.iv99 = phi i64 [ 1, %.lr.ph.new ], [ %indvars.iv.next100.1, %61 ]
  %niter = phi i64 [ 0, %.lr.ph.new ], [ %niter.next.1, %61 ]
  %63 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %10, i64 %indvars.iv99
  %64 = load i64, ptr %63, align 8, !tbaa !5
  %65 = add nsw i64 %64, %62
  %66 = srem i64 %65, %1
  %67 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv103, i64 %indvars.iv99
  store i64 %66, ptr %67, align 8, !tbaa !5
  %indvars.iv.next100 = add nuw nsw i64 %indvars.iv99, 1
  %68 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %10, i64 %indvars.iv.next100
  %69 = load i64, ptr %68, align 8, !tbaa !5
  %70 = add nsw i64 %69, %64
  %71 = srem i64 %70, %1
  %72 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv103, i64 %indvars.iv.next100
  store i64 %71, ptr %72, align 8, !tbaa !5
  %indvars.iv.next100.1 = add nuw nsw i64 %indvars.iv99, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %._crit_edge.loopexit.unr-lcssa, label %61, !llvm.loop !14

73:                                               ; preds = %12
  %74 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef 0)
  %75 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %74, ptr noundef nonnull @.str.1)
  br label %135

76:                                               ; preds = %12
  %.not79 = icmp sgt i32 %51, %54
  br i1 %.not79, label %.preheader72, label %.lr.ph82.preheader

.lr.ph82.preheader:                               ; preds = %76
  %77 = sext i32 %51 to i64
  %78 = add i32 %54, 1
  %79 = sub i32 %78, %51
  %80 = sub i32 %54, %51
  %xtraiter143 = and i32 %79, 3
  %lcmp.mod144.not = icmp eq i32 %xtraiter143, 0
  br i1 %lcmp.mod144.not, label %.lr.ph82.prol.loopexit, label %.lr.ph82.prol

.lr.ph82.prol:                                    ; preds = %.lr.ph82.preheader, %.lr.ph82.prol
  %indvars.iv111.prol = phi i64 [ %indvars.iv.next112.prol, %.lr.ph82.prol ], [ %77, %.lr.ph82.preheader ]
  %prol.iter = phi i32 [ %prol.iter.next, %.lr.ph82.prol ], [ 0, %.lr.ph82.preheader ]
  %81 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv111.prol, i64 9
  store i64 1, ptr %81, align 8, !tbaa !5
  %indvars.iv.next112.prol = add nsw i64 %indvars.iv111.prol, 1
  %prol.iter.next = add i32 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i32 %prol.iter.next, %xtraiter143
  br i1 %prol.iter.cmp.not, label %.lr.ph82.prol.loopexit, label %.lr.ph82.prol, !llvm.loop !15

.lr.ph82.prol.loopexit:                           ; preds = %.lr.ph82.prol, %.lr.ph82.preheader
  %indvars.iv111.unr = phi i64 [ %77, %.lr.ph82.preheader ], [ %indvars.iv.next112.prol, %.lr.ph82.prol ]
  %82 = icmp ult i32 %80, 3
  br i1 %82, label %.preheader72, label %.lr.ph82

.preheader72:                                     ; preds = %.lr.ph82.prol.loopexit, %.lr.ph82, %76
  %.not6790 = icmp slt i32 %54, 0
  br i1 %.not6790, label %._crit_edge96, label %.preheader71.lr.ph

.preheader71.lr.ph:                               ; preds = %.preheader72
  %83 = load i64, ptr @MOD, align 8
  %84 = add nuw i32 %54, 1
  %wide.trip.count = zext i32 %84 to i64
  br label %.preheader71

.lr.ph82:                                         ; preds = %.lr.ph82.prol.loopexit, %.lr.ph82
  %indvars.iv111 = phi i64 [ %indvars.iv.next112.3, %.lr.ph82 ], [ %indvars.iv111.unr, %.lr.ph82.prol.loopexit ]
  %85 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv111, i64 9
  store i64 1, ptr %85, align 8, !tbaa !5
  %indvars.iv.next112 = add nsw i64 %indvars.iv111, 1
  %86 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv.next112, i64 9
  store i64 1, ptr %86, align 8, !tbaa !5
  %indvars.iv.next112.1 = add nsw i64 %indvars.iv111, 2
  %87 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv.next112.1, i64 9
  store i64 1, ptr %87, align 8, !tbaa !5
  %indvars.iv.next112.2 = add nsw i64 %indvars.iv111, 3
  %88 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv.next112.2, i64 9
  store i64 1, ptr %88, align 8, !tbaa !5
  %indvars.iv.next112.3 = add nsw i64 %indvars.iv111, 4
  %lftr.wideiv.3 = trunc i64 %indvars.iv.next112.3 to i32
  %exitcond114.not.3 = icmp eq i32 %78, %lftr.wideiv.3
  br i1 %exitcond114.not.3, label %.preheader72, label %.lr.ph82, !llvm.loop !17

.preheader71:                                     ; preds = %.preheader71.lr.ph, %93
  %indvars.iv130 = phi i64 [ 0, %.preheader71.lr.ph ], [ %indvars.iv.next131, %93 ]
  %indvars.iv118 = phi i32 [ 1, %.preheader71.lr.ph ], [ %indvars.iv.next119, %93 ]
  %89 = add nsw i64 %indvars.iv130, -1
  br label %94

.preheader:                                       ; preds = %93
  %.not6892 = icmp eq i32 %54, 0
  br i1 %.not6892, label %._crit_edge96, label %.lr.ph95

.lr.ph95:                                         ; preds = %.preheader
  %90 = load i64, ptr @MOD, align 8, !tbaa !5
  %91 = zext nneg i32 %54 to i64
  %xtraiter146 = and i64 %91, 1
  %92 = icmp eq i32 %84, 2
  br i1 %92, label %._crit_edge96.loopexit.unr-lcssa, label %.lr.ph95.new

.lr.ph95.new:                                     ; preds = %.lr.ph95
  %unroll_iter149 = and i64 %91, 2147483646
  br label %126

93:                                               ; preds = %._crit_edge87
  %indvars.iv.next131 = add nuw nsw i64 %indvars.iv130, 1
  %indvars.iv.next119 = add nuw i32 %indvars.iv118, 1
  %exitcond133.not = icmp eq i64 %indvars.iv.next131, %wide.trip.count
  br i1 %exitcond133.not, label %.preheader, label %.preheader71, !llvm.loop !18

94:                                               ; preds = %.preheader71, %._crit_edge87
  %indvars.iv127 = phi i64 [ 8, %.preheader71 ], [ %indvars.iv.next128, %._crit_edge87 ]
  %95 = getelementptr inbounds [10 x i32], ptr @a, i64 0, i64 %indvars.iv127
  %96 = load i32, ptr %95, align 4, !tbaa !11
  %97 = sext i32 %96 to i64
  %.not6983 = icmp slt i64 %indvars.iv130, %97
  br i1 %.not6983, label %._crit_edge87, label %.lr.ph86

.lr.ph86:                                         ; preds = %94
  %.not70 = icmp eq i64 %indvars.iv127, 0
  %98 = add nuw nsw i64 %indvars.iv127, 1
  %99 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv130, i64 %indvars.iv127
  %.promoted88 = load i64, ptr %99, align 8, !tbaa !5
  br i1 %.not70, label %.lr.ph86.split.us, label %.lr.ph86.split

.lr.ph86.split.us:                                ; preds = %.lr.ph86, %.lr.ph86.split.us
  %indvars.iv122 = phi i64 [ %indvars.iv.next123, %.lr.ph86.split.us ], [ %97, %.lr.ph86 ]
  %100 = phi i64 [ %109, %.lr.ph86.split.us ], [ %.promoted88, %.lr.ph86 ]
  %101 = sub nsw i64 %indvars.iv130, %indvars.iv122
  %102 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %101, i64 1
  %103 = load i64, ptr %102, align 8, !tbaa !5
  %104 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %89, i64 %indvars.iv122
  %105 = load i64, ptr %104, align 8, !tbaa !5
  %106 = mul nsw i64 %105, %103
  %107 = srem i64 %106, %83
  %108 = add nsw i64 %100, %107
  %109 = srem i64 %108, %83
  store i64 %109, ptr %99, align 8, !tbaa !5
  %indvars.iv.next123 = add nsw i64 %indvars.iv122, 1
  %lftr.wideiv125 = trunc i64 %indvars.iv.next123 to i32
  %exitcond126.not = icmp eq i32 %indvars.iv118, %lftr.wideiv125
  br i1 %exitcond126.not, label %._crit_edge87, label %.lr.ph86.split.us, !llvm.loop !19

._crit_edge87.split:                              ; preds = %.lr.ph86.split
  store i64 %119, ptr %99, align 8, !tbaa !5
  br label %._crit_edge87

._crit_edge87:                                    ; preds = %.lr.ph86.split.us, %._crit_edge87.split, %94
  %indvars.iv.next128 = add nsw i64 %indvars.iv127, -1
  %.not = icmp eq i64 %indvars.iv127, 0
  br i1 %.not, label %93, label %94, !llvm.loop !20

.lr.ph86.split:                                   ; preds = %.lr.ph86, %.lr.ph86.split
  %indvars.iv115 = phi i64 [ %indvars.iv.next116, %.lr.ph86.split ], [ %97, %.lr.ph86 ]
  %110 = phi i64 [ %119, %.lr.ph86.split ], [ %.promoted88, %.lr.ph86 ]
  %111 = sub nsw i64 %indvars.iv130, %indvars.iv115
  %112 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %111, i64 %98
  %113 = load i64, ptr %112, align 8, !tbaa !5
  %114 = getelementptr inbounds [101 x [101 x i64]], ptr @c, i64 0, i64 %indvars.iv130, i64 %indvars.iv115
  %115 = load i64, ptr %114, align 8, !tbaa !5
  %116 = mul nsw i64 %115, %113
  %117 = srem i64 %116, %83
  %118 = add nsw i64 %110, %117
  %119 = srem i64 %118, %83
  %indvars.iv.next116 = add nsw i64 %indvars.iv115, 1
  %lftr.wideiv120 = trunc i64 %indvars.iv.next116 to i32
  %exitcond121.not = icmp eq i32 %indvars.iv118, %lftr.wideiv120
  br i1 %exitcond121.not, label %._crit_edge87.split, label %.lr.ph86.split, !llvm.loop !19

._crit_edge96.loopexit.unr-lcssa:                 ; preds = %126, %.lr.ph95
  %.lcssa.ph = phi i64 [ poison, %.lr.ph95 ], [ %134, %126 ]
  %indvars.iv134.unr = phi i64 [ 1, %.lr.ph95 ], [ %indvars.iv.next135.1, %126 ]
  %.05793.unr = phi i64 [ 0, %.lr.ph95 ], [ %134, %126 ]
  %lcmp.mod147.not = icmp eq i64 %xtraiter146, 0
  br i1 %lcmp.mod147.not, label %._crit_edge96, label %._crit_edge96.loopexit.epilog-lcssa

._crit_edge96.loopexit.epilog-lcssa:              ; preds = %._crit_edge96.loopexit.unr-lcssa
  %120 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv134.unr
  %121 = load i64, ptr %120, align 16, !tbaa !5
  %122 = add nsw i64 %121, %.05793.unr
  %123 = srem i64 %122, %90
  br label %._crit_edge96

._crit_edge96:                                    ; preds = %._crit_edge96.loopexit.epilog-lcssa, %._crit_edge96.loopexit.unr-lcssa, %.preheader72, %.preheader
  %.057.lcssa = phi i64 [ 0, %.preheader ], [ 0, %.preheader72 ], [ %.lcssa.ph, %._crit_edge96.loopexit.unr-lcssa ], [ %123, %._crit_edge96.loopexit.epilog-lcssa ]
  %124 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEx(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i64 noundef %.057.lcssa)
  %125 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEPFRSoS_E(ptr noundef nonnull align 8 dereferenceable(8) %124, ptr noundef nonnull @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_)
  br label %135

126:                                              ; preds = %126, %.lr.ph95.new
  %indvars.iv134 = phi i64 [ 1, %.lr.ph95.new ], [ %indvars.iv.next135.1, %126 ]
  %.05793 = phi i64 [ 0, %.lr.ph95.new ], [ %134, %126 ]
  %niter150 = phi i64 [ 0, %.lr.ph95.new ], [ %niter150.next.1, %126 ]
  %127 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv134
  %128 = load i64, ptr %127, align 16, !tbaa !5
  %129 = add nsw i64 %128, %.05793
  %130 = srem i64 %129, %90
  %indvars.iv.next135 = add nuw nsw i64 %indvars.iv134, 1
  %131 = getelementptr inbounds [101 x [10 x i64]], ptr @dp, i64 0, i64 %indvars.iv.next135
  %132 = load i64, ptr %131, align 16, !tbaa !5
  %133 = add nsw i64 %132, %130
  %134 = srem i64 %133, %90
  %indvars.iv.next135.1 = add nuw nsw i64 %indvars.iv134, 2
  %niter150.next.1 = add i64 %niter150, 2
  %niter150.ncmp.1 = icmp eq i64 %niter150.next.1, %unroll_iter149
  br i1 %niter150.ncmp.1, label %._crit_edge96.loopexit.unr-lcssa, label %126, !llvm.loop !21

135:                                              ; preds = %._crit_edge96, %73
  ret i32 0
}

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

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

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #3

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_(ptr noundef nonnull align 8 dereferenceable(8)) #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 = { 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 #2 = { 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 #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" }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"long long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !10}
!14 = distinct !{!14, !10}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.unroll.disable"}
!17 = distinct !{!17, !10}
!18 = distinct !{!18, !10}
!19 = distinct !{!19, !10}
!20 = distinct !{!20, !10}
!21 = distinct !{!21, !10}


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