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

; 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.BigInt = type { i32, [17 x i32] }
%struct.Node = type { [49 x i32], %struct.BigInt, %struct.BigInt }
%"class.std::priority_queue" = type <{ %"class.std::vector", [8 x i8] }>
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl" }
%"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl" = type { %"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@vlim = external dso_local global %struct.BigInt, align 4
@slim = external dso_local global %struct.BigInt, align 4
@tot = external dso_local global i32, align 4
@pr = external dso_local global [225 x i32], align 16
@d = external dso_local global [225 x i32], align 16
@cnt = external dso_local global i32, align 4
@seq = external dso_local global [1381 x %struct.Node], align 16
@cur = external dso_local global %struct.Node, align 4
@nxt = external dso_local global %struct.Node, align 4
@Q = external dso_local global %"class.std::priority_queue", align 8
@buf = external dso_local global [101 x i8], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca %struct.BigInt, 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 %struct.BigInt, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca %struct.BigInt, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 72, ptr %2) #6
  call void @_ZN6BigIntC2Ei(ptr noundef nonnull align 4 dereferenceable(72) %2, i32 noundef 1)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 @vlim, ptr align 4 %2, i64 72, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.end.p0(i64 72, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #6
  store i32 1, ptr %3, align 4, !tbaa !6
  br label %17

17:                                               ; preds = %22, %0
  %18 = load i32, ptr %3, align 4, !tbaa !6
  %19 = icmp slt i32 %18, 101
  br i1 %19, label %21, label %20

20:                                               ; preds = %17
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  br label %25

21:                                               ; preds = %17
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 10, ptr %4, align 4, !tbaa !6
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(4) %4)
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  br label %22

22:                                               ; preds = %21
  %23 = load i32, ptr %3, align 4, !tbaa !6
  %24 = add nsw i32 %23, 1
  store i32 %24, ptr %3, align 4, !tbaa !6
  br label %17, !llvm.loop !11

25:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  store i32 2, ptr %5, align 4, !tbaa !6
  br label %26

26:                                               ; preds = %79, %25
  %27 = load i32, ptr %5, align 4, !tbaa !6
  %28 = icmp slt i32 %27, 225
  br i1 %28, label %30, label %29

29:                                               ; preds = %26
  store i32 5, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  br label %82

30:                                               ; preds = %26
  %31 = load i32, ptr %5, align 4, !tbaa !6
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds [225 x i32], ptr @d, i64 0, i64 %32
  %34 = load i32, ptr %33, align 4, !tbaa !6
  %35 = icmp ne i32 %34, 0
  br i1 %35, label %45, label %36

36:                                               ; preds = %30
  %37 = load i32, ptr %5, align 4, !tbaa !6
  %38 = load i32, ptr %5, align 4, !tbaa !6
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [225 x i32], ptr @d, i64 0, i64 %39
  store i32 %37, ptr %40, align 4, !tbaa !6
  %41 = load i32, ptr @tot, align 4, !tbaa !6
  %42 = add nsw i32 %41, 1
  store i32 %42, ptr @tot, align 4, !tbaa !6
  %43 = sext i32 %41 to i64
  %44 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %43
  store i32 %37, ptr %44, align 4, !tbaa !6
  br label %45

45:                                               ; preds = %36, %30
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  store i32 0, ptr %7, align 4, !tbaa !6
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  br label %46

46:                                               ; preds = %74, %45
  %47 = load i32, ptr %5, align 4, !tbaa !6
  %48 = load i32, ptr %7, align 4, !tbaa !6
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %49
  %51 = load i32, ptr %50, align 4, !tbaa !6
  %52 = mul nsw i32 %47, %51
  store i32 %52, ptr %8, align 4, !tbaa !6
  %53 = icmp slt i32 %52, 225
  br i1 %53, label %55, label %54

54:                                               ; preds = %46
  store i32 8, ptr %6, align 4
  br label %77

