; LLVM IR from BehaviorTree/BehaviorTree.CPP :: src/controls/parallel_node.ll (ZN2BT12ParallelNode4tickEv)

; 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.nonstd::expected_lite::expected" = type { %"class.nonstd::expected_lite::detail::storage_t" }
%"class.nonstd::expected_lite::detail::storage_t" = type { %"class.nonstd::expected_lite::detail::storage_t_impl.base", [7 x i8] }
%"class.nonstd::expected_lite::detail::storage_t_impl.base" = type <{ %union.anon.27, i8 }>
%union.anon.27 = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }
%"struct.std::pair" = type <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"class.BT::ParallelNode" = type <{ %"class.BT::ControlNode", i32, i32, %"class.std::set", i64, i64, i8, [7 x i8] }>
%"class.BT::ControlNode" = type { %"class.BT::TreeNode", %"class.std::vector" }
%"class.BT::TreeNode" = type { ptr, %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.1" }
%"struct.std::_Head_base.1" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<BT::TreeNode *, std::allocator<BT::TreeNode *>>::_Vector_impl" }
%"struct.std::_Vector_base<BT::TreeNode *, std::allocator<BT::TreeNode *>>::_Vector_impl" = type { %"struct.std::_Vector_base<BT::TreeNode *, std::allocator<BT::TreeNode *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<BT::TreeNode *, std::allocator<BT::TreeNode *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }

@_ZN2BT12ParallelNode17THRESHOLD_FAILUREE = external dso_local constant ptr, align 8
@_ZN2BT12ParallelNode17THRESHOLD_SUCCESSE = external dso_local constant ptr, align 8
@.str.12 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [18 x i8], align 1
@_ZTIN2BT12RuntimeErrorE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.15 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [62 x i8], align 1
@_ZTIN2BT10LogicErrorE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.17 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [37 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: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN2BT12ParallelNode4tickEv(ptr noundef nonnull align 8 dereferenceable(113) %0) unnamed_addr #2 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca i32, align 4
  %3 = alloca ptr, align 8
  %4 = alloca %"class.nonstd::expected_lite::expected", align 8
  %5 = alloca %"class.std::__cxx11::basic_string", align 8
  %6 = alloca %"class.std::allocator", align 1
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %"class.nonstd::expected_lite::expected", align 8
  %10 = alloca %"class.std::__cxx11::basic_string", align 8
  %11 = alloca %"class.std::allocator", align 1
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i32, align 4
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca %"struct.std::pair", align 8
  %19 = alloca %"struct.std::pair", align 8
  %20 = alloca i64, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  %21 = load ptr, ptr %3, align 8
  %22 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 6
  %23 = load i8, ptr %22, align 8, !tbaa !9, !range !34, !noundef !35
  %24 = trunc i8 %23 to i1
  br i1 %24, label %25, label %70

25:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 40, ptr %4) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr %5) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %6) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %5, ptr noundef @.str.12, ptr noundef nonnull align 1 dereferenceable(1) %6)
          to label %26 unwind label %34

26:                                               ; preds = %25
  %27 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 1
  invoke void @_ZNK2BT8TreeNode8getInputIiEEN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_RT_(ptr dead_on_unwind writable sret(%"class.nonstd::expected_lite::expected") align 8 %4, ptr noundef nonnull align 8 dereferenceable(16) %21, ptr noundef nonnull align 8 dereferenceable(32) %5, ptr noundef nonnull align 4 dereferenceable(4) %27)
          to label %28 unwind label %38

28:                                               ; preds = %26
  %29 = call noundef zeroext i1 @_ZNK6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(40) %4) #6
  %30 = xor i1 %29, true
  call void @_ZN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %4) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %4) #6
  br i1 %30, label %31, label %47

31:                                               ; preds = %28
  %32 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT12RuntimeErrorC2IJA20_cPKcA18_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %32, ptr noundef nonnull align 1 dereferenceable(20) @.str.13, ptr noundef nonnull align 8 dereferenceable(8) @_ZN2BT12ParallelNode17THRESHOLD_SUCCESSE, ptr noundef nonnull align 1 dereferenceable(18) @.str.14)
          to label %33 unwind label %43

33:                                               ; preds = %31
  call void @__cxa_throw(ptr %32, ptr @_ZTIN2BT12RuntimeErrorE, ptr @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

34:                                               ; preds = %25
  %35 = landingpad { ptr, i32 }
          cleanup
  %36 = extractvalue { ptr, i32 } %35, 0
  store ptr %36, ptr %7, align 8
  %37 = extractvalue { ptr, i32 } %35, 1
  store i32 %37, ptr %8, align 4
  br label %42

38:                                               ; preds = %26
  %39 = landingpad { ptr, i32 }
          cleanup
  %40 = extractvalue { ptr, i32 } %39, 0
  store ptr %40, ptr %7, align 8
  %41 = extractvalue { ptr, i32 } %39, 1
  store i32 %41, ptr %8, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #6
  br label %42

42:                                               ; preds = %38, %34
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %6) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %4) #6
  br label %198

43:                                               ; preds = %31
  %44 = landingpad { ptr, i32 }
          cleanup
  %45 = extractvalue { ptr, i32 } %44, 0
  store ptr %45, ptr %7, align 8
  %46 = extractvalue { ptr, i32 } %44, 1
  store i32 %46, ptr %8, align 4
  call void @__cxa_free_exception(ptr %32) #6
  br label %198

47:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 40, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr %10) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %11) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %10, ptr noundef @.str.15, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %48 unwind label %56

48:                                               ; preds = %47
  %49 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 2
  invoke void @_ZNK2BT8TreeNode8getInputIiEEN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_RT_(ptr dead_on_unwind writable sret(%"class.nonstd::expected_lite::expected") align 8 %9, ptr noundef nonnull align 8 dereferenceable(16) %21, ptr noundef nonnull align 8 dereferenceable(32) %10, ptr noundef nonnull align 4 dereferenceable(4) %49)
          to label %50 unwind label %60

50:                                               ; preds = %48
  %51 = call noundef zeroext i1 @_ZNK6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(40) %9) #6
  %52 = xor i1 %51, true
  call void @_ZN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %9) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %9) #6
  br i1 %52, label %53, label %69

53:                                               ; preds = %50
  %54 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT12RuntimeErrorC2IJA20_cPKcA18_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %54, ptr noundef nonnull align 1 dereferenceable(20) @.str.13, ptr noundef nonnull align 8 dereferenceable(8) @_ZN2BT12ParallelNode17THRESHOLD_FAILUREE, ptr noundef nonnull align 1 dereferenceable(18) @.str.14)
          to label %55 unwind label %65

55:                                               ; preds = %53
  call void @__cxa_throw(ptr %54, ptr @_ZTIN2BT12RuntimeErrorE, ptr @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

56:                                               ; preds = %47
  %57 = landingpad { ptr, i32 }
          cleanup
  %58 = extractvalue { ptr, i32 } %57, 0
  store ptr %58, ptr %7, align 8
  %59 = extractvalue { ptr, i32 } %57, 1
  store i32 %59, ptr %8, align 4
  br label %64

60:                                               ; preds = %48
  %61 = landingpad { ptr, i32 }
          cleanup
  %62 = extractvalue { ptr, i32 } %61, 0
  store ptr %62, ptr %7, align 8
  %63 = extractvalue { ptr, i32 } %61, 1
  store i32 %63, ptr %8, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #6
  br label %64

64:                                               ; preds = %60, %56
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %9) #6
  br label %198

65:                                               ; preds = %53
  %66 = landingpad { ptr, i32 }
          cleanup
  %67 = extractvalue { ptr, i32 } %66, 0
  store ptr %67, ptr %7, align 8
  %68 = extractvalue { ptr, i32 } %66, 1
  store i32 %68, ptr %8, align 4
  call void @__cxa_free_exception(ptr %54) #6
  br label %198

69:                                               ; preds = %50
  br label %70

70:                                               ; preds = %69, %1
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %71 = getelementptr inbounds %"class.BT::ControlNode", ptr %21, i32 0, i32 1
  %72 = call noundef i64 @_ZNKSt6vectorIPN2BT8TreeNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %71) #6
  store i64 %72, ptr %12, align 8, !tbaa !36
  %73 = load i64, ptr %12, align 8, !tbaa !36
  %74 = call noundef i64 @_ZNK2BT12ParallelNode16successThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %21)
  %75 = icmp ult i64 %73, %74
  br i1 %75, label %76, label %83

76:                                               ; preds = %70
  %77 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT10LogicErrorC2IJA62_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %77, ptr noundef nonnull align 1 dereferenceable(62) @.str.16)
          to label %78 unwind label %79

78:                                               ; preds = %76
  call void @__cxa_throw(ptr %77, ptr @_ZTIN2BT10LogicErrorE, ptr @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

79:                                               ; preds = %76
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %7, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %8, align 4
  call void @__cxa_free_exception(ptr %77) #6
  br label %197

83:                                               ; preds = %70
  %84 = load i64, ptr %12, align 8, !tbaa !36
  %85 = call noundef i64 @_ZNK2BT12ParallelNode16failureThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %21)
  %86 = icmp ult i64 %84, %85
  br i1 %86, label %87, label %94

87:                                               ; preds = %83
  %88 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT10LogicErrorC2IJA59_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %88, ptr noundef nonnull align 1 dereferenceable(59) @.str.17)
          to label %89 unwind label %90

89:                                               ; preds = %87
  call void @__cxa_throw(ptr %88, ptr @_ZTIN2BT10LogicErrorE, ptr @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

90:                                               ; preds = %87
  %91 = landingpad { ptr, i32 }
          cleanup
  %92 = extractvalue { ptr, i32 } %91, 0
  store ptr %92, ptr %7, align 8
  %93 = extractvalue { ptr, i32 } %91, 1
  store i32 %93, ptr %8, align 4
  call void @__cxa_free_exception(ptr %88) #6
  br label %197

94:                                               ; preds = %83
  call void @_ZN2BT8TreeNode9setStatusENS_10NodeStatusE(ptr noundef nonnull align 8 dereferenceable(16) %21, i32 noundef 1)
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  store i64 0, ptr %13, align 8, !tbaa !36
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  store i64 0, ptr %14, align 8, !tbaa !36
  br label %95

95:                                               ; preds = %184, %94
  %96 = load i64, ptr %14, align 8, !tbaa !36
  %97 = load i64, ptr %12, align 8, !tbaa !36
  %98 = icmp ult i64 %96, %97
  br i1 %98, label %100, label %99

99:                                               ; preds = %95
  store i32 2, ptr %15, align 4
  br label %187

100:                                              ; preds = %95
  %101 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 3
  %102 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48) %101, ptr noundef nonnull align 8 dereferenceable(8) %14)
  %103 = icmp eq i64 %102, 0
  br i1 %103, label %104, label %149

104:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %105 = getelementptr inbounds %"class.BT::ControlNode", ptr %21, i32 0, i32 1
  %106 = load i64, ptr %14, align 8, !tbaa !36
  %107 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN2BT8TreeNodeESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %105, i64 noundef %106) #6
  %108 = load ptr, ptr %107, align 8, !tbaa !5
  store ptr %108, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  %109 = load ptr, ptr %16, align 8, !tbaa !5
  %110 = load ptr, ptr %109, align 8, !tbaa !37
  %111 = getelementptr inbounds ptr, ptr %110, i64 2
  %112 = load ptr, ptr %111, align 8
  %113 = call noundef i32 %112(ptr noundef nonnull align 8 dereferenceable(16) %109)
  store i32 %113, ptr %17, align 4, !tbaa !39
  %114 = load i32, ptr %17, align 4, !tbaa !39
  switch i32 %114, label %148 [
    i32 4, label %115
    i32 2, label %118
    i32 3, label %128
    i32 1, label %138
    i32 0, label %139
  ]

115:                                              ; preds = %104
  %116 = load i64, ptr %13, align 8, !tbaa !36
  %117 = add i64 %116, 1
  store i64 %117, ptr %13, align 8, !tbaa !36
  br label %148

118:                                              ; preds = %104
  %119 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 3
  %120 = call { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %119, ptr noundef nonnull align 8 dereferenceable(8) %14)
  %121 = getelementptr inbounds { ptr, i8 }, ptr %18, i32 0, i32 0
  %122 = extractvalue { ptr, i8 } %120, 0
  store ptr %122, ptr %121, align 8
  %123 = getelementptr inbounds { ptr, i8 }, ptr %18, i32 0, i32 1
  %124 = extractvalue { ptr, i8 } %120, 1
  store i8 %124, ptr %123, align 8
  %125 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 4
  %126 = load i64, ptr %125, align 8, !tbaa !41
  %127 = add i64 %126, 1
  store i64 %127, ptr %125, align 8, !tbaa !41
  br label %148

128:                                              ; preds = %104
  %129 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 3
  %130 = call { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %129, ptr noundef nonnull align 8 dereferenceable(8) %14)
  %131 = getelementptr inbounds { ptr, i8 }, ptr %19, i32 0, i32 0
  %132 = extractvalue { ptr, i8 } %130, 0
  store ptr %132, ptr %131, align 8
  %133 = getelementptr inbounds { ptr, i8 }, ptr %19, i32 0, i32 1
  %134 = extractvalue { ptr, i8 } %130, 1
  store i8 %134, ptr %133, align 8
  %135 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 5
  %136 = load i64, ptr %135, align 8, !tbaa !42
  %137 = add i64 %136, 1
  store i64 %137, ptr %135, align 8, !tbaa !42
  br label %148

138:                                              ; preds = %104
  br label %148

139:                                              ; preds = %104
  %140 = call ptr @__cxa_allocate_exception(i64 40) #6
  %141 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNK2BT8TreeNode4nameB5cxx11Ev(ptr noundef nonnull align 8 dereferenceable(16) %21)
          to label %142 unwind label %144

142:                                              ; preds = %139
  invoke void @_ZN2BT10LogicErrorC2IJA2_cNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEA37_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %140, ptr noundef nonnull align 1 dereferenceable(2) @.str.18, ptr noundef nonnull align 8 dereferenceable(32) %141, ptr noundef nonnull align 1 dereferenceable(37) @.str.19)
          to label %143 unwind label %144

143:                                              ; preds = %142
  call void @__cxa_throw(ptr %140, ptr @_ZTIN2BT10LogicErrorE, ptr @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

144:                                              ; preds = %142, %139
  %145 = landingpad { ptr, i32 }
          cleanup
  %146 = extractvalue { ptr, i32 } %145, 0
  store ptr %146, ptr %7, align 8
  %147 = extractvalue { ptr, i32 } %145, 1
  store i32 %147, ptr %8, align 4
  call void @__cxa_free_exception(ptr %140) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  br label %197

148:                                              ; preds = %138, %128, %118, %115, %104
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %149

149:                                              ; preds = %148, %100
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  %150 = call noundef i64 @_ZNK2BT12ParallelNode16successThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %21)
  store i64 %150, ptr %20, align 8, !tbaa !36
  %151 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 4
  %152 = load i64, ptr %151, align 8, !tbaa !41
  %153 = load i64, ptr %20, align 8, !tbaa !36
  %154 = icmp uge i64 %152, %153
  br i1 %154, label %166, label %155

155:                                              ; preds = %149
  %156 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 1
  %157 = load i32, ptr %156, align 8, !tbaa !43
  %158 = icmp slt i32 %157, 0
  br i1 %158, label %159, label %167

159:                                              ; preds = %155
  %160 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 4
  %161 = load i64, ptr %160, align 8, !tbaa !41
  %162 = load i64, ptr %13, align 8, !tbaa !36
  %163 = add i64 %161, %162
  %164 = load i64, ptr %20, align 8, !tbaa !36
  %165 = icmp uge i64 %163, %164
  br i1 %165, label %166, label %167

166:                                              ; preds = %159, %149
  call void @_ZN2BT12ParallelNode5clearEv(ptr noundef nonnull align 8 dereferenceable(113) %21)
  call void @_ZN2BT11ControlNode13resetChildrenEv(ptr noundef nonnull align 8 dereferenceable(40) %21)
  store i32 2, ptr %2, align 4
  store i32 1, ptr %15, align 4
  br label %181

167:                                              ; preds = %159, %155
  %168 = load i64, ptr %12, align 8, !tbaa !36
  %169 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 5
  %170 = load i64, ptr %169, align 8, !tbaa !42
  %171 = sub i64 %168, %170
  %172 = load i64, ptr %20, align 8, !tbaa !36
  %173 = icmp ult i64 %171, %172
  br i1 %173, label %179, label %174

174:                                              ; preds = %167
  %175 = getelementptr inbounds %"class.BT::ParallelNode", ptr %21, i32 0, i32 5
  %176 = load i64, ptr %175, align 8, !tbaa !42
  %177 = call noundef i64 @_ZNK2BT12ParallelNode16failureThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %21)
  %178 = icmp eq i64 %176, %177
  br i1 %178, label %179, label %180

179:                                              ; preds = %174, %167
  call void @_ZN2BT12ParallelNode5clearEv(ptr noundef nonnull align 8 dereferenceable(113) %21)
  call void @_ZN2BT11ControlNode13resetChildrenEv(ptr noundef nonnull align 8 dereferenceable(40) %21)
  store i32 3, ptr %2, align 4
  store i32 1, ptr %15, align 4
  br label %181

180:                                              ; preds = %174
  store i32 0, ptr %15, align 4
  br label %181

181:                                              ; preds = %180, %179, %166
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  %182 = load i32, ptr %15, align 4
  switch i32 %182, label %187 [
    i32 0, label %183
  ]

183:                                              ; preds = %181
  br label %184

184:                                              ; preds = %183
  %185 = load i64, ptr %14, align 8, !tbaa !36
  %186 = add i64 %185, 1
  store i64 %186, ptr %14, align 8, !tbaa !36
  br label %95, !llvm.loop !44

187:                                              ; preds = %181, %99
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  %188 = load i32, ptr %15, align 4
  switch i32 %188, label %195 [
    i32 2, label %189
  ]

189:                                              ; preds = %187
  %190 = load i64, ptr %13, align 8, !tbaa !36
  %191 = load i64, ptr %12, align 8, !tbaa !36
  %192 = icmp eq i64 %190, %191
  %193 = zext i1 %192 to i64
  %194 = select i1 %192, i32 4, i32 1
  store i32 %194, ptr %2, align 4
  store i32 1, ptr %15, align 4
  br label %195

195:                                              ; preds = %189, %187
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  %196 = load i32, ptr %2, align 4
  ret i32 %196

197:                                              ; preds = %144, %90, %79
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  br label %198

198:                                              ; preds = %197, %65, %64, %43, %42
  %199 = load ptr, ptr %7, align 8
  %200 = load i32, ptr %8, align 4
  %201 = insertvalue { ptr, i32 } poison, ptr %199, 0
  %202 = insertvalue { ptr, i32 } %201, i32 %200, 1
  resume { ptr, i32 } %202
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK2BT8TreeNode8getInputIiEEN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_RT_(ptr dead_on_unwind noalias writable sret(%"class.nonstd::expected_lite::expected") align 8, ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 4 dereferenceable(4)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(40)) #1 align 2

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

declare ptr @__cxa_allocate_exception(i64)

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT12RuntimeErrorC2IJA20_cPKcA18_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(20), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 1 dereferenceable(18)) unnamed_addr #2 align 2

declare void @__cxa_free_exception(ptr)

declare void @__cxa_throw(ptr, ptr, ptr)

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK2BT12ParallelNode16successThresholdEv(ptr noundef nonnull align 8 dereferenceable(113)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT10LogicErrorC2IJA62_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(62)) unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK2BT12ParallelNode16failureThresholdEv(ptr noundef nonnull align 8 dereferenceable(113)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT10LogicErrorC2IJA59_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(59)) unnamed_addr #2 align 2

declare void @_ZN2BT8TreeNode9setStatusENS_10NodeStatusE(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) #5

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

declare noundef nonnull align 8 dereferenceable(32) ptr @_ZNK2BT8TreeNode4nameB5cxx11Ev(ptr noundef nonnull align 8 dereferenceable(16)) #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT10LogicErrorC2IJA2_cNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEA37_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(2), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 1 dereferenceable(37)) unnamed_addr #2 align 2

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

declare void @_ZN2BT11ControlNode13resetChildrenEv(ptr noundef nonnull align 8 dereferenceable(40)) #5

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

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 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 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 = { "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 }
attributes #7 = { noreturn }

!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, !33, i64 112}
!10 = !{!"_ZTSN2BT12ParallelNodeE", !11, i64 0, !23, i64 40, !23, i64 44, !24, i64 48, !32, i64 96, !32, i64 104, !33, i64 112}
!11 = !{!"_ZTSN2BT11ControlNodeE", !12, i64 0, !19, i64 16}
!12 = !{!"_ZTSN2BT8TreeNodeE", !13, i64 8}
!13 = !{!"_ZTSSt10unique_ptrIN2BT8TreeNode5PImplESt14default_deleteIS2_EE", !14, i64 0}
!14 = !{!"_ZTSSt15__uniq_ptr_dataIN2BT8TreeNode5PImplESt14default_deleteIS2_ELb1ELb1EE", !15, i64 0}
!15 = !{!"_ZTSSt15__uniq_ptr_implIN2BT8TreeNode5PImplESt14default_deleteIS2_EE", !16, i64 0}
!16 = !{!"_ZTSSt5tupleIJPN2BT8TreeNode5PImplESt14default_deleteIS2_EEE", !17, i64 0}
!17 = !{!"_ZTSSt11_Tuple_implILm0EJPN2BT8TreeNode5PImplESt14default_deleteIS2_EEE", !18, i64 0}
!18 = !{!"_ZTSSt10_Head_baseILm0EPN2BT8TreeNode5PImplELb0EE", !6, i64 0}
!19 = !{!"_ZTSSt6vectorIPN2BT8TreeNodeESaIS2_EE", !20, i64 0}
!20 = !{!"_ZTSSt12_Vector_baseIPN2BT8TreeNodeESaIS2_EE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIPN2BT8TreeNodeESaIS2_EE12_Vector_implE", !22, i64 0}
!22 = !{!"_ZTSNSt12_Vector_baseIPN2BT8TreeNodeESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!23 = !{!"int", !7, i64 0}
!24 = !{!"_ZTSSt3setImSt4lessImESaImEE", !25, i64 0}
!25 = !{!"_ZTSSt8_Rb_treeImmSt9_IdentityImESt4lessImESaImEE", !26, i64 0}
!26 = !{!"_ZTSNSt8_Rb_treeImmSt9_IdentityImESt4lessImESaImEE13_Rb_tree_implIS3_Lb1EEE", !27, i64 0, !29, i64 8}
!27 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessImEE", !28, i64 0}
!28 = !{!"_ZTSSt4lessImE"}
!29 = !{!"_ZTSSt15_Rb_tree_header", !30, i64 0, !32, i64 32}
!30 = !{!"_ZTSSt18_Rb_tree_node_base", !31, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!31 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!32 = !{!"long", !7, i64 0}
!33 = !{!"bool", !7, i64 0}
!34 = !{i8 0, i8 2}
!35 = !{}
!36 = !{!32, !32, i64 0}
!37 = !{!38, !38, i64 0}
!38 = !{!"vtable pointer", !8, i64 0}
!39 = !{!40, !40, i64 0}
!40 = !{!"_ZTSN2BT10NodeStatusE", !7, i64 0}
!41 = !{!10, !32, i64 96}
!42 = !{!10, !32, i64 104}
!43 = !{!10, !23, i64 40}
!44 = distinct !{!44, !45}
!45 = !{!"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.nonstd::expected_lite::expected" = type { %"class.nonstd::expected_lite::detail::storage_t" }
%"class.nonstd::expected_lite::detail::storage_t" = type { %"class.nonstd::expected_lite::detail::storage_t_impl.base", [7 x i8] }
%"class.nonstd::expected_lite::detail::storage_t_impl.base" = type <{ %union.anon.27, i8 }>
%union.anon.27 = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@_ZN2BT12ParallelNode17THRESHOLD_FAILUREE = external dso_local constant ptr, align 8
@_ZN2BT12ParallelNode17THRESHOLD_SUCCESSE = external dso_local constant ptr, align 8
@.str.12 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [18 x i8], align 1
@_ZTIN2BT12RuntimeErrorE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.15 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [62 x i8], align 1
@_ZTIN2BT10LogicErrorE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.17 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [37 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 nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN2BT12ParallelNode4tickEv(ptr noundef nonnull align 8 dereferenceable(113) %0) unnamed_addr #2 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"class.nonstd::expected_lite::expected", align 8
  %3 = alloca %"class.std::__cxx11::basic_string", align 8
  %4 = alloca %"class.std::allocator", align 1
  %5 = alloca %"class.nonstd::expected_lite::expected", align 8
  %6 = alloca %"class.std::__cxx11::basic_string", align 8
  %7 = alloca %"class.std::allocator", align 1
  %8 = alloca i64, align 8
  %9 = getelementptr inbounds i8, ptr %0, i64 112
  %10 = load i8, ptr %9, align 8, !tbaa !5, !range !33, !noundef !34
  %11 = trunc nuw i8 %10 to i1
  br i1 %11, label %12, label %42

12:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %4) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %3, ptr noundef nonnull @.str.12, ptr noundef nonnull align 1 dereferenceable(1) %4)
          to label %13 unwind label %20

13:                                               ; preds = %12
  %14 = getelementptr inbounds i8, ptr %0, i64 40
  invoke void @_ZNK2BT8TreeNode8getInputIiEEN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_RT_(ptr dead_on_unwind nonnull writable sret(%"class.nonstd::expected_lite::expected") align 8 %2, ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef nonnull align 8 dereferenceable(32) %3, ptr noundef nonnull align 4 dereferenceable(4) %14)
          to label %15 unwind label %22

15:                                               ; preds = %13
  %16 = call noundef zeroext i1 @_ZNK6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(40) %2) #6
  call void @_ZN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %2) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %3) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %2) #6
  br i1 %16, label %27, label %17

17:                                               ; preds = %15
  %18 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT12RuntimeErrorC2IJA20_cPKcA18_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %18, ptr noundef nonnull align 1 dereferenceable(20) @.str.13, ptr noundef nonnull align 8 dereferenceable(8) @_ZN2BT12ParallelNode17THRESHOLD_SUCCESSE, ptr noundef nonnull align 1 dereferenceable(18) @.str.14)
          to label %19 unwind label %25

19:                                               ; preds = %17
  call void @__cxa_throw(ptr nonnull %18, ptr nonnull @_ZTIN2BT12RuntimeErrorE, ptr nonnull @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

20:                                               ; preds = %12
  %21 = landingpad { ptr, i32 }
          cleanup
  br label %24

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

24:                                               ; preds = %22, %20
  %.pn = phi { ptr, i32 } [ %23, %22 ], [ %21, %20 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %4) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %2) #6
  br label %115

25:                                               ; preds = %17
  %26 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %18) #6
  br label %115

27:                                               ; preds = %15
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %7) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %6, ptr noundef nonnull @.str.15, ptr noundef nonnull align 1 dereferenceable(1) %7)
          to label %28 unwind label %35

28:                                               ; preds = %27
  %29 = getelementptr inbounds i8, ptr %0, i64 44
  invoke void @_ZNK2BT8TreeNode8getInputIiEEN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_RT_(ptr dead_on_unwind nonnull writable sret(%"class.nonstd::expected_lite::expected") align 8 %5, ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef nonnull align 8 dereferenceable(32) %6, ptr noundef nonnull align 4 dereferenceable(4) %29)
          to label %30 unwind label %37

30:                                               ; preds = %28
  %31 = call noundef zeroext i1 @_ZNK6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(40) %5) #6
  call void @_ZN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEED2Ev(ptr noundef nonnull align 8 dereferenceable(40) %5) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  br i1 %31, label %42, label %32

32:                                               ; preds = %30
  %33 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT12RuntimeErrorC2IJA20_cPKcA18_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %33, ptr noundef nonnull align 1 dereferenceable(20) @.str.13, ptr noundef nonnull align 8 dereferenceable(8) @_ZN2BT12ParallelNode17THRESHOLD_FAILUREE, ptr noundef nonnull align 1 dereferenceable(18) @.str.14)
          to label %34 unwind label %40

34:                                               ; preds = %32
  call void @__cxa_throw(ptr nonnull %33, ptr nonnull @_ZTIN2BT12RuntimeErrorE, ptr nonnull @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

35:                                               ; preds = %27
  %36 = landingpad { ptr, i32 }
          cleanup
  br label %39

37:                                               ; preds = %28
  %38 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #6
  br label %39

39:                                               ; preds = %37, %35
  %.pn39 = phi { ptr, i32 } [ %38, %37 ], [ %36, %35 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  br label %115

40:                                               ; preds = %32
  %41 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %33) #6
  br label %115

42:                                               ; preds = %30, %1
  %43 = getelementptr inbounds i8, ptr %0, i64 16
  %44 = call noundef i64 @_ZNKSt6vectorIPN2BT8TreeNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %43) #6
  %45 = call noundef i64 @_ZNK2BT12ParallelNode16successThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %0)
  %46 = icmp ult i64 %44, %45
  br i1 %46, label %47, label %52

47:                                               ; preds = %42
  %48 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT10LogicErrorC2IJA62_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %48, ptr noundef nonnull align 1 dereferenceable(62) @.str.16)
          to label %49 unwind label %50

49:                                               ; preds = %47
  call void @__cxa_throw(ptr nonnull %48, ptr nonnull @_ZTIN2BT10LogicErrorE, ptr nonnull @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

50:                                               ; preds = %47
  %51 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %48) #6
  br label %115

52:                                               ; preds = %42
  %53 = call noundef i64 @_ZNK2BT12ParallelNode16failureThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %0)
  %54 = icmp ult i64 %44, %53
  br i1 %54, label %55, label %60

55:                                               ; preds = %52
  %56 = call ptr @__cxa_allocate_exception(i64 40) #6
  invoke void @_ZN2BT10LogicErrorC2IJA59_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %56, ptr noundef nonnull align 1 dereferenceable(59) @.str.17)
          to label %57 unwind label %58

57:                                               ; preds = %55
  call void @__cxa_throw(ptr nonnull %56, ptr nonnull @_ZTIN2BT10LogicErrorE, ptr nonnull @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

58:                                               ; preds = %55
  %59 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %56) #6
  br label %115

60:                                               ; preds = %52
  call void @_ZN2BT8TreeNode9setStatusENS_10NodeStatusE(ptr noundef nonnull align 8 dereferenceable(16) %0, i32 noundef 1)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #6
  store i64 0, ptr %8, align 8, !tbaa !35
  %.not4257.not = icmp eq i64 %44, 0
  br i1 %.not4257.not, label %.thread, label %.lr.ph

.lr.ph:                                           ; preds = %60
  %61 = getelementptr inbounds i8, ptr %0, i64 48
  %62 = getelementptr inbounds i8, ptr %0, i64 104
  %63 = getelementptr inbounds i8, ptr %0, i64 96
  %64 = getelementptr inbounds i8, ptr %0, i64 40
  br label %65

65:                                               ; preds = %.lr.ph, %107
  %.02958 = phi i64 [ 0, %.lr.ph ], [ %.231, %107 ]
  %66 = call noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48) %61, ptr noundef nonnull align 8 dereferenceable(8) %8)
  %67 = icmp eq i64 %66, 0
  br i1 %67, label %68, label %93

68:                                               ; preds = %65
  %69 = load i64, ptr %8, align 8, !tbaa !35
  %70 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN2BT8TreeNodeESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %43, i64 noundef %69) #6
  %71 = load ptr, ptr %70, align 8, !tbaa !36
  %72 = load ptr, ptr %71, align 8, !tbaa !37
  %73 = getelementptr inbounds i8, ptr %72, i64 16
  %74 = load ptr, ptr %73, align 8
  %75 = call noundef i32 %74(ptr noundef nonnull align 8 dereferenceable(16) %71)
  switch i32 %75, label %93 [
    i32 4, label %76
    i32 2, label %78
    i32 3, label %82
    i32 0, label %86
  ]

76:                                               ; preds = %68
  %77 = add i64 %.02958, 1
  br label %93

78:                                               ; preds = %68
  %79 = call { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %61, ptr noundef nonnull align 8 dereferenceable(8) %8)
  %80 = load i64, ptr %63, align 8, !tbaa !39
  %81 = add i64 %80, 1
  store i64 %81, ptr %63, align 8, !tbaa !39
  br label %93

82:                                               ; preds = %68
  %83 = call { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %61, ptr noundef nonnull align 8 dereferenceable(8) %8)
  %84 = load i64, ptr %62, align 8, !tbaa !40
  %85 = add i64 %84, 1
  store i64 %85, ptr %62, align 8, !tbaa !40
  br label %93

86:                                               ; preds = %68
  %87 = call ptr @__cxa_allocate_exception(i64 40) #6
  %88 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNK2BT8TreeNode4nameB5cxx11Ev(ptr noundef nonnull align 8 dereferenceable(16) %0)
          to label %89 unwind label %91

89:                                               ; preds = %86
  invoke void @_ZN2BT10LogicErrorC2IJA2_cNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEA37_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40) %87, ptr noundef nonnull align 1 dereferenceable(2) @.str.18, ptr noundef nonnull align 8 dereferenceable(32) %88, ptr noundef nonnull align 1 dereferenceable(37) @.str.19)
          to label %90 unwind label %91

90:                                               ; preds = %89
  call void @__cxa_throw(ptr nonnull %87, ptr nonnull @_ZTIN2BT10LogicErrorE, ptr nonnull @_ZN2BT21BehaviorTreeExceptionD2Ev) #7
  unreachable

91:                                               ; preds = %89, %86
  %92 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %87) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  br label %115

93:                                               ; preds = %68, %76, %78, %82, %65
  %.231 = phi i64 [ %.02958, %65 ], [ %.02958, %68 ], [ %.02958, %82 ], [ %.02958, %78 ], [ %77, %76 ]
  %94 = call noundef i64 @_ZNK2BT12ParallelNode16successThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %0)
  %95 = load i64, ptr %63, align 8, !tbaa !39
  %.not = icmp ult i64 %95, %94
  br i1 %.not, label %96, label %112

96:                                               ; preds = %93
  %97 = load i32, ptr %64, align 8, !tbaa !41
  %98 = icmp sgt i32 %97, -1
  %99 = add i64 %95, %.231
  %.not41 = icmp ult i64 %99, %94
  %or.cond = select i1 %98, i1 true, i1 %.not41
  br i1 %or.cond, label %100, label %112

100:                                              ; preds = %96
  %101 = load i64, ptr %62, align 8, !tbaa !40
  %102 = sub i64 %44, %101
  %103 = icmp ult i64 %102, %94
  br i1 %103, label %112, label %104

104:                                              ; preds = %100
  %105 = call noundef i64 @_ZNK2BT12ParallelNode16failureThresholdEv(ptr noundef nonnull align 8 dereferenceable(113) %0)
  %106 = icmp eq i64 %101, %105
  br i1 %106, label %112, label %107

107:                                              ; preds = %104
  %108 = load i64, ptr %8, align 8, !tbaa !35
  %109 = add i64 %108, 1
  store i64 %109, ptr %8, align 8, !tbaa !35
  %.not42 = icmp ult i64 %109, %44
  br i1 %.not42, label %65, label %.thread, !llvm.loop !42

.thread:                                          ; preds = %107, %60
  %.332 = phi i64 [ 0, %60 ], [ %.231, %107 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  %110 = icmp eq i64 %.332, %44
  %111 = select i1 %110, i32 4, i32 1
  br label %113

112:                                              ; preds = %100, %104, %93, %96
  %.2.ph = phi i32 [ 2, %96 ], [ 2, %93 ], [ 3, %104 ], [ 3, %100 ]
  call void @_ZN2BT12ParallelNode5clearEv(ptr noundef nonnull align 8 dereferenceable(113) %0)
  call void @_ZN2BT11ControlNode13resetChildrenEv(ptr noundef nonnull align 8 dereferenceable(40) %0)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  br label %113

113:                                              ; preds = %.thread, %112
  %114 = phi i32 [ %.2.ph, %112 ], [ %111, %.thread ]
  ret i32 %114

115:                                              ; preds = %50, %58, %91, %40, %39, %25, %24
  %.pn45 = phi { ptr, i32 } [ %26, %25 ], [ %41, %40 ], [ %.pn39, %39 ], [ %.pn, %24 ], [ %51, %50 ], [ %59, %58 ], [ %92, %91 ]
  resume { ptr, i32 } %.pn45
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK2BT8TreeNode8getInputIiEEN6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_RT_(ptr dead_on_unwind noalias writable sret(%"class.nonstd::expected_lite::expected") align 8, ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK6nonstd13expected_lite8expectedISt9monostateNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #1 align 2

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

declare ptr @__cxa_allocate_exception(i64) local_unnamed_addr

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT12RuntimeErrorC2IJA20_cPKcA18_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(20), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 1 dereferenceable(18)) unnamed_addr #2 align 2

declare void @__cxa_free_exception(ptr) local_unnamed_addr

declare void @__cxa_throw(ptr, ptr, ptr) local_unnamed_addr

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIPN2BT8TreeNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK2BT12ParallelNode16successThresholdEv(ptr noundef nonnull align 8 dereferenceable(113)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT10LogicErrorC2IJA62_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(62)) unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK2BT12ParallelNode16failureThresholdEv(ptr noundef nonnull align 8 dereferenceable(113)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT10LogicErrorC2IJA59_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(59)) unnamed_addr #2 align 2

declare void @_ZN2BT8TreeNode9setStatusENS_10NodeStatusE(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNKSt3setImSt4lessImESaImEE5countERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

declare noundef nonnull align 8 dereferenceable(32) ptr @_ZNK2BT8TreeNode4nameB5cxx11Ev(ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN2BT10LogicErrorC2IJA2_cNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEA37_cEEEDpRKT_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef nonnull align 1 dereferenceable(2), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 1 dereferenceable(37)) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2BT12ParallelNode5clearEv(ptr noundef nonnull align 8 dereferenceable(113)) local_unnamed_addr #1 align 2

declare void @_ZN2BT11ControlNode13resetChildrenEv(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #5

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

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 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 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 = { "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 }
attributes #7 = { noreturn }

!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, !32, i64 112}
!6 = !{!"_ZTSN2BT12ParallelNodeE", !7, i64 0, !22, i64 40, !22, i64 44, !23, i64 48, !31, i64 96, !31, i64 104, !32, i64 112}
!7 = !{!"_ZTSN2BT11ControlNodeE", !8, i64 0, !18, i64 16}
!8 = !{!"_ZTSN2BT8TreeNodeE", !9, i64 8}
!9 = !{!"_ZTSSt10unique_ptrIN2BT8TreeNode5PImplESt14default_deleteIS2_EE", !10, i64 0}
!10 = !{!"_ZTSSt15__uniq_ptr_dataIN2BT8TreeNode5PImplESt14default_deleteIS2_ELb1ELb1EE", !11, i64 0}
!11 = !{!"_ZTSSt15__uniq_ptr_implIN2BT8TreeNode5PImplESt14default_deleteIS2_EE", !12, i64 0}
!12 = !{!"_ZTSSt5tupleIJPN2BT8TreeNode5PImplESt14default_deleteIS2_EEE", !13, i64 0}
!13 = !{!"_ZTSSt11_Tuple_implILm0EJPN2BT8TreeNode5PImplESt14default_deleteIS2_EEE", !14, i64 0}
!14 = !{!"_ZTSSt10_Head_baseILm0EPN2BT8TreeNode5PImplELb0EE", !15, i64 0}
!15 = !{!"any pointer", !16, i64 0}
!16 = !{!"omnipotent char", !17, i64 0}
!17 = !{!"Simple C++ TBAA"}
!18 = !{!"_ZTSSt6vectorIPN2BT8TreeNodeESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseIPN2BT8TreeNodeESaIS2_EE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIPN2BT8TreeNodeESaIS2_EE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIPN2BT8TreeNodeESaIS2_EE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!22 = !{!"int", !16, i64 0}
!23 = !{!"_ZTSSt3setImSt4lessImESaImEE", !24, i64 0}
!24 = !{!"_ZTSSt8_Rb_treeImmSt9_IdentityImESt4lessImESaImEE", !25, i64 0}
!25 = !{!"_ZTSNSt8_Rb_treeImmSt9_IdentityImESt4lessImESaImEE13_Rb_tree_implIS3_Lb1EEE", !26, i64 0, !28, i64 8}
!26 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessImEE", !27, i64 0}
!27 = !{!"_ZTSSt4lessImE"}
!28 = !{!"_ZTSSt15_Rb_tree_header", !29, i64 0, !31, i64 32}
!29 = !{!"_ZTSSt18_Rb_tree_node_base", !30, i64 0, !15, i64 8, !15, i64 16, !15, i64 24}
!30 = !{!"_ZTSSt14_Rb_tree_color", !16, i64 0}
!31 = !{!"long", !16, i64 0}
!32 = !{!"bool", !16, i64 0}
!33 = !{i8 0, i8 2}
!34 = !{}
!35 = !{!31, !31, i64 0}
!36 = !{!15, !15, i64 0}
!37 = !{!38, !38, i64 0}
!38 = !{!"vtable pointer", !17, i64 0}
!39 = !{!6, !31, i64 96}
!40 = !{!6, !31, i64 104}
!41 = !{!6, !22, i64 40}
!42 = distinct !{!42, !43}
!43 = !{!"llvm.loop.mustprogress"}


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