; LLVM IR from weicao/cascadb :: src/tree/node.ll (ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE)

; 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.cascadb::Slice" = type <{ ptr, i32, [4 x i8] }>
%"class.__gnu_cxx::__normal_iterator.23" = type { ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.cascadb::DataNode" = type <{ %"class.cascadb::Node", ptr, i32, [4 x i8] }>
%"class.cascadb::Node" = type { ptr, %"class.std::__cxx11::basic_string", i64, %"class.cascadb::Mutex", i8, i8, i8, %struct.timeval, %struct.timeval, i32, i32, %"class.cascadb::RWLock" }
%"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.cascadb::Mutex" = type { i8, %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 }
%struct.timeval = type { i64, i64 }
%"class.cascadb::RWLock" = type { %union.pthread_rwlock_t }
%union.pthread_rwlock_t = type { %struct.__pthread_rwlock_arch_t }
%struct.__pthread_rwlock_arch_t = type { i32, i32, i32, i32, i32, i32, i32, i32, i8, [7 x i8], i64, i32 }
%"class.cascadb::InnerNode" = type { %"class.cascadb::DataNode.base", i8, i64, ptr, %"class.cascadb::Slice", i32, i32, i32, i16, %"class.std::vector", i64, i64, i64 }
%"class.cascadb::DataNode.base" = type <{ %"class.cascadb::Node", ptr, i32 }>
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<cascadb::Pivot, std::allocator<cascadb::Pivot>>::_Vector_impl" }
%"struct.std::_Vector_base<cascadb::Pivot, std::allocator<cascadb::Pivot>>::_Vector_impl" = type { %"struct.std::_Vector_base<cascadb::Pivot, std::allocator<cascadb::Pivot>>::_Vector_impl_data" }
%"struct.std::_Vector_base<cascadb::Pivot, std::allocator<cascadb::Pivot>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.cascadb::Pivot" = type <{ %"class.cascadb::Slice", %"class.cascadb::Slice", i64, ptr, i32, i32, i32, i16, [2 x i8] }>

@.str.1 = external hidden unnamed_addr constant [66 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [7 x i8], align 1
@__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE = external hidden unnamed_addr constant [68 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [25 x i8], align 1

; Function Attrs: nounwind
declare void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104)) unnamed_addr #0

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #1

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

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

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

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

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

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

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #5

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node9set_dirtyEb(ptr noundef nonnull align 8 dereferenceable(200), i1 noundef zeroext) #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb9InnerNode15load_all_msgbufEv(ptr noundef nonnull align 8 dereferenceable(312)) #6 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #7

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200)) #6 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node7dec_refEv(ptr noundef nonnull align 8 dereferenceable(200)) #6 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZN7cascadb9InnerNode10pivot_sizeENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312), ptr, i32) #6 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(312) %0, i64 noundef %1, ptr noundef nonnull align 8 dereferenceable(24) %2) #6 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca i64, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca %"class.cascadb::Slice", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator.23", align 8
  %10 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %11 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %12 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %16 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %17 = alloca %"class.cascadb::Slice", align 8
  %18 = alloca %"class.__gnu_cxx::__normal_iterator.23", align 8
  %19 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store i64 %1, ptr %5, align 8, !tbaa !9
  store ptr %2, ptr %6, align 8, !tbaa !5
  %20 = load ptr, ptr %4, align 8
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  %22 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %21) #9
  %23 = load ptr, ptr %22, align 8, !tbaa !5
  %24 = icmp eq ptr %23, %20
  br i1 %24, label %25, label %26

25:                                               ; preds = %3
  br label %28

26:                                               ; preds = %3
  call void @__assert_fail(ptr noundef @.str.9, ptr noundef @.str.1, i32 noundef 452, ptr noundef @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #10
  unreachable

27:                                               ; No predecessors!
  br label %28

28:                                               ; preds = %27, %25
  %29 = getelementptr inbounds %"class.cascadb::DataNode", ptr %20, i32 0, i32 2
  %30 = load i32, ptr %29, align 8, !tbaa !11
  %31 = icmp eq i32 %30, 2
  br i1 %31, label %32, label %34

32:                                               ; preds = %28
  %33 = call noundef zeroext i1 @_ZN7cascadb9InnerNode15load_all_msgbufEv(ptr noundef nonnull align 8 dereferenceable(312) %20)
  br label %34

34:                                               ; preds = %32, %28
  %35 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 2
  %36 = load i64, ptr %35, align 8, !tbaa !22
  %37 = load i64, ptr %5, align 8, !tbaa !9
  %38 = icmp eq i64 %36, %37
  br i1 %38, label %39, label %117

39:                                               ; preds = %34
  %40 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 3
  %41 = load ptr, ptr %40, align 8, !tbaa !30
  %42 = call noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104) %41)
  %43 = icmp eq i64 %42, 0
  br i1 %43, label %44, label %45