55:                                               ; preds = %46
  %56 = load i32, ptr %7, align 4, !tbaa !6
  %57 = sext i32 %56 to i64
  %58 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %57
  %59 = load i32, ptr %58, align 4, !tbaa !6
  %60 = load i32, ptr %8, align 4, !tbaa !6
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [225 x i32], ptr @d, i64 0, i64 %61
  store i32 %59, ptr %62, align 4, !tbaa !6
  %63 = load i32, ptr %5, align 4, !tbaa !6
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds [225 x i32], ptr @d, i64 0, i64 %64
  %66 = load i32, ptr %65, align 4, !tbaa !6
  %67 = load i32, ptr %7, align 4, !tbaa !6
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %68
  %70 = load i32, ptr %69, align 4, !tbaa !6
  %71 = icmp eq i32 %66, %70
  br i1 %71, label %72, label %73

72:                                               ; preds = %55
  store i32 8, ptr %6, align 4
  br label %77

73:                                               ; preds = %55
  br label %74

74:                                               ; preds = %73
  %75 = load i32, ptr %7, align 4, !tbaa !6
  %76 = add nsw i32 %75, 1
  store i32 %76, ptr %7, align 4, !tbaa !6
  br label %46, !llvm.loop !13

77:                                               ; preds = %72, %54
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %78

78:                                               ; preds = %77
  br label %79

79:                                               ; preds = %78
  %80 = load i32, ptr %5, align 4, !tbaa !6
  %81 = add nsw i32 %80, 1
  store i32 %81, ptr %5, align 4, !tbaa !6
  br label %26, !llvm.loop !14

82:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 72, ptr %9) #6
  call void @_ZN6BigIntC2Ei(ptr noundef nonnull align 4 dereferenceable(72) %9, i32 noundef 1)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 getelementptr inbounds (%struct.Node, ptr @cur, i32 0, i32 2), ptr align 4 %9, i64 72, i1 false), !tbaa.struct !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 getelementptr inbounds (%struct.Node, ptr @cur, i32 0, i32 1), ptr align 4 getelementptr inbounds (%struct.Node, ptr @cur, i32 0, i32 2), i64 72, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.end.p0(i64 72, ptr %9) #6
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE4pushERKS0_(ptr noundef nonnull align 8 dereferenceable(25) @Q, ptr noundef nonnull align 4 dereferenceable(340) @cur)
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !6
  br label %83

83:                                               ; preds = %152, %82
  %84 = call noundef zeroext i1 @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  %85 = xor i1 %84, true
  br i1 %85, label %86, label %153

86:                                               ; preds = %83
  %87 = call noundef nonnull align 4 dereferenceable(340) ptr @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE3topEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 @cur, ptr align 4 %87, i64 340, i1 false), !tbaa.struct !15
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE3popEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  %88 = call noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (%struct.Node, ptr @cur, i32 0, i32 1))
  br i1 %88, label %89, label %90

89:                                               ; preds = %86
  br label %153

90:                                               ; preds = %86
  %91 = call noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72) @slim, ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (%struct.Node, ptr @cur, i32 0, i32 2))
  br i1 %91, label %92, label %152

92:                                               ; preds = %90
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 @slim, ptr align 4 getelementptr inbounds (%struct.Node, ptr @cur, i32 0, i32 2), i64 72, i1 false), !tbaa.struct !5
  %93 = load i32, ptr @cnt, align 4, !tbaa !6
  %94 = add nsw i32 %93, 1
  store i32 %94, ptr @cnt, align 4, !tbaa !6
  %95 = sext i32 %93 to i64
  %96 = getelementptr inbounds [1381 x %struct.Node], ptr @seq, i64 0, i64 %95
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %96, ptr align 4 @cur, i64 340, i1 false), !tbaa.struct !15
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  store i32 0, ptr %11, align 4, !tbaa !6
  br label %97

