; LLVM IR from mwarning/KadNode :: src (dht)

; 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.timeval = type { i64, i64 }
%struct.bucket = type { i32, [20 x i8], i32, i32, i64, ptr, %struct.sockaddr_storage, i32, ptr }
%struct.sockaddr_storage = type { i16, [118 x i8], i64 }

@searches = external hidden global ptr, align 8
@now = external hidden global %struct.timeval, align 8
@search_id = external hidden global i16, align 2
@myid = external hidden global [20 x i8], align 16
@search_time = external hidden global i64, align 8
@buckets = external hidden global ptr, align 8
@buckets6 = external hidden global ptr, align 8
@storage = external hidden global ptr, align 8
@dht_socket = external hidden global i32, align 4
@dht_socket6 = external hidden global i32, align 4
@numsearches = external hidden global i32, align 4
@numstorage = external hidden global i32, align 4
@my_v = external hidden global [9 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [6 x i8], align 1
@have_v = external hidden global i32, align 4
@mybucket_grow_time = external hidden global i64, align 8
@mybucket6_grow_time = external hidden global i64, align 8
@confirm_nodes_time = external hidden global i64, align 8
@next_blacklisted = external dso_local global i32, align 4
@token_bucket_time = external hidden global i64, align 8
@token_bucket_tokens = external hidden global i32, align 4
@secret = external hidden global [8 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: nounwind willreturn memory(none)
declare ptr @__errno_location() #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) #0

; Function Attrs: nounwind uwtable
define dso_local i32 @dht_init(i32 noundef %0, i32 noundef %1, ptr noundef %2, ptr noundef %3) #3 {
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  store i32 %0, ptr %6, align 4, !tbaa !5
  store i32 %1, ptr %7, align 4, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !9
  store ptr %3, ptr %9, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #7
  %12 = load i32, ptr @dht_socket, align 4, !tbaa !5
  %13 = icmp sge i32 %12, 0
  br i1 %13, label %23, label %14

14:                                               ; preds = %4
  %15 = load i32, ptr @dht_socket6, align 4, !tbaa !5
  %16 = icmp sge i32 %15, 0
  br i1 %16, label %23, label %17

17:                                               ; preds = %14
  %18 = load ptr, ptr @buckets, align 8, !tbaa !9
  %19 = icmp ne ptr %18, null
  br i1 %19, label %23, label %20

20:                                               ; preds = %17
  %21 = load ptr, ptr @buckets6, align 8, !tbaa !9
  %22 = icmp ne ptr %21, null
  br i1 %22, label %23, label %25

23:                                               ; preds = %20, %17, %14, %4
  %24 = call ptr @__errno_location() #8
  store i32 16, ptr %24, align 4, !tbaa !5
  store i32 -1, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %84

25:                                               ; preds = %20
  store ptr null, ptr @searches, align 8, !tbaa !9
  store i32 0, ptr @numsearches, align 4, !tbaa !5
  store ptr null, ptr @storage, align 8, !tbaa !9
  store i32 0, ptr @numstorage, align 4, !tbaa !5
  %26 = load i32, ptr %6, align 4, !tbaa !5
  %27 = icmp sge i32 %26, 0
  br i1 %27, label %28, label %38

28:                                               ; preds = %25
  %29 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 192) #9
  store ptr %29, ptr @buckets, align 8, !tbaa !9
  %30 = load ptr, ptr @buckets, align 8, !tbaa !9
  %31 = icmp eq ptr %30, null
  br i1 %31, label %32, label %33

32:                                               ; preds = %28
  store i32 -1, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %84

33:                                               ; preds = %28
  %34 = load ptr, ptr @buckets, align 8, !tbaa !9
  %35 = getelementptr inbounds %struct.bucket, ptr %34, i32 0, i32 3
  store i32 128, ptr %35, align 4, !tbaa !11
  %36 = load ptr, ptr @buckets, align 8, !tbaa !9
  %37 = getelementptr inbounds %struct.bucket, ptr %36, i32 0, i32 0
  store i32 2, ptr %37, align 8, !tbaa !16
  br label %38

38:                                               ; preds = %33, %25
  %39 = load i32, ptr %7, align 4, !tbaa !5
  %40 = icmp sge i32 %39, 0
  br i1 %40, label %41, label %51

41:                                               ; preds = %38
  %42 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 192) #9
  store ptr %42, ptr @buckets6, align 8, !tbaa !9
  %43 = load ptr, ptr @buckets6, align 8, !tbaa !9
  %44 = icmp eq ptr %43, null
  br i1 %44, label %45, label %46