44:                                               ; preds = %39
  br label %47

45:                                               ; preds = %39
  call void @__assert_fail(ptr noundef @.str.14, ptr noundef @.str.1, i32 noundef 460, ptr noundef @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #10
  unreachable

46:                                               ; No predecessors!
  br label %47

47:                                               ; preds = %46, %44
  %48 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 3
  %49 = load ptr, ptr %48, align 8, !tbaa !30
  %50 = call noundef i64 @_ZNK7cascadb6MsgBuf4sizeEv(ptr noundef nonnull align 8 dereferenceable(104) %49)
  %51 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 12
  %52 = load i64, ptr %51, align 8, !tbaa !31
  %53 = sub i64 %52, %50
  store i64 %53, ptr %51, align 8, !tbaa !31
  %54 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 3
  %55 = load ptr, ptr %54, align 8, !tbaa !30
  %56 = icmp eq ptr %55, null
  br i1 %56, label %58, label %57

57:                                               ; preds = %47
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %55) #9
  call void @_ZdlPvm(ptr noundef %55, i64 noundef 104) #11
  br label %58

58:                                               ; preds = %57, %47
  %59 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %60 = call noundef i64 @_ZNKSt6vectorIN7cascadb5PivotESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %59) #9
  %61 = icmp eq i64 %60, 0
  br i1 %61, label %62, label %87

62:                                               ; preds = %58
  %63 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 3
  store ptr null, ptr %63, align 8, !tbaa !30
  %64 = getelementptr inbounds %"class.cascadb::Node", ptr %20, i32 0, i32 5
  store i8 1, ptr %64, align 1, !tbaa !32
  %65 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %65) #9
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %20)
  call void @_ZN7cascadb4Node7dec_refEv(ptr noundef nonnull align 8 dereferenceable(200) %20)
  %66 = load ptr, ptr %6, align 8, !tbaa !5
  %67 = call noundef i64 @_ZNKSt6vectorIPN7cascadb8DataNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %66) #9
  %68 = icmp eq i64 %67, 0
  br i1 %68, label %69, label %72

69:                                               ; preds = %62
  %70 = getelementptr inbounds %"class.cascadb::DataNode", ptr %20, i32 0, i32 1
  %71 = load ptr, ptr %70, align 8, !tbaa !33
  call void @_ZN7cascadb4Tree8collapseEv(ptr noundef nonnull align 8 dereferenceable(184) %71)
  br label %86

72:                                               ; preds = %62
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #9
  %73 = load ptr, ptr %6, align 8, !tbaa !5
  %74 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %73) #9
  %75 = load ptr, ptr %74, align 8, !tbaa !5
  store ptr %75, ptr %7, align 8, !tbaa !5
  %76 = load ptr, ptr %7, align 8, !tbaa !5
  %77 = icmp ne ptr %76, null
  br i1 %77, label %78, label %79

78:                                               ; preds = %72
  br label %81

79:                                               ; preds = %72
  call void @__assert_fail(ptr noundef @.str.13, ptr noundef @.str.1, i32 noundef 478, ptr noundef @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #10
  unreachable

80:                                               ; No predecessors!
  br label %81

81:                                               ; preds = %80, %78
  %82 = load ptr, ptr %7, align 8, !tbaa !5
  %83 = getelementptr inbounds %"class.cascadb::Node", ptr %20, i32 0, i32 2
  %84 = load i64, ptr %83, align 8, !tbaa !34
  %85 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(312) %82, i64 noundef %84, ptr noundef nonnull align 8 dereferenceable(24) %85)
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #9
  br label %86

86:                                               ; preds = %81, %69
  br label %196

