; LLVM IR from turi-code/SFrame :: oss_src/parallel (execute_task_in_native_thread)

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

%"class.std::__exception_ptr::exception_ptr" = type { ptr }
%"class.graphlab::mutex" = type { %union.pthread_mutex_t }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.graphlab::conditional" = type { %union.pthread_cond_t }
%union.pthread_cond_t = type { %struct.__pthread_cond_s }
%struct.__pthread_cond_s = type { %union.__atomic_wide_counter, %union.__atomic_wide_counter, [2 x i32], [2 x i32], i32, i32, [2 x i32] }
%union.__atomic_wide_counter = type { i64 }
%"class.boost::function" = type { %"class.boost::function0" }
%"class.boost::function0" = type { %"class.boost::function_base" }
%"class.boost::function_base" = type { ptr, %"union.boost::detail::function::function_buffer" }
%"union.boost::detail::function::function_buffer" = type { %"union.boost::detail::function::function_buffer_members" }
%"union.boost::detail::function::function_buffer_members" = type { %"struct.boost::detail::function::function_buffer_members::bound_memfunc_ptr_t" }
%"struct.boost::detail::function::function_buffer_members::bound_memfunc_ptr_t" = type { { i64, i64 }, ptr }
%class.anon = type { ptr, ptr, ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN8graphlab29execute_task_in_native_threadERKSt8functionIFvvEE(ptr dead_on_unwind noalias writable sret(%"class.std::__exception_ptr::exception_ptr") align 8 %0, ptr noundef nonnull align 8 dereferenceable(32) %1) #0 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca %"class.graphlab::mutex", align 8
  %7 = alloca %"class.graphlab::conditional", align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i8, align 1
  %11 = alloca i1, align 1
  %12 = alloca %"class.boost::function", align 8
  %13 = alloca %class.anon, align 8
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #6
  %14 = call noundef nonnull align 8 dereferenceable(193) ptr @_ZN8graphlabL14get_task_queueEv()
  store ptr %14, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 40, ptr %6) #6
  call void @_ZN8graphlab5mutexC2Ev(ptr noundef nonnull align 8 dereferenceable(40) %6)
  call void @llvm.lifetime.start.p0(i64 48, ptr %7) #6
  invoke void @_ZN8graphlab11conditionalC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7)
          to label %15 unwind label %32

15:                                               ; preds = %2
  call void @llvm.lifetime.start.p0(i64 1, ptr %10) #6
  store i8 0, ptr %10, align 1, !tbaa !9
  store i1 false, ptr %11, align 1
  call void @_ZNSt15__exception_ptr13exception_ptrC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #6
  %16 = load ptr, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %12) #6
  %17 = getelementptr inbounds %class.anon, ptr %13, i32 0, i32 0
  %18 = load ptr, ptr %4, align 8, !tbaa !5
  store ptr %18, ptr %17, align 8, !tbaa !5
  %19 = getelementptr inbounds %class.anon, ptr %13, i32 0, i32 1
  store ptr %0, ptr %19, align 8, !tbaa !5
  %20 = getelementptr inbounds %class.anon, ptr %13, i32 0, i32 2
  store ptr %6, ptr %20, align 8, !tbaa !5
  %21 = getelementptr inbounds %class.anon, ptr %13, i32 0, i32 3
  store ptr %10, ptr %21, align 8, !tbaa !5
  %22 = getelementptr inbounds %class.anon, ptr %13, i32 0, i32 4
  store ptr %7, ptr %22, align 8, !tbaa !5
  invoke void @"_ZN5boost8functionIFvvEEC2IZN8graphlab29execute_task_in_native_threadERKSt8functionIS1_EE3$_0EET_NS_10enable_if_IXntsr11is_integralISA_EE5valueEiE4typeE"(ptr noundef nonnull align 8 dereferenceable(32) %12, ptr noundef byval(%class.anon) align 8 %13, i32 noundef 0)
          to label %23 unwind label %36

23:                                               ; preds = %15
  invoke void @_ZN8graphlab19parallel_task_queue6launchERKN5boost8functionIFvvEEEi(ptr noundef nonnull align 8 dereferenceable(193) %16, ptr noundef nonnull align 8 dereferenceable(32) %12, i32 noundef -1)
          to label %24 unwind label %40

24:                                               ; preds = %23
  call void @_ZN5boost9function0IvED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %12) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #6
  invoke void @_ZNK8graphlab5mutex4lockEv(ptr noundef nonnull align 8 dereferenceable(40) %6)
          to label %25 unwind label %45

25:                                               ; preds = %24
  br label %26

26:                                               ; preds = %31, %25
  %27 = load i8, ptr %10, align 1, !tbaa !9, !range !11, !noundef !12
  %28 = trunc i8 %27 to i1
  %29 = xor i1 %28, true
  br i1 %29, label %30, label %49

30:                                               ; preds = %26
  invoke void @_ZNK8graphlab11conditional4waitERKNS_5mutexE(ptr noundef nonnull align 8 dereferenceable(48) %7, ptr noundef nonnull align 8 dereferenceable(40) %6)
          to label %31 unwind label %45

31:                                               ; preds = %30
  br label %26, !llvm.loop !13

32:                                               ; preds = %2
  %33 = landingpad { ptr, i32 }
          cleanup
  %34 = extractvalue { ptr, i32 } %33, 0
  store ptr %34, ptr %8, align 8
  %35 = extractvalue { ptr, i32 } %33, 1
  store i32 %35, ptr %9, align 4
  br label %55

36:                                               ; preds = %15
  %37 = landingpad { ptr, i32 }
          cleanup
  %38 = extractvalue { ptr, i32 } %37, 0
  store ptr %38, ptr %8, align 8
  %39 = extractvalue { ptr, i32 } %37, 1
  store i32 %39, ptr %9, align 4
  br label %44

40:                                               ; preds = %23
  %41 = landingpad { ptr, i32 }
          cleanup
  %42 = extractvalue { ptr, i32 } %41, 0
  store ptr %42, ptr %8, align 8
  %43 = extractvalue { ptr, i32 } %41, 1
  store i32 %43, ptr %9, align 4
  call void @_ZN5boost9function0IvED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %12) #6
  br label %44

44:                                               ; preds = %40, %36
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #6
  br label %54

45:                                               ; preds = %49, %30, %24
  %46 = landingpad { ptr, i32 }
          cleanup
  %47 = extractvalue { ptr, i32 } %46, 0
  store ptr %47, ptr %8, align 8
  %48 = extractvalue { ptr, i32 } %46, 1
  store i32 %48, ptr %9, align 4
  br label %54

49:                                               ; preds = %26
  invoke void @_ZNK8graphlab5mutex6unlockEv(ptr noundef nonnull align 8 dereferenceable(40) %6)
          to label %50 unwind label %45

50:                                               ; preds = %49
  store i1 true, ptr %11, align 1
  %51 = load i1, ptr %11, align 1
  br i1 %51, label %53, label %52

52:                                               ; preds = %50
  call void @_ZNSt15__exception_ptr13exception_ptrD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #6
  br label %53

53:                                               ; preds = %52, %50
  call void @llvm.lifetime.end.p0(i64 1, ptr %10) #6
  call void @_ZN8graphlab11conditionalD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr %7) #6
  call void @_ZN8graphlab5mutexD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  ret void

54:                                               ; preds = %45, %44
  call void @_ZNSt15__exception_ptr13exception_ptrD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %10) #6
  call void @_ZN8graphlab11conditionalD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #6
  br label %55

55:                                               ; preds = %54, %32
  call void @llvm.lifetime.end.p0(i64 48, ptr %7) #6
  call void @_ZN8graphlab5mutexD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  br label %56

56:                                               ; preds = %55
  %57 = load ptr, ptr %8, align 8
  %58 = load i32, ptr %9, align 4
  %59 = insertvalue { ptr, i32 } poison, ptr %57, 0
  %60 = insertvalue { ptr, i32 } %59, i32 %58, 1
  resume { ptr, i32 } %60
}

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

; Function Attrs: mustprogress uwtable
declare hidden noundef nonnull align 8 dereferenceable(193) ptr @_ZN8graphlabL14get_task_queueEv() #0

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8graphlab5mutexC2Ev(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8graphlab11conditionalC2Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #0 align 2

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

declare void @_ZN8graphlab19parallel_task_queue6launchERKN5boost8functionIFvvEEEi(ptr noundef nonnull align 8 dereferenceable(193), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) #3

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZN5boost8functionIFvvEEC2IZN8graphlab29execute_task_in_native_threadERKSt8functionIS1_EE3$_0EET_NS_10enable_if_IXntsr11is_integralISA_EE5valueEiE4typeE"(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef byval(%class.anon) align 8, i32 noundef) unnamed_addr #0 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK8graphlab5mutex4lockEv(ptr noundef nonnull align 8 dereferenceable(40)) #5 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK8graphlab11conditional4waitERKNS_5mutexE(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(40)) #5 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK8graphlab5mutex6unlockEv(ptr noundef nonnull align 8 dereferenceable(40)) #5 align 2

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

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

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { "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 = { 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 #5 = { 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 #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 = !{i8 0, i8 2}
!12 = !{}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}


; 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::__exception_ptr::exception_ptr" = type { ptr }
%"class.graphlab::mutex" = type { %union.pthread_mutex_t }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.graphlab::conditional" = type { %union.pthread_cond_t }
%union.pthread_cond_t = type { %struct.__pthread_cond_s }
%struct.__pthread_cond_s = type { %union.__atomic_wide_counter, %union.__atomic_wide_counter, [2 x i32], [2 x i32], i32, i32, [2 x i32] }
%union.__atomic_wide_counter = type { i64 }
%"class.boost::function" = type { %"class.boost::function0" }
%"class.boost::function0" = type { %"class.boost::function_base" }
%"class.boost::function_base" = type { ptr, %"union.boost::detail::function::function_buffer" }
%"union.boost::detail::function::function_buffer" = type { %"union.boost::detail::function::function_buffer_members" }
%"union.boost::detail::function::function_buffer_members" = type { %"struct.boost::detail::function::function_buffer_members::bound_memfunc_ptr_t" }
%"struct.boost::detail::function::function_buffer_members::bound_memfunc_ptr_t" = type { { i64, i64 }, ptr }
%class.anon = type { ptr, ptr, ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN8graphlab29execute_task_in_native_threadERKSt8functionIFvvEE(ptr dead_on_unwind noalias writable sret(%"class.std::__exception_ptr::exception_ptr") align 8 %0, ptr noundef nonnull align 8 dereferenceable(32) %1) local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.graphlab::mutex", align 8
  %4 = alloca %"class.graphlab::conditional", align 8
  %5 = alloca i8, align 1
  %6 = alloca %"class.boost::function", align 8
  %7 = alloca %class.anon, align 8
  %8 = tail call noundef nonnull align 8 dereferenceable(193) ptr @_ZN8graphlabL14get_task_queueEv()
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %3) #6
  call void @_ZN8graphlab5mutexC2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %4) #6
  invoke void @_ZN8graphlab11conditionalC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4)
          to label %9 unwind label %19

9:                                                ; preds = %2
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %5) #6
  store i8 0, ptr %5, align 1, !tbaa !5
  call void @_ZNSt15__exception_ptr13exception_ptrC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #6
  store ptr %1, ptr %7, align 8, !tbaa !9
  %10 = getelementptr inbounds i8, ptr %7, i64 8
  store ptr %0, ptr %10, align 8, !tbaa !9
  %11 = getelementptr inbounds i8, ptr %7, i64 16
  store ptr %3, ptr %11, align 8, !tbaa !9
  %12 = getelementptr inbounds i8, ptr %7, i64 24
  store ptr %5, ptr %12, align 8, !tbaa !9
  %13 = getelementptr inbounds i8, ptr %7, i64 32
  store ptr %4, ptr %13, align 8, !tbaa !9
  invoke void @"_ZN5boost8functionIFvvEEC2IZN8graphlab29execute_task_in_native_threadERKSt8functionIS1_EE3$_0EET_NS_10enable_if_IXntsr11is_integralISA_EE5valueEiE4typeE"(ptr noundef nonnull align 8 dereferenceable(32) %6, ptr noundef nonnull byval(%class.anon) align 8 %7, i32 noundef 0)
          to label %14 unwind label %21

14:                                               ; preds = %9
  invoke void @_ZN8graphlab19parallel_task_queue6launchERKN5boost8functionIFvvEEEi(ptr noundef nonnull align 8 dereferenceable(193) %8, ptr noundef nonnull align 8 dereferenceable(32) %6, i32 noundef -1)
          to label %15 unwind label %23

15:                                               ; preds = %14
  call void @_ZN5boost9function0IvED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  invoke void @_ZNK8graphlab5mutex4lockEv(ptr noundef nonnull align 8 dereferenceable(40) %3)
          to label %.preheader unwind label %.loopexit.split-lp

.preheader:                                       ; preds = %15, %18
  %16 = load i8, ptr %5, align 1, !tbaa !5, !range !11, !noundef !12
  %17 = trunc nuw i8 %16 to i1
  br i1 %17, label %26, label %18

18:                                               ; preds = %.preheader
  invoke void @_ZNK8graphlab11conditional4waitERKNS_5mutexE(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 8 dereferenceable(40) %3)
          to label %.preheader unwind label %.loopexit, !llvm.loop !13

19:                                               ; preds = %2
  %20 = landingpad { ptr, i32 }
          cleanup
  br label %29

21:                                               ; preds = %9
  %22 = landingpad { ptr, i32 }
          cleanup
  br label %25

23:                                               ; preds = %14
  %24 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN5boost9function0IvED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #6
  br label %25

25:                                               ; preds = %23, %21
  %.pn = phi { ptr, i32 } [ %24, %23 ], [ %22, %21 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  br label %28

.loopexit:                                        ; preds = %18
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %28

.loopexit.split-lp:                               ; preds = %15, %26
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %28

26:                                               ; preds = %.preheader
  invoke void @_ZNK8graphlab5mutex6unlockEv(ptr noundef nonnull align 8 dereferenceable(40) %3)
          to label %27 unwind label %.loopexit.split-lp

27:                                               ; preds = %26
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #6
  call void @_ZN8graphlab11conditionalD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #6
  call void @_ZN8graphlab5mutexD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %3) #6
  ret void

28:                                               ; preds = %.loopexit, %.loopexit.split-lp, %25
  %.pn8 = phi { ptr, i32 } [ %.pn, %25 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @_ZNSt15__exception_ptr13exception_ptrD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #6
  call void @_ZN8graphlab11conditionalD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #6
  br label %29

29:                                               ; preds = %28, %19
  %.pn8.pn = phi { ptr, i32 } [ %.pn8, %28 ], [ %20, %19 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #6
  call void @_ZN8graphlab5mutexD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %3) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %3) #6
  resume { ptr, i32 } %.pn8.pn
}

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

; Function Attrs: mustprogress uwtable
declare hidden noundef nonnull align 8 dereferenceable(193) ptr @_ZN8graphlabL14get_task_queueEv() local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8graphlab5mutexC2Ev(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8graphlab11conditionalC2Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #0 align 2

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

declare void @_ZN8graphlab19parallel_task_queue6launchERKN5boost8functionIFvvEEEi(ptr noundef nonnull align 8 dereferenceable(193), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZN5boost8functionIFvvEEC2IZN8graphlab29execute_task_in_native_threadERKSt8functionIS1_EE3$_0EET_NS_10enable_if_IXntsr11is_integralISA_EE5valueEiE4typeE"(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef byval(%class.anon) align 8, i32 noundef) unnamed_addr #0 align 2

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK8graphlab5mutex4lockEv(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #5 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK8graphlab11conditional4waitERKNS_5mutexE(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #5 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK8graphlab5mutex6unlockEv(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #5 align 2

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

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

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

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


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