; LLVM IR from lzyrapx/Competitive-Programming :: HDUOJ/5782(....) (main)

; 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::bitset" = type { %"struct.std::_Base_bitset" }
%"struct.std::_Base_bitset" = type { [157 x i64] }
%"class.std::bitset<10010>::reference" = type { ptr, i64 }

@A = external dso_local global [10010 x i8], align 16
@B = external dso_local global [10010 x i8], align 16
@posA = external dso_local global [26 x %"class.std::bitset"], align 16
@posB = external dso_local global [26 x %"class.std::bitset"], align 16
@Ap = external dso_local global [10010 x %"class.std::bitset"], align 16
@Bp = external dso_local global [10010 x %"class.std::bitset"], align 16
@ans = external dso_local global { [157 x i64] }, align 8
@tem = external dso_local global { [157 x i64] }, align 8
@pre = external dso_local global [10010 x %"class.std::bitset"], align 16
@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca %"class.std::bitset<10010>::reference", align 8
  %7 = alloca %"class.std::bitset<10010>::reference", align 8
  %8 = alloca i32, align 4
  %9 = alloca %"class.std::bitset", align 8
  %10 = alloca %"class.std::bitset", align 8
  %11 = alloca i8, align 1
  %12 = alloca %"class.std::bitset<10010>::reference", align 8
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca %"class.std::bitset", align 8
  %16 = alloca %"class.std::bitset", align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca %"class.std::bitset<10010>::reference", align 8
  %21 = alloca %"class.std::bitset<10010>::reference", align 8
  %22 = alloca %"class.std::bitset", align 8
  %23 = alloca %"class.std::bitset", align 8
  %24 = alloca i32, align 4
  %25 = alloca %"class.std::bitset<10010>::reference", align 8
  %26 = alloca ptr, align 8
  %27 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #9
  store i32 1, ptr %2, align 4, !tbaa !5
  br label %28

28:                                               ; preds = %44, %0
  %29 = load i32, ptr %2, align 4, !tbaa !5
  %30 = icmp slt i32 %29, 10010
  br i1 %30, label %32, label %31

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

32:                                               ; preds = %28
  %33 = load i32, ptr %2, align 4, !tbaa !5
  %34 = sub nsw i32 %33, 1
  %35 = sext i32 %34 to i64
  %36 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @pre, i64 0, i64 %35
  %37 = load i32, ptr %2, align 4, !tbaa !5
  %38 = sub nsw i32 %37, 1
  %39 = sext i32 %38 to i64
  %40 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE3setEmb(ptr noundef nonnull align 8 dereferenceable(1256) %36, i64 noundef %39, i1 noundef zeroext true)
  %41 = load i32, ptr %2, align 4, !tbaa !5
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @pre, i64 0, i64 %42
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %43, ptr align 8 %40, i64 1256, i1 false)
  br label %44

44:                                               ; preds = %32
  %45 = load i32, ptr %2, align 4, !tbaa !5
  %46 = add nsw i32 %45, 1
  store i32 %46, ptr %2, align 4, !tbaa !5
  br label %28, !llvm.loop !9

47:                                               ; preds = %31
  br label %48

48:                                               ; preds = %280, %47
  %49 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str, ptr noundef @A, ptr noundef @B)
  %50 = xor i32 %49, -1
  %51 = icmp ne i32 %50, 0
  br i1 %51, label %52, label %282

52:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #9
  %53 = call i64 @strlen(ptr noundef @A) #10
  %54 = trunc i64 %53 to i32
  store i32 %54, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #9
  store i32 0, ptr %4, align 4, !tbaa !5
  br label %55

55:                                               ; preds = %68, %52
  %56 = load i32, ptr %4, align 4, !tbaa !5
  %57 = icmp slt i32 %56, 26
  br i1 %57, label %59, label %58

58:                                               ; preds = %55
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #9
  br label %71

59:                                               ; preds = %55
  %60 = load i32, ptr %4, align 4, !tbaa !5
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %61
  %63 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) %62) #9
  %64 = load i32, ptr %4, align 4, !tbaa !5
  %65 = sext i32 %64 to i64
  %66 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %65
  %67 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) %66) #9
  br label %68

68:                                               ; preds = %59
  %69 = load i32, ptr %4, align 4, !tbaa !5
  %70 = add nsw i32 %69, 1
  store i32 %70, ptr %4, align 4, !tbaa !5
  br label %55, !llvm.loop !11

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

72:                                               ; preds = %100, %71
  %73 = load i32, ptr %5, align 4, !tbaa !5
  %74 = load i32, ptr %3, align 4, !tbaa !5
  %75 = icmp slt i32 %73, %74
  br i1 %75, label %77, label %76

76:                                               ; preds = %72
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #9
  br label %103