45:                                               ; preds = %41
  store i32 -1, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %84

46:                                               ; preds = %41
  %47 = load ptr, ptr @buckets6, align 8, !tbaa !9
  %48 = getelementptr inbounds %struct.bucket, ptr %47, i32 0, i32 3
  store i32 128, ptr %48, align 4, !tbaa !11
  %49 = load ptr, ptr @buckets6, align 8, !tbaa !9
  %50 = getelementptr inbounds %struct.bucket, ptr %49, i32 0, i32 0
  store i32 10, ptr %50, align 8, !tbaa !16
  br label %51

51:                                               ; preds = %46, %38
  %52 = load ptr, ptr %8, align 8, !tbaa !9
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 @myid, ptr align 1 %52, i64 20, i1 false)
  %53 = load ptr, ptr %9, align 8, !tbaa !9
  %54 = icmp ne ptr %53, null
  br i1 %54, label %55, label %57

55:                                               ; preds = %51
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 @my_v, ptr align 1 @.str.22, i64 5, i1 false)
  %56 = load ptr, ptr %9, align 8, !tbaa !9
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 getelementptr inbounds (i8, ptr @my_v, i64 5), ptr align 1 %56, i64 4, i1 false)
  store i32 1, ptr @have_v, align 4, !tbaa !5
  br label %58

57:                                               ; preds = %51
  store i32 0, ptr @have_v, align 4, !tbaa !5
  br label %58

58:                                               ; preds = %57, %55
  %59 = call i32 @gettimeofday(ptr noundef @now, ptr noundef null) #7
  %60 = load i64, ptr @now, align 8, !tbaa !17
  store i64 %60, ptr @mybucket_grow_time, align 8, !tbaa !19
  %61 = load i64, ptr @now, align 8, !tbaa !17
  store i64 %61, ptr @mybucket6_grow_time, align 8, !tbaa !19
  %62 = load i64, ptr @now, align 8, !tbaa !17
  %63 = call i64 @random() #7
  %64 = srem i64 %63, 3
  %65 = add nsw i64 %62, %64
  store i64 %65, ptr @confirm_nodes_time, align 8, !tbaa !19
  %66 = call i64 @random() #7
  %67 = and i64 %66, 65535
  %68 = trunc i64 %67 to i16
  store i16 %68, ptr @search_id, align 2, !tbaa !20
  store i64 0, ptr @search_time, align 8, !tbaa !19
  store i32 0, ptr @next_blacklisted, align 4, !tbaa !5
  %69 = load i64, ptr @now, align 8, !tbaa !17
  store i64 %69, ptr @token_bucket_time, align 8, !tbaa !19
  store i32 400, ptr @token_bucket_tokens, align 4, !tbaa !5
  call void @llvm.memset.p0.i64(ptr align 1 @secret, i8 0, i64 8, i1 false)
  %70 = call i32 @rotate_secrets()
  store i32 %70, ptr %10, align 4, !tbaa !5
  %71 = load i32, ptr %10, align 4, !tbaa !5
  %72 = icmp slt i32 %71, 0
  br i1 %72, label %73, label %74

73:                                               ; preds = %58
  br label %81

