; LLVM IR from viveakrt/Competitive-programing :: SPOJ (larmy)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::basic_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" }

@n = external dso_local global i32, align 4
@k = external dso_local global i32, align 4
@a = external dso_local global [5001 x i32], align 16
@dp = external dso_local global [2 x [5001 x i32]], align 16
@in = external dso_local global [5001 x [5001 x i32]], align 16
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z7computeiiiiii(i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #0

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

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #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
  store i32 0, ptr %1, align 4
  %7 = call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  %8 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %9 = getelementptr i8, ptr %8, i64 -24
  %10 = load i64, ptr %9, align 8
  %11 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %10
  %12 = call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %11, ptr noundef null)
  %13 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) @n)
  %14 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef nonnull align 4 dereferenceable(4) @k)
  %15 = load i32, ptr @k, align 4, !tbaa !8
  %16 = add nsw i32 %15, -1
  store i32 %16, ptr @k, align 4, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  store i32 1, ptr %2, align 4, !tbaa !8
  br label %17

17:                                               ; preds = %27, %0
  %18 = load i32, ptr %2, align 4, !tbaa !8
  %19 = load i32, ptr @n, align 4, !tbaa !8
  %20 = icmp sle i32 %18, %19
  br i1 %20, label %22, label %21

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

22:                                               ; preds = %17
  %23 = load i32, ptr %2, align 4, !tbaa !8
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [5001 x i32], ptr @a, i64 0, i64 %24
  %26 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %25)
  br label %27

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

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

31:                                               ; preds = %103, %30
  %32 = load i32, ptr %3, align 4, !tbaa !8
  %33 = load i32, ptr @n, align 4, !tbaa !8
  %34 = icmp sle i32 %32, %33
  br i1 %34, label %36, label %35

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

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

37:                                               ; preds = %99, %36
  %38 = load i32, ptr %5, align 4, !tbaa !8
  %39 = load i32, ptr @n, align 4, !tbaa !8
  %40 = icmp sle i32 %38, %39
  br i1 %40, label %42, label %41

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

42:                                               ; preds = %37
  %43 = load i32, ptr %3, align 4, !tbaa !8
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [5001 x i32], ptr @a, i64 0, i64 %44
  %46 = load i32, ptr %45, align 4, !tbaa !8
  %47 = load i32, ptr %5, align 4, !tbaa !8
  %48 = sext i32 %47 to i64
  %49 = getelementptr inbounds [5001 x i32], ptr @a, i64 0, i64 %48
  %50 = load i32, ptr %49, align 4, !tbaa !8
  %51 = icmp sgt i32 %46, %50
  br i1 %51, label %52, label %63

52:                                               ; preds = %42
  %53 = load i32, ptr %5, align 4, !tbaa !8
  %54 = load i32, ptr %3, align 4, !tbaa !8
  %55 = icmp sgt i32 %53, %54
  br i1 %55, label %56, label %63

56:                                               ; preds = %52
  %57 = load i32, ptr %3, align 4, !tbaa !8
  %58 = sext i32 %57 to i64
  %59 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %58
  %60 = load i32, ptr %5, align 4, !tbaa !8
  %61 = sext i32 %60 to i64
  %62 = getelementptr inbounds [5001 x i32], ptr %59, i64 0, i64 %61
  store i32 1, ptr %62, align 4, !tbaa !8
  br label %63

63:                                               ; preds = %56, %52, %42
  %64 = load i32, ptr %3, align 4, !tbaa !8
  %65 = sub nsw i32 %64, 1
  %66 = sext i32 %65 to i64
  %67 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %66
  %68 = load i32, ptr %5, align 4, !tbaa !8
  %69 = sext i32 %68 to i64
  %70 = getelementptr inbounds [5001 x i32], ptr %67, i64 0, i64 %69
  %71 = load i32, ptr %70, align 4, !tbaa !8
  %72 = load i32, ptr %3, align 4, !tbaa !8
  %73 = sext i32 %72 to i64
  %74 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %73
  %75 = load i32, ptr %5, align 4, !tbaa !8
  %76 = sub nsw i32 %75, 1
  %77 = sext i32 %76 to i64
  %78 = getelementptr inbounds [5001 x i32], ptr %74, i64 0, i64 %77
  %79 = load i32, ptr %78, align 4, !tbaa !8
  %80 = add nsw i32 %71, %79
  %81 = load i32, ptr %3, align 4, !tbaa !8
  %82 = sub nsw i32 %81, 1
  %83 = sext i32 %82 to i64
  %84 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %83
  %85 = load i32, ptr %5, align 4, !tbaa !8
  %86 = sub nsw i32 %85, 1
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds [5001 x i32], ptr %84, i64 0, i64 %87
  %89 = load i32, ptr %88, align 4, !tbaa !8
  %90 = sub nsw i32 %80, %89
  %91 = load i32, ptr %3, align 4, !tbaa !8
  %92 = sext i32 %91 to i64
  %93 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %92
  %94 = load i32, ptr %5, align 4, !tbaa !8
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds [5001 x i32], ptr %93, i64 0, i64 %95
  %97 = load i32, ptr %96, align 4, !tbaa !8
  %98 = add nsw i32 %97, %90
  store i32 %98, ptr %96, align 4, !tbaa !8
  br label %99

99:                                               ; preds = %63
  %100 = load i32, ptr %5, align 4, !tbaa !8
  %101 = add nsw i32 %100, 1
  store i32 %101, ptr %5, align 4, !tbaa !8
  br label %37, !llvm.loop !13

102:                                              ; preds = %41
  br label %103

103:                                              ; preds = %102
  %104 = load i32, ptr %3, align 4, !tbaa !8
  %105 = add nsw i32 %104, 1
  store i32 %105, ptr %3, align 4, !tbaa !8
  br label %31, !llvm.loop !14

106:                                              ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  store i32 1, ptr %6, align 4, !tbaa !8
  br label %107

107:                                              ; preds = %120, %106
  %108 = load i32, ptr %6, align 4, !tbaa !8
  %109 = load i32, ptr @k, align 4, !tbaa !8
  %110 = icmp sle i32 %108, %109
  br i1 %110, label %112, label %111

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

112:                                              ; preds = %107
  %113 = load i32, ptr %6, align 4, !tbaa !8
  %114 = load i32, ptr @n, align 4, !tbaa !8
  %115 = load i32, ptr %6, align 4, !tbaa !8
  %116 = load i32, ptr @n, align 4, !tbaa !8
  %117 = load i32, ptr %6, align 4, !tbaa !8
  %118 = srem i32 %117, 2
  %119 = load i32, ptr %6, align 4, !tbaa !8
  call void @_Z7computeiiiiii(i32 noundef %113, i32 noundef %114, i32 noundef %115, i32 noundef %116, i32 noundef %118, i32 noundef %119)
  br label %120

120:                                              ; preds = %112
  %121 = load i32, ptr %6, align 4, !tbaa !8
  %122 = add nsw i32 %121, 1
  store i32 %122, ptr %6, align 4, !tbaa !8
  br label %107, !llvm.loop !15

123:                                              ; preds = %111
  %124 = load i32, ptr @k, align 4, !tbaa !8
  %125 = srem i32 %124, 2
  %126 = sext i32 %125 to i64
  %127 = getelementptr inbounds [2 x [5001 x i32]], ptr @dp, i64 0, i64 %126
  %128 = load i32, ptr @n, align 4, !tbaa !8
  %129 = sext i32 %128 to i64
  %130 = getelementptr inbounds [5001 x i32], ptr %127, i64 0, i64 %129
  %131 = load i32, ptr %130, align 4, !tbaa !8
  %132 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %131)
  %133 = load i32, ptr %1, align 4
  ret i32 %133
}

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) #3

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

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) #3

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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 #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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"int", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}


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

%"class.std::basic_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" }

@n = external dso_local global i32, align 4
@k = external dso_local global i32, align 4
@a = external dso_local global [5001 x i32], align 16
@dp = external dso_local local_unnamed_addr global [2 x [5001 x i32]], align 16
@in = external dso_local local_unnamed_addr global [5001 x [5001 x i32]], align 16
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@_ZSt4cout = external global %"class.std::basic_ostream", align 8

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z7computeiiiiii(i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #1 {
  %1 = tail call noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext false)
  %2 = load ptr, ptr @_ZSt3cin, align 8, !tbaa !5
  %3 = getelementptr i8, ptr %2, i64 -24
  %4 = load i64, ptr %3, align 8
  %5 = getelementptr inbounds i8, ptr @_ZSt3cin, i64 %4
  %6 = tail call noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264) %5, ptr noundef null)
  %7 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) @n)
  %8 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) %7, ptr noundef nonnull align 4 dereferenceable(4) @k)
  %9 = load i32, ptr @k, align 4, !tbaa !8
  %10 = add nsw i32 %9, -1
  store i32 %10, ptr @k, align 4, !tbaa !8
  %11 = load i32, ptr @n, align 4, !tbaa !8
  %.not38 = icmp slt i32 %11, 1
  br i1 %.not38, label %.preheader, label %.lr.ph

.preheader36:                                     ; preds = %.lr.ph
  %.not3243 = icmp slt i32 %15, 1
  br i1 %.not3243, label %.preheaderthread-pre-split, label %.preheader35.preheader

.preheader35.preheader:                           ; preds = %.preheader36
  %12 = add nuw i32 %15, 1
  %wide.trip.count59 = zext i32 %12 to i64
  br label %.preheader35

.lr.ph:                                           ; preds = %0, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 1, %0 ]
  %13 = getelementptr inbounds [5001 x i32], ptr @a, i64 0, i64 %indvars.iv
  %14 = tail call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %13)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %15 = load i32, ptr @n, align 4, !tbaa !8
  %16 = sext i32 %15 to i64
  %.not.not = icmp slt i64 %indvars.iv, %16
  br i1 %.not.not, label %.lr.ph, label %.preheader36, !llvm.loop !11

.preheader35:                                     ; preds = %.preheader35.preheader, %._crit_edge
  %indvars.iv56 = phi i64 [ 1, %.preheader35.preheader ], [ %indvars.iv.next57, %._crit_edge ]
  %17 = getelementptr inbounds [5001 x i32], ptr @a, i64 0, i64 %indvars.iv56
  %18 = load i32, ptr %17, align 4, !tbaa !8
  %19 = add nsw i64 %indvars.iv56, -1
  br label %21

.preheaderthread-pre-split:                       ; preds = %._crit_edge, %.preheader36
  %.pr = load i32, ptr @k, align 4, !tbaa !8
  br label %.preheader

.preheader:                                       ; preds = %0, %.preheaderthread-pre-split
  %20 = phi i32 [ %.pr, %.preheaderthread-pre-split ], [ %10, %0 ]
  %.lcssa3765 = phi i32 [ %15, %.preheaderthread-pre-split ], [ %11, %0 ]
  %.not3345 = icmp slt i32 %20, 1
  br i1 %.not3345, label %._crit_edge48, label %.lr.ph47

._crit_edge:                                      ; preds = %26
  %indvars.iv.next57 = add nuw nsw i64 %indvars.iv56, 1
  %exitcond60.not = icmp eq i64 %indvars.iv.next57, %wide.trip.count59
  br i1 %exitcond60.not, label %.preheaderthread-pre-split, label %.preheader35, !llvm.loop !13

21:                                               ; preds = %.preheader35, %26
  %indvars.iv53 = phi i64 [ 1, %.preheader35 ], [ %indvars.iv.next54, %26 ]
  %22 = getelementptr inbounds [5001 x i32], ptr @a, i64 0, i64 %indvars.iv53
  %23 = load i32, ptr %22, align 4, !tbaa !8
  %24 = icmp sgt i32 %18, %23
  %25 = icmp ugt i64 %indvars.iv53, %indvars.iv56
  %or.cond = and i1 %25, %24
  br i1 %or.cond, label %26, label %._crit_edge61

._crit_edge61:                                    ; preds = %21
  %.phi.trans.insert = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %indvars.iv56, i64 %indvars.iv53
  %.pre = load i32, ptr %.phi.trans.insert, align 4, !tbaa !8
  br label %26

26:                                               ; preds = %21, %._crit_edge61
  %27 = phi i32 [ %.pre, %._crit_edge61 ], [ 1, %21 ]
  %28 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %19, i64 %indvars.iv53
  %29 = load i32, ptr %28, align 4, !tbaa !8
  %30 = add nsw i64 %indvars.iv53, -1
  %31 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %indvars.iv56, i64 %30
  %32 = load i32, ptr %31, align 4, !tbaa !8
  %33 = add nsw i32 %32, %29
  %34 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %19, i64 %30
  %35 = load i32, ptr %34, align 4, !tbaa !8
  %36 = sub i32 %33, %35
  %37 = getelementptr inbounds [5001 x [5001 x i32]], ptr @in, i64 0, i64 %indvars.iv56, i64 %indvars.iv53
  %38 = add nsw i32 %36, %27
  store i32 %38, ptr %37, align 4, !tbaa !8
  %indvars.iv.next54 = add nuw nsw i64 %indvars.iv53, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next54, %wide.trip.count59
  br i1 %exitcond.not, label %._crit_edge, label %21, !llvm.loop !14

._crit_edge48.loopexit:                           ; preds = %.lr.ph47
  %.pre62 = load i32, ptr @n, align 4, !tbaa !8
  br label %._crit_edge48

._crit_edge48:                                    ; preds = %._crit_edge48.loopexit, %.preheader
  %39 = phi i32 [ %.lcssa3765, %.preheader ], [ %.pre62, %._crit_edge48.loopexit ]
  %.lcssa = phi i32 [ %20, %.preheader ], [ %49, %._crit_edge48.loopexit ]
  %40 = srem i32 %.lcssa, 2
  %41 = sext i32 %40 to i64
  %42 = sext i32 %39 to i64
  %43 = getelementptr inbounds [2 x [5001 x i32]], ptr @dp, i64 0, i64 %41, i64 %42
  %44 = load i32, ptr %43, align 4, !tbaa !8
  %45 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, i32 noundef %44)
  ret i32 0

.lr.ph47:                                         ; preds = %.preheader, %.lr.ph47
  %.046 = phi i32 [ %48, %.lr.ph47 ], [ 1, %.preheader ]
  %46 = load i32, ptr @n, align 4, !tbaa !8
  %47 = and i32 %.046, 1
  tail call void @_Z7computeiiiiii(i32 noundef %.046, i32 noundef %46, i32 noundef %.046, i32 noundef %46, i32 noundef %47, i32 noundef %.046)
  %48 = add nuw nsw i32 %.046, 1
  %49 = load i32, ptr @k, align 4, !tbaa !8
  %.not33.not = icmp slt i32 %.046, %49
  br i1 %.not33.not, label %.lr.ph47, label %._crit_edge48.loopexit, !llvm.loop !15
}

declare noundef zeroext i1 @_ZNSt8ios_base15sync_with_stdioEb(i1 noundef zeroext) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNSt9basic_iosIcSt11char_traitsIcEE3tieEPSo(ptr noundef nonnull align 8 dereferenceable(264), ptr noundef) local_unnamed_addr #3 align 2

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2

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

attributes #0 = { 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 #1 = { mustprogress norecurse uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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" }

!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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"int", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}


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