77:                                               ; preds = %72
  call void @llvm.lifetime.start.p0(i64 16, ptr %6) #9
  %78 = load i32, ptr %5, align 4, !tbaa !5
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds [10010 x i8], ptr @A, i64 0, i64 %79
  %81 = load i8, ptr %80, align 1, !tbaa !12
  %82 = sext i8 %81 to i32
  %83 = sub nsw i32 %82, 97
  %84 = sext i32 %83 to i64
  %85 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %84
  %86 = load i32, ptr %5, align 4, !tbaa !5
  %87 = sext i32 %86 to i64
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind writable sret(%"class.std::bitset<10010>::reference") align 8 %6, ptr noundef nonnull align 8 dereferenceable(1256) %85, i64 noundef %87)
  %88 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %6, i1 noundef zeroext true) #9
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %6) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %6) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %7) #9
  %89 = load i32, ptr %5, align 4, !tbaa !5
  %90 = sext i32 %89 to i64
  %91 = getelementptr inbounds [10010 x i8], ptr @B, i64 0, i64 %90
  %92 = load i8, ptr %91, align 1, !tbaa !12
  %93 = sext i8 %92 to i32
  %94 = sub nsw i32 %93, 97
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %95
  %97 = load i32, ptr %5, align 4, !tbaa !5
  %98 = sext i32 %97 to i64
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind writable sret(%"class.std::bitset<10010>::reference") align 8 %7, ptr noundef nonnull align 8 dereferenceable(1256) %96, i64 noundef %98)
  %99 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %7, i1 noundef zeroext true) #9
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %7) #9
  br label %100

100:                                              ; preds = %77
  %101 = load i32, ptr %5, align 4, !tbaa !5
  %102 = add nsw i32 %101, 1
  store i32 %102, ptr %5, align 4, !tbaa !5
  br label %72, !llvm.loop !13

103:                                              ; preds = %76
  %104 = load i8, ptr @A, align 16, !tbaa !12
  %105 = sext i8 %104 to i32
  %106 = sub nsw i32 %105, 97
  %107 = sext i32 %106 to i64
  %108 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %107
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 @Ap, ptr align 8 %108, i64 1256, i1 false)
  %109 = load i8, ptr @B, align 16, !tbaa !12
  %110 = sext i8 %109 to i32
  %111 = sub nsw i32 %110, 97
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %112
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 @Bp, ptr align 8 %113, i64 1256, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #9
  store i32 1, ptr %8, align 4, !tbaa !5
  br label %114

114:                                              ; preds = %137, %103
  %115 = load i32, ptr %8, align 4, !tbaa !5
  %116 = load i32, ptr %3, align 4, !tbaa !5
  %117 = icmp slt i32 %115, %116
  br i1 %117, label %119, label %118

118:                                              ; preds = %114
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #9
  br label %140

119:                                              ; preds = %114
  call void @llvm.lifetime.start.p0(i64 1256, ptr %9) #9
  %120 = load i32, ptr %8, align 4, !tbaa !5
  %121 = sub nsw i32 %120, 1
  %122 = sext i32 %121 to i64
  %123 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Bp, i64 0, i64 %122
  call void @llvm.lifetime.start.p0(i64 1256, ptr %10) #9
  %124 = load i32, ptr %8, align 4, !tbaa !5
  %125 = sext i32 %124 to i64
  %126 = getelementptr inbounds [10010 x i8], ptr @B, i64 0, i64 %125
  %127 = load i8, ptr %126, align 1, !tbaa !12
  %128 = sext i8 %127 to i32
  %129 = sub nsw i32 %128, 97
  %130 = sext i32 %129 to i64
  %131 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %130
  %132 = load i32, ptr %8, align 4, !tbaa !5
  %133 = sext i32 %132 to i64
  call void @_ZNKSt6bitsetILm10010EErsEm(ptr dead_on_unwind writable sret(%"class.std::bitset") align 8 %10, ptr noundef nonnull align 8 dereferenceable(1256) %131, i64 noundef %133) #9
  call void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind writable sret(%"class.std::bitset") align 8 %9, ptr noundef nonnull align 8 dereferenceable(1256) %123, ptr noundef nonnull align 8 dereferenceable(1256) %10) #9
  %134 = load i32, ptr %8, align 4, !tbaa !5
  %135 = sext i32 %134 to i64
  %136 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Bp, i64 0, i64 %135
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %136, ptr align 8 %9, i64 1256, i1 false)
  call void @llvm.lifetime.end.p0(i64 1256, ptr %10) #9
  call void @llvm.lifetime.end.p0(i64 1256, ptr %9) #9
  br label %137

137:                                              ; preds = %119
  %138 = load i32, ptr %8, align 4, !tbaa !5
  %139 = add nsw i32 %138, 1
  store i32 %139, ptr %8, align 4, !tbaa !5
  br label %114, !llvm.loop !14

140:                                              ; preds = %118
  %141 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) @ans) #9
  %142 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) @tem) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr %11) #9
  %143 = load i8, ptr @A, align 16, !tbaa !12
  %144 = sext i8 %143 to i32
  %145 = load i8, ptr @B, align 16, !tbaa !12
  %146 = sext i8 %145 to i32
  %147 = icmp eq i32 %144, %146
  %148 = zext i1 %147 to i8
  store i8 %148, ptr %11, align 1, !tbaa !15
  %149 = load i8, ptr %11, align 1, !tbaa !15, !range !17, !noundef !18
  %150 = trunc i8 %149 to i1
  br i1 %150, label %151, label %153

151:                                              ; preds = %140
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #9
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind writable sret(%"class.std::bitset<10010>::reference") align 8 %12, ptr noundef nonnull align 8 dereferenceable(1256) @ans, i64 noundef 0)
  %152 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %12, i1 noundef zeroext true) #9
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #9
  br label %153

153:                                              ; preds = %151, %140
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #9
  store i32 1, ptr %13, align 4, !tbaa !5
  br label %154

154:                                              ; preds = %256, %153
  %155 = load i32, ptr %13, align 4, !tbaa !5
  %156 = load i32, ptr %3, align 4, !tbaa !5
  %157 = icmp slt i32 %155, %156
  br i1 %157, label %159, label %158

158:                                              ; preds = %154
  store i32 16, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #9
  br label %259

159:                                              ; preds = %154
  call void @llvm.lifetime.start.p0(i64 1256, ptr %15) #9
  %160 = load i32, ptr %13, align 4, !tbaa !5
  %161 = sub nsw i32 %160, 1
  %162 = sext i32 %161 to i64
  %163 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Ap, i64 0, i64 %162
  call void @llvm.lifetime.start.p0(i64 1256, ptr %16) #9
  %164 = load i32, ptr %13, align 4, !tbaa !5
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds [10010 x i8], ptr @A, i64 0, i64 %165
  %167 = load i8, ptr %166, align 1, !tbaa !12
  %168 = sext i8 %167 to i32
  %169 = sub nsw i32 %168, 97
  %170 = sext i32 %169 to i64
  %171 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %170
  %172 = load i32, ptr %13, align 4, !tbaa !5
  %173 = sext i32 %172 to i64
  call void @_ZNKSt6bitsetILm10010EErsEm(ptr dead_on_unwind writable sret(%"class.std::bitset") align 8 %16, ptr noundef nonnull align 8 dereferenceable(1256) %171, i64 noundef %173) #9
  call void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind writable sret(%"class.std::bitset") align 8 %15, ptr noundef nonnull align 8 dereferenceable(1256) %163, ptr noundef nonnull align 8 dereferenceable(1256) %16) #9
  %174 = load i32, ptr %13, align 4, !tbaa !5
  %175 = sext i32 %174 to i64
  %176 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Ap, i64 0, i64 %175
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %176, ptr align 8 %15, i64 1256, i1 false)
  call void @llvm.lifetime.end.p0(i64 1256, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 1256, ptr %15) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #9
  store i32 0, ptr %17, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #9
  %177 = load i32, ptr %3, align 4, !tbaa !5
  %178 = sub nsw i32 %177, 1
  store i32 %178, ptr %18, align 4, !tbaa !5
  br label %179

179:                                              ; preds = %201, %159
  %180 = load i32, ptr %17, align 4, !tbaa !5
  %181 = load i32, ptr %18, align 4, !tbaa !5
  %182 = icmp slt i32 %180, %181
  br i1 %182, label %183, label %202

183:                                              ; preds = %179
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #9
  %184 = load i32, ptr %17, align 4, !tbaa !5
  %185 = load i32, ptr %18, align 4, !tbaa !5
  %186 = add nsw i32 %184, %185
  %187 = add nsw i32 %186, 1
  %188 = ashr i32 %187, 1
  store i32 %188, ptr %19, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #9
  %189 = load i32, ptr %19, align 4, !tbaa !5
  %190 = sext i32 %189 to i64
  %191 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Bp, i64 0, i64 %190
  %192 = load i32, ptr %13, align 4, !tbaa !5
  %193 = sext i32 %192 to i64
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind writable sret(%"class.std::bitset<10010>::reference") align 8 %20, ptr noundef nonnull align 8 dereferenceable(1256) %191, i64 noundef %193)
  %194 = call noundef zeroext i1 @_ZNKSt6bitsetILm10010EE9referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %20) #9
  %195 = xor i1 %194, true
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %20) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #9
  br i1 %195, label %196, label %199

196:                                              ; preds = %183
  %197 = load i32, ptr %19, align 4, !tbaa !5
  %198 = sub nsw i32 %197, 1
  store i32 %198, ptr %18, align 4, !tbaa !5
  br label %201

199:                                              ; preds = %183
  %200 = load i32, ptr %19, align 4, !tbaa !5
  store i32 %200, ptr %17, align 4, !tbaa !5
  br label %201

201:                                              ; preds = %199, %196
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #9
  br label %179, !llvm.loop !19

202:                                              ; preds = %179
  %203 = load i32, ptr %13, align 4, !tbaa !5
  %204 = sext i32 %203 to i64
  %205 = getelementptr inbounds [10010 x i8], ptr @A, i64 0, i64 %204
  %206 = load i8, ptr %205, align 1, !tbaa !12
  %207 = sext i8 %206 to i32
  %208 = load i32, ptr %13, align 4, !tbaa !5
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds [10010 x i8], ptr @B, i64 0, i64 %209
  %211 = load i8, ptr %210, align 1, !tbaa !12
  %212 = sext i8 %211 to i32
  %213 = icmp eq i32 %207, %212
  %214 = zext i1 %213 to i32
  %215 = load i8, ptr %11, align 1, !tbaa !15, !range !17, !noundef !18
  %216 = trunc i8 %215 to i1
  %217 = zext i1 %216 to i32
  %218 = and i32 %217, %214
  %219 = icmp ne i32 %218, 0
  %220 = zext i1 %219 to i8
  store i8 %220, ptr %11, align 1, !tbaa !15
  %221 = load i8, ptr %11, align 1, !tbaa !15, !range !17, !noundef !18
  %222 = trunc i8 %221 to i1
  br i1 %222, label %223, label %227