74:                                               ; preds = %58
  %75 = load i32, ptr %6, align 4, !tbaa !5
  store i32 %75, ptr @dht_socket, align 4, !tbaa !5
  %76 = load i32, ptr %7, align 4, !tbaa !5
  store i32 %76, ptr @dht_socket6, align 4, !tbaa !5
  %77 = load ptr, ptr @buckets, align 8, !tbaa !9
  %78 = call i32 @expire_buckets(ptr noundef %77)
  %79 = load ptr, ptr @buckets6, align 8, !tbaa !9
  %80 = call i32 @expire_buckets(ptr noundef %79)
  store i32 1, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %84

81:                                               ; preds = %73
  %82 = load ptr, ptr @buckets, align 8, !tbaa !9
  call void @free(ptr noundef %82) #7
  store ptr null, ptr @buckets, align 8, !tbaa !9
  %83 = load ptr, ptr @buckets6, align 8, !tbaa !9
  call void @free(ptr noundef %83) #7
  store ptr null, ptr @buckets6, align 8, !tbaa !9
  store i32 -1, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %84

84:                                               ; preds = %81, %74, %45, %32, %23
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #7
  %85 = load i32, ptr %5, align 4
  ret i32 %85
}

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

; Function Attrs: nounwind
declare i32 @gettimeofday(ptr noundef, ptr noundef) #5

; Function Attrs: nounwind
declare i64 @random() #5

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

; Function Attrs: nounwind uwtable
declare hidden i32 @rotate_secrets() #3

; Function Attrs: nounwind uwtable
declare hidden i32 @expire_buckets(ptr noundef) #3

; Function Attrs: nounwind
declare void @free(ptr noundef) #5

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nounwind willreturn memory(none) "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 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #4 = { 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 #5 = { 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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { nounwind }
attributes #8 = { nounwind willreturn memory(none) }
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 = !{!12, !6, i64 28}
!12 = !{!"bucket", !6, i64 0, !7, i64 4, !6, i64 24, !6, i64 28, !13, i64 32, !10, i64 40, !14, i64 48, !6, i64 176, !10, i64 184}
!13 = !{!"long", !7, i64 0}
!14 = !{!"sockaddr_storage", !15, i64 0, !7, i64 2, !13, i64 120}
!15 = !{!"short", !7, i64 0}
!16 = !{!12, !6, i64 0}
!17 = !{!18, !13, i64 0}
!18 = !{!"timeval", !13, i64 0, !13, i64 8}
!19 = !{!13, !13, i64 0}
!20 = !{!15, !15, i64 0}


; 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.timeval = type { i64, i64 }

