; LLVM IR from mlcommons/tiny :: benchmark/interface/Middlewares/ST/threadx/common/src (tx_block_pool_create)

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

@_tx_block_pool_created_count = external global i64, align 8
@_tx_block_pool_created_ptr = external global ptr, align 8

; Function Attrs: nounwind uwtable
define dso_local i32 @_tx_block_pool_create(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3, i64 noundef %4) #0 {
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i64, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i64, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i64, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store i64 %2, ptr %8, align 8, !tbaa !9
  store ptr %3, ptr %9, align 8, !tbaa !5
  store i64 %4, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  %20 = load ptr, ptr %6, align 8, !tbaa !5
  call void @llvm.memset.p0.i64(ptr align 8 %20, i8 0, i64 88, i1 false)
  %21 = load i64, ptr %8, align 8, !tbaa !9
  %22 = add i64 %21, 8
  %23 = sub i64 %22, 1
  %24 = udiv i64 %23, 8
  %25 = mul i64 %24, 8
  store i64 %25, ptr %8, align 8, !tbaa !9
  %26 = load i64, ptr %10, align 8, !tbaa !9
  %27 = udiv i64 %26, 8
  %28 = mul i64 %27, 8
  store i64 %28, ptr %10, align 8, !tbaa !9
  %29 = load ptr, ptr %7, align 8, !tbaa !5
  %30 = load ptr, ptr %6, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %30, i32 0, i32 1
  store ptr %29, ptr %31, align 8, !tbaa !11
  %32 = load ptr, ptr %9, align 8, !tbaa !5
  %33 = load ptr, ptr %6, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %33, i32 0, i32 5
  store ptr %32, ptr %34, align 8, !tbaa !14
  %35 = load i64, ptr %10, align 8, !tbaa !9
  %36 = load ptr, ptr %6, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %36, i32 0, i32 6
  store i64 %35, ptr %37, align 8, !tbaa !15
  %38 = load i64, ptr %8, align 8, !tbaa !9
  %39 = trunc i64 %38 to i32
  %40 = load ptr, ptr %6, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %40, i32 0, i32 7
  store i32 %39, ptr %41, align 8, !tbaa !16
  %42 = load i64, ptr %10, align 8, !tbaa !9
  %43 = load i64, ptr %8, align 8, !tbaa !9
  %44 = add i64 %43, 8
  %45 = udiv i64 %42, %44
  store i64 %45, ptr %14, align 8, !tbaa !9
  store i32 0, ptr %12, align 4, !tbaa !17
  %46 = load ptr, ptr %9, align 8, !tbaa !5
  store ptr %46, ptr %15, align 8, !tbaa !5
  %47 = load ptr, ptr %15, align 8, !tbaa !5
  %48 = load i64, ptr %8, align 8, !tbaa !9
  %49 = add i64 %48, 8
  %50 = trunc i64 %49 to i32
  %51 = zext i32 %50 to i64
  %52 = getelementptr inbounds i8, ptr %47, i64 %51
  store ptr %52, ptr %17, align 8, !tbaa !5
  br label %53

53:                                               ; preds = %58, %5
  %54 = load i32, ptr %12, align 4, !tbaa !17
  %55 = load i64, ptr %14, align 8, !tbaa !9
  %56 = trunc i64 %55 to i32
  %57 = icmp ult i32 %54, %56
  br i1 %57, label %58, label %71

58:                                               ; preds = %53
  %59 = load i32, ptr %12, align 4, !tbaa !17
  %60 = add i32 %59, 1
  store i32 %60, ptr %12, align 4, !tbaa !17
  %61 = load ptr, ptr %15, align 8, !tbaa !5
  store ptr %61, ptr %16, align 8, !tbaa !5
  %62 = load ptr, ptr %17, align 8, !tbaa !5
  %63 = load ptr, ptr %16, align 8, !tbaa !5
  store ptr %62, ptr %63, align 8, !tbaa !5
  %64 = load ptr, ptr %17, align 8, !tbaa !5
  store ptr %64, ptr %15, align 8, !tbaa !5
  %65 = load ptr, ptr %15, align 8, !tbaa !5
  %66 = load i64, ptr %8, align 8, !tbaa !9
  %67 = add i64 %66, 8
  %68 = trunc i64 %67 to i32
  %69 = zext i32 %68 to i64
  %70 = getelementptr inbounds i8, ptr %65, i64 %69
  store ptr %70, ptr %17, align 8, !tbaa !5
  br label %53, !llvm.loop !18

71:                                               ; preds = %53
  %72 = load i32, ptr %12, align 4, !tbaa !17
  %73 = load ptr, ptr %6, align 8, !tbaa !5
  %74 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %73, i32 0, i32 2
  store i32 %72, ptr %74, align 8, !tbaa !20
  %75 = load i32, ptr %12, align 4, !tbaa !17
  %76 = load ptr, ptr %6, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %76, i32 0, i32 3
  store i32 %75, ptr %77, align 4, !tbaa !21
  %78 = load i32, ptr %12, align 4, !tbaa !17
  %79 = icmp ne i32 %78, 0
  br i1 %79, label %80, label %127

80:                                               ; preds = %71
  %81 = load ptr, ptr %15, align 8, !tbaa !5
  %82 = load i64, ptr %8, align 8, !tbaa !9
  %83 = add i64 %82, 8
  %84 = trunc i64 %83 to i32
  %85 = zext i32 %84 to i64
  %86 = sub i64 0, %85
  %87 = getelementptr inbounds i8, ptr %81, i64 %86
  store ptr %87, ptr %15, align 8, !tbaa !5
  %88 = load ptr, ptr %15, align 8, !tbaa !5
  store ptr %88, ptr %16, align 8, !tbaa !5
  %89 = load ptr, ptr %16, align 8, !tbaa !5
  store ptr null, ptr %89, align 8, !tbaa !5
  %90 = load ptr, ptr %9, align 8, !tbaa !5
  %91 = load ptr, ptr %6, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %91, i32 0, i32 4
  store ptr %90, ptr %92, align 8, !tbaa !22
  %93 = call i32 @__disable_interrupts()
  store i32 %93, ptr %11, align 4, !tbaa !17
  %94 = load ptr, ptr %6, align 8, !tbaa !5
  %95 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %94, i32 0, i32 0
  store i64 1112297283, ptr %95, align 8, !tbaa !23
  %96 = load i64, ptr @_tx_block_pool_created_count, align 8, !tbaa !9
  %97 = icmp eq i64 %96, 0
  br i1 %97, label %98, label %106

98:                                               ; preds = %80
  %99 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %99, ptr @_tx_block_pool_created_ptr, align 8, !tbaa !5
  %100 = load ptr, ptr %6, align 8, !tbaa !5
  %101 = load ptr, ptr %6, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %101, i32 0, i32 10
  store ptr %100, ptr %102, align 8, !tbaa !24
  %103 = load ptr, ptr %6, align 8, !tbaa !5
  %104 = load ptr, ptr %6, align 8, !tbaa !5
  %105 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %104, i32 0, i32 11
  store ptr %103, ptr %105, align 8, !tbaa !25
  br label %123

106:                                              ; preds = %80
  %107 = load ptr, ptr @_tx_block_pool_created_ptr, align 8, !tbaa !5
  store ptr %107, ptr %18, align 8, !tbaa !5
  %108 = load ptr, ptr %18, align 8, !tbaa !5
  %109 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %108, i32 0, i32 11
  %110 = load ptr, ptr %109, align 8, !tbaa !25
  store ptr %110, ptr %19, align 8, !tbaa !5
  %111 = load ptr, ptr %6, align 8, !tbaa !5
  %112 = load ptr, ptr %18, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %112, i32 0, i32 11
  store ptr %111, ptr %113, align 8, !tbaa !25
  %114 = load ptr, ptr %6, align 8, !tbaa !5
  %115 = load ptr, ptr %19, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %115, i32 0, i32 10
  store ptr %114, ptr %116, align 8, !tbaa !24
  %117 = load ptr, ptr %19, align 8, !tbaa !5
  %118 = load ptr, ptr %6, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %118, i32 0, i32 11
  store ptr %117, ptr %119, align 8, !tbaa !25
  %120 = load ptr, ptr %18, align 8, !tbaa !5
  %121 = load ptr, ptr %6, align 8, !tbaa !5
  %122 = getelementptr inbounds %struct.TX_BLOCK_POOL_STRUCT, ptr %121, i32 0, i32 10
  store ptr %120, ptr %122, align 8, !tbaa !24
  br label %123

123:                                              ; preds = %106, %98
  %124 = load i64, ptr @_tx_block_pool_created_count, align 8, !tbaa !9
  %125 = add i64 %124, 1
  store i64 %125, ptr @_tx_block_pool_created_count, align 8, !tbaa !9
  %126 = load i32, ptr %11, align 4, !tbaa !17
  call void @__restore_interrupt(i32 noundef %126)
  store i32 0, ptr %13, align 4, !tbaa !17
  br label %128

127:                                              ; preds = %71
  store i32 5, ptr %13, align 4, !tbaa !17
  br label %128

128:                                              ; preds = %127, %123
  %129 = load i32, ptr %13, align 4, !tbaa !17
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  ret i32 %129
}

; 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: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @__restore_interrupt(i32 noundef) #3

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

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: write) }
attributes #3 = { alwaysinline 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 }

!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 = !{!"long", !7, i64 0}
!11 = !{!12, !6, i64 8}
!12 = !{!"TX_BLOCK_POOL_STRUCT", !10, i64 0, !6, i64 8, !13, i64 16, !13, i64 20, !6, i64 24, !6, i64 32, !10, i64 40, !13, i64 48, !6, i64 56, !13, i64 64, !6, i64 72, !6, i64 80}
!13 = !{!"int", !7, i64 0}
!14 = !{!12, !6, i64 32}
!15 = !{!12, !10, i64 40}
!16 = !{!12, !13, i64 48}
!17 = !{!13, !13, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = !{!12, !13, i64 16}
!21 = !{!12, !13, i64 20}
!22 = !{!12, !6, i64 24}
!23 = !{!12, !10, i64 0}
!24 = !{!12, !6, i64 72}
!25 = !{!12, !6, i64 80}


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

@_tx_block_pool_created_count = external local_unnamed_addr global i64, align 8
@_tx_block_pool_created_ptr = external local_unnamed_addr global ptr, align 8

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 6) i32 @_tx_block_pool_create(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3, i64 noundef %4) local_unnamed_addr #0 {
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(88) %0, i8 0, i64 88, i1 false)
  %6 = add i64 %2, 7
  %7 = and i64 %6, -8
  %8 = and i64 %4, -8
  %9 = getelementptr inbounds i8, ptr %0, i64 8
  store ptr %1, ptr %9, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %0, i64 32
  store ptr %3, ptr %10, align 8, !tbaa !12
  %11 = getelementptr inbounds i8, ptr %0, i64 40
  store i64 %8, ptr %11, align 8, !tbaa !13
  %12 = trunc i64 %7 to i32
  %13 = getelementptr inbounds i8, ptr %0, i64 48
  store i32 %12, ptr %13, align 8, !tbaa !14
  %14 = add i64 %7, 8
  %15 = udiv i64 %8, %14
  %16 = and i64 %14, 4294967288
  %17 = trunc i64 %15 to i32
  %.not58 = icmp eq i32 %17, 0
  br i1 %.not58, label %._crit_edge.thread, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %5
  %xtraiter = and i32 %17, 7
  %18 = icmp ult i32 %17, 8
  br i1 %18, label %.unr-lcssa, label %.lr.ph.preheader.new

.lr.ph.preheader.new:                             ; preds = %.lr.ph.preheader
  %unroll_iter = and i32 %17, -8
  br label %.lr.ph

._crit_edge.thread:                               ; preds = %5
  %19 = getelementptr inbounds i8, ptr %0, i64 20
  store i32 0, ptr %19, align 4, !tbaa !15
  br label %37

.lr.ph:                                           ; preds = %.lr.ph, %.lr.ph.preheader.new
  %.056 = phi i32 [ 0, %.lr.ph.preheader.new ], [ %20, %.lr.ph ]
  %.05355 = phi ptr [ %3, %.lr.ph.preheader.new ], [ %.052.7, %.lr.ph ]
  %niter = phi i32 [ 0, %.lr.ph.preheader.new ], [ %niter.next.7, %.lr.ph ]
  %.052 = getelementptr inbounds i8, ptr %.05355, i64 %16
  store ptr %.052, ptr %.05355, align 8, !tbaa !16
  %.052.1 = getelementptr inbounds i8, ptr %.052, i64 %16
  store ptr %.052.1, ptr %.052, align 8, !tbaa !16
  %.052.2 = getelementptr inbounds i8, ptr %.052.1, i64 %16
  store ptr %.052.2, ptr %.052.1, align 8, !tbaa !16
  %.052.3 = getelementptr inbounds i8, ptr %.052.2, i64 %16
  store ptr %.052.3, ptr %.052.2, align 8, !tbaa !16
  %.052.4 = getelementptr inbounds i8, ptr %.052.3, i64 %16
  store ptr %.052.4, ptr %.052.3, align 8, !tbaa !16
  %.052.5 = getelementptr inbounds i8, ptr %.052.4, i64 %16
  store ptr %.052.5, ptr %.052.4, align 8, !tbaa !16
  %.052.6 = getelementptr inbounds i8, ptr %.052.5, i64 %16
  store ptr %.052.6, ptr %.052.5, align 8, !tbaa !16
  %.052.7 = getelementptr inbounds i8, ptr %.052.6, i64 %16
  %20 = add nuw i32 %.056, 8
  store ptr %.052.7, ptr %.052.6, align 8, !tbaa !16
  %niter.next.7 = add i32 %niter, 8
  %niter.ncmp.7.not = icmp eq i32 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7.not, label %.unr-lcssa, label %.lr.ph, !llvm.loop !17

.unr-lcssa:                                       ; preds = %.lr.ph, %.lr.ph.preheader
  %.05355.lcssa.ph = phi ptr [ poison, %.lr.ph.preheader ], [ %.052.6, %.lr.ph ]
  %.lcssa.ph = phi i32 [ poison, %.lr.ph.preheader ], [ %20, %.lr.ph ]
  %.056.unr = phi i32 [ 0, %.lr.ph.preheader ], [ %20, %.lr.ph ]
  %.05355.unr = phi ptr [ %3, %.lr.ph.preheader ], [ %.052.7, %.lr.ph ]
  %lcmp.mod.not = icmp eq i32 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.epilog-lcssa, label %.lr.ph.epil

.lr.ph.epil:                                      ; preds = %.unr-lcssa, %.lr.ph.epil
  %.056.epil = phi i32 [ %21, %.lr.ph.epil ], [ %.056.unr, %.unr-lcssa ]
  %.05355.epil = phi ptr [ %.052.epil, %.lr.ph.epil ], [ %.05355.unr, %.unr-lcssa ]
  %epil.iter = phi i32 [ %epil.iter.next, %.lr.ph.epil ], [ 0, %.unr-lcssa ]
  %.052.epil = getelementptr inbounds i8, ptr %.05355.epil, i64 %16
  %21 = add nuw i32 %.056.epil, 1
  store ptr %.052.epil, ptr %.05355.epil, align 8, !tbaa !16
  %epil.iter.next = add i32 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i32 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.epilog-lcssa, label %.lr.ph.epil, !llvm.loop !19

.epilog-lcssa:                                    ; preds = %.lr.ph.epil, %.unr-lcssa
  %.05355.lcssa = phi ptr [ %.05355.lcssa.ph, %.unr-lcssa ], [ %.05355.epil, %.lr.ph.epil ]
  %.lcssa = phi i32 [ %.lcssa.ph, %.unr-lcssa ], [ %21, %.lr.ph.epil ]
  %22 = getelementptr inbounds i8, ptr %0, i64 16
  store i32 %.lcssa, ptr %22, align 8, !tbaa !21
  %23 = getelementptr inbounds i8, ptr %0, i64 20
  store i32 %.lcssa, ptr %23, align 4, !tbaa !15
  store ptr null, ptr %.05355.lcssa, align 8, !tbaa !16
  %24 = getelementptr inbounds i8, ptr %0, i64 24
  store ptr %3, ptr %24, align 8, !tbaa !22
  %25 = tail call i32 @__disable_interrupts()
  store i64 1112297283, ptr %0, align 8, !tbaa !23
  %26 = load i64, ptr @_tx_block_pool_created_count, align 8, !tbaa !24
  %27 = icmp eq i64 %26, 0
  br i1 %27, label %33, label %28

28:                                               ; preds = %.epilog-lcssa
  %29 = load ptr, ptr @_tx_block_pool_created_ptr, align 8, !tbaa !16
  %30 = getelementptr inbounds i8, ptr %29, i64 80
  %31 = load ptr, ptr %30, align 8, !tbaa !25
  store ptr %0, ptr %30, align 8, !tbaa !25
  %32 = getelementptr inbounds i8, ptr %31, i64 72
  br label %33

33:                                               ; preds = %.epilog-lcssa, %28
  %.sink63 = phi ptr [ %32, %28 ], [ @_tx_block_pool_created_ptr, %.epilog-lcssa ]
  %.sink59 = phi ptr [ %29, %28 ], [ %0, %.epilog-lcssa ]
  %.sink = phi ptr [ %31, %28 ], [ %0, %.epilog-lcssa ]
  store ptr %0, ptr %.sink63, align 8, !tbaa !16
  %34 = getelementptr inbounds i8, ptr %0, i64 72
  store ptr %.sink59, ptr %34, align 8
  %35 = getelementptr inbounds i8, ptr %0, i64 80
  store ptr %.sink, ptr %35, align 8
  %36 = add i64 %26, 1
  store i64 %36, ptr @_tx_block_pool_created_count, align 8, !tbaa !24
  tail call void @__restore_interrupt(i32 noundef %25)
  br label %37

37:                                               ; preds = %._crit_edge.thread, %33
  %.054 = phi i32 [ 0, %33 ], [ 5, %._crit_edge.thread ]
  ret i32 %.054
}

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

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

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @__restore_interrupt(i32 noundef) local_unnamed_addr #2

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: write) }
attributes #2 = { alwaysinline 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, !10, i64 8}
!6 = !{!"TX_BLOCK_POOL_STRUCT", !7, i64 0, !10, i64 8, !11, i64 16, !11, i64 20, !10, i64 24, !10, i64 32, !7, i64 40, !11, i64 48, !10, i64 56, !11, i64 64, !10, i64 72, !10, i64 80}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!6, !10, i64 32}
!13 = !{!6, !7, i64 40}
!14 = !{!6, !11, i64 48}
!15 = !{!6, !11, i64 20}
!16 = !{!10, !10, i64 0}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.unroll.disable"}
!21 = !{!6, !11, i64 16}
!22 = !{!6, !10, i64 24}
!23 = !{!6, !7, i64 0}
!24 = !{!7, !7, i64 0}
!25 = !{!6, !10, i64 80}


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