223:                                              ; preds = %202
  call void @llvm.lifetime.start.p0(i64 16, ptr %21) #9
  %224 = load i32, ptr %13, align 4, !tbaa !5
  %225 = sext i32 %224 to i64
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind writable sret(%"class.std::bitset<10010>::reference") align 8 %21, ptr noundef nonnull align 8 dereferenceable(1256) @ans, i64 noundef %225)
  %226 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %21, i1 noundef zeroext true) #9
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %21) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %21) #9
  br label %227

227:                                              ; preds = %223, %202
  %228 = load i32, ptr %17, align 4, !tbaa !5
  %229 = icmp eq i32 %228, 0
  br i1 %229, label %230, label %240

230:                                              ; preds = %227
  %231 = load i32, ptr %13, align 4, !tbaa !5
  %232 = sext i32 %231 to i64
  %233 = getelementptr inbounds [10010 x i8], ptr @A, i64 0, i64 %232
  %234 = load i8, ptr %233, align 1, !tbaa !12
  %235 = sext i8 %234 to i32
  %236 = load i8, ptr @B, align 16, !tbaa !12
  %237 = sext i8 %236 to i32
  %238 = icmp ne i32 %235, %237
  br i1 %238, label %239, label %240

239:                                              ; preds = %230
  store i32 18, ptr %14, align 4
  br label %253

240:                                              ; preds = %230, %227
  call void @llvm.lifetime.start.p0(i64 1256, ptr %22) #9
  call void @llvm.lifetime.start.p0(i64 1256, ptr %23) #9
  %241 = load i32, ptr %13, align 4, !tbaa !5
  %242 = sub nsw i32 %241, 1
  %243 = sext i32 %242 to i64
  %244 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Ap, i64 0, i64 %243
  %245 = load i32, ptr %17, align 4, !tbaa !5
  %246 = add nsw i32 %245, 1
  %247 = sext i32 %246 to i64
  %248 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @pre, i64 0, i64 %247
  call void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind writable sret(%"class.std::bitset") align 8 %23, ptr noundef nonnull align 8 dereferenceable(1256) %244, ptr noundef nonnull align 8 dereferenceable(1256) %248) #9
  %249 = load i32, ptr %13, align 4, !tbaa !5
  %250 = sub nsw i32 %249, 1
  %251 = sext i32 %250 to i64
  call void @_ZNKSt6bitsetILm10010EElsEm(ptr dead_on_unwind writable sret(%"class.std::bitset") align 8 %22, ptr noundef nonnull align 8 dereferenceable(1256) %23, i64 noundef %251) #9
  %252 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EEoRERKS0_(ptr noundef nonnull align 8 dereferenceable(1256) @ans, ptr noundef nonnull align 8 dereferenceable(1256) %22) #9
  call void @llvm.lifetime.end.p0(i64 1256, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 1256, ptr %22) #9
  store i32 0, ptr %14, align 4
  br label %253

253:                                              ; preds = %240, %239
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #9
  %254 = load i32, ptr %14, align 4
  switch i32 %254, label %288 [
    i32 0, label %255
    i32 18, label %256
  ]

255:                                              ; preds = %253
  br label %256

256:                                              ; preds = %255, %253
  %257 = load i32, ptr %13, align 4, !tbaa !5
  %258 = add nsw i32 %257, 1
  store i32 %258, ptr %13, align 4, !tbaa !5
  br label %154, !llvm.loop !20

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

260:                                              ; preds = %273, %259
  %261 = load i32, ptr %24, align 4, !tbaa !5
  %262 = load i32, ptr %3, align 4, !tbaa !5
  %263 = icmp slt i32 %261, %262
  br i1 %263, label %265, label %264

264:                                              ; preds = %260
  store i32 21, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  br label %280

265:                                              ; preds = %260
  call void @llvm.lifetime.start.p0(i64 16, ptr %25) #9
  %266 = load i32, ptr %24, align 4, !tbaa !5
  %267 = sext i32 %266 to i64
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind writable sret(%"class.std::bitset<10010>::reference") align 8 %25, ptr noundef nonnull align 8 dereferenceable(1256) @ans, i64 noundef %267)
  %268 = call noundef zeroext i1 @_ZNKSt6bitsetILm10010EE9referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %25) #9
  %269 = zext i1 %268 to i32
  %270 = add nsw i32 %269, 48
  %271 = invoke i32 @putchar(i32 noundef %270)
          to label %272 unwind label %276

272:                                              ; preds = %265
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %25) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %25) #9
  br label %273

273:                                              ; preds = %272
  %274 = load i32, ptr %24, align 4, !tbaa !5
  %275 = add nsw i32 %274, 1
  store i32 %275, ptr %24, align 4, !tbaa !5
  br label %260, !llvm.loop !21

276:                                              ; preds = %265
  %277 = landingpad { ptr, i32 }
          cleanup
  %278 = extractvalue { ptr, i32 } %277, 0
  store ptr %278, ptr %26, align 8
  %279 = extractvalue { ptr, i32 } %277, 1
  store i32 %279, ptr %27, align 4
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %25) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %25) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #9
  br label %283

280:                                              ; preds = %264
  %281 = call i32 @puts(ptr noundef @.str.1)
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #9
  br label %48, !llvm.loop !22

282:                                              ; preds = %48
  ret i32 0

283:                                              ; preds = %276
  %284 = load ptr, ptr %26, align 8
  %285 = load i32, ptr %27, align 4
  %286 = insertvalue { ptr, i32 } poison, ptr %284, 0
  %287 = insertvalue { ptr, i32 } %286, i32 %285, 1
  resume { ptr, i32 } %287

288:                                              ; preds = %253
  unreachable
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE3setEmb(ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef, i1 noundef zeroext) #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

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

; Function Attrs: nounwind willreturn memory(read)
declare i64 @strlen(ptr noundef) #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256)) #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind noalias writable sret(%"class.std::bitset<10010>::reference") align 8, ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef) #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16), i1 noundef zeroext) #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #6 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind noalias writable sret(%"class.std::bitset") align 8, ptr noundef nonnull align 8 dereferenceable(1256), ptr noundef nonnull align 8 dereferenceable(1256)) #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt6bitsetILm10010EErsEm(ptr dead_on_unwind noalias writable sret(%"class.std::bitset") align 8, ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef) #6 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt6bitsetILm10010EElsEm(ptr dead_on_unwind noalias writable sret(%"class.std::bitset") align 8, ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef) #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EEoRERKS0_(ptr noundef nonnull align 8 dereferenceable(1256), ptr noundef nonnull align 8 dereferenceable(1256)) #6 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare i32 @putchar(i32 noundef) #8

declare i32 @__gxx_personality_v0(...)

declare i32 @puts(ptr noundef) #4

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

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

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


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

%"class.std::bitset" = type { %"struct.std::_Base_bitset" }
%"struct.std::_Base_bitset" = type { [157 x i64] }
%"class.std::bitset<10010>::reference" = type { ptr, i64 }

@A = external dso_local global [10010 x i8], align 16
@B = external dso_local global [10010 x i8], align 16
@posA = external dso_local global [26 x %"class.std::bitset"], align 16
@posB = external dso_local global [26 x %"class.std::bitset"], align 16
@Ap = external dso_local global [10010 x %"class.std::bitset"], align 16
@Bp = external dso_local global [10010 x %"class.std::bitset"], align 16
@ans = external dso_local global { [157 x i64] }, align 8
@tem = external dso_local global { [157 x i64] }, align 8
@pre = external dso_local global [10010 x %"class.std::bitset"], align 16
@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::bitset<10010>::reference", align 8
  %2 = alloca %"class.std::bitset<10010>::reference", align 8
  %3 = alloca %"class.std::bitset", align 8
  %4 = alloca %"class.std::bitset", align 8
  %5 = alloca %"class.std::bitset<10010>::reference", align 8
  %6 = alloca %"class.std::bitset", align 8
  %7 = alloca %"class.std::bitset", align 8
  %8 = alloca %"class.std::bitset<10010>::reference", align 8
  %9 = alloca %"class.std::bitset<10010>::reference", align 8
  %10 = alloca %"class.std::bitset", align 8
  %11 = alloca %"class.std::bitset", align 8
  %12 = alloca %"class.std::bitset<10010>::reference", align 8
  br label %14

.preheader66:                                     ; preds = %14
  %13 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @A, ptr noundef nonnull @B)
  %.not86 = icmp eq i32 %13, -1
  br i1 %.not86, label %._crit_edge88, label %.lr.ph87

14:                                               ; preds = %0, %14
  %indvars.iv = phi i64 [ 1, %0 ], [ %indvars.iv.next, %14 ]
  %15 = add nsw i64 %indvars.iv, -1
  %16 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @pre, i64 0, i64 %15
  %17 = tail call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE3setEmb(ptr noundef nonnull align 8 dereferenceable(1256) %16, i64 noundef %15, i1 noundef zeroext true)
  %18 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @pre, i64 0, i64 %indvars.iv
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(1256) %18, ptr noundef nonnull align 8 dereferenceable(1256) %17, i64 1256, i1 false)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 10010
  br i1 %exitcond.not, label %.preheader66, label %14, !llvm.loop !5

.lr.ph87:                                         ; preds = %.preheader66, %._crit_edge85
  %19 = call i64 @strlen(ptr noundef nonnull dereferenceable(1) @A) #9
  %20 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) @posA) #10
  %21 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) @posB) #10
  %22 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 1256)) #10
  %23 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 1256)) #10
  %24 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 2512)) #10
  %25 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 2512)) #10
  %26 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 3768)) #10
  %27 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 3768)) #10
  %28 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 5024)) #10
  %29 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 5024)) #10
  %30 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 6280)) #10
  %31 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 6280)) #10
  %32 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 7536)) #10
  %33 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 7536)) #10
  %34 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 8792)) #10
  %35 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 8792)) #10
  %36 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 10048)) #10
  %37 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 10048)) #10
  %38 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 11304)) #10
  %39 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 11304)) #10
  %40 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 12560)) #10
  %41 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 12560)) #10
  %42 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 13816)) #10
  %43 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 13816)) #10
  %44 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 15072)) #10
  %45 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 15072)) #10
  %46 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 16328)) #10
  %47 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 16328)) #10
  %48 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 17584)) #10
  %49 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 17584)) #10
  %50 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 18840)) #10
  %51 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 18840)) #10
  %52 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 20096)) #10
  %53 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 20096)) #10
  %54 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 21352)) #10
  %55 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 21352)) #10
  %56 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 22608)) #10
  %57 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 22608)) #10
  %58 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 23864)) #10
  %59 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 23864)) #10
  %60 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 25120)) #10
  %61 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 25120)) #10
  %62 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 26376)) #10
  %63 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 26376)) #10
  %64 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 27632)) #10
  %65 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 27632)) #10
  %66 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 28888)) #10
  %67 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 28888)) #10
  %68 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 30144)) #10
  %69 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 30144)) #10
  %70 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posA, i64 31400)) #10
  %71 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) getelementptr inbounds (i8, ptr @posB, i64 31400)) #10
  %72 = trunc i64 %19 to i32
  %73 = icmp sgt i32 %72, 0
  br i1 %73, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %.lr.ph87
  %wide.trip.count = and i64 %19, 2147483647
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %.lr.ph87
  %74 = load i8, ptr @A, align 16, !tbaa !7
  %75 = sext i8 %74 to i64
  %76 = add nsw i64 %75, -97
  %77 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %76
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(1256) @Ap, ptr noundef nonnull align 8 dereferenceable(1256) %77, i64 1256, i1 false)
  %78 = load i8, ptr @B, align 16, !tbaa !7
  %79 = sext i8 %78 to i64
  %80 = add nsw i64 %79, -97
  %81 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %80
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(1256) @Bp, ptr noundef nonnull align 8 dereferenceable(1256) %81, i64 1256, i1 false)
  %82 = icmp sgt i32 %72, 1
  br i1 %82, label %.lr.ph72.preheader, label %._crit_edge73

.lr.ph72.preheader:                               ; preds = %._crit_edge
  %wide.trip.count101 = and i64 %19, 2147483647
  br label %.lr.ph72

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv94 = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next95, %.lr.ph ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %1) #10
  %83 = getelementptr inbounds [10010 x i8], ptr @A, i64 0, i64 %indvars.iv94
  %84 = load i8, ptr %83, align 1, !tbaa !7
  %85 = sext i8 %84 to i64
  %86 = add nsw i64 %85, -97
  %87 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %86
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset<10010>::reference") align 8 %1, ptr noundef nonnull align 8 dereferenceable(1256) %87, i64 noundef %indvars.iv94)
  %88 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %1, i1 noundef zeroext true) #10
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %1) #10
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %1) #10
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %2) #10
  %89 = getelementptr inbounds [10010 x i8], ptr @B, i64 0, i64 %indvars.iv94
  %90 = load i8, ptr %89, align 1, !tbaa !7
  %91 = sext i8 %90 to i64
  %92 = add nsw i64 %91, -97
  %93 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %92
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset<10010>::reference") align 8 %2, ptr noundef nonnull align 8 dereferenceable(1256) %93, i64 noundef %indvars.iv94)
  %94 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %2, i1 noundef zeroext true) #10
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %2) #10
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %2) #10
  %indvars.iv.next95 = add nuw nsw i64 %indvars.iv94, 1
  %exitcond97.not = icmp eq i64 %indvars.iv.next95, %wide.trip.count
  br i1 %exitcond97.not, label %._crit_edge, label %.lr.ph, !llvm.loop !10

._crit_edge73:                                    ; preds = %.lr.ph72, %._crit_edge
  %95 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) @ans) #10
  %96 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256) @tem) #10
  %97 = load i8, ptr @A, align 16, !tbaa !7
  %98 = load i8, ptr @B, align 16, !tbaa !7
  %99 = icmp eq i8 %97, %98
  br i1 %99, label %108, label %110

.lr.ph72:                                         ; preds = %.lr.ph72.preheader, %.lr.ph72
  %indvars.iv98 = phi i64 [ 1, %.lr.ph72.preheader ], [ %indvars.iv.next99, %.lr.ph72 ]
  call void @llvm.lifetime.start.p0(i64 1256, ptr nonnull %3) #10
  %100 = add nsw i64 %indvars.iv98, -1
  %101 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Bp, i64 0, i64 %100
  call void @llvm.lifetime.start.p0(i64 1256, ptr nonnull %4) #10
  %102 = getelementptr inbounds [10010 x i8], ptr @B, i64 0, i64 %indvars.iv98
  %103 = load i8, ptr %102, align 1, !tbaa !7
  %104 = sext i8 %103 to i64
  %105 = add nsw i64 %104, -97
  %106 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posA, i64 0, i64 %105
  call void @_ZNKSt6bitsetILm10010EErsEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset") align 8 %4, ptr noundef nonnull align 8 dereferenceable(1256) %106, i64 noundef %indvars.iv98) #10
  call void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset") align 8 %3, ptr noundef nonnull align 8 dereferenceable(1256) %101, ptr noundef nonnull align 8 dereferenceable(1256) %4) #10
  %107 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Bp, i64 0, i64 %indvars.iv98
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(1256) %107, ptr noundef nonnull align 8 dereferenceable(1256) %3, i64 1256, i1 false)
  call void @llvm.lifetime.end.p0(i64 1256, ptr nonnull %4) #10
  call void @llvm.lifetime.end.p0(i64 1256, ptr nonnull %3) #10
  %indvars.iv.next99 = add nuw nsw i64 %indvars.iv98, 1
  %exitcond102.not = icmp eq i64 %indvars.iv.next99, %wide.trip.count101
  br i1 %exitcond102.not, label %._crit_edge73, label %.lr.ph72, !llvm.loop !11