@searches = external hidden local_unnamed_addr global ptr, align 8
@now = external hidden global %struct.timeval, align 8
@search_id = external hidden local_unnamed_addr global i16, align 2
@myid = external hidden local_unnamed_addr global [20 x i8], align 16
@search_time = external hidden local_unnamed_addr global i64, align 8
@buckets = external hidden local_unnamed_addr global ptr, align 8
@buckets6 = external hidden local_unnamed_addr global ptr, align 8
@storage = external hidden local_unnamed_addr global ptr, align 8
@dht_socket = external hidden local_unnamed_addr global i32, align 4
@dht_socket6 = external hidden local_unnamed_addr global i32, align 4
@numsearches = external hidden local_unnamed_addr global i32, align 4
@numstorage = external hidden local_unnamed_addr global i32, align 4
@my_v = external hidden local_unnamed_addr global [9 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [6 x i8], align 1
@have_v = external hidden local_unnamed_addr global i32, align 4
@mybucket_grow_time = external hidden local_unnamed_addr global i64, align 8
@mybucket6_grow_time = external hidden local_unnamed_addr global i64, align 8
@confirm_nodes_time = external hidden local_unnamed_addr global i64, align 8
@next_blacklisted = external dso_local local_unnamed_addr global i32, align 4
@token_bucket_time = external hidden local_unnamed_addr global i64, align 8
@token_bucket_tokens = external hidden local_unnamed_addr global i32, align 4
@secret = external hidden local_unnamed_addr global [8 x i8], align 1

; Function Attrs: mustprogress nofree nosync nounwind willreturn memory(none)
declare ptr @__errno_location() local_unnamed_addr #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: nounwind uwtable
define dso_local range(i32 -1, 2) i32 @dht_init(i32 noundef %0, i32 noundef %1, ptr nocapture noundef readonly %2, ptr noundef readonly %3) local_unnamed_addr #2 {
  %5 = load i32, ptr @dht_socket, align 4, !tbaa !5
  %6 = icmp sgt i32 %5, -1
  %7 = load i32, ptr @dht_socket6, align 4
  %8 = icmp sgt i32 %7, -1
  %or.cond = select i1 %6, i1 true, i1 %8
  %9 = load ptr, ptr @buckets, align 8
  %10 = icmp ne ptr %9, null
  %or.cond3 = select i1 %or.cond, i1 true, i1 %10
  %11 = load ptr, ptr @buckets6, align 8
  %12 = icmp ne ptr %11, null
  %or.cond5 = select i1 %or.cond3, i1 true, i1 %12
  br i1 %or.cond5, label %13, label %15

13:                                               ; preds = %4
  %14 = tail call ptr @__errno_location() #7
  store i32 16, ptr %14, align 4, !tbaa !5
  br label %51

15:                                               ; preds = %4
  store ptr null, ptr @searches, align 8, !tbaa !9
  store i32 0, ptr @numsearches, align 4, !tbaa !5
  store ptr null, ptr @storage, align 8, !tbaa !9
  store i32 0, ptr @numstorage, align 4, !tbaa !5
  %16 = icmp sgt i32 %0, -1
  br i1 %16, label %17, label %22

17:                                               ; preds = %15
  %18 = tail call noalias dereferenceable_or_null(192) ptr @calloc(i64 noundef 1, i64 noundef 192) #8
  store ptr %18, ptr @buckets, align 8, !tbaa !9
  %19 = icmp eq ptr %18, null
  br i1 %19, label %51, label %20

20:                                               ; preds = %17
  %21 = getelementptr inbounds i8, ptr %18, i64 28
  store i32 128, ptr %21, align 4, !tbaa !11
  store i32 2, ptr %18, align 8, !tbaa !16
  br label %22

22:                                               ; preds = %20, %15
  %23 = icmp sgt i32 %1, -1
  br i1 %23, label %24, label %29

24:                                               ; preds = %22
  %25 = tail call noalias dereferenceable_or_null(192) ptr @calloc(i64 noundef 1, i64 noundef 192) #8
  store ptr %25, ptr @buckets6, align 8, !tbaa !9
  %26 = icmp eq ptr %25, null
  br i1 %26, label %51, label %27

27:                                               ; preds = %24
  %28 = getelementptr inbounds i8, ptr %25, i64 28
  store i32 128, ptr %28, align 4, !tbaa !11
  store i32 10, ptr %25, align 8, !tbaa !16
  br label %29

29:                                               ; preds = %27, %22
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(20) @myid, ptr noundef nonnull align 1 dereferenceable(20) %2, i64 20, i1 false)
  %.not = icmp eq ptr %3, null
  br i1 %.not, label %32, label %30

30:                                               ; preds = %29
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(5) @my_v, ptr noundef nonnull align 1 dereferenceable(5) @.str.22, i64 5, i1 false)
  %31 = load i32, ptr %3, align 1
  store i32 %31, ptr getelementptr inbounds (i8, ptr @my_v, i64 5), align 1
  br label %32

