; LLVM IR from HenryRLee/PokerHandEvaluator :: cpp/test (evaluation6_standalone)

; 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.phevaluator::Rank" = type { i32 }
%"class.phevaluator::Card" = type { i32 }

@.str = external hidden unnamed_addr constant [25 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [97 x i8], align 1
@__PRETTY_FUNCTION__.main = external hidden unnamed_addr constant [11 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [26 x i8], align 1

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_Z10percentagexx(i64 noundef, i64 noundef) #1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca %"class.phevaluator::Rank", align 4
  %14 = alloca %"class.phevaluator::Card", align 4
  %15 = alloca %"class.phevaluator::Card", align 4
  %16 = alloca %"class.phevaluator::Card", align 4
  %17 = alloca %"class.phevaluator::Card", align 4
  %18 = alloca %"class.phevaluator::Card", align 4
  %19 = alloca %"class.phevaluator::Card", align 4
  %20 = 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
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  store i32 0, ptr %3, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  store i32 20358520, ptr %4, align 4, !tbaa !5
  %21 = call i32 (ptr, ...) @printf(ptr noundef @.str)
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 0, ptr %5, align 4, !tbaa !5
  br label %22

22:                                               ; preds = %125, %0
  %23 = load i32, ptr %5, align 4, !tbaa !5
  %24 = icmp slt i32 %23, 47
  br i1 %24, label %26, label %25

25:                                               ; preds = %22
  store i32 2, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  br label %128

26:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  %27 = load i32, ptr %5, align 4, !tbaa !5
  %28 = add nsw i32 %27, 1
  store i32 %28, ptr %7, align 4, !tbaa !5
  br label %29

29:                                               ; preds = %121, %26
  %30 = load i32, ptr %7, align 4, !tbaa !5
  %31 = icmp slt i32 %30, 48
  br i1 %31, label %33, label %32

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

33:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  %34 = load i32, ptr %7, align 4, !tbaa !5
  %35 = add nsw i32 %34, 1
  store i32 %35, ptr %8, align 4, !tbaa !5
  br label %36

36:                                               ; preds = %117, %33
  %37 = load i32, ptr %8, align 4, !tbaa !5
  %38 = icmp slt i32 %37, 49
  br i1 %38, label %40, label %39

39:                                               ; preds = %36
  store i32 8, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  br label %120

40:                                               ; preds = %36
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  %41 = load i32, ptr %8, align 4, !tbaa !5
  %42 = add nsw i32 %41, 1
  store i32 %42, ptr %9, align 4, !tbaa !5
  br label %43

43:                                               ; preds = %113, %40
  %44 = load i32, ptr %9, align 4, !tbaa !5
  %45 = icmp slt i32 %44, 50
  br i1 %45, label %47, label %46

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

47:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  %48 = load i32, ptr %9, align 4, !tbaa !5
  %49 = add nsw i32 %48, 1
  store i32 %49, ptr %10, align 4, !tbaa !5
  br label %50

50:                                               ; preds = %109, %47
  %51 = load i32, ptr %10, align 4, !tbaa !5
  %52 = icmp slt i32 %51, 51
  br i1 %52, label %54, label %53

53:                                               ; preds = %50
  store i32 14, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  br label %112

54:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  %55 = load i32, ptr %10, align 4, !tbaa !5
  %56 = add nsw i32 %55, 1
  store i32 %56, ptr %11, align 4, !tbaa !5
  br label %57

57:                                               ; preds = %105, %54
  %58 = load i32, ptr %11, align 4, !tbaa !5
  %59 = icmp slt i32 %58, 52
  br i1 %59, label %61, label %60

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

61:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  %62 = load i32, ptr %5, align 4, !tbaa !5
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %14, i32 noundef %62)
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %63 = load i32, ptr %7, align 4, !tbaa !5
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %15, i32 noundef %63)
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %64 = load i32, ptr %8, align 4, !tbaa !5
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %16, i32 noundef %64)
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  %65 = load i32, ptr %9, align 4, !tbaa !5
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %17, i32 noundef %65)
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %66 = load i32, ptr %10, align 4, !tbaa !5
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %18, i32 noundef %66)
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  %67 = load i32, ptr %11, align 4, !tbaa !5
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %19, i32 noundef %67)
  %68 = call i32 @_ZN11phevaluator13EvaluateCardsERKNS_4CardES2_S2_S2_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %14, ptr noundef nonnull align 4 dereferenceable(4) %15, ptr noundef nonnull align 4 dereferenceable(4) %16, ptr noundef nonnull align 4 dereferenceable(4) %17, ptr noundef nonnull align 4 dereferenceable(4) %18, ptr noundef nonnull align 4 dereferenceable(4) %19)
  %69 = getelementptr inbounds %"class.phevaluator::Rank", ptr %13, i32 0, i32 0
  store i32 %68, ptr %69, align 4
  %70 = call noundef i32 @_ZNK11phevaluator4Rank5valueEv(ptr noundef nonnull align 4 dereferenceable(4) %13)
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  store i32 %70, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  %71 = load i32, ptr %5, align 4, !tbaa !5
  %72 = load i32, ptr %7, align 4, !tbaa !5
  %73 = load i32, ptr %8, align 4, !tbaa !5
  %74 = load i32, ptr %9, align 4, !tbaa !5
  %75 = load i32, ptr %10, align 4, !tbaa !5
  %76 = load i32, ptr %11, align 4, !tbaa !5
  %77 = call signext i16 @kev_eval_6cards(i32 noundef %71, i32 noundef %72, i32 noundef %73, i32 noundef %74, i32 noundef %75, i32 noundef %76)
  %78 = sext i16 %77 to i32
  store i32 %78, ptr %20, align 4, !tbaa !5
  %79 = load i32, ptr %12, align 4, !tbaa !5
  %80 = load i32, ptr %20, align 4, !tbaa !5
  %81 = icmp eq i32 %79, %80
  br i1 %81, label %82, label %83

