; LLVM IR from MostafaTwfiq/C-DataStructures-And-Algorithms :: Algorithms/ArraysAlg/Sources (ArraysAlg)

; 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"

@stderr = external global ptr, align 8
@.str = external hidden unnamed_addr constant [31 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [42 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [33 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local void @nullFreeFunArrAlg(ptr 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 nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #2

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

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #3

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) #4

; Function Attrs: nounwind uwtable
define dso_local i32 @arrRemoveDuplicatesH(ptr noundef %0, i32 noundef %1, i32 noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5) #0 {
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  store ptr %0, ptr %7, align 8, !tbaa !5
  store i32 %1, ptr %8, align 4, !tbaa !9
  store i32 %2, ptr %9, align 4, !tbaa !9
  store ptr %3, ptr %10, align 8, !tbaa !5
  store ptr %4, ptr %11, align 8, !tbaa !5
  store ptr %5, ptr %12, align 8, !tbaa !5
  %19 = load ptr, ptr %7, align 8, !tbaa !5
  %20 = icmp eq ptr %19, null
  br i1 %20, label %21, label %24

21:                                               ; preds = %6
  %22 = load ptr, ptr @stderr, align 8, !tbaa !5
  %23 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %22, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.43) #6
  call void @exit(i32 noundef -83386157) #7
  unreachable

24:                                               ; preds = %6
  %25 = load ptr, ptr %10, align 8, !tbaa !5
  %26 = icmp eq ptr %25, null
  br i1 %26, label %27, label %30

27:                                               ; preds = %24
  %28 = load ptr, ptr @stderr, align 8, !tbaa !5
  %29 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %28, ptr noundef @.str.3, ptr noundef @.str.7, ptr noundef @.str.43) #6
  call void @exit(i32 noundef -83384987) #7
  unreachable

30:                                               ; preds = %24
  %31 = load i32, ptr %8, align 4, !tbaa !9
  %32 = icmp slt i32 %31, 0
  br i1 %32, label %33, label %36

33:                                               ; preds = %30
  %34 = load ptr, ptr @stderr, align 8, !tbaa !5
  %35 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %34, ptr noundef @.str.3, ptr noundef @.str.4, ptr noundef @.str.43) #6
  call void @exit(i32 noundef -83384987) #7
  unreachable

36:                                               ; preds = %30
  %37 = load i32, ptr %9, align 4, !tbaa !9
  %38 = icmp sle i32 %37, 0
  br i1 %38, label %39, label %42

39:                                               ; preds = %36
  %40 = load ptr, ptr @stderr, align 8, !tbaa !5
  %41 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %40, ptr noundef @.str.3, ptr noundef @.str.5, ptr noundef @.str.43) #6
  call void @exit(i32 noundef -83384987) #7
  unreachable

42:                                               ; preds = %36
  %43 = load ptr, ptr %11, align 8, !tbaa !5
  %44 = icmp eq ptr %43, null
  br i1 %44, label %45, label %48

45:                                               ; preds = %42
  %46 = load ptr, ptr @stderr, align 8, !tbaa !5
  %47 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %46, ptr noundef @.str.3, ptr noundef @.str.8, ptr noundef @.str.43) #6
  call void @exit(i32 noundef -83384987) #7
  unreachable

48:                                               ; preds = %42
  br label %49

49:                                               ; preds = %48
  br label %50

50:                                               ; preds = %49
  br label %51

51:                                               ; preds = %50
  br label %52

52:                                               ; preds = %51
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %53 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %53, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %54 = load ptr, ptr %10, align 8, !tbaa !5
  %55 = load ptr, ptr %11, align 8, !tbaa !5
  %56 = call ptr @hashSetInitialization(ptr noundef @nullFreeFunArrAlg, ptr noundef %54, ptr noundef %55)
  store ptr %56, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #6
  store i32 0, ptr %15, align 4, !tbaa !9
  br label %57

57:                                               ; preds = %113, %52
  %58 = load i32, ptr %15, align 4, !tbaa !9
  %59 = load i32, ptr %8, align 4, !tbaa !9
  %60 = icmp slt i32 %58, %59
  br i1 %60, label %61, label %114

61:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %62 = load ptr, ptr %13, align 8, !tbaa !5
  %63 = load i32, ptr %15, align 4, !tbaa !9
  %64 = load i32, ptr %9, align 4, !tbaa !9
  %65 = mul nsw i32 %63, %64
  %66 = sext i32 %65 to i64
  %67 = getelementptr inbounds i8, ptr %62, i64 %66
  store ptr %67, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  %68 = load ptr, ptr %14, align 8, !tbaa !5
  %69 = load ptr, ptr %16, align 8, !tbaa !5
  %70 = call i32 @hashSetContains(ptr noundef %68, ptr noundef %69)
  store i32 %70, ptr %17, align 4, !tbaa !9
  %71 = load i32, ptr %17, align 4, !tbaa !9
  %72 = icmp ne i32 %71, 0
  br i1 %72, label %73, label %108

73:                                               ; preds = %61
  %74 = load i32, ptr %8, align 4, !tbaa !9
  %75 = add nsw i32 %74, -1
  store i32 %75, ptr %8, align 4, !tbaa !9
  %76 = load ptr, ptr %12, align 8, !tbaa !5
  %77 = icmp ne ptr %76, null
  br i1 %77, label %78, label %81

78:                                               ; preds = %73
  %79 = load ptr, ptr %12, align 8, !tbaa !5
  %80 = load ptr, ptr %16, align 8, !tbaa !5
  call void %79(ptr noundef %80)
  br label %81

81:                                               ; preds = %78, %73
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #6
  %82 = load i32, ptr %15, align 4, !tbaa !9
  store i32 %82, ptr %18, align 4, !tbaa !9
  br label %83

83:                                               ; preds = %104, %81
  %84 = load i32, ptr %18, align 4, !tbaa !9
  %85 = load i32, ptr %8, align 4, !tbaa !9
  %86 = icmp slt i32 %84, %85
  br i1 %86, label %88, label %87

87:                                               ; preds = %83
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #6
  br label %107

88:                                               ; preds = %83
  %89 = load ptr, ptr %13, align 8, !tbaa !5
  %90 = load i32, ptr %18, align 4, !tbaa !9
  %91 = load i32, ptr %9, align 4, !tbaa !9
  %92 = mul nsw i32 %90, %91
  %93 = sext i32 %92 to i64
  %94 = getelementptr inbounds i8, ptr %89, i64 %93
  %95 = load ptr, ptr %13, align 8, !tbaa !5
  %96 = load i32, ptr %18, align 4, !tbaa !9
  %97 = add nsw i32 %96, 1
  %98 = load i32, ptr %9, align 4, !tbaa !9
  %99 = mul nsw i32 %97, %98
  %100 = sext i32 %99 to i64
  %101 = getelementptr inbounds i8, ptr %95, i64 %100
  %102 = load i32, ptr %9, align 4, !tbaa !9
  %103 = sext i32 %102 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %94, ptr align 1 %101, i64 %103, i1 false)
  br label %104

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

107:                                              ; preds = %87
  br label %113

108:                                              ; preds = %61
  %109 = load ptr, ptr %14, align 8, !tbaa !5
  %110 = load ptr, ptr %16, align 8, !tbaa !5
  call void @hashSetInsert(ptr noundef %109, ptr noundef %110)
  %111 = load i32, ptr %15, align 4, !tbaa !9
  %112 = add nsw i32 %111, 1
  store i32 %112, ptr %15, align 4, !tbaa !9
  br label %113

113:                                              ; preds = %108, %107
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %57, !llvm.loop !13

114:                                              ; preds = %57
  %115 = load ptr, ptr %14, align 8, !tbaa !5
  call void @destroyHashSet(ptr noundef %115)
  %116 = load i32, ptr %8, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  ret i32 %116
}

declare ptr @hashSetInitialization(ptr noundef, ptr noundef, ptr noundef) #5

declare i32 @hashSetContains(ptr noundef, ptr noundef) #5

declare void @hashSetInsert(ptr noundef, ptr noundef) #5

declare void @destroyHashSet(ptr noundef) #5

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

