; LLVM IR from ShahjalalShohag/code-library :: Strings (Bit LCS)

; 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.Bitset = type { [811 x i64] }
%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }

@M = external dso_local global i32, align 4
@row = external dso_local global %struct.Bitset, align 8
@bs = external dso_local global [26 x %struct.Bitset], align 16
@x = external dso_local global %struct.Bitset, align 8
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; 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 %"class.std::__cxx11::basic_string", align 8
  %4 = alloca %"class.std::__cxx11::basic_string", align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  store i32 0, ptr %2, align 4, !tbaa !5
  br label %13

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

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

17:                                               ; preds = %13
  %18 = load i32, ptr %2, align 4, !tbaa !5
  %19 = sext i32 %18 to i64
  %20 = getelementptr inbounds [26 x %struct.Bitset], ptr @bs, i64 0, i64 %19
  call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) %20)
  br label %21

21:                                               ; preds = %17
  %22 = load i32, ptr %2, align 4, !tbaa !5
  %23 = add nsw i32 %22, 1
  store i32 %23, ptr %2, align 4, !tbaa !5
  br label %13, !llvm.loop !9

24:                                               ; preds = %16
  call void @llvm.lifetime.start.p0(i64 32, ptr %3) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %3) #5
  call void @llvm.lifetime.start.p0(i64 32, ptr %4) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  %25 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %3)
          to label %26 unwind label %38

26:                                               ; preds = %24
  %27 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) %25, ptr noundef nonnull align 8 dereferenceable(32) %4)
          to label %28 unwind label %38

28:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  %29 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %3) #5
  %30 = trunc i64 %29 to i32
  store i32 %30, ptr %7, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  %31 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  %32 = trunc i64 %31 to i32
  store i32 %32, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !5
  br label %33

33:                                               ; preds = %54, %28
  %34 = load i32, ptr %9, align 4, !tbaa !5
  %35 = load i32, ptr %7, align 4, !tbaa !5
  %36 = icmp slt i32 %34, %35
  br i1 %36, label %42, label %37

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

38:                                               ; preds = %26, %24
  %39 = landingpad { ptr, i32 }
          cleanup
  %40 = extractvalue { ptr, i32 } %39, 0
  store ptr %40, ptr %5, align 8
  %41 = extractvalue { ptr, i32 } %39, 1
  store i32 %41, ptr %6, align 4
  br label %136

42:                                               ; preds = %33
  %43 = load i32, ptr %9, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %45 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %3, i64 noundef %44)
          to label %46 unwind label %57

46:                                               ; preds = %42
  %47 = load i8, ptr %45, align 1, !tbaa !11
  %48 = sext i8 %47 to i32
  %49 = sub nsw i32 %48, 97
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds [26 x %struct.Bitset], ptr @bs, i64 0, i64 %50
  %52 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_ZN6Bitset3setEi(ptr noundef nonnull align 8 dereferenceable(6488) %51, i32 noundef %52)
          to label %53 unwind label %57

53:                                               ; preds = %46
  br label %54

54:                                               ; preds = %53
  %55 = load i32, ptr %9, align 4, !tbaa !5
  %56 = add nsw i32 %55, 1
  store i32 %56, ptr %9, align 4, !tbaa !5
  br label %33, !llvm.loop !12

57:                                               ; preds = %46, %42
  %58 = landingpad { ptr, i32 }
          cleanup
  %59 = extractvalue { ptr, i32 } %58, 0
  store ptr %59, ptr %5, align 8
  %60 = extractvalue { ptr, i32 } %58, 1
  store i32 %60, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %135

61:                                               ; preds = %37
  %62 = load i32, ptr %7, align 4, !tbaa !5
  %63 = sdiv i32 %62, 62
  %64 = load i32, ptr %7, align 4, !tbaa !5
  %65 = srem i32 %64, 62
  %66 = icmp ne i32 %65, 0
  %67 = zext i1 %66 to i32
  %68 = add nsw i32 %63, %67
  store i32 %68, ptr @M, align 4, !tbaa !5
  invoke void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) @row)
          to label %69 unwind label %75

69:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %70

70:                                               ; preds = %119, %69
  %71 = load i32, ptr %10, align 4, !tbaa !5
  %72 = load i32, ptr %8, align 4, !tbaa !5
  %73 = icmp slt i32 %71, %72
  br i1 %73, label %79, label %74

74:                                               ; preds = %70
  store i32 8, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  br label %127

75:                                               ; preds = %131, %129, %127, %61
  %76 = landingpad { ptr, i32 }
          cleanup
  %77 = extractvalue { ptr, i32 } %76, 0
  store ptr %77, ptr %5, align 8
  %78 = extractvalue { ptr, i32 } %76, 1
  store i32 %78, ptr %6, align 4
  br label %135

79:                                               ; preds = %70
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 0, ptr %12, align 4, !tbaa !5
  br label %80

80:                                               ; preds = %108, %79
  %81 = load i32, ptr %12, align 4, !tbaa !5
  %82 = load i32, ptr @M, align 4, !tbaa !5
  %83 = icmp slt i32 %81, %82
  br i1 %83, label %85, label %84

84:                                               ; preds = %80
  store i32 11, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %115

85:                                               ; preds = %80
  %86 = load i32, ptr %12, align 4, !tbaa !5
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds [811 x i64], ptr @row, i64 0, i64 %87
  %89 = load i64, ptr %88, align 8, !tbaa !13
  %90 = load i32, ptr %10, align 4, !tbaa !5
  %91 = sext i32 %90 to i64
  %92 = invoke noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %4, i64 noundef %91)
          to label %93 unwind label %111

93:                                               ; preds = %85
  %94 = load i8, ptr %92, align 1, !tbaa !11
  %95 = sext i8 %94 to i32
  %96 = sub nsw i32 %95, 97
  %97 = sext i32 %96 to i64
  %98 = getelementptr inbounds [26 x %struct.Bitset], ptr @bs, i64 0, i64 %97
  %99 = getelementptr inbounds %struct.Bitset, ptr %98, i32 0, i32 0
  %100 = load i32, ptr %12, align 4, !tbaa !5
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds [811 x i64], ptr %99, i64 0, i64 %101
  %103 = load i64, ptr %102, align 8, !tbaa !13
  %104 = or i64 %89, %103
  %105 = load i32, ptr %12, align 4, !tbaa !5
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds [811 x i64], ptr @x, i64 0, i64 %106
  store i64 %104, ptr %107, align 8, !tbaa !13
  br label %108

108:                                              ; preds = %93
  %109 = load i32, ptr %12, align 4, !tbaa !5
  %110 = add nsw i32 %109, 1
  store i32 %110, ptr %12, align 4, !tbaa !5
  br label %80, !llvm.loop !15

111:                                              ; preds = %85
  %112 = landingpad { ptr, i32 }
          cleanup
  %113 = extractvalue { ptr, i32 } %112, 0
  store ptr %113, ptr %5, align 8
  %114 = extractvalue { ptr, i32 } %112, 1
  store i32 %114, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %126

115:                                              ; preds = %84
  invoke void @_ZN6Bitset3shlEv(ptr noundef nonnull align 8 dereferenceable(6488) @row)
          to label %116 unwind label %122

116:                                              ; preds = %115
  invoke void @_ZN6Bitset3subERKS_(ptr noundef nonnull align 8 dereferenceable(6488) @row, ptr noundef nonnull align 8 dereferenceable(6488) @x)
          to label %117 unwind label %122

117:                                              ; preds = %116
  invoke void @_ZN6Bitset2yoERKS_(ptr noundef nonnull align 8 dereferenceable(6488) @row, ptr noundef nonnull align 8 dereferenceable(6488) @x)
          to label %118 unwind label %122

118:                                              ; preds = %117
  br label %119

119:                                              ; preds = %118
  %120 = load i32, ptr %10, align 4, !tbaa !5
  %121 = add nsw i32 %120, 1
  store i32 %121, ptr %10, align 4, !tbaa !5
  br label %70, !llvm.loop !16

122:                                              ; preds = %117, %116, %115
  %123 = landingpad { ptr, i32 }
          cleanup
  %124 = extractvalue { ptr, i32 } %123, 0
  store ptr %124, ptr %5, align 8
  %125 = extractvalue { ptr, i32 } %123, 1
  store i32 %125, ptr %6, align 4
  br label %126

126:                                              ; preds = %122, %111
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  br label %135

127:                                              ; preds = %74
  %128 = invoke noundef i32 @_ZNK6Bitset5countEv(ptr noundef nonnull align 8 dereferenceable(6488) @row)
          to label %129 unwind label %75

