; LLVM IR from ryanlayer/giggle :: test/unit (test_bpt)

; 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.cache_def = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.cache_handler = type { ptr, ptr, ptr }

@ORDER = external dso_local global i32, align 4
@cache = external dso_local global %struct.cache_def, align 8
@uint32_t_cache_handler = external dso_local global %struct.cache_handler, align 8
@bpt_node_repair = external dso_local global ptr, align 8
@__const.test_bpt_write_tree.bpt_file_out = external hidden unnamed_addr constant [1 x ptr], align 8
@.str.2 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [28 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 nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

declare void @UnityAssertEqualNumber(i64 noundef, i64 noundef, ptr noundef, i64 noundef, i32 noundef) #2

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

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #3

declare ptr @simple_cache_init(i32 noundef, i32 noundef, ptr noundef) #2

declare i32 @bpt_insert_new_value(i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare i32 @bpt_find(i32 noundef, i32 noundef, ptr noundef, ptr noundef, i32 noundef) #2

; Function Attrs: nounwind
declare i64 @time(ptr noundef) #4

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

; Function Attrs: nounwind
declare i32 @rand() #4

; Function Attrs: nounwind uwtable
define dso_local void @test_bpt_write_tree() #5 {
  %1 = alloca [1 x ptr], align 8
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %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 ptr, align 8
  %14 = alloca i8, align 1
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %1) #7
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %1, ptr align 8 @__const.test_bpt_write_tree.bpt_file_out, i64 8, i1 false)
  %19 = call i32 @access(ptr noundef @.str.2, i32 noundef 0) #7
  %20 = icmp ne i32 %19, -1
  br i1 %20, label %21, label %23

21:                                               ; preds = %0
  %22 = call i32 @remove(ptr noundef @.str.2) #7
  br label %23

23:                                               ; preds = %21, %0
  %24 = call i32 @access(ptr noundef @.str.3, i32 noundef 0) #7
  %25 = icmp ne i32 %24, -1
  br i1 %25, label %26, label %28

26:                                               ; preds = %23
  %27 = call i32 @remove(ptr noundef @.str.3) #7
  br label %28

28:                                               ; preds = %26, %23
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #7
  %29 = getelementptr inbounds [1 x ptr], ptr %1, i64 0, i64 0
  %30 = call ptr @simple_cache_init(i32 noundef 5, i32 noundef 1, ptr noundef %29)
  store ptr %30, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #7
  store i32 0, ptr %3, align 4, !tbaa !9
  store i32 5, ptr @ORDER, align 4, !tbaa !9
  store ptr null, ptr @bpt_node_repair, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #7
  store i32 20, ptr %4, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #7
  %31 = load i32, ptr %4, align 4, !tbaa !9
  %32 = zext i32 %31 to i64
  %33 = mul i64 %32, 4
  %34 = call noalias ptr @malloc(i64 noundef %33) #8
  store ptr %34, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #7
  %35 = call i64 @time(ptr noundef null) #7
  store i64 %35, ptr %6, align 8, !tbaa !11
  %36 = load i64, ptr %6, align 8, !tbaa !11
  %37 = trunc i64 %36 to i32
  call void @srand(i32 noundef %37) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #7
  store i32 0, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #7
  store i32 0, ptr %11, align 4, !tbaa !9
  br label %38

38:                                               ; preds = %65, %28
  %39 = load i32, ptr %11, align 4, !tbaa !9
  %40 = load i32, ptr %4, align 4, !tbaa !9
  %41 = icmp ult i32 %39, %40
  br i1 %41, label %42, label %68