@stderr = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [31 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [42 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [33 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local void @nullFreeFunArrAlg(ptr noundef) #0

; 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) #1

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

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local i32 @arrRemoveDuplicatesH(ptr noundef %0, i32 noundef %1, i32 noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef readonly %5) local_unnamed_addr #0 {
  %7 = icmp eq ptr %0, null
  br i1 %7, label %8, label %11

8:                                                ; preds = %6
  %9 = load ptr, ptr @stderr, align 8, !tbaa !5
  %10 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %9, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.43) #5
  tail call void @exit(i32 noundef -83386157) #6
  unreachable

11:                                               ; preds = %6
  %12 = icmp eq ptr %3, null
  br i1 %12, label %13, label %16

13:                                               ; preds = %11
  %14 = load ptr, ptr @stderr, align 8, !tbaa !5
  %15 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %14, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.7, ptr noundef nonnull @.str.43) #5
  tail call void @exit(i32 noundef -83384987) #6
  unreachable

16:                                               ; preds = %11
  %17 = icmp slt i32 %1, 0
  br i1 %17, label %18, label %21

18:                                               ; preds = %16
  %19 = load ptr, ptr @stderr, align 8, !tbaa !5
  %20 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %19, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.43) #5
  tail call void @exit(i32 noundef -83384987) #6
  unreachable

21:                                               ; preds = %16
  %22 = icmp slt i32 %2, 1
  br i1 %22, label %23, label %26

23:                                               ; preds = %21
  %24 = load ptr, ptr @stderr, align 8, !tbaa !5
  %25 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.43) #5
  tail call void @exit(i32 noundef -83384987) #6
  unreachable

26:                                               ; preds = %21
  %27 = icmp eq ptr %4, null
  br i1 %27, label %28, label %31

28:                                               ; preds = %26
  %29 = load ptr, ptr @stderr, align 8, !tbaa !5
  %30 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.8, ptr noundef nonnull @.str.43) #5
  tail call void @exit(i32 noundef -83384987) #6
  unreachable

31:                                               ; preds = %26
  %32 = tail call ptr @hashSetInitialization(ptr noundef nonnull @nullFreeFunArrAlg, ptr noundef nonnull %3, ptr noundef nonnull %4) #7
  %.not50 = icmp eq i32 %1, 0
  br i1 %.not50, label %._crit_edge, label %.lr.ph49

.lr.ph49:                                         ; preds = %31
  %.not45 = icmp eq ptr %5, null
  %33 = zext nneg i32 %2 to i64
  %34 = zext nneg i32 %2 to i64
  br i1 %.not45, label %.lr.ph49.split.us, label %.lr.ph49.split

.lr.ph49.split.us:                                ; preds = %.lr.ph49, %.loopexit.us
  %.03548.us = phi i32 [ %.1.us, %.loopexit.us ], [ %1, %.lr.ph49 ]
  %.03647.us = phi i32 [ %.137.us, %.loopexit.us ], [ 0, %.lr.ph49 ]
  %35 = mul nsw i32 %.03647.us, %2
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds i8, ptr %0, i64 %36
  %38 = tail call i32 @hashSetContains(ptr noundef %32, ptr noundef nonnull %37) #7
  %.not.us = icmp eq i32 %38, 0
  br i1 %.not.us, label %58, label %39

39:                                               ; preds = %.lr.ph49.split.us
  %40 = add nsw i32 %.03548.us, -1
  %41 = icmp slt i32 %.03647.us, %40
  br i1 %41, label %.lr.ph.us.preheader, label %.loopexit.us

.lr.ph.us.preheader:                              ; preds = %39
  %42 = sext i32 %.03647.us to i64
  %wide.trip.count56 = sext i32 %40 to i64
  %43 = sub nsw i64 %wide.trip.count56, %42
  %xtraiter61 = and i64 %43, 1
  %lcmp.mod62.not = icmp eq i64 %xtraiter61, 0
  br i1 %lcmp.mod62.not, label %.lr.ph.us.prol.loopexit, label %.lr.ph.us.prol

.lr.ph.us.prol:                                   ; preds = %.lr.ph.us.preheader
  %44 = mul nsw i64 %42, %34
  %45 = getelementptr inbounds i8, ptr %0, i64 %44
  %indvars.iv.next54.prol = add nsw i64 %42, 1
  %46 = mul nsw i64 %indvars.iv.next54.prol, %34
  %47 = getelementptr inbounds i8, ptr %0, i64 %46
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %45, ptr nonnull align 1 %47, i64 %33, i1 false)
  br label %.lr.ph.us.prol.loopexit

.lr.ph.us.prol.loopexit:                          ; preds = %.lr.ph.us.prol, %.lr.ph.us.preheader
  %indvars.iv53.unr = phi i64 [ %42, %.lr.ph.us.preheader ], [ %indvars.iv.next54.prol, %.lr.ph.us.prol ]
  %48 = add nsw i64 %wide.trip.count56, -1
  %49 = icmp eq i64 %48, %42
  br i1 %49, label %.loopexit.us, label %.lr.ph.us

.lr.ph.us:                                        ; preds = %.lr.ph.us.prol.loopexit, %.lr.ph.us
  %indvars.iv53 = phi i64 [ %indvars.iv.next54.1, %.lr.ph.us ], [ %indvars.iv53.unr, %.lr.ph.us.prol.loopexit ]
  %50 = mul nsw i64 %indvars.iv53, %34
  %51 = getelementptr inbounds i8, ptr %0, i64 %50
  %indvars.iv.next54 = add nsw i64 %indvars.iv53, 1
  %52 = mul nsw i64 %indvars.iv.next54, %34
  %53 = getelementptr inbounds i8, ptr %0, i64 %52
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %51, ptr nonnull align 1 %53, i64 %33, i1 false)
  %54 = mul nsw i64 %indvars.iv.next54, %34
  %55 = getelementptr inbounds i8, ptr %0, i64 %54
  %indvars.iv.next54.1 = add nsw i64 %indvars.iv53, 2
  %56 = mul nsw i64 %indvars.iv.next54.1, %34
  %57 = getelementptr inbounds i8, ptr %0, i64 %56
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %55, ptr nonnull align 1 %57, i64 %33, i1 false)
  %exitcond57.not.1 = icmp eq i64 %indvars.iv.next54.1, %wide.trip.count56
  br i1 %exitcond57.not.1, label %.loopexit.us, label %.lr.ph.us, !llvm.loop !9

58:                                               ; preds = %.lr.ph49.split.us
  tail call void @hashSetInsert(ptr noundef %32, ptr noundef nonnull %37) #7
  %59 = add nsw i32 %.03647.us, 1
  br label %.loopexit.us

.loopexit.us:                                     ; preds = %.lr.ph.us.prol.loopexit, %.lr.ph.us, %39, %58
  %.137.us = phi i32 [ %59, %58 ], [ %.03647.us, %39 ], [ %.03647.us, %.lr.ph.us ], [ %.03647.us, %.lr.ph.us.prol.loopexit ]
  %.1.us = phi i32 [ %.03548.us, %58 ], [ %40, %39 ], [ %40, %.lr.ph.us ], [ %40, %.lr.ph.us.prol.loopexit ]
  %60 = icmp slt i32 %.137.us, %.1.us
  br i1 %60, label %.lr.ph49.split.us, label %._crit_edge, !llvm.loop !11

.lr.ph49.split:                                   ; preds = %.lr.ph49, %.loopexit
  %.03548 = phi i32 [ %.1, %.loopexit ], [ %1, %.lr.ph49 ]
  %.03647 = phi i32 [ %.137, %.loopexit ], [ 0, %.lr.ph49 ]
  %61 = mul nsw i32 %.03647, %2
  %62 = sext i32 %61 to i64
  %63 = getelementptr inbounds i8, ptr %0, i64 %62
  %64 = tail call i32 @hashSetContains(ptr noundef %32, ptr noundef nonnull %63) #7
  %.not = icmp eq i32 %64, 0
  br i1 %.not, label %84, label %65

65:                                               ; preds = %.lr.ph49.split
  %66 = add nsw i32 %.03548, -1
  tail call void %5(ptr noundef nonnull %63) #7
  %67 = icmp slt i32 %.03647, %66
  br i1 %67, label %.lr.ph.preheader, label %.loopexit

.lr.ph.preheader:                                 ; preds = %65
  %68 = sext i32 %.03647 to i64
  %wide.trip.count = sext i32 %66 to i64
  %69 = sub nsw i64 %wide.trip.count, %68
  %xtraiter = and i64 %69, 1
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.lr.ph.prol.loopexit, label %.lr.ph.prol

.lr.ph.prol:                                      ; preds = %.lr.ph.preheader
  %70 = mul nsw i64 %68, %34
  %71 = getelementptr inbounds i8, ptr %0, i64 %70
  %indvars.iv.next.prol = add nsw i64 %68, 1
  %72 = mul nsw i64 %indvars.iv.next.prol, %34
  %73 = getelementptr inbounds i8, ptr %0, i64 %72
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %71, ptr nonnull align 1 %73, i64 %33, i1 false)
  br label %.lr.ph.prol.loopexit

.lr.ph.prol.loopexit:                             ; preds = %.lr.ph.prol, %.lr.ph.preheader
  %indvars.iv.unr = phi i64 [ %68, %.lr.ph.preheader ], [ %indvars.iv.next.prol, %.lr.ph.prol ]
  %74 = add nsw i64 %wide.trip.count, -1
  %75 = icmp eq i64 %74, %68
  br i1 %75, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.prol.loopexit, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next.1, %.lr.ph ], [ %indvars.iv.unr, %.lr.ph.prol.loopexit ]
  %76 = mul nsw i64 %indvars.iv, %34
  %77 = getelementptr inbounds i8, ptr %0, i64 %76
  %indvars.iv.next = add nsw i64 %indvars.iv, 1
  %78 = mul nsw i64 %indvars.iv.next, %34
  %79 = getelementptr inbounds i8, ptr %0, i64 %78
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %77, ptr nonnull align 1 %79, i64 %33, i1 false)
  %80 = mul nsw i64 %indvars.iv.next, %34
  %81 = getelementptr inbounds i8, ptr %0, i64 %80
  %indvars.iv.next.1 = add nsw i64 %indvars.iv, 2
  %82 = mul nsw i64 %indvars.iv.next.1, %34
  %83 = getelementptr inbounds i8, ptr %0, i64 %82
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %81, ptr nonnull align 1 %83, i64 %33, i1 false)
  %exitcond.not.1 = icmp eq i64 %indvars.iv.next.1, %wide.trip.count
  br i1 %exitcond.not.1, label %.loopexit, label %.lr.ph, !llvm.loop !9

84:                                               ; preds = %.lr.ph49.split
  tail call void @hashSetInsert(ptr noundef %32, ptr noundef nonnull %63) #7
  %85 = add nsw i32 %.03647, 1
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph.prol.loopexit, %.lr.ph, %65, %84
  %.137 = phi i32 [ %85, %84 ], [ %.03647, %65 ], [ %.03647, %.lr.ph ], [ %.03647, %.lr.ph.prol.loopexit ]
  %.1 = phi i32 [ %.03548, %84 ], [ %66, %65 ], [ %66, %.lr.ph ], [ %66, %.lr.ph.prol.loopexit ]
  %86 = icmp slt i32 %.137, %.1
  br i1 %86, label %.lr.ph49.split, label %._crit_edge, !llvm.loop !11

._crit_edge:                                      ; preds = %.loopexit, %.loopexit.us, %31
  %.035.lcssa = phi i32 [ 0, %31 ], [ %.1.us, %.loopexit.us ], [ %.1, %.loopexit ]
  tail call void @destroyHashSet(ptr noundef %32) #7
  ret i32 %.035.lcssa
}

declare ptr @hashSetInitialization(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #4

declare i32 @hashSetContains(ptr noundef, ptr noundef) local_unnamed_addr #4

declare void @hashSetInsert(ptr noundef, ptr noundef) local_unnamed_addr #4

declare void @destroyHashSet(ptr noundef) local_unnamed_addr #4

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { 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 #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 = { cold nounwind }
attributes #6 = { noreturn nounwind }
attributes #7 = { 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}


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