129:                                              ; preds = %127
  %130 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %128)
          to label %131 unwind label %75

131:                                              ; preds = %129
  %132 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8) %130, i8 noundef signext 10)
          to label %133 unwind label %75

133:                                              ; preds = %131
  store i32 0, ptr %1, align 4
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %4) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %3) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %3) #5
  %134 = load i32, ptr %1, align 4
  ret i32 %134

135:                                              ; preds = %126, %75, %57
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  br label %136

136:                                              ; preds = %135, %38
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %4) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %3) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %3) #5
  br label %137

137:                                              ; preds = %136
  %138 = load ptr, ptr %5, align 8
  %139 = load i32, ptr %6, align 4
  %140 = insertvalue { ptr, i32 } poison, ptr %138, 0
  %141 = insertvalue { ptr, i32 } %140, i32 %139, 1
  resume { ptr, i32 } %141
}

; 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 @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488)) #2 align 2

; 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 void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 align 2

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32)) #3

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset3setEi(ptr noundef nonnull align 8 dereferenceable(6488), i32 noundef) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset3shlEv(ptr noundef nonnull align 8 dereferenceable(6488)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset3subERKS_(ptr noundef nonnull align 8 dereferenceable(6488), ptr noundef nonnull align 8 dereferenceable(6488)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset2yoERKS_(ptr noundef nonnull align 8 dereferenceable(6488), ptr noundef nonnull align 8 dereferenceable(6488)) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8), i8 noundef signext) #4

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK6Bitset5countEv(ptr noundef nonnull align 8 dereferenceable(6488)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }

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

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

%struct.Bitset = type { [811 x i64] }
%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }

@M = external dso_local local_unnamed_addr global i32, align 4
@row = external dso_local global %struct.Bitset, align 8
@bs = external dso_local global [26 x %struct.Bitset], align 16
@x = external dso_local global %struct.Bitset, align 8
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::__cxx11::basic_string", align 8
  %2 = alloca %"class.std::__cxx11::basic_string", align 8
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) @bs)
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 6488))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 12976))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 19464))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 25952))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 32440))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 38928))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 45416))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 51904))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 58392))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 64880))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 71368))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 77856))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 84344))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 90832))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 97320))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 103808))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 110296))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 116784))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 123272))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 129760))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 136248))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 142736))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 149224))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 155712))
  tail call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) getelementptr inbounds (i8, ptr @bs, i64 162200))
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %1) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %2) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %2) #5
  %3 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 8 dereferenceable(32) %1)
          to label %4 unwind label %18

4:                                                ; preds = %0
  %5 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(32) %2)
          to label %6 unwind label %18

6:                                                ; preds = %4
  %7 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %1) #5
  %8 = trunc i64 %7 to i32
  %9 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %2) #5
  %10 = trunc i64 %9 to i32
  %11 = icmp sgt i32 %8, 0
  br i1 %11, label %.lr.ph.preheader, label %._crit_edge

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

._crit_edge:                                      ; preds = %.lr.ph, %6
  %12 = sdiv i32 %8, 62
  %13 = srem i32 %8, 62
  %14 = icmp ne i32 %13, 0
  %15 = zext i1 %14 to i32
  %16 = add nsw i32 %12, %15
  store i32 %16, ptr @M, align 4, !tbaa !5
  call void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488) @row)
  %17 = icmp sgt i32 %10, 0
  br i1 %17, label %.preheader.preheader, label %._crit_edge34

.preheader.preheader:                             ; preds = %._crit_edge
  %wide.trip.count43 = and i64 %9, 2147483647
  br label %.preheader

18:                                               ; preds = %4, %0
  %19 = landingpad { ptr, i32 }
          cleanup
  br label %49

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %20 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %1, i64 noundef %indvars.iv)
  %21 = load i8, ptr %20, align 1, !tbaa !9
  %22 = sext i8 %21 to i64
  %23 = add nsw i64 %22, -97
  %24 = getelementptr inbounds [26 x %struct.Bitset], ptr @bs, i64 0, i64 %23
  %25 = trunc nuw nsw i64 %indvars.iv to i32
  call void @_ZN6Bitset3setEi(ptr noundef nonnull align 8 dereferenceable(6488) %24, i32 noundef %25)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !10

.preheader:                                       ; preds = %.preheader.preheader, %._crit_edge32
  %indvars.iv40 = phi i64 [ 0, %.preheader.preheader ], [ %indvars.iv.next41, %._crit_edge32 ]
  %26 = load i32, ptr @M, align 4, !tbaa !5
  %27 = icmp sgt i32 %26, 0
  br i1 %27, label %.lr.ph31, label %._crit_edge32

._crit_edge34:                                    ; preds = %._crit_edge32, %._crit_edge
  %28 = call noundef i32 @_ZNK6Bitset5countEv(ptr noundef nonnull align 8 dereferenceable(6488) @row)
  %29 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %28)
          to label %46 unwind label %30

30:                                               ; preds = %46, %._crit_edge34
  %31 = landingpad { ptr, i32 }
          cleanup
  br label %49

._crit_edge32:                                    ; preds = %.lr.ph31, %.preheader
  call void @_ZN6Bitset3shlEv(ptr noundef nonnull align 8 dereferenceable(6488) @row)
  call void @_ZN6Bitset3subERKS_(ptr noundef nonnull align 8 dereferenceable(6488) @row, ptr noundef nonnull align 8 dereferenceable(6488) @x)
  call void @_ZN6Bitset2yoERKS_(ptr noundef nonnull align 8 dereferenceable(6488) @row, ptr noundef nonnull align 8 dereferenceable(6488) @x)
  %indvars.iv.next41 = add nuw nsw i64 %indvars.iv40, 1
  %exitcond44.not = icmp eq i64 %indvars.iv.next41, %wide.trip.count43
  br i1 %exitcond44.not, label %._crit_edge34, label %.preheader, !llvm.loop !12

.lr.ph31:                                         ; preds = %.preheader, %.lr.ph31
  %indvars.iv37 = phi i64 [ %indvars.iv.next38, %.lr.ph31 ], [ 0, %.preheader ]
  %32 = getelementptr inbounds [811 x i64], ptr @row, i64 0, i64 %indvars.iv37
  %33 = load i64, ptr %32, align 8, !tbaa !13
  %34 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %2, i64 noundef %indvars.iv40)
  %35 = load i8, ptr %34, align 1, !tbaa !9
  %36 = sext i8 %35 to i64
  %37 = add nsw i64 %36, -97
  %38 = getelementptr inbounds [26 x %struct.Bitset], ptr @bs, i64 0, i64 %37
  %39 = getelementptr inbounds [811 x i64], ptr %38, i64 0, i64 %indvars.iv37
  %40 = load i64, ptr %39, align 8, !tbaa !13
  %41 = or i64 %40, %33
  %42 = getelementptr inbounds [811 x i64], ptr @x, i64 0, i64 %indvars.iv37
  store i64 %41, ptr %42, align 8, !tbaa !13
  %indvars.iv.next38 = add nuw nsw i64 %indvars.iv37, 1
  %43 = load i32, ptr @M, align 4, !tbaa !5
  %44 = sext i32 %43 to i64
  %45 = icmp slt i64 %indvars.iv.next38, %44
  br i1 %45, label %.lr.ph31, label %._crit_edge32, !llvm.loop !15

46:                                               ; preds = %._crit_edge34
  %47 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8) %29, i8 noundef signext 10)
          to label %48 unwind label %30

48:                                               ; preds = %46
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %2) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %2) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %1) #5
  ret i32 0

49:                                               ; preds = %30, %18
  %.pn = phi { ptr, i32 } [ %31, %30 ], [ %19, %18 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %2) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %2) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %1) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %1) #5
  resume { ptr, i32 } %.pn
}

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset5clearEv(ptr noundef nonnull align 8 dereferenceable(6488)) local_unnamed_addr #2 align 2

; 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 void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 align 2

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZStrsIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #3

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset3setEi(ptr noundef nonnull align 8 dereferenceable(6488), i32 noundef) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset3shlEv(ptr noundef nonnull align 8 dereferenceable(6488)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset3subERKS_(ptr noundef nonnull align 8 dereferenceable(6488), ptr noundef nonnull align 8 dereferenceable(6488)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6Bitset2yoERKS_(ptr noundef nonnull align 8 dereferenceable(6488), ptr noundef nonnull align 8 dereferenceable(6488)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_c(ptr noundef nonnull align 8 dereferenceable(8), i8 noundef signext) local_unnamed_addr #4

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK6Bitset5countEv(ptr noundef nonnull align 8 dereferenceable(6488)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }

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

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


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