108:                                              ; preds = %._crit_edge73
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #10
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset<10010>::reference") align 8 %5, ptr noundef nonnull align 8 dereferenceable(1256) @ans, i64 noundef 0)
  %109 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %5, i1 noundef zeroext true) #10
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %5) #10
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #10
  br label %110

110:                                              ; preds = %108, %._crit_edge73
  br i1 %82, label %.lr.ph82, label %.preheader

.lr.ph82:                                         ; preds = %110
  %111 = add nsw i32 %72, -1
  %wide.trip.count105 = and i64 %19, 2147483647
  br label %.lr.ph77.preheader

.preheader:                                       ; preds = %145, %110
  br i1 %73, label %.lr.ph84.preheader, label %._crit_edge85

.lr.ph84.preheader:                               ; preds = %.preheader
  %wide.trip.count110 = and i64 %19, 2147483647
  br label %.lr.ph84

.lr.ph77.preheader:                               ; preds = %145, %.lr.ph82
  %indvars.iv103 = phi i64 [ 1, %.lr.ph82 ], [ %indvars.iv.next104, %145 ]
  %.059.in79 = phi i1 [ %99, %.lr.ph82 ], [ %132, %145 ]
  call void @llvm.lifetime.start.p0(i64 1256, ptr nonnull %6) #10
  %112 = add nsw i64 %indvars.iv103, -1
  %113 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Ap, i64 0, i64 %112
  call void @llvm.lifetime.start.p0(i64 1256, ptr nonnull %7) #10
  %114 = getelementptr inbounds [10010 x i8], ptr @A, i64 0, i64 %indvars.iv103
  %115 = load i8, ptr %114, align 1, !tbaa !7
  %116 = sext i8 %115 to i64
  %117 = add nsw i64 %116, -97
  %118 = getelementptr inbounds [26 x %"class.std::bitset"], ptr @posB, i64 0, i64 %117
  call void @_ZNKSt6bitsetILm10010EErsEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset") align 8 %7, ptr noundef nonnull align 8 dereferenceable(1256) %118, i64 noundef %indvars.iv103) #10
  call void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset") align 8 %6, ptr noundef nonnull align 8 dereferenceable(1256) %113, ptr noundef nonnull align 8 dereferenceable(1256) %7) #10
  %119 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Ap, i64 0, i64 %indvars.iv103
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(1256) %119, ptr noundef nonnull align 8 dereferenceable(1256) %6, i64 1256, i1 false)
  call void @llvm.lifetime.end.p0(i64 1256, ptr nonnull %7) #10
  call void @llvm.lifetime.end.p0(i64 1256, ptr nonnull %6) #10
  br label %.lr.ph77

.lr.ph77:                                         ; preds = %.lr.ph77.preheader, %.lr.ph77
  %.05575 = phi i32 [ %.1, %.lr.ph77 ], [ %111, %.lr.ph77.preheader ]
  %.05674 = phi i32 [ %.157, %.lr.ph77 ], [ 0, %.lr.ph77.preheader ]
  %120 = add nuw nsw i32 %.05674, 1
  %121 = add nuw nsw i32 %120, %.05575
  %122 = lshr i32 %121, 1
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %8) #10
  %123 = zext nneg i32 %122 to i64
  %124 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @Bp, i64 0, i64 %123
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset<10010>::reference") align 8 %8, ptr noundef nonnull align 8 dereferenceable(1256) %124, i64 noundef %indvars.iv103)
  %125 = call noundef zeroext i1 @_ZNKSt6bitsetILm10010EE9referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %8) #10
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %8) #10
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #10
  %126 = add nsw i32 %122, -1
  %.157 = select i1 %125, i32 %122, i32 %.05674
  %.1 = select i1 %125, i32 %.05575, i32 %126
  %127 = icmp slt i32 %.157, %.1
  br i1 %127, label %.lr.ph77, label %._crit_edge78, !llvm.loop !12

._crit_edge78:                                    ; preds = %.lr.ph77
  %128 = load i8, ptr %114, align 1, !tbaa !7
  %129 = getelementptr inbounds [10010 x i8], ptr @B, i64 0, i64 %indvars.iv103
  %130 = load i8, ptr %129, align 1, !tbaa !7
  %131 = icmp eq i8 %128, %130
  %132 = and i1 %.059.in79, %131
  br i1 %132, label %133, label %135

133:                                              ; preds = %._crit_edge78
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #10
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset<10010>::reference") align 8 %9, ptr noundef nonnull align 8 dereferenceable(1256) @ans, i64 noundef %indvars.iv103)
  %134 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16) %9, i1 noundef zeroext true) #10
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #10
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #10
  br label %135

135:                                              ; preds = %133, %._crit_edge78
  %136 = icmp eq i32 %.157, 0
  br i1 %136, label %137, label %140

137:                                              ; preds = %135
  %138 = load i8, ptr %114, align 1, !tbaa !7
  %139 = load i8, ptr @B, align 16, !tbaa !7
  %.not64 = icmp eq i8 %138, %139
  br i1 %.not64, label %140, label %145

140:                                              ; preds = %137, %135
  call void @llvm.lifetime.start.p0(i64 1256, ptr nonnull %10) #10
  call void @llvm.lifetime.start.p0(i64 1256, ptr nonnull %11) #10
  %141 = add nuw nsw i32 %.157, 1
  %142 = zext nneg i32 %141 to i64
  %143 = getelementptr inbounds [10010 x %"class.std::bitset"], ptr @pre, i64 0, i64 %142
  call void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset") align 8 %11, ptr noundef nonnull align 8 dereferenceable(1256) %113, ptr noundef nonnull align 8 dereferenceable(1256) %143) #10
  call void @_ZNKSt6bitsetILm10010EElsEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset") align 8 %10, ptr noundef nonnull align 8 dereferenceable(1256) %11, i64 noundef %112) #10
  %144 = call noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EEoRERKS0_(ptr noundef nonnull align 8 dereferenceable(1256) @ans, ptr noundef nonnull align 8 dereferenceable(1256) %10) #10
  call void @llvm.lifetime.end.p0(i64 1256, ptr nonnull %11) #10
  call void @llvm.lifetime.end.p0(i64 1256, ptr nonnull %10) #10
  br label %145

145:                                              ; preds = %137, %140
  %indvars.iv.next104 = add nuw nsw i64 %indvars.iv103, 1
  %exitcond106.not = icmp eq i64 %indvars.iv.next104, %wide.trip.count105
  br i1 %exitcond106.not, label %.preheader, label %.lr.ph77.preheader, !llvm.loop !13

._crit_edge85:                                    ; preds = %.lr.ph84, %.preheader
  %146 = call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.1)
  %147 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str, ptr noundef nonnull @A, ptr noundef nonnull @B)
  %.not = icmp eq i32 %147, -1
  br i1 %.not, label %._crit_edge88, label %.lr.ph87, !llvm.loop !14

.lr.ph84:                                         ; preds = %.lr.ph84.preheader, %.lr.ph84
  %indvars.iv107 = phi i64 [ 0, %.lr.ph84.preheader ], [ %indvars.iv.next108, %.lr.ph84 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %12) #10
  call void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind nonnull writable sret(%"class.std::bitset<10010>::reference") align 8 %12, ptr noundef nonnull align 8 dereferenceable(1256) @ans, i64 noundef %indvars.iv107)
  %148 = call noundef zeroext i1 @_ZNKSt6bitsetILm10010EE9referencecvbEv(ptr noundef nonnull align 8 dereferenceable(16) %12) #10
  %149 = select i1 %148, i32 49, i32 48
  %150 = call i32 @putchar(i32 noundef %149)
  call void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #10
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #10
  %indvars.iv.next108 = add nuw nsw i64 %indvars.iv107, 1
  %exitcond111.not = icmp eq i64 %indvars.iv.next108, %wide.trip.count110
  br i1 %exitcond111.not, label %._crit_edge85, label %.lr.ph84, !llvm.loop !15

._crit_edge88:                                    ; preds = %._crit_edge85, %.preheader66
  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 uwtable
declare dso_local noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE3setEmb(ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef, i1 noundef zeroext) local_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: nofree nounwind
declare noundef i32 @__isoc99_scanf(ptr nocapture noundef readonly, ...) local_unnamed_addr #4

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare i64 @strlen(ptr nocapture noundef) local_unnamed_addr #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EE5resetEv(ptr noundef nonnull align 8 dereferenceable(1256)) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6bitsetILm10010EEixEm(ptr dead_on_unwind noalias writable sret(%"class.std::bitset<10010>::reference") align 8, ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt6bitsetILm10010EE9referenceaSEb(ptr noundef nonnull align 8 dereferenceable(16), i1 noundef zeroext) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6bitsetILm10010EE9referenceD2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #6 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZStanILm10010EESt6bitsetIXT_EERKS1_S3_(ptr dead_on_unwind noalias writable sret(%"class.std::bitset") align 8, ptr noundef nonnull align 8 dereferenceable(1256), ptr noundef nonnull align 8 dereferenceable(1256)) local_unnamed_addr #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt6bitsetILm10010EErsEm(ptr dead_on_unwind noalias writable sret(%"class.std::bitset") align 8, ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef) local_unnamed_addr #6 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt6bitsetILm10010EElsEm(ptr dead_on_unwind noalias writable sret(%"class.std::bitset") align 8, ptr noundef nonnull align 8 dereferenceable(1256), i64 noundef) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(1256) ptr @_ZNSt6bitsetILm10010EEoRERKS0_(ptr noundef nonnull align 8 dereferenceable(1256), ptr noundef nonnull align 8 dereferenceable(1256)) local_unnamed_addr #6 align 2

; Function Attrs: inlinehint mustprogress nofree nounwind uwtable
declare noundef i32 @putchar(i32 noundef) local_unnamed_addr #8

declare i32 @__gxx_personality_v0(...)

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

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 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 = { 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 #5 = { mustprogress nofree nounwind willreturn memory(argmem: read) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress 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 #7 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { inlinehint mustprogress nofree 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 #9 = { nounwind willreturn memory(read) }
attributes #10 = { 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 = distinct !{!5, !6}
!6 = !{!"llvm.loop.mustprogress"}
!7 = !{!8, !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = distinct !{!10, !6}
!11 = distinct !{!11, !6}
!12 = distinct !{!12, !6}
!13 = distinct !{!13, !6}
!14 = distinct !{!14, !6}
!15 = distinct !{!15, !6}


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