82:                                               ; preds = %61
  br label %85

83:                                               ; preds = %61
  call void @__assert_fail(ptr noundef @.str.3, ptr noundef @.str.4, i32 noundef 32, ptr noundef @__PRETTY_FUNCTION__.main) #6
  unreachable

84:                                               ; No predecessors!
  br label %85

85:                                               ; preds = %84, %82
  %86 = load i32, ptr %2, align 4, !tbaa !5
  %87 = add nsw i32 %86, 1
  store i32 %87, ptr %2, align 4, !tbaa !5
  %88 = load i32, ptr %2, align 4, !tbaa !5
  %89 = sext i32 %88 to i64
  %90 = call noundef i32 @_Z10percentagexx(i64 noundef %89, i64 noundef 20358520)
  %91 = load i32, ptr %3, align 4, !tbaa !5
  %92 = icmp sgt i32 %90, %91
  br i1 %92, label %93, label %104

93:                                               ; preds = %85
  %94 = load i32, ptr %2, align 4, !tbaa !5
  %95 = sext i32 %94 to i64
  %96 = call noundef i32 @_Z10percentagexx(i64 noundef %95, i64 noundef 20358520)
  store i32 %96, ptr %3, align 4, !tbaa !5
  %97 = load i32, ptr %3, align 4, !tbaa !5
  %98 = srem i32 %97, 10
  %99 = icmp eq i32 %98, 0
  br i1 %99, label %100, label %103

100:                                              ; preds = %93
  %101 = load i32, ptr %3, align 4, !tbaa !5
  %102 = call i32 (ptr, ...) @printf(ptr noundef @.str.5, i32 noundef %101)
  br label %103

103:                                              ; preds = %100, %93
  br label %104

104:                                              ; preds = %103, %85
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %105

105:                                              ; preds = %104
  %106 = load i32, ptr %11, align 4, !tbaa !5
  %107 = add nsw i32 %106, 1
  store i32 %107, ptr %11, align 4, !tbaa !5
  br label %57, !llvm.loop !9

108:                                              ; preds = %60
  br label %109

109:                                              ; preds = %108
  %110 = load i32, ptr %10, align 4, !tbaa !5
  %111 = add nsw i32 %110, 1
  store i32 %111, ptr %10, align 4, !tbaa !5
  br label %50, !llvm.loop !11

112:                                              ; preds = %53
  br label %113

113:                                              ; preds = %112
  %114 = load i32, ptr %9, align 4, !tbaa !5
  %115 = add nsw i32 %114, 1
  store i32 %115, ptr %9, align 4, !tbaa !5
  br label %43, !llvm.loop !12

116:                                              ; preds = %46
  br label %117

117:                                              ; preds = %116
  %118 = load i32, ptr %8, align 4, !tbaa !5
  %119 = add nsw i32 %118, 1
  store i32 %119, ptr %8, align 4, !tbaa !5
  br label %36, !llvm.loop !13

120:                                              ; preds = %39
  br label %121

121:                                              ; preds = %120
  %122 = load i32, ptr %7, align 4, !tbaa !5
  %123 = add nsw i32 %122, 1
  store i32 %123, ptr %7, align 4, !tbaa !5
  br label %29, !llvm.loop !14

124:                                              ; preds = %32
  br label %125

125:                                              ; preds = %124
  %126 = load i32, ptr %5, align 4, !tbaa !5
  %127 = add nsw i32 %126, 1
  store i32 %127, ptr %5, align 4, !tbaa !5
  br label %22, !llvm.loop !15