32:                                               ; preds = %29, %30
  %storemerge = phi i32 [ 1, %30 ], [ 0, %29 ]
  store i32 %storemerge, ptr @have_v, align 4, !tbaa !5
  %33 = tail call i32 @gettimeofday(ptr noundef nonnull @now, ptr noundef null) #9
  %34 = load i64, ptr @now, align 8, !tbaa !17
  store i64 %34, ptr @mybucket_grow_time, align 8, !tbaa !19
  store i64 %34, ptr @mybucket6_grow_time, align 8, !tbaa !19
  %35 = tail call i64 @random() #9
  %36 = srem i64 %35, 3
  %37 = add nsw i64 %36, %34
  store i64 %37, ptr @confirm_nodes_time, align 8, !tbaa !19
  %38 = tail call i64 @random() #9
  %39 = trunc i64 %38 to i16
  store i16 %39, ptr @search_id, align 2, !tbaa !20
  store i64 0, ptr @search_time, align 8, !tbaa !19
  store i32 0, ptr @next_blacklisted, align 4, !tbaa !5
  %40 = load i64, ptr @now, align 8, !tbaa !17
  store i64 %40, ptr @token_bucket_time, align 8, !tbaa !19
  store i32 400, ptr @token_bucket_tokens, align 4, !tbaa !5
  store i64 0, ptr @secret, align 1
  %41 = tail call i32 @rotate_secrets()
  %42 = icmp slt i32 %41, 0
  br i1 %42, label %48, label %43

43:                                               ; preds = %32
  store i32 %0, ptr @dht_socket, align 4, !tbaa !5
  store i32 %1, ptr @dht_socket6, align 4, !tbaa !5
  %44 = load ptr, ptr @buckets, align 8, !tbaa !9
  %45 = tail call i32 @expire_buckets(ptr noundef %44)
  %46 = load ptr, ptr @buckets6, align 8, !tbaa !9
  %47 = tail call i32 @expire_buckets(ptr noundef %46)
  br label %51

48:                                               ; preds = %32
  %49 = load ptr, ptr @buckets, align 8, !tbaa !9
  tail call void @free(ptr noundef %49) #9
  store ptr null, ptr @buckets, align 8, !tbaa !9
  %50 = load ptr, ptr @buckets6, align 8, !tbaa !9
  tail call void @free(ptr noundef %50) #9
  store ptr null, ptr @buckets6, align 8, !tbaa !9
  br label %51

51:                                               ; preds = %24, %17, %48, %43, %13
  %.0 = phi i32 [ -1, %13 ], [ -1, %48 ], [ 1, %43 ], [ -1, %17 ], [ -1, %24 ]
  ret i32 %.0
}

; 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 #3

; Function Attrs: nofree nounwind
declare noundef i32 @gettimeofday(ptr nocapture noundef, ptr nocapture noundef) local_unnamed_addr #4

; Function Attrs: nounwind
declare i64 @random() local_unnamed_addr #5

; Function Attrs: nounwind uwtable
declare hidden i32 @rotate_secrets() local_unnamed_addr #2

; Function Attrs: nounwind uwtable
declare hidden i32 @expire_buckets(ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #6

attributes #0 = { mustprogress nofree nosync nounwind willreturn memory(none) "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 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { 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 #5 = { 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 nounwind willreturn allockind("free") memory(argmem: readwrite, 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 willreturn memory(none) }
attributes #8 = { nounwind allocsize(0,1) }
attributes #9 = { 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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !6, i64 28}
!12 = !{!"bucket", !6, i64 0, !7, i64 4, !6, i64 24, !6, i64 28, !13, i64 32, !10, i64 40, !14, i64 48, !6, i64 176, !10, i64 184}
!13 = !{!"long", !7, i64 0}
!14 = !{!"sockaddr_storage", !15, i64 0, !7, i64 2, !13, i64 120}
!15 = !{!"short", !7, i64 0}
!16 = !{!12, !6, i64 0}
!17 = !{!18, !13, i64 0}
!18 = !{!"timeval", !13, i64 0, !13, i64 8}
!19 = !{!13, !13, i64 0}
!20 = !{!15, !15, i64 0}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass