; LLVM IR from jrouwe/JoltPhysics :: Jolt/Core (JobSystemWithBarrier)

; 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.JPH::AssertLastParam" = type { i8 }
%"class.std::chrono::duration" = type { i64 }
%"class.JPH::JobSystemWithBarrier::BarrierImpl" = type { %"class.JPH::JobSystem::Barrier", %"struct.std::atomic", [2048 x %"struct.std::atomic.0"], [48 x i8], %"struct.std::atomic.2", [60 x i8], %"struct.std::atomic.2", %"struct.std::atomic.4", [56 x i8], %"class.JPH::Semaphore" }
%"class.JPH::JobSystem::Barrier" = type { ptr }
%"struct.std::atomic" = type { %"struct.std::__atomic_base" }
%"struct.std::__atomic_base" = type { i8 }
%"struct.std::atomic.0" = type { %"struct.std::__atomic_base.1" }
%"struct.std::__atomic_base.1" = type { ptr }
%"struct.std::atomic.2" = type { %"struct.std::__atomic_base.3" }
%"struct.std::__atomic_base.3" = type { i32 }
%"struct.std::atomic.4" = type { %"struct.std::__atomic_base.5" }
%"struct.std::__atomic_base.5" = type { i32 }
%"class.JPH::Semaphore" = type { %"struct.std::atomic.4", %union.sem_t, [24 x i8] }
%union.sem_t = type { i64, [24 x i8] }

@.str.1 = external hidden unnamed_addr constant [87 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [24 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 nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNSt6atomicIPN3JPH9JobSystem3JobEEaSES3_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3JPH20JobSystemWithBarrier11BarrierImpl6AddJobERKNS_9JobSystem9JobHandleE(ptr noundef nonnull align 64 dereferenceable(16640) %0, ptr noundef nonnull align 8 dereferenceable(8) %1) unnamed_addr #2 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i8, align 1
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca %"struct.JPH::AssertLastParam", align 1
  %9 = alloca %"class.std::chrono::duration", align 8
  %10 = alloca i32, align 4
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  %11 = load ptr, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 1, ptr %5) #6
  store i8 0, ptr %5, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #6
  %12 = load ptr, ptr %4, align 8, !tbaa !5
  %13 = call noundef ptr @_ZNK3JPH3RefINS_9JobSystem3JobEE6GetPtrEv(ptr noundef nonnull align 8 dereferenceable(8) %12)
  store ptr %13, ptr %6, align 8, !tbaa !5
  %14 = load ptr, ptr %6, align 8, !tbaa !5
  %15 = call noundef zeroext i1 @_ZN3JPH9JobSystem3Job10SetBarrierEPNS0_7BarrierE(ptr noundef nonnull align 8 dereferenceable(56) %14, ptr noundef %11)
  br i1 %15, label %16, label %49

16:                                               ; preds = %2
  %17 = getelementptr inbounds %"class.JPH::JobSystemWithBarrier::BarrierImpl", ptr %11, i32 0, i32 7
  %18 = call noundef i32 @_ZNSt13__atomic_baseIiEppEi(ptr noundef nonnull align 4 dereferenceable(4) %17, i32 noundef 0) #6
  %19 = load ptr, ptr %6, align 8, !tbaa !5
  %20 = call noundef zeroext i1 @_ZNK3JPH9JobSystem3Job13CanBeExecutedEv(ptr noundef nonnull align 8 dereferenceable(56) %19)
  br i1 %20, label %21, label %24

21:                                               ; preds = %16
  store i8 1, ptr %5, align 1, !tbaa !9
  %22 = getelementptr inbounds %"class.JPH::JobSystemWithBarrier::BarrierImpl", ptr %11, i32 0, i32 7
  %23 = call noundef i32 @_ZNSt13__atomic_baseIiEppEi(ptr noundef nonnull align 4 dereferenceable(4) %22, i32 noundef 0) #6
  br label %24

24:                                               ; preds = %21, %16
  %25 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZN3JPH9JobSystem3Job6AddRefEv(ptr noundef nonnull align 8 dereferenceable(56) %25)
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  %26 = getelementptr inbounds %"class.JPH::JobSystemWithBarrier::BarrierImpl", ptr %11, i32 0, i32 6
  %27 = call noundef i32 @_ZNSt13__atomic_baseIjEppEi(ptr noundef nonnull align 4 dereferenceable(4) %26, i32 noundef 0) #6
  store i32 %27, ptr %7, align 4, !tbaa !11
  br label %28

28:                                               ; preds = %40, %24
  %29 = load i32, ptr %7, align 4, !tbaa !11
  %30 = getelementptr inbounds %"class.JPH::JobSystemWithBarrier::BarrierImpl", ptr %11, i32 0, i32 4
  %31 = call noundef i32 @_ZNKSt13__atomic_baseIjEcvjEv(ptr noundef nonnull align 4 dereferenceable(4) %30) #6
  %32 = sub i32 %29, %31
  %33 = icmp uge i32 %32, 2048
  br i1 %33, label %34, label %41

34:                                               ; preds = %28
  br label %35

35:                                               ; preds = %34
  %36 = call noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jS1_NS_15AssertLastParamE(ptr noundef @.str.2, ptr noundef @.str.1, i32 noundef 50, ptr noundef @.str.3)
  br i1 %36, label %37, label %38

37:                                               ; preds = %35
  call void asm sideeffect "int $$0x3", "~{dirflag},~{fpsr},~{flags}"() #6, !srcloc !13
  br label %38

38:                                               ; preds = %37, %35
  br label %39

39:                                               ; preds = %38
  br label %40

40:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 100, ptr %10, align 4, !tbaa !11
  call void @_ZNSt6chrono8durationIlSt5ratioILl1ELl1000000EEEC2IivEERKT_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 4 dereferenceable(4) %10)
  call void @_ZNSt11this_thread9sleep_forIlSt5ratioILl1ELl1000000EEEEvRKNSt6chrono8durationIT_T0_EE(ptr noundef nonnull align 8 dereferenceable(8) %9)
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  br label %28, !llvm.loop !14