128:                                              ; preds = %25
  %129 = call i32 (ptr, ...) @printf(ptr noundef @.str.6)
  %130 = load i32, ptr %2, align 4, !tbaa !5
  %131 = call i32 (ptr, ...) @printf(ptr noundef @.str.7, i32 noundef %130)
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  %132 = load i32, ptr %1, align 4
  ret i32 %132
}

declare i32 @printf(ptr noundef, ...) #3

declare i32 @_ZN11phevaluator13EvaluateCardsERKNS_4CardES2_S2_S2_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #3

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK11phevaluator4Rank5valueEv(ptr noundef nonnull align 4 dereferenceable(4)) #1 align 2

declare signext i16 @kev_eval_6cards(i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #3

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 #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 = { noreturn 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 = { nounwind }
attributes #6 = { noreturn nounwind }

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

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

@.str = external hidden unnamed_addr constant [25 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [97 x i8], align 1
@__PRETTY_FUNCTION__.main = external hidden unnamed_addr constant [11 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [26 x i8], align 1

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_Z10percentagexx(i64 noundef, i64 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 {
  %1 = alloca %"class.phevaluator::Rank", align 4
  %2 = alloca %"class.phevaluator::Card", align 4
  %3 = alloca %"class.phevaluator::Card", align 4
  %4 = alloca %"class.phevaluator::Card", align 4
  %5 = alloca %"class.phevaluator::Card", align 4
  %6 = alloca %"class.phevaluator::Card", align 4
  %7 = alloca %"class.phevaluator::Card", align 4
  %8 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str)
  br label %.lr.ph91.preheader

.loopexit54:                                      ; preds = %.loopexit53
  %exitcond98.not = icmp eq i32 %12, 47
  br i1 %exitcond98.not, label %9, label %.lr.ph91.preheader, !llvm.loop !5

9:                                                ; preds = %.loopexit54
  %10 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.6)
  %11 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.7, i32 noundef %.2.lcssa)
  ret i32 0

.lr.ph91.preheader:                               ; preds = %.loopexit54, %0
  %.096 = phi i32 [ 0, %0 ], [ %.2.lcssa, %.loopexit54 ]
  %.03995 = phi i32 [ 0, %0 ], [ %.241.lcssa, %.loopexit54 ]
  %.05094 = phi i32 [ 0, %0 ], [ %12, %.loopexit54 ]
  %12 = add nuw nsw i32 %.05094, 1
  br label %.lr.ph91

.loopexit53:                                      ; preds = %.loopexit52, %.lr.ph91
  %.241.lcssa = phi i32 [ %.14089, %.lr.ph91 ], [ %.6, %.loopexit52 ]
  %.2.lcssa = phi i32 [ %.190, %.lr.ph91 ], [ %19, %.loopexit52 ]
  %exitcond.not = icmp eq i32 %13, 48
  br i1 %exitcond.not, label %.loopexit54, label %.lr.ph91, !llvm.loop !7

.lr.ph91:                                         ; preds = %.lr.ph91.preheader, %.loopexit53
  %.190 = phi i32 [ %.2.lcssa, %.loopexit53 ], [ %.096, %.lr.ph91.preheader ]
  %.14089 = phi i32 [ %.241.lcssa, %.loopexit53 ], [ %.03995, %.lr.ph91.preheader ]
  %.04988 = phi i32 [ %13, %.loopexit53 ], [ %12, %.lr.ph91.preheader ]
  %13 = add nuw nsw i32 %.04988, 1
  %14 = icmp ult i32 %.04988, 48
  br i1 %14, label %.lr.ph79.preheader, label %.loopexit53

.loopexit52:                                      ; preds = %.loopexit51
  %15 = icmp ult i32 %.04882, 48
  br i1 %15, label %.lr.ph79.preheader, label %.loopexit53, !llvm.loop !8

.lr.ph79.preheader:                               ; preds = %.lr.ph91, %.loopexit52
  %.284 = phi i32 [ %19, %.loopexit52 ], [ %.190, %.lr.ph91 ]
  %.24183 = phi i32 [ %.6, %.loopexit52 ], [ %.14089, %.lr.ph91 ]
  %.04882 = phi i32 [ %16, %.loopexit52 ], [ %13, %.lr.ph91 ]
  %16 = add nuw nsw i32 %.04882, 1
  br label %.lr.ph73.preheader

.loopexit51:                                      ; preds = %.loopexit
  %17 = icmp ult i32 %.04776, 49
  br i1 %17, label %.lr.ph73.preheader, label %.loopexit52, !llvm.loop !9

.lr.ph73.preheader:                               ; preds = %.loopexit51, %.lr.ph79.preheader
  %.378 = phi i32 [ %19, %.loopexit51 ], [ %.284, %.lr.ph79.preheader ]
  %.34277 = phi i32 [ %.6, %.loopexit51 ], [ %.24183, %.lr.ph79.preheader ]
  %.04776 = phi i32 [ %18, %.loopexit51 ], [ %16, %.lr.ph79.preheader ]
  %18 = add nuw nsw i32 %.04776, 1
  br label %.lr.ph.preheader

.loopexit:                                        ; preds = %38
  %19 = trunc nsw i64 %indvars.iv.next to i32
  %20 = icmp ult i32 %.04670, 50
  br i1 %20, label %.lr.ph.preheader, label %.loopexit51, !llvm.loop !10

.lr.ph.preheader:                                 ; preds = %.loopexit, %.lr.ph73.preheader
  %.472 = phi i32 [ %19, %.loopexit ], [ %.378, %.lr.ph73.preheader ]
  %.44371 = phi i32 [ %.6, %.loopexit ], [ %.34277, %.lr.ph73.preheader ]
  %.04670 = phi i32 [ %21, %.loopexit ], [ %18, %.lr.ph73.preheader ]
  %21 = add nuw nsw i32 %.04670, 1
  %22 = sext i32 %.472 to i64
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %38
  %indvars.iv = phi i64 [ %22, %.lr.ph.preheader ], [ %indvars.iv.next, %38 ]
  %.54467 = phi i32 [ %.44371, %.lr.ph.preheader ], [ %.6, %38 ]
  %.04566 = phi i32 [ %21, %.lr.ph.preheader ], [ %39, %38 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #6
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %2, i32 noundef %.05094)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %3, i32 noundef %.04988)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #6
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %4, i32 noundef %.04882)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #6
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %5, i32 noundef %.04776)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #6
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %6, i32 noundef %.04670)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #6
  call void @_ZN11phevaluator4CardC2Ei(ptr noundef nonnull align 4 dereferenceable(4) %7, i32 noundef %.04566)
  %23 = call i32 @_ZN11phevaluator13EvaluateCardsERKNS_4CardES2_S2_S2_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %2, ptr noundef nonnull align 4 dereferenceable(4) %3, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %6, ptr noundef nonnull align 4 dereferenceable(4) %7)
  store i32 %23, ptr %1, align 4
  %24 = call noundef i32 @_ZNK11phevaluator4Rank5valueEv(ptr noundef nonnull align 4 dereferenceable(4) %1)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #6
  %25 = call signext i16 @kev_eval_6cards(i32 noundef %.05094, i32 noundef %.04988, i32 noundef %.04882, i32 noundef %.04776, i32 noundef %.04670, i32 noundef %.04566)
  %26 = sext i16 %25 to i32
  %27 = icmp eq i32 %24, %26
  br i1 %27, label %29, label %28

28:                                               ; preds = %.lr.ph
  call void @__assert_fail(ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.4, i32 noundef 32, ptr noundef nonnull @__PRETTY_FUNCTION__.main) #7
  unreachable

29:                                               ; preds = %.lr.ph
  %indvars.iv.next = add nsw i64 %indvars.iv, 1
  %30 = call noundef i32 @_Z10percentagexx(i64 noundef %indvars.iv.next, i64 noundef 20358520)
  %31 = icmp sgt i32 %30, %.54467
  br i1 %31, label %32, label %38

32:                                               ; preds = %29
  %33 = call noundef i32 @_Z10percentagexx(i64 noundef %indvars.iv.next, i64 noundef 20358520)
  %34 = srem i32 %33, 10
  %35 = icmp eq i32 %34, 0
  br i1 %35, label %36, label %38

36:                                               ; preds = %32
  %37 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i32 noundef %33)
  br label %38

38:                                               ; preds = %32, %36, %29
  %.6 = phi i32 [ %33, %36 ], [ %33, %32 ], [ %.54467, %29 ]
  %39 = add nuw nsw i32 %.04566, 1
  %40 = icmp ult i32 %.04566, 51
  br i1 %40, label %.lr.ph, label %.loopexit, !llvm.loop !11
}

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

declare i32 @_ZN11phevaluator13EvaluateCardsERKNS_4CardES2_S2_S2_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK11phevaluator4Rank5valueEv(ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1 align 2

declare signext i16 @kev_eval_6cards(i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #4

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #5

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 #3 = { 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 #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 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }
attributes #7 = { noreturn 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 = distinct !{!7, !6}
!8 = distinct !{!8, !6}
!9 = distinct !{!9, !6}
!10 = distinct !{!10, !6}
!11 = distinct !{!11, !6}


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