42:                                               ; preds = %38
  %43 = call i32 @rand() #7
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = load i32, ptr %11, align 4, !tbaa !9
  %46 = zext i32 %45 to i64
  %47 = getelementptr inbounds i32, ptr %44, i64 %46
  store i32 %43, ptr %47, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #7
  %48 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 4) #9
  store ptr %48, ptr %13, align 8, !tbaa !5
  %49 = load ptr, ptr %5, align 8, !tbaa !5
  %50 = load i32, ptr %11, align 4, !tbaa !9
  %51 = zext i32 %50 to i64
  %52 = getelementptr inbounds i32, ptr %49, i64 %51
  %53 = load i32, ptr %52, align 4, !tbaa !9
  %54 = udiv i32 %53, 2
  %55 = load ptr, ptr %13, align 8, !tbaa !5
  store i32 %54, ptr %55, align 4, !tbaa !9
  %56 = load i32, ptr %3, align 4, !tbaa !9
  %57 = load i32, ptr %7, align 4, !tbaa !9
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = load i32, ptr %11, align 4, !tbaa !9
  %60 = zext i32 %59 to i64
  %61 = getelementptr inbounds i32, ptr %58, i64 %60
  %62 = load i32, ptr %61, align 4, !tbaa !9
  %63 = load ptr, ptr %13, align 8, !tbaa !5
  %64 = call i32 @bpt_insert_new_value(i32 noundef %56, i32 noundef %57, i32 noundef %62, ptr noundef %63, ptr noundef @uint32_t_cache_handler, ptr noundef %8, ptr noundef %9, ptr noundef %10)
  store i32 %64, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #7
  br label %65

65:                                               ; preds = %42
  %66 = load i32, ptr %11, align 4, !tbaa !9
  %67 = add i32 %66, 1
  store i32 %67, ptr %11, align 4, !tbaa !9
  br label %38, !llvm.loop !13

68:                                               ; preds = %38
  call void @llvm.lifetime.start.p0(i64 1, ptr %14) #7
  %69 = load i32, ptr %3, align 4, !tbaa !9
  %70 = load i32, ptr %7, align 4, !tbaa !9
  %71 = call zeroext i1 @bpt_write_tree(i32 noundef %69, i32 noundef %70)
  %72 = zext i1 %71 to i8
  store i8 %72, ptr %14, align 1, !tbaa !15
  %73 = load ptr, ptr getelementptr inbounds (%struct.cache_def, ptr @cache, i32 0, i32 6), align 8, !tbaa !17
  call void (...) %73()
  %74 = getelementptr inbounds [1 x ptr], ptr %1, i64 0, i64 0
  %75 = call ptr @simple_cache_init(i32 noundef 5, i32 noundef 1, ptr noundef %74)
  store ptr %75, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #7
  store i32 0, ptr %11, align 4, !tbaa !9
  br label %76

76:                                               ; preds = %104, %68
  %77 = load i32, ptr %11, align 4, !tbaa !9
  %78 = load i32, ptr %4, align 4, !tbaa !9
  %79 = icmp ult i32 %77, %78
  br i1 %79, label %80, label %107

80:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #7
  %81 = load i32, ptr %3, align 4, !tbaa !9
  %82 = load i32, ptr %7, align 4, !tbaa !9
  %83 = load ptr, ptr %5, align 8, !tbaa !5
  %84 = load i32, ptr %11, align 4, !tbaa !9
  %85 = zext i32 %84 to i64
  %86 = getelementptr inbounds i32, ptr %83, i64 %85
  %87 = load i32, ptr %86, align 4, !tbaa !9
  %88 = call i32 @bpt_find(i32 noundef %81, i32 noundef %82, ptr noundef %9, ptr noundef %10, i32 noundef %87)
  store i32 %88, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #7
  %89 = load ptr, ptr getelementptr inbounds (%struct.cache_def, ptr @cache, i32 0, i32 3), align 8, !tbaa !19
  %90 = load i32, ptr %3, align 4, !tbaa !9
  %91 = load i32, ptr %17, align 4, !tbaa !9
  %92 = sub i32 %91, 1
  %93 = call ptr %89(i32 noundef %90, i32 noundef %92, ptr noundef @uint32_t_cache_handler)
  store ptr %93, ptr %18, align 8, !tbaa !5
  %94 = load ptr, ptr %5, align 8, !tbaa !5
  %95 = load i32, ptr %11, align 4, !tbaa !9
  %96 = zext i32 %95 to i64
  %97 = getelementptr inbounds i32, ptr %94, i64 %96
  %98 = load i32, ptr %97, align 4, !tbaa !9
  %99 = udiv i32 %98, 2
  %100 = zext i32 %99 to i64
  %101 = load ptr, ptr %18, align 8, !tbaa !5
  %102 = load i32, ptr %101, align 4, !tbaa !9
  %103 = zext i32 %102 to i64
  call void @UnityAssertEqualNumber(i64 noundef %100, i64 noundef %103, ptr noundef null, i64 noundef 2119, i32 noundef 148)
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #7
  br label %104

104:                                              ; preds = %80
  %105 = load i32, ptr %11, align 4, !tbaa !9
  %106 = add i32 %105, 1
  store i32 %106, ptr %11, align 4, !tbaa !9
  br label %76, !llvm.loop !20

107:                                              ; preds = %76
  %108 = load ptr, ptr getelementptr inbounds (%struct.cache_def, ptr @cache, i32 0, i32 6), align 8, !tbaa !17
  call void (...) %108()
  %109 = call i32 @remove(ptr noundef @.str.2) #7
  %110 = call i32 @remove(ptr noundef @.str.3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %1) #7
  ret void
}

; Function Attrs: nounwind
declare i32 @access(ptr noundef, i32 noundef) #4

; Function Attrs: nounwind
declare i32 @remove(ptr noundef) #4

; Function Attrs: nounwind allocsize(0,1)
declare noalias ptr @calloc(i64 noundef, i64 noundef) #6

declare zeroext i1 @bpt_write_tree(i32 noundef, i32 noundef) #2

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

!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 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !16, i64 0}
!16 = !{!"_Bool", !7, i64 0}
!17 = !{!18, !6, i64 48}
!18 = !{!"cache_def", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48}
!19 = !{!18, !6, i64 24}
!20 = distinct !{!20, !14}


; 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.cache_def = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.cache_handler = type { ptr, ptr, ptr }

@ORDER = external dso_local local_unnamed_addr global i32, align 4
@cache = external dso_local local_unnamed_addr global %struct.cache_def, align 8
@uint32_t_cache_handler = external dso_local global %struct.cache_handler, align 8
@bpt_node_repair = external dso_local local_unnamed_addr global ptr, align 8
@__const.test_bpt_write_tree.bpt_file_out = external hidden unnamed_addr constant [1 x ptr], align 8
@.str.2 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [28 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

declare void @UnityAssertEqualNumber(i64 noundef, i64 noundef, ptr noundef, i64 noundef, i32 noundef) local_unnamed_addr #1

; 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 nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #2

declare ptr @simple_cache_init(i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

declare i32 @bpt_insert_new_value(i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @bpt_find(i32 noundef, i32 noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: nounwind
declare i64 @time(ptr noundef) local_unnamed_addr #3

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

; Function Attrs: nounwind
declare i32 @rand() local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local void @test_bpt_write_tree() local_unnamed_addr #4 {
  %1 = alloca [1 x ptr], align 8
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #7
  %5 = load i64, ptr @__const.test_bpt_write_tree.bpt_file_out, align 8
  store i64 %5, ptr %1, align 8
  %6 = tail call i32 @access(ptr noundef nonnull @.str.2, i32 noundef 0) #7
  %.not = icmp eq i32 %6, -1
  br i1 %.not, label %9, label %7

7:                                                ; preds = %0
  %8 = tail call i32 @remove(ptr noundef nonnull @.str.2) #7
  br label %9

9:                                                ; preds = %7, %0
  %10 = tail call i32 @access(ptr noundef nonnull @.str.3, i32 noundef 0) #7
  %.not29 = icmp eq i32 %10, -1
  br i1 %.not29, label %13, label %11

11:                                               ; preds = %9
  %12 = tail call i32 @remove(ptr noundef nonnull @.str.3) #7
  br label %13

13:                                               ; preds = %11, %9
  %14 = call ptr @simple_cache_init(i32 noundef 5, i32 noundef 1, ptr noundef nonnull %1) #7
  store i32 5, ptr @ORDER, align 4, !tbaa !5
  store ptr null, ptr @bpt_node_repair, align 8, !tbaa !9
  %15 = call noalias dereferenceable_or_null(80) ptr @malloc(i64 noundef 80) #8
  %16 = call i64 @time(ptr noundef null) #7
  %17 = trunc i64 %16 to i32
  call void @srand(i32 noundef %17) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #7
  br label %18

18:                                               ; preds = %13, %18
  %indvars.iv = phi i64 [ 0, %13 ], [ %indvars.iv.next, %18 ]
  %.031 = phi i32 [ 0, %13 ], [ %23, %18 ]
  %19 = call i32 @rand() #7
  %20 = getelementptr inbounds i32, ptr %15, i64 %indvars.iv
  store i32 %19, ptr %20, align 4, !tbaa !5
  %21 = call noalias dereferenceable_or_null(4) ptr @calloc(i64 noundef 1, i64 noundef 4) #9
  %22 = lshr i32 %19, 1
  store i32 %22, ptr %21, align 4, !tbaa !5
  %23 = call i32 @bpt_insert_new_value(i32 noundef 0, i32 noundef %.031, i32 noundef %19, ptr noundef nonnull %21, ptr noundef nonnull @uint32_t_cache_handler, ptr noundef nonnull %2, ptr noundef nonnull %3, ptr noundef nonnull %4) #7
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 20
  br i1 %exitcond.not, label %24, label %18, !llvm.loop !11

24:                                               ; preds = %18
  %25 = call zeroext i1 @bpt_write_tree(i32 noundef 0, i32 noundef %23) #7
  %26 = load ptr, ptr getelementptr inbounds (i8, ptr @cache, i64 48), align 8, !tbaa !13
  call void (...) %26() #7
  %27 = call ptr @simple_cache_init(i32 noundef 5, i32 noundef 1, ptr noundef nonnull %1) #7
  br label %28

28:                                               ; preds = %24, %28
  %indvars.iv34 = phi i64 [ 0, %24 ], [ %indvars.iv.next35, %28 ]
  %29 = getelementptr inbounds i32, ptr %15, i64 %indvars.iv34
  %30 = load i32, ptr %29, align 4, !tbaa !5
  %31 = call i32 @bpt_find(i32 noundef 0, i32 noundef %23, ptr noundef nonnull %3, ptr noundef nonnull %4, i32 noundef %30) #7
  %32 = load ptr, ptr getelementptr inbounds (i8, ptr @cache, i64 24), align 8, !tbaa !15
  %33 = add i32 %31, -1
  %34 = call ptr %32(i32 noundef 0, i32 noundef %33, ptr noundef nonnull @uint32_t_cache_handler) #7
  %35 = lshr i32 %30, 1
  %36 = zext nneg i32 %35 to i64
  %37 = load i32, ptr %34, align 4, !tbaa !5
  %38 = zext i32 %37 to i64
  call void @UnityAssertEqualNumber(i64 noundef %36, i64 noundef %38, ptr noundef null, i64 noundef 2119, i32 noundef 148) #7
  %indvars.iv.next35 = add nuw nsw i64 %indvars.iv34, 1
  %exitcond37.not = icmp eq i64 %indvars.iv.next35, 20
  br i1 %exitcond37.not, label %39, label %28, !llvm.loop !16

39:                                               ; preds = %28
  %40 = load ptr, ptr getelementptr inbounds (i8, ptr @cache, i64 48), align 8, !tbaa !13
  call void (...) %40() #7
  %41 = call i32 @remove(ptr noundef nonnull @.str.2) #7
  %42 = call i32 @remove(ptr noundef nonnull @.str.3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #7
  ret void
}

; Function Attrs: nofree nounwind
declare noundef i32 @access(ptr nocapture noundef readonly, i32 noundef) local_unnamed_addr #5

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

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @calloc(i64 noundef, i64 noundef) local_unnamed_addr #6

declare zeroext i1 @bpt_write_tree(i32 noundef, i32 noundef) local_unnamed_addr #1

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 = { 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 = { 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 = { 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 #6 = { mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { nounwind allocsize(0) }
attributes #9 = { nounwind allocsize(0,1) }

!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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !10, i64 48}
!14 = !{!"cache_def", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48}
!15 = !{!14, !10, i64 24}
!16 = distinct !{!16, !12}


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