41:                                               ; preds = %28
  %42 = load ptr, ptr %6, align 8, !tbaa !5
  %43 = getelementptr inbounds %"class.JPH::JobSystemWithBarrier::BarrierImpl", ptr %11, i32 0, i32 2
  %44 = load i32, ptr %7, align 4, !tbaa !11
  %45 = and i32 %44, 2047
  %46 = zext i32 %45 to i64
  %47 = getelementptr inbounds [2048 x %"struct.std::atomic.0"], ptr %43, i64 0, i64 %46
  %48 = call noundef ptr @_ZNSt6atomicIPN3JPH9JobSystem3JobEEaSES3_(ptr noundef nonnull align 8 dereferenceable(8) %47, ptr noundef %42) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  br label %49

49:                                               ; preds = %41, %2
  %50 = load i8, ptr %5, align 1, !tbaa !9, !range !16, !noundef !17
  %51 = trunc i8 %50 to i1
  br i1 %51, label %52, label %54

52:                                               ; preds = %49
  %53 = getelementptr inbounds %"class.JPH::JobSystemWithBarrier::BarrierImpl", ptr %11, i32 0, i32 9
  call void @_ZN3JPH9Semaphore7ReleaseEj(ptr noundef nonnull align 64 dereferenceable(40) %53, i32 noundef 1)
  br label %54