97:                                               ; preds = %147, %92
  %98 = load i32, ptr %11, align 4, !tbaa !6
  %99 = load i32, ptr @tot, align 4, !tbaa !6
  %100 = icmp slt i32 %98, %99
  br i1 %100, label %102, label %101

101:                                              ; preds = %97
  store i32 13, ptr %6, align 4
  br label %150

102:                                              ; preds = %97
  %103 = load i32, ptr %11, align 4, !tbaa !6
  %104 = icmp ne i32 %103, 0
  br i1 %104, label %105, label %116

105:                                              ; preds = %102
  %106 = load i32, ptr %11, align 4, !tbaa !6
  %107 = sub nsw i32 %106, 1
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds [49 x i32], ptr @cur, i64 0, i64 %108
  %110 = load i32, ptr %109, align 4, !tbaa !6
  %111 = load i32, ptr %11, align 4, !tbaa !6
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds [49 x i32], ptr @cur, i64 0, i64 %112
  %114 = load i32, ptr %113, align 4, !tbaa !6
  %115 = icmp sgt i32 %110, %114
  br i1 %115, label %116, label %133

116:                                              ; preds = %105, %102
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 @nxt, ptr align 4 @cur, i64 340, i1 false), !tbaa.struct !15
  %117 = load i32, ptr %11, align 4, !tbaa !6
  %118 = sext i32 %117 to i64
  %119 = getelementptr inbounds [49 x i32], ptr @nxt, i64 0, i64 %118
  %120 = load i32, ptr %119, align 4, !tbaa !6
  %121 = add nsw i32 %120, 1
  store i32 %121, ptr %119, align 4, !tbaa !6
  %122 = load i32, ptr %11, align 4, !tbaa !6
  %123 = sext i32 %122 to i64
  %124 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %123
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (%struct.Node, ptr @nxt, i32 0, i32 1), ptr noundef nonnull align 4 dereferenceable(4) %124)
  %125 = load i32, ptr %11, align 4, !tbaa !6
  %126 = sext i32 %125 to i64
  %127 = getelementptr inbounds [49 x i32], ptr @nxt, i64 0, i64 %126
  call void @_ZN6BigIntdVERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (%struct.Node, ptr @nxt, i32 0, i32 2), ptr noundef nonnull align 4 dereferenceable(4) %127)
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  %128 = load i32, ptr %11, align 4, !tbaa !6
  %129 = sext i32 %128 to i64
  %130 = getelementptr inbounds [49 x i32], ptr @nxt, i64 0, i64 %129
  %131 = load i32, ptr %130, align 4, !tbaa !6
  %132 = add nsw i32 %131, 1
  store i32 %132, ptr %12, align 4, !tbaa !6
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (%struct.Node, ptr @nxt, i32 0, i32 2), ptr noundef nonnull align 4 dereferenceable(4) %12)
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE4pushERKS0_(ptr noundef nonnull align 8 dereferenceable(25) @Q, ptr noundef nonnull align 4 dereferenceable(340) @nxt)
  br label %133

133:                                              ; preds = %116, %105
  %134 = load i32, ptr %11, align 4, !tbaa !6
  %135 = sext i32 %134 to i64
  %136 = getelementptr inbounds [49 x i32], ptr @cur, i64 0, i64 %135
  %137 = load i32, ptr %136, align 4, !tbaa !6
  %138 = icmp ne i32 %137, 0
  br i1 %138, label %140, label %139

139:                                              ; preds = %133
  store i32 13, ptr %6, align 4
  br label %150

140:                                              ; preds = %133
  %141 = load i32, ptr %10, align 4, !tbaa !6
  %142 = load i32, ptr %11, align 4, !tbaa !6
  %143 = icmp slt i32 %141, %142
  br i1 %143, label %144, label %146

144:                                              ; preds = %140
  %145 = load i32, ptr %11, align 4, !tbaa !6
  store i32 %145, ptr %10, align 4, !tbaa !6
  br label %146

146:                                              ; preds = %144, %140
  br label %147

147:                                              ; preds = %146
  %148 = load i32, ptr %11, align 4, !tbaa !6
  %149 = add nsw i32 %148, 1
  store i32 %149, ptr %11, align 4, !tbaa !6
  br label %97, !llvm.loop !16

150:                                              ; preds = %139, %101
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  br label %151

151:                                              ; preds = %150
  br label %152

152:                                              ; preds = %151, %90
  br label %83, !llvm.loop !17

153:                                              ; preds = %89, %83
  %154 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @buf)
  call void @llvm.lifetime.start.p0(i64 72, ptr %13) #6
  call void @_ZN6BigIntC2EPc(ptr noundef nonnull align 4 dereferenceable(72) %13, ptr noundef @buf)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 @vlim, ptr align 4 %13, i64 72, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.end.p0(i64 72, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #6
  store i32 0, ptr %14, align 4, !tbaa !6
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #6
  %155 = load i32, ptr @cnt, align 4, !tbaa !6
  %156 = sub nsw i32 %155, 1
  store i32 %156, ptr %15, align 4, !tbaa !6
  br label %157

157:                                              ; preds = %177, %153
  %158 = load i32, ptr %14, align 4, !tbaa !6
  %159 = load i32, ptr %15, align 4, !tbaa !6
  %160 = icmp slt i32 %158, %159
  br i1 %160, label %161, label %178

161:                                              ; preds = %157
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  %162 = load i32, ptr %14, align 4, !tbaa !6
  %163 = load i32, ptr %15, align 4, !tbaa !6
  %164 = add nsw i32 %162, %163
  %165 = add nsw i32 %164, 1
  %166 = ashr i32 %165, 1
  store i32 %166, ptr %16, align 4, !tbaa !6
  %167 = load i32, ptr %16, align 4, !tbaa !6
  %168 = sext i32 %167 to i64
  %169 = getelementptr inbounds [1381 x %struct.Node], ptr @seq, i64 0, i64 %168
  %170 = getelementptr inbounds %struct.Node, ptr %169, i32 0, i32 1
  %171 = call noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(72) %170)
  br i1 %171, label %172, label %175

172:                                              ; preds = %161
  %173 = load i32, ptr %16, align 4, !tbaa !6
  %174 = sub nsw i32 %173, 1
  store i32 %174, ptr %15, align 4, !tbaa !6
  br label %177

175:                                              ; preds = %161
  %176 = load i32, ptr %16, align 4, !tbaa !6
  store i32 %176, ptr %14, align 4, !tbaa !6
  br label %177

177:                                              ; preds = %175, %172
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  br label %157, !llvm.loop !18

178:                                              ; preds = %157
  %179 = load i32, ptr %14, align 4, !tbaa !6
  %180 = sext i32 %179 to i64
  %181 = getelementptr inbounds [1381 x %struct.Node], ptr @seq, i64 0, i64 %180
  %182 = getelementptr inbounds %struct.Node, ptr %181, i32 0, i32 1
  call void @_ZN6BigInt5printEc(ptr noundef nonnull align 4 dereferenceable(72) %182, i8 noundef signext 10)
  store i32 0, ptr %1, align 4
  store i32 1, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  %183 = load i32, ptr %1, align 4
  ret i32 %183
}

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6BigIntC2Ei(ptr noundef nonnull align 4 dereferenceable(72), i32 noundef) unnamed_addr #2 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef nonnull align 4 dereferenceable(4)) #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(25)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(340) ptr @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE3topEv(ptr noundef nonnull align 8 dereferenceable(25)) #2 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6BigIntdVERKi(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef nonnull align 4 dereferenceable(4)) #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6BigIntC2EPc(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6BigInt5printEc(ptr noundef nonnull align 4 dereferenceable(72), i8 noundef signext) #4 align 2

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { 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 = !{i64 0, i64 4, !6, i64 4, i64 68, !10}
!6 = !{!7, !7, i64 0}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!8, !8, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = !{i64 0, i64 196, !10, i64 196, i64 4, !6, i64 200, i64 68, !10, i64 268, i64 4, !6, i64 272, i64 68, !10}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !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.BigInt = type { i32, [17 x i32] }
%struct.Node = type { [49 x i32], %struct.BigInt, %struct.BigInt }
%"class.std::priority_queue" = type <{ %"class.std::vector", [8 x i8] }>
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl" }
%"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl" = type { %"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@vlim = external dso_local global %struct.BigInt, align 4
@slim = external dso_local global %struct.BigInt, align 4
@tot = external dso_local local_unnamed_addr global i32, align 4
@pr = external dso_local global [225 x i32], align 16
@d = external dso_local local_unnamed_addr global [225 x i32], align 16
@cnt = external dso_local local_unnamed_addr global i32, align 4
@seq = external dso_local global [1381 x %struct.Node], align 16
@cur = external dso_local global %struct.Node, align 4
@nxt = external dso_local global %struct.Node, align 4
@Q = external dso_local global %"class.std::priority_queue", align 8
@buf = external dso_local global [101 x i8], align 16
@.str = external hidden unnamed_addr constant [3 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = alloca %struct.BigInt, align 4
  %2 = alloca i32, align 4
  %3 = alloca %struct.BigInt, align 4
  %4 = alloca i32, align 4
  %5 = alloca %struct.BigInt, align 4
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %1) #6
  call void @_ZN6BigIntC2Ei(ptr noundef nonnull align 4 dereferenceable(72) %1, i32 noundef 1)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(72) %1, i64 72, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %1) #6
  br label %6

.preheader:                                       ; preds = %6
  %tot.promoted = load i32, ptr @tot, align 4, !tbaa !6
  br label %10

6:                                                ; preds = %0, %6
  %.04147 = phi i32 [ 1, %0 ], [ %7, %6 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #6
  store i32 10, ptr %2, align 4, !tbaa !6
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(4) %2)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #6
  %7 = add nuw nsw i32 %.04147, 1
  %exitcond.not = icmp eq i32 %7, 101
  br i1 %exitcond.not, label %.preheader, label %6, !llvm.loop !11

8:                                                ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %3) #6
  call void @_ZN6BigIntC2Ei(ptr noundef nonnull align 4 dereferenceable(72) %3, i32 noundef 1)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @cur, i64 268), ptr noundef nonnull align 4 dereferenceable(72) %3, i64 72, i1 false), !tbaa.struct !5
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @cur, i64 196), ptr noundef nonnull align 4 dereferenceable(72) %3, i64 72, i1 false)
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %3) #6
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE4pushERKS0_(ptr noundef nonnull align 8 dereferenceable(25) @Q, ptr noundef nonnull align 4 dereferenceable(340) @cur)
  %9 = call noundef zeroext i1 @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  br i1 %9, label %._crit_edge60, label %.lr.ph59

10:                                               ; preds = %.preheader, %._crit_edge
  %indvars.iv69 = phi i64 [ 2, %.preheader ], [ %indvars.iv.next70, %._crit_edge ]
  %11 = phi i32 [ %tot.promoted, %.preheader ], [ %19, %._crit_edge ]
  %12 = getelementptr inbounds [225 x i32], ptr @d, i64 0, i64 %indvars.iv69
  %13 = load i32, ptr %12, align 4, !tbaa !6
  %.not46 = icmp eq i32 %13, 0
  %14 = trunc nuw nsw i64 %indvars.iv69 to i32
  br i1 %.not46, label %15, label %._crit_edge80

15:                                               ; preds = %10
  store i32 %14, ptr %12, align 4, !tbaa !6
  %16 = add nsw i32 %11, 1
  store i32 %16, ptr @tot, align 4, !tbaa !6
  %17 = sext i32 %11 to i64
  %18 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %17
  store i32 %14, ptr %18, align 4, !tbaa !6
  br label %._crit_edge80

._crit_edge80:                                    ; preds = %10, %15
  %19 = phi i32 [ %16, %15 ], [ %11, %10 ]
  %20 = load i32, ptr @pr, align 16, !tbaa !6
  %21 = mul nsw i32 %20, %14
  %22 = icmp slt i32 %21, 225
  br i1 %22, label %.lr.ph, label %._crit_edge

23:                                               ; preds = %.lr.ph
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %24 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %indvars.iv.next
  %25 = load i32, ptr %24, align 4, !tbaa !6
  %26 = mul nsw i32 %25, %14
  %27 = icmp slt i32 %26, 225
  br i1 %27, label %.lr.ph, label %._crit_edge, !llvm.loop !13

.lr.ph:                                           ; preds = %._crit_edge80, %23
  %indvars.iv = phi i64 [ %indvars.iv.next, %23 ], [ 0, %._crit_edge80 ]
  %28 = phi i32 [ %26, %23 ], [ %21, %._crit_edge80 ]
  %29 = phi i32 [ %25, %23 ], [ %20, %._crit_edge80 ]
  %30 = sext i32 %28 to i64
  %31 = getelementptr inbounds [225 x i32], ptr @d, i64 0, i64 %30
  store i32 %29, ptr %31, align 4, !tbaa !6
  %32 = load i32, ptr %12, align 4, !tbaa !6
  %33 = icmp eq i32 %32, %29
  br i1 %33, label %._crit_edge, label %23

._crit_edge:                                      ; preds = %23, %.lr.ph, %._crit_edge80
  %indvars.iv.next70 = add nuw nsw i64 %indvars.iv69, 1
  %exitcond72.not = icmp eq i64 %indvars.iv.next70, 225
  br i1 %exitcond72.not, label %8, label %10, !llvm.loop !14

.lr.ph59:                                         ; preds = %8, %.loopexit
  %34 = call noundef nonnull align 4 dereferenceable(340) ptr @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE3topEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(340) @cur, ptr noundef nonnull align 4 dereferenceable(340) %34, i64 340, i1 false), !tbaa.struct !15
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE3popEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  %35 = call noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @cur, i64 196))
  br i1 %35, label %._crit_edge60, label %36

36:                                               ; preds = %.lr.ph59
  %37 = call noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72) @slim, ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @cur, i64 268))
  br i1 %37, label %38, label %.loopexit

38:                                               ; preds = %36
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(72) @slim, ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @cur, i64 268), i64 72, i1 false), !tbaa.struct !5
  %39 = load i32, ptr @cnt, align 4, !tbaa !6
  %40 = add nsw i32 %39, 1
  store i32 %40, ptr @cnt, align 4, !tbaa !6
  %41 = sext i32 %39 to i64
  %42 = getelementptr inbounds [1381 x %struct.Node], ptr @seq, i64 0, i64 %41
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(340) %42, ptr noundef nonnull align 4 dereferenceable(340) @cur, i64 340, i1 false), !tbaa.struct !15
  %43 = load i32, ptr @tot, align 4, !tbaa !6
  %44 = icmp sgt i32 %43, 0
  br i1 %44, label %45, label %.loopexit

45:                                               ; preds = %38
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(340) @nxt, ptr noundef nonnull align 4 dereferenceable(340) @cur, i64 340, i1 false), !tbaa.struct !15
  %46 = load i32, ptr @nxt, align 4, !tbaa !6
  %47 = add nsw i32 %46, 1
  store i32 %47, ptr @nxt, align 4, !tbaa !6
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @nxt, i64 196), ptr noundef nonnull align 4 dereferenceable(4) @pr)
  call void @_ZN6BigIntdVERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @nxt, i64 268), ptr noundef nonnull align 4 dereferenceable(4) @nxt)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #6
  %48 = load i32, ptr @nxt, align 4, !tbaa !6
  %49 = add nsw i32 %48, 1
  store i32 %49, ptr %4, align 4, !tbaa !6
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @nxt, i64 268), ptr noundef nonnull align 4 dereferenceable(4) %4)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE4pushERKS0_(ptr noundef nonnull align 8 dereferenceable(25) @Q, ptr noundef nonnull align 4 dereferenceable(340) @nxt)
  %.pre = load i32, ptr @cur, align 4, !tbaa !6
  %.not45.peel = icmp ne i32 %.pre, 0
  %50 = load i32, ptr @tot, align 4
  %51 = icmp sgt i32 %50, 1
  %or.cond = select i1 %.not45.peel, i1 %51, i1 false
  br i1 %or.cond, label %.lr.ph54.peel.next, label %.loopexit

.lr.ph54.peel.next:                               ; preds = %45, %65
  %52 = phi i32 [ %64, %65 ], [ %.pre, %45 ]
  %indvars.iv73 = phi i64 [ %indvars.iv.next74, %65 ], [ 1, %45 ]
  %53 = getelementptr inbounds [49 x i32], ptr @cur, i64 0, i64 %indvars.iv73
  %54 = load i32, ptr %53, align 4, !tbaa !6
  %55 = icmp sgt i32 %52, %54
  br i1 %55, label %56, label %63

56:                                               ; preds = %.lr.ph54.peel.next
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(340) @nxt, ptr noundef nonnull align 4 dereferenceable(340) @cur, i64 340, i1 false), !tbaa.struct !15
  %57 = getelementptr inbounds [49 x i32], ptr @nxt, i64 0, i64 %indvars.iv73
  %58 = load i32, ptr %57, align 4, !tbaa !6
  %59 = add nsw i32 %58, 1
  store i32 %59, ptr %57, align 4, !tbaa !6
  %60 = getelementptr inbounds [225 x i32], ptr @pr, i64 0, i64 %indvars.iv73
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @nxt, i64 196), ptr noundef nonnull align 4 dereferenceable(4) %60)
  call void @_ZN6BigIntdVERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @nxt, i64 268), ptr noundef nonnull align 4 dereferenceable(4) %57)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #6
  %61 = load i32, ptr %57, align 4, !tbaa !6
  %62 = add nsw i32 %61, 1
  store i32 %62, ptr %4, align 4, !tbaa !6
  call void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72) getelementptr inbounds (i8, ptr @nxt, i64 268), ptr noundef nonnull align 4 dereferenceable(4) %4)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @_ZNSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE4pushERKS0_(ptr noundef nonnull align 8 dereferenceable(25) @Q, ptr noundef nonnull align 4 dereferenceable(340) @nxt)
  %.phi.trans.insert = getelementptr inbounds [49 x i32], ptr @cur, i64 0, i64 %indvars.iv73
  %.pre79 = load i32, ptr %.phi.trans.insert, align 4, !tbaa !6
  br label %63

63:                                               ; preds = %56, %.lr.ph54.peel.next
  %64 = phi i32 [ %.pre79, %56 ], [ %54, %.lr.ph54.peel.next ]
  %.not45 = icmp eq i32 %64, 0
  br i1 %.not45, label %.loopexit, label %65

65:                                               ; preds = %63
  %indvars.iv.next74 = add nuw nsw i64 %indvars.iv73, 1
  %66 = load i32, ptr @tot, align 4, !tbaa !6
  %67 = sext i32 %66 to i64
  %68 = icmp slt i64 %indvars.iv.next74, %67
  br i1 %68, label %.lr.ph54.peel.next, label %.loopexit, !llvm.loop !16

.loopexit:                                        ; preds = %63, %65, %45, %38, %36
  %69 = call noundef zeroext i1 @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(25) @Q)
  br i1 %69, label %._crit_edge60, label %.lr.ph59, !llvm.loop !18

._crit_edge60:                                    ; preds = %.loopexit, %.lr.ph59, %8
  %70 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @buf)
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %5) #6
  call void @_ZN6BigIntC2EPc(ptr noundef nonnull align 4 dereferenceable(72) %5, ptr noundef nonnull @buf)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(72) %5, i64 72, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %5) #6
  %71 = load i32, ptr @cnt, align 4, !tbaa !6
  %72 = icmp sgt i32 %71, 1
  br i1 %72, label %.lr.ph65.preheader, label %._crit_edge66

.lr.ph65.preheader:                               ; preds = %._crit_edge60
  %73 = add nsw i32 %71, -1
  br label %.lr.ph65

.lr.ph65:                                         ; preds = %.lr.ph65.preheader, %.lr.ph65
  %.063 = phi i32 [ %.1, %.lr.ph65 ], [ %73, %.lr.ph65.preheader ]
  %.03662 = phi i32 [ %.137, %.lr.ph65 ], [ 0, %.lr.ph65.preheader ]
  %74 = add nuw nsw i32 %.03662, 1
  %75 = add nuw nsw i32 %74, %.063
  %76 = lshr i32 %75, 1
  %77 = zext nneg i32 %76 to i64
  %78 = getelementptr inbounds [1381 x %struct.Node], ptr @seq, i64 0, i64 %77, i32 1
  %79 = call noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72) @vlim, ptr noundef nonnull align 4 dereferenceable(72) %78)
  %80 = add nsw i32 %76, -1
  %.137 = select i1 %79, i32 %.03662, i32 %76
  %.1 = select i1 %79, i32 %80, i32 %.063
  %81 = icmp slt i32 %.137, %.1
  br i1 %81, label %.lr.ph65, label %._crit_edge66.loopexit, !llvm.loop !19

._crit_edge66.loopexit:                           ; preds = %.lr.ph65
  %82 = zext nneg i32 %.137 to i64
  br label %._crit_edge66

._crit_edge66:                                    ; preds = %._crit_edge66.loopexit, %._crit_edge60
  %.036.lcssa = phi i64 [ 0, %._crit_edge60 ], [ %82, %._crit_edge66.loopexit ]
  %83 = getelementptr inbounds [1381 x %struct.Node], ptr @seq, i64 0, i64 %.036.lcssa, i32 1
  call void @_ZN6BigInt5printEc(ptr noundef nonnull align 4 dereferenceable(72) %83, i8 noundef signext 10)
  ret i32 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 nounwind uwtable
declare dso_local void @_ZN6BigIntC2Ei(ptr noundef nonnull align 4 dereferenceable(72), i32 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6BigIntmLERKi(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(25)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(340) ptr @_ZNKSt14priority_queueI4NodeSt6vectorIS0_SaIS0_EESt4lessIS0_EE3topEv(ptr noundef nonnull align 8 dereferenceable(25)) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK6BigIntltERKS_(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef nonnull align 4 dereferenceable(72)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6BigIntdVERKi(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6BigIntC2EPc(ptr noundef nonnull align 4 dereferenceable(72), ptr noundef) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6BigInt5printEc(ptr noundef nonnull align 4 dereferenceable(72), i8 noundef signext) local_unnamed_addr #4 align 2

attributes #0 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = { 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 #6 = { 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 = !{i64 0, i64 4, !6, i64 4, i64 68, !10}
!6 = !{!7, !7, i64 0}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!8, !8, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = !{i64 0, i64 196, !10, i64 196, i64 4, !6, i64 200, i64 68, !10, i64 268, i64 4, !6, i64 272, i64 68, !10}
!16 = distinct !{!16, !12, !17}
!17 = !{!"llvm.loop.peeled.count", i32 1}
!18 = distinct !{!18, !12}
!19 = distinct !{!19, !12}


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