87:                                               ; preds = %58
  %88 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %89 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %88, i64 noundef 0) #9
  %90 = getelementptr inbounds %"class.cascadb::Pivot", ptr %89, i32 0, i32 2
  %91 = load i64, ptr %90, align 8, !tbaa !35
  %92 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 2
  store i64 %91, ptr %92, align 8, !tbaa !22
  %93 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %94 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %93, i64 noundef 0) #9
  %95 = getelementptr inbounds %"class.cascadb::Pivot", ptr %94, i32 0, i32 3
  %96 = load ptr, ptr %95, align 8, !tbaa !37
  %97 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 3
  store ptr %96, ptr %97, align 8, !tbaa !30
  %98 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %99 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %98, i64 noundef 0) #9
  %100 = getelementptr inbounds %"class.cascadb::Pivot", ptr %99, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %8, ptr align 8 %100, i64 16, i1 false), !tbaa.struct !38
  %101 = getelementptr inbounds { ptr, i32 }, ptr %8, i32 0, i32 0
  %102 = load ptr, ptr %101, align 8
  %103 = getelementptr inbounds { ptr, i32 }, ptr %8, i32 0, i32 1
  %104 = load i32, ptr %103, align 8
  %105 = call noundef i64 @_ZN7cascadb9InnerNode10pivot_sizeENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312) %20, ptr %102, i32 %104)
  %106 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 10
  %107 = load i64, ptr %106, align 8, !tbaa !40
  %108 = sub i64 %107, %105
  store i64 %108, ptr %106, align 8, !tbaa !40
  %109 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #9
  %110 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %111 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %110) #9
  %112 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %10, i32 0, i32 0
  store ptr %111, ptr %112, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPKN7cascadb5PivotESt6vectorIS2_SaIS2_EEEC2IPS2_vEERKNS0_IT_S7_EE(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #9
  %113 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.23", ptr %9, i32 0, i32 0
  %114 = load ptr, ptr %113, align 8
  %115 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE(ptr noundef nonnull align 8 dereferenceable(24) %109, ptr %114)
  %116 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %11, i32 0, i32 0
  store ptr %115, ptr %116, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #9
  br label %183

117:                                              ; preds = %34
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #9
  call void @_ZN9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #9
  %118 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %119 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %118) #9
  %120 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %13, i32 0, i32 0
  store ptr %119, ptr %120, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %12, ptr align 8 %13, i64 8, i1 false), !tbaa.struct !41
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #9
  br label %121

121:                                              ; preds = %134, %117
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #9
  %122 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %123 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %122) #9
  %124 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  store ptr %123, ptr %124, align 8
  %125 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %14) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  br i1 %125, label %126, label %137

126:                                              ; preds = %121
  %127 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  %128 = getelementptr inbounds %"class.cascadb::Pivot", ptr %127, i32 0, i32 2
  %129 = load i64, ptr %128, align 8, !tbaa !35
  %130 = load i64, ptr %5, align 8, !tbaa !9
  %131 = icmp eq i64 %129, %130
  br i1 %131, label %132, label %133

132:                                              ; preds = %126
  br label %137

133:                                              ; preds = %126
  br label %134

134:                                              ; preds = %133
  %135 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %12, i32 noundef 0) #9
  %136 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %15, i32 0, i32 0
  store ptr %135, ptr %136, align 8
  br label %121, !llvm.loop !42

137:                                              ; preds = %132, %121
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #9
  %138 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  %139 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %138) #9
  %140 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %16, i32 0, i32 0
  store ptr %139, ptr %140, align 8
  %141 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %16) #9
  br i1 %141, label %142, label %143

142:                                              ; preds = %137
  br label %145

143:                                              ; preds = %137
  call void @__assert_fail(ptr noundef @.str.15, ptr noundef @.str.1, i32 noundef 501, ptr noundef @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #10
  unreachable

144:                                              ; No predecessors!
  br label %145

145:                                              ; preds = %144, %142
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #9
  %146 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  %147 = getelementptr inbounds %"class.cascadb::Pivot", ptr %146, i32 0, i32 3
  %148 = load ptr, ptr %147, align 8, !tbaa !37
  %149 = call noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104) %148)
  %150 = icmp eq i64 %149, 0
  br i1 %150, label %151, label %152

151:                                              ; preds = %145
  br label %154

152:                                              ; preds = %145
  call void @__assert_fail(ptr noundef @.str.16, ptr noundef @.str.1, i32 noundef 503, ptr noundef @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #10
  unreachable

153:                                              ; No predecessors!
  br label %154

154:                                              ; preds = %153, %151
  %155 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  %156 = getelementptr inbounds %"class.cascadb::Pivot", ptr %155, i32 0, i32 3
  %157 = load ptr, ptr %156, align 8, !tbaa !37
  %158 = call noundef i64 @_ZNK7cascadb6MsgBuf4sizeEv(ptr noundef nonnull align 8 dereferenceable(104) %157)
  %159 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 12
  %160 = load i64, ptr %159, align 8, !tbaa !31
  %161 = sub i64 %160, %158
  store i64 %161, ptr %159, align 8, !tbaa !31
  %162 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  %163 = getelementptr inbounds %"class.cascadb::Pivot", ptr %162, i32 0, i32 3
  %164 = load ptr, ptr %163, align 8, !tbaa !37
  %165 = icmp eq ptr %164, null
  br i1 %165, label %167, label %166

166:                                              ; preds = %154
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %164) #9
  call void @_ZdlPvm(ptr noundef %164, i64 noundef 104) #11
  br label %167

167:                                              ; preds = %166, %154
  %168 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  %169 = getelementptr inbounds %"class.cascadb::Pivot", ptr %168, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %17, ptr align 8 %169, i64 16, i1 false), !tbaa.struct !38
  %170 = getelementptr inbounds { ptr, i32 }, ptr %17, i32 0, i32 0
  %171 = load ptr, ptr %170, align 8
  %172 = getelementptr inbounds { ptr, i32 }, ptr %17, i32 0, i32 1
  %173 = load i32, ptr %172, align 8
  %174 = call noundef i64 @_ZN7cascadb9InnerNode10pivot_sizeENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312) %20, ptr %171, i32 %173)
  %175 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 10
  %176 = load i64, ptr %175, align 8, !tbaa !40
  %177 = sub i64 %176, %174
  store i64 %177, ptr %175, align 8, !tbaa !40
  %178 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %20, i32 0, i32 9
  call void @_ZN9__gnu_cxx17__normal_iteratorIPKN7cascadb5PivotESt6vectorIS2_SaIS2_EEEC2IPS2_vEERKNS0_IT_S7_EE(ptr noundef nonnull align 8 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(8) %12) #9
  %179 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.23", ptr %18, i32 0, i32 0
  %180 = load ptr, ptr %179, align 8
  %181 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE(ptr noundef nonnull align 8 dereferenceable(24) %178, ptr %180)
  %182 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %19, i32 0, i32 0
  store ptr %181, ptr %182, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #9
  br label %183

183:                                              ; preds = %167, %87
  call void @_ZN7cascadb4Node9set_dirtyEb(ptr noundef nonnull align 8 dereferenceable(200) %20, i1 noundef zeroext true)
  br label %184

184:                                              ; preds = %188, %183
  %185 = load ptr, ptr %6, align 8, !tbaa !5
  %186 = call noundef i64 @_ZNKSt6vectorIPN7cascadb8DataNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %185) #9
  %187 = icmp ne i64 %186, 0
  br i1 %187, label %188, label %196

188:                                              ; preds = %184
  %189 = load ptr, ptr %6, align 8, !tbaa !5
  %190 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %189) #9
  %191 = load ptr, ptr %190, align 8, !tbaa !5
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %191)
  %192 = load ptr, ptr %6, align 8, !tbaa !5
  %193 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %192) #9
  %194 = load ptr, ptr %193, align 8, !tbaa !5
  call void @_ZN7cascadb4Node7dec_refEv(ptr noundef nonnull align 8 dereferenceable(200) %194)
  %195 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %195) #9
  br label %184, !llvm.loop !44

196:                                              ; preds = %184, %86
  ret void
}

declare void @_ZN7cascadb4Tree8collapseEv(ptr noundef nonnull align 8 dereferenceable(184)) #8

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE(ptr noundef nonnull align 8 dereferenceable(24), ptr) #6 align 2

attributes #0 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 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 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress 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 #7 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #8 = { "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 #9 = { nounwind }
attributes #10 = { noreturn nounwind }
attributes #11 = { builtin 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 = !{!"long", !7, i64 0}
!11 = !{!12, !21, i64 208}
!12 = !{!"_ZTSN7cascadb8DataNodeE", !13, i64 0, !6, i64 200, !21, i64 208}
!13 = !{!"_ZTSN7cascadb4NodeE", !14, i64 8, !10, i64 40, !16, i64 48, !17, i64 96, !17, i64 97, !17, i64 98, !18, i64 104, !18, i64 120, !19, i64 136, !19, i64 140, !20, i64 144}
!14 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !15, i64 0, !10, i64 8, !7, i64 16}
!15 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!16 = !{!"_ZTSN7cascadb5MutexE", !17, i64 0, !7, i64 8}
!17 = !{!"bool", !7, i64 0}
!18 = !{!"_ZTS7timeval", !10, i64 0, !10, i64 8}
!19 = !{!"int", !7, i64 0}
!20 = !{!"_ZTSN7cascadb6RWLockE", !7, i64 0}
!21 = !{!"_ZTSN7cascadb10NodeStatusE", !7, i64 0}
!22 = !{!23, !10, i64 216}
!23 = !{!"_ZTSN7cascadb9InnerNodeE", !12, i64 0, !17, i64 212, !10, i64 216, !6, i64 224, !24, i64 232, !19, i64 248, !19, i64 252, !19, i64 256, !25, i64 260, !26, i64 264, !10, i64 288, !10, i64 296, !10, i64 304}
!24 = !{!"_ZTSN7cascadb5SliceE", !6, i64 0, !19, i64 8}
!25 = !{!"short", !7, i64 0}
!26 = !{!"_ZTSSt6vectorIN7cascadb5PivotESaIS1_EE", !27, i64 0}
!27 = !{!"_ZTSSt12_Vector_baseIN7cascadb5PivotESaIS1_EE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseIN7cascadb5PivotESaIS1_EE12_Vector_implE", !29, i64 0}
!29 = !{!"_ZTSNSt12_Vector_baseIN7cascadb5PivotESaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!30 = !{!23, !6, i64 224}
!31 = !{!23, !10, i64 304}
!32 = !{!13, !17, i64 97}
!33 = !{!12, !6, i64 200}
!34 = !{!13, !10, i64 40}
!35 = !{!36, !10, i64 32}
!36 = !{!"_ZTSN7cascadb5PivotE", !24, i64 0, !24, i64 16, !10, i64 32, !6, i64 40, !19, i64 48, !19, i64 52, !19, i64 56, !25, i64 60}
!37 = !{!36, !6, i64 40}
!38 = !{i64 0, i64 8, !5, i64 8, i64 4, !39}
!39 = !{!19, !19, i64 0}
!40 = !{!23, !10, i64 288}
!41 = !{i64 0, i64 8, !5}
!42 = distinct !{!42, !43}
!43 = !{!"llvm.loop.mustprogress"}
!44 = distinct !{!44, !43}


; 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.__gnu_cxx::__normal_iterator.23" = type { ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }

@.str.1 = external hidden unnamed_addr constant [66 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [7 x i8], align 1
@__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE = external hidden unnamed_addr constant [68 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [25 x i8], align 1

; Function Attrs: nounwind
declare void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104)) unnamed_addr #0

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) local_unnamed_addr #1

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

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

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

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

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

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

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #5

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node9set_dirtyEb(ptr noundef nonnull align 8 dereferenceable(200), i1 noundef zeroext) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb9InnerNode15load_all_msgbufEv(ptr noundef nonnull align 8 dereferenceable(312)) local_unnamed_addr #6 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200)) local_unnamed_addr #6 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node7dec_refEv(ptr noundef nonnull align 8 dereferenceable(200)) local_unnamed_addr #6 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZN7cascadb9InnerNode10pivot_sizeENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312), ptr, i32) local_unnamed_addr #6 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(312) %0, i64 noundef %1, ptr noundef nonnull align 8 dereferenceable(24) %2) local_unnamed_addr #6 align 2 {
  %4 = alloca %"class.__gnu_cxx::__normal_iterator.23", align 8
  %5 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %6 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %7 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator.23", align 8
  %10 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %11 = load ptr, ptr %10, align 8, !tbaa !5
  %12 = icmp eq ptr %11, %0
  br i1 %12, label %.lr.ph, label %tailrecurse._crit_edge

tailrecurse._crit_edge:                           ; preds = %tailrecurse, %3
  tail call void @__assert_fail(ptr noundef nonnull @.str.9, ptr noundef nonnull @.str.1, i32 noundef 452, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #9
  unreachable

.lr.ph:                                           ; preds = %3, %tailrecurse
  %.tr2550 = phi i64 [ %53, %tailrecurse ], [ %1, %3 ]
  %.tr49 = phi ptr [ %50, %tailrecurse ], [ %0, %3 ]
  %13 = getelementptr inbounds i8, ptr %.tr49, i64 208
  %14 = load i32, ptr %13, align 8, !tbaa !9
  %15 = icmp eq i32 %14, 2
  br i1 %15, label %16, label %18

16:                                               ; preds = %.lr.ph
  %17 = tail call noundef zeroext i1 @_ZN7cascadb9InnerNode15load_all_msgbufEv(ptr noundef nonnull align 8 dereferenceable(312) %.tr49)
  br label %18

18:                                               ; preds = %16, %.lr.ph
  %19 = getelementptr inbounds i8, ptr %.tr49, i64 216
  %20 = load i64, ptr %19, align 8, !tbaa !21
  %21 = icmp eq i64 %20, %.tr2550
  br i1 %21, label %22, label %73

22:                                               ; preds = %18
  %23 = getelementptr inbounds i8, ptr %.tr49, i64 224
  %24 = load ptr, ptr %23, align 8, !tbaa !29
  %25 = tail call noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104) %24)
  %26 = icmp eq i64 %25, 0
  br i1 %26, label %28, label %27

27:                                               ; preds = %22
  tail call void @__assert_fail(ptr noundef nonnull @.str.14, ptr noundef nonnull @.str.1, i32 noundef 460, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #9
  unreachable

28:                                               ; preds = %22
  %29 = load ptr, ptr %23, align 8, !tbaa !29
  %30 = tail call noundef i64 @_ZNK7cascadb6MsgBuf4sizeEv(ptr noundef nonnull align 8 dereferenceable(104) %29)
  %31 = getelementptr inbounds i8, ptr %.tr49, i64 304
  %32 = load i64, ptr %31, align 8, !tbaa !30
  %33 = sub i64 %32, %30
  store i64 %33, ptr %31, align 8, !tbaa !30
  %34 = load ptr, ptr %23, align 8, !tbaa !29
  %35 = icmp eq ptr %34, null
  br i1 %35, label %37, label %36

36:                                               ; preds = %28
  tail call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %34) #8
  tail call void @_ZdlPvm(ptr noundef nonnull %34, i64 noundef 104) #10
  br label %37

37:                                               ; preds = %36, %28
  %38 = getelementptr inbounds i8, ptr %.tr49, i64 264
  %39 = tail call noundef i64 @_ZNKSt6vectorIN7cascadb5PivotESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %38) #8
  %40 = icmp eq i64 %39, 0
  br i1 %40, label %41, label %57

41:                                               ; preds = %37
  store ptr null, ptr %23, align 8, !tbaa !29
  %42 = getelementptr inbounds i8, ptr %.tr49, i64 97
  store i8 1, ptr %42, align 1, !tbaa !31
  tail call void @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  tail call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %.tr49)
  tail call void @_ZN7cascadb4Node7dec_refEv(ptr noundef nonnull align 8 dereferenceable(200) %.tr49)
  %43 = tail call noundef i64 @_ZNKSt6vectorIPN7cascadb8DataNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %44 = icmp eq i64 %43, 0
  br i1 %44, label %45, label %48

45:                                               ; preds = %41
  %46 = getelementptr inbounds i8, ptr %.tr49, i64 200
  %47 = load ptr, ptr %46, align 8, !tbaa !32
  tail call void @_ZN7cascadb4Tree8collapseEv(ptr noundef nonnull align 8 dereferenceable(184) %47)
  br label %.loopexit

48:                                               ; preds = %41
  %49 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %50 = load ptr, ptr %49, align 8, !tbaa !5
  %.not24 = icmp eq ptr %50, null
  br i1 %.not24, label %51, label %tailrecurse

51:                                               ; preds = %48
  tail call void @__assert_fail(ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.1, i32 noundef 478, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #9
  unreachable

tailrecurse:                                      ; preds = %48
  %52 = getelementptr inbounds i8, ptr %.tr49, i64 40
  %53 = load i64, ptr %52, align 8, !tbaa !33
  %54 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %55 = load ptr, ptr %54, align 8, !tbaa !5
  %56 = icmp eq ptr %55, %50
  br i1 %56, label %.lr.ph, label %tailrecurse._crit_edge

57:                                               ; preds = %37
  %58 = getelementptr inbounds i8, ptr %.tr49, i64 216
  %59 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef 0) #8
  %60 = getelementptr inbounds i8, ptr %59, i64 32
  %61 = load i64, ptr %60, align 8, !tbaa !34
  store i64 %61, ptr %58, align 8, !tbaa !21
  %62 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef 0) #8
  %63 = getelementptr inbounds i8, ptr %62, i64 40
  %64 = load ptr, ptr %63, align 8, !tbaa !36
  store ptr %64, ptr %23, align 8, !tbaa !29
  %65 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef 0) #8
  %.sroa.05.0.copyload = load ptr, ptr %65, align 8, !tbaa !5
  %.sroa.26.0..sroa_idx = getelementptr inbounds i8, ptr %65, i64 8
  %.sroa.26.0.copyload = load i32, ptr %.sroa.26.0..sroa_idx, align 8, !tbaa !37
  %66 = tail call noundef i64 @_ZN7cascadb9InnerNode10pivot_sizeENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312) %.tr49, ptr %.sroa.05.0.copyload, i32 %.sroa.26.0.copyload)
  %67 = getelementptr inbounds i8, ptr %.tr49, i64 288
  %68 = load i64, ptr %67, align 8, !tbaa !38
  %69 = sub i64 %68, %66
  store i64 %69, ptr %67, align 8, !tbaa !38
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #8
  %70 = tail call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %38) #8
  store ptr %70, ptr %5, align 8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPKN7cascadb5PivotESt6vectorIS2_SaIS2_EEEC2IPS2_vEERKNS0_IT_S7_EE(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #8
  %71 = load ptr, ptr %4, align 8
  %72 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE(ptr noundef nonnull align 8 dereferenceable(24) %38, ptr %71)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #8
  br label %117

73:                                               ; preds = %18
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #8
  call void @_ZN9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %74 = getelementptr inbounds i8, ptr %.tr49, i64 264
  %75 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %74) #8
  store ptr %75, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #8
  %76 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %74) #8
  store ptr %76, ptr %7, align 8
  %77 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  br i1 %77, label %.lr.ph51, label %._crit_edge

.lr.ph51:                                         ; preds = %73, %82
  %78 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %79 = getelementptr inbounds i8, ptr %78, i64 32
  %80 = load i64, ptr %79, align 8, !tbaa !34
  %81 = icmp eq i64 %80, %.tr2550
  br i1 %81, label %._crit_edge, label %82

82:                                               ; preds = %.lr.ph51
  %83 = call ptr @_ZN9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEppEi(ptr noundef nonnull align 8 dereferenceable(8) %6, i32 noundef 0) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #8
  %84 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %74) #8
  store ptr %84, ptr %7, align 8
  %85 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  br i1 %85, label %.lr.ph51, label %._crit_edge, !llvm.loop !39

._crit_edge:                                      ; preds = %82, %.lr.ph51, %73
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #8
  %86 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %74) #8
  store ptr %86, ptr %8, align 8
  %87 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %8) #8
  br i1 %87, label %89, label %88

88:                                               ; preds = %._crit_edge
  call void @__assert_fail(ptr noundef nonnull @.str.15, ptr noundef nonnull @.str.1, i32 noundef 501, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #9
  unreachable

89:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #8
  %90 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %91 = getelementptr inbounds i8, ptr %90, i64 40
  %92 = load ptr, ptr %91, align 8, !tbaa !36
  %93 = call noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104) %92)
  %94 = icmp eq i64 %93, 0
  br i1 %94, label %96, label %95

95:                                               ; preds = %89
  call void @__assert_fail(ptr noundef nonnull @.str.16, ptr noundef nonnull @.str.1, i32 noundef 503, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode8rm_pivotEmRSt6vectorIPNS_8DataNodeESaIS3_EE) #9
  unreachable

96:                                               ; preds = %89
  %97 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %98 = getelementptr inbounds i8, ptr %97, i64 40
  %99 = load ptr, ptr %98, align 8, !tbaa !36
  %100 = call noundef i64 @_ZNK7cascadb6MsgBuf4sizeEv(ptr noundef nonnull align 8 dereferenceable(104) %99)
  %101 = getelementptr inbounds i8, ptr %.tr49, i64 304
  %102 = load i64, ptr %101, align 8, !tbaa !30
  %103 = sub i64 %102, %100
  store i64 %103, ptr %101, align 8, !tbaa !30
  %104 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %105 = getelementptr inbounds i8, ptr %104, i64 40
  %106 = load ptr, ptr %105, align 8, !tbaa !36
  %107 = icmp eq ptr %106, null
  br i1 %107, label %109, label %108

108:                                              ; preds = %96
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %106) #8
  call void @_ZdlPvm(ptr noundef nonnull %106, i64 noundef 104) #10
  br label %109

109:                                              ; preds = %108, %96
  %110 = call noundef ptr @_ZNK9__gnu_cxx17__normal_iteratorIPN7cascadb5PivotESt6vectorIS2_SaIS2_EEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %.sroa.01.0.copyload = load ptr, ptr %110, align 8, !tbaa !5
  %.sroa.2.0..sroa_idx = getelementptr inbounds i8, ptr %110, i64 8
  %.sroa.2.0.copyload = load i32, ptr %.sroa.2.0..sroa_idx, align 8, !tbaa !37
  %111 = call noundef i64 @_ZN7cascadb9InnerNode10pivot_sizeENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312) %.tr49, ptr %.sroa.01.0.copyload, i32 %.sroa.2.0.copyload)
  %112 = getelementptr inbounds i8, ptr %.tr49, i64 288
  %113 = load i64, ptr %112, align 8, !tbaa !38
  %114 = sub i64 %113, %111
  store i64 %114, ptr %112, align 8, !tbaa !38
  call void @_ZN9__gnu_cxx17__normal_iteratorIPKN7cascadb5PivotESt6vectorIS2_SaIS2_EEEC2IPS2_vEERKNS0_IT_S7_EE(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %6) #8
  %115 = load ptr, ptr %9, align 8
  %116 = call ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE(ptr noundef nonnull align 8 dereferenceable(24) %74, ptr %115)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #8
  br label %117

117:                                              ; preds = %109, %57
  call void @_ZN7cascadb4Node9set_dirtyEb(ptr noundef nonnull align 8 dereferenceable(200) %.tr49, i1 noundef zeroext true)
  %118 = call noundef i64 @_ZNKSt6vectorIPN7cascadb8DataNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %.not53 = icmp eq i64 %118, 0
  br i1 %.not53, label %.loopexit, label %.lr.ph55

.lr.ph55:                                         ; preds = %117, %.lr.ph55
  %119 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %120 = load ptr, ptr %119, align 8, !tbaa !5
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %120)
  %121 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %122 = load ptr, ptr %121, align 8, !tbaa !5
  call void @_ZN7cascadb4Node7dec_refEv(ptr noundef nonnull align 8 dereferenceable(200) %122)
  call void @_ZNSt6vectorIPN7cascadb8DataNodeESaIS2_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %123 = call noundef i64 @_ZNKSt6vectorIPN7cascadb8DataNodeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %2) #8
  %.not = icmp eq i64 %123, 0
  br i1 %.not, label %.loopexit, label %.lr.ph55, !llvm.loop !41

.loopexit:                                        ; preds = %.lr.ph55, %117, %45
  ret void
}

declare void @_ZN7cascadb4Tree8collapseEv(ptr noundef nonnull align 8 dereferenceable(184)) local_unnamed_addr #7

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE(ptr noundef nonnull align 8 dereferenceable(24), ptr) local_unnamed_addr #6 align 2

attributes #0 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 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 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { mustprogress 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 #7 = { "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 #8 = { nounwind }
attributes #9 = { noreturn nounwind }
attributes #10 = { builtin 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, !20, i64 208}
!10 = !{!"_ZTSN7cascadb8DataNodeE", !11, i64 0, !6, i64 200, !20, i64 208}
!11 = !{!"_ZTSN7cascadb4NodeE", !12, i64 8, !14, i64 40, !15, i64 48, !16, i64 96, !16, i64 97, !16, i64 98, !17, i64 104, !17, i64 120, !18, i64 136, !18, i64 140, !19, i64 144}
!12 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !13, i64 0, !14, i64 8, !7, i64 16}
!13 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!"_ZTSN7cascadb5MutexE", !16, i64 0, !7, i64 8}
!16 = !{!"bool", !7, i64 0}
!17 = !{!"_ZTS7timeval", !14, i64 0, !14, i64 8}
!18 = !{!"int", !7, i64 0}
!19 = !{!"_ZTSN7cascadb6RWLockE", !7, i64 0}
!20 = !{!"_ZTSN7cascadb10NodeStatusE", !7, i64 0}
!21 = !{!22, !14, i64 216}
!22 = !{!"_ZTSN7cascadb9InnerNodeE", !10, i64 0, !16, i64 212, !14, i64 216, !6, i64 224, !23, i64 232, !18, i64 248, !18, i64 252, !18, i64 256, !24, i64 260, !25, i64 264, !14, i64 288, !14, i64 296, !14, i64 304}
!23 = !{!"_ZTSN7cascadb5SliceE", !6, i64 0, !18, i64 8}
!24 = !{!"short", !7, i64 0}
!25 = !{!"_ZTSSt6vectorIN7cascadb5PivotESaIS1_EE", !26, i64 0}
!26 = !{!"_ZTSSt12_Vector_baseIN7cascadb5PivotESaIS1_EE", !27, i64 0}
!27 = !{!"_ZTSNSt12_Vector_baseIN7cascadb5PivotESaIS1_EE12_Vector_implE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseIN7cascadb5PivotESaIS1_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!29 = !{!22, !6, i64 224}
!30 = !{!22, !14, i64 304}
!31 = !{!11, !16, i64 97}
!32 = !{!10, !6, i64 200}
!33 = !{!11, !14, i64 40}
!34 = !{!35, !14, i64 32}
!35 = !{!"_ZTSN7cascadb5PivotE", !23, i64 0, !23, i64 16, !14, i64 32, !6, i64 40, !18, i64 48, !18, i64 52, !18, i64 56, !24, i64 60}
!36 = !{!35, !6, i64 40}
!37 = !{!18, !18, i64 0}
!38 = !{!22, !14, i64 288}
!39 = distinct !{!39, !40}
!40 = !{!"llvm.loop.mustprogress"}
!41 = distinct !{!41, !40}


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