54:                                               ; preds = %52, %49
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %5) #6
  ret void
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK3JPH3RefINS_9JobSystem3JobEE6GetPtrEv(ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN3JPH9JobSystem3Job10SetBarrierEPNS0_7BarrierE(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef) #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNSt13__atomic_baseIiEppEi(ptr noundef nonnull align 4 dereferenceable(4), i32 noundef) #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK3JPH9JobSystem3Job13CanBeExecutedEv(ptr noundef nonnull align 8 dereferenceable(56)) #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH9JobSystem3Job6AddRefEv(ptr noundef nonnull align 8 dereferenceable(56)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNSt13__atomic_baseIjEppEi(ptr noundef nonnull align 4 dereferenceable(4), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNKSt13__atomic_baseIjEcvjEv(ptr noundef nonnull align 4 dereferenceable(4)) #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jS1_NS_15AssertLastParamE(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNSt11this_thread9sleep_forIlSt5ratioILl1ELl1000000EEEEvRKNSt6chrono8durationIT_T0_EE(ptr noundef nonnull align 8 dereferenceable(8)) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6chrono8durationIlSt5ratioILl1ELl1000000EEEC2IivEERKT_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #1 align 2

declare void @_ZN3JPH9Semaphore7ReleaseEj(ptr noundef nonnull align 64 dereferenceable(40), i32 noundef) #5

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 #3 = { inlinehint 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 #4 = { inlinehint 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 #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 }

!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++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{i64 2157458524}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = !{i8 0, i8 2}
!17 = !{}


; 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::chrono::duration" = type { i64 }
%"struct.std::atomic.0" = type { %"struct.std::__atomic_base.1" }
%"struct.std::__atomic_base.1" = type { ptr }

@.str.1 = external hidden unnamed_addr constant [87 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [24 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

; 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 nounwind uwtable
declare dso_local noundef ptr @_ZNSt6atomicIPN3JPH9JobSystem3JobEEaSES3_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3JPH20JobSystemWithBarrier11BarrierImpl6AddJobERKNS_9JobSystem9JobHandleE(ptr noundef nonnull align 64 dereferenceable(16640) %0, ptr noundef nonnull align 8 dereferenceable(8) %1) unnamed_addr #2 align 2 {
  %3 = alloca %"class.std::chrono::duration", align 8
  %4 = alloca i32, align 4
  %5 = tail call noundef ptr @_ZNK3JPH3RefINS_9JobSystem3JobEE6GetPtrEv(ptr noundef nonnull align 8 dereferenceable(8) %1)
  %6 = tail call noundef zeroext i1 @_ZN3JPH9JobSystem3Job10SetBarrierEPNS0_7BarrierE(ptr noundef nonnull align 8 dereferenceable(56) %5, ptr noundef nonnull %0)
  br i1 %6, label %7, label %.critedge

7:                                                ; preds = %2
  %8 = getelementptr inbounds i8, ptr %0, i64 16516
  %9 = tail call noundef i32 @_ZNSt13__atomic_baseIiEppEi(ptr noundef nonnull align 4 dereferenceable(4) %8, i32 noundef 0) #6
  %10 = tail call noundef zeroext i1 @_ZNK3JPH9JobSystem3Job13CanBeExecutedEv(ptr noundef nonnull align 8 dereferenceable(56) %5)
  br i1 %10, label %11, label %13

11:                                               ; preds = %7
  %12 = tail call noundef i32 @_ZNSt13__atomic_baseIiEppEi(ptr noundef nonnull align 4 dereferenceable(4) %8, i32 noundef 0) #6
  br label %13

13:                                               ; preds = %11, %7
  tail call void @_ZN3JPH9JobSystem3Job6AddRefEv(ptr noundef nonnull align 8 dereferenceable(56) %5)
  %14 = getelementptr inbounds i8, ptr %0, i64 16512
  %15 = tail call noundef i32 @_ZNSt13__atomic_baseIjEppEi(ptr noundef nonnull align 4 dereferenceable(4) %14, i32 noundef 0) #6
  %16 = getelementptr inbounds i8, ptr %0, i64 16448
  %17 = tail call noundef i32 @_ZNKSt13__atomic_baseIjEcvjEv(ptr noundef nonnull align 4 dereferenceable(4) %16) #6
  %18 = sub i32 %15, %17
  %19 = icmp ugt i32 %18, 2047
  br i1 %19, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %13, %22
  %20 = call noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jS1_NS_15AssertLastParamE(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.1, i32 noundef 50, ptr noundef nonnull @.str.3)
  br i1 %20, label %21, label %22

21:                                               ; preds = %.lr.ph
  call void asm sideeffect "int $$0x3", "~{dirflag},~{fpsr},~{flags}"() #6, !srcloc !5
  br label %22

22:                                               ; preds = %21, %.lr.ph
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #6
  store i32 100, ptr %4, align 4, !tbaa !6
  call void @_ZNSt6chrono8durationIlSt5ratioILl1ELl1000000EEEC2IivEERKT_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 4 dereferenceable(4) %4)
  call void @_ZNSt11this_thread9sleep_forIlSt5ratioILl1ELl1000000EEEEvRKNSt6chrono8durationIT_T0_EE(ptr noundef nonnull align 8 dereferenceable(8) %3)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #6
  %23 = call noundef i32 @_ZNKSt13__atomic_baseIjEcvjEv(ptr noundef nonnull align 4 dereferenceable(4) %16) #6
  %24 = sub i32 %15, %23
  %25 = icmp ugt i32 %24, 2047
  br i1 %25, label %.lr.ph, label %._crit_edge, !llvm.loop !10

._crit_edge:                                      ; preds = %22, %13
  %26 = getelementptr inbounds i8, ptr %0, i64 16
  %27 = and i32 %15, 2047
  %28 = zext nneg i32 %27 to i64
  %29 = getelementptr inbounds [2048 x %"struct.std::atomic.0"], ptr %26, i64 0, i64 %28
  %30 = call noundef ptr @_ZNSt6atomicIPN3JPH9JobSystem3JobEEaSES3_(ptr noundef nonnull align 8 dereferenceable(8) %29, ptr noundef nonnull %5) #6
  br i1 %10, label %31, label %.critedge

31:                                               ; preds = %._crit_edge
  %32 = getelementptr inbounds i8, ptr %0, i64 16576
  call void @_ZN3JPH9Semaphore7ReleaseEj(ptr noundef nonnull align 64 dereferenceable(40) %32, i32 noundef 1)
  br label %.critedge

.critedge:                                        ; preds = %2, %31, %._crit_edge
  ret void
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK3JPH3RefINS_9JobSystem3JobEE6GetPtrEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN3JPH9JobSystem3Job10SetBarrierEPNS0_7BarrierE(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNSt13__atomic_baseIiEppEi(ptr noundef nonnull align 4 dereferenceable(4), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK3JPH9JobSystem3Job13CanBeExecutedEv(ptr noundef nonnull align 8 dereferenceable(56)) local_unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3JPH9JobSystem3Job6AddRefEv(ptr noundef nonnull align 8 dereferenceable(56)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNSt13__atomic_baseIjEppEi(ptr noundef nonnull align 4 dereferenceable(4), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNKSt13__atomic_baseIjEcvjEv(ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN3JPH23AssertFailedParamHelperEPKcS1_jS1_NS_15AssertLastParamE(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNSt11this_thread9sleep_forIlSt5ratioILl1ELl1000000EEEEvRKNSt6chrono8durationIT_T0_EE(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6chrono8durationIlSt5ratioILl1ELl1000000EEEC2IivEERKT_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #1 align 2

declare void @_ZN3JPH9Semaphore7ReleaseEj(ptr noundef nonnull align 64 dereferenceable(40), i32 noundef) local_unnamed_addr #5

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 #3 = { inlinehint 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 #4 = { inlinehint 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 #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 }

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


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass