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

; 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::LoggerFormat" = type { ptr, %"class.std::__cxx11::basic_ostringstream" }
%"class.std::__cxx11::basic_ostringstream" = type { %"class.std::basic_ostream.base", %"class.std::__cxx11::basic_stringbuf", %"class.std::basic_ios" }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.cascadb::BlockReader" = type { ptr, i64 }
%"class.cascadb::Slice" = type <{ ptr, i32, [4 x i8] }>
%"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.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.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.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] }>
%"class.cascadb::DataNode" = type <{ %"class.cascadb::Node", ptr, i32, [4 x i8] }>
%"class.cascadb::Tree" = type { %"class.std::__cxx11::basic_string", %"class.cascadb::Options", ptr, ptr, ptr, ptr, ptr, ptr }
%"class.cascadb::Options" = type <{ ptr, ptr, i64, i64, i64, i64, i64, i64, i64, i32, i32, i32, i32, i32, i32, i32, i8, [3 x i8] }>

@.str.1 = external hidden unnamed_addr constant [66 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [2 x i8], align 1
@_ZN7cascadb14g_logger_levelE = external global i32, align 4
@_ZN7cascadb8g_loggerE = external global ptr, align 8
@.str.19 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [14 x i8], align 1
@__PRETTY_FUNCTION__._ZN7cascadb9InnerNode11load_msgbufEi = external hidden unnamed_addr constant [42 x i8], align 1
@.str.29 = external hidden unnamed_addr constant [19 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: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #2

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) #5

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node9read_lockEv(ptr noundef nonnull align 8 dereferenceable(200)) #3 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)) #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200)) #3 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) #6 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN7cascadb9InnerNode11load_msgbufEi(ptr noundef nonnull align 8 dereferenceable(312) %0, i32 noundef %1) #3 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca i1, align 1
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i16, align 2
  %10 = alloca i16, align 2
  %11 = alloca ptr, align 8
  %12 = alloca %"class.cascadb::LoggerFormat", align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca %"class.cascadb::LoggerFormat", align 8
  %17 = alloca %"class.cascadb::BlockReader", align 8
  %18 = alloca %"class.cascadb::Slice", align 8
  %19 = alloca %"class.cascadb::Slice", align 8
  %20 = alloca { ptr, i32 }, align 8
  %21 = alloca ptr, align 8
  %22 = alloca %"class.cascadb::Slice", align 8
  %23 = alloca %"class.cascadb::LoggerFormat", align 8
  %24 = alloca ptr, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store i32 %1, ptr %5, align 4, !tbaa !9
  %25 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #11
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #11
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #11
  call void @llvm.lifetime.start.p0(i64 2, ptr %9) #11
  call void @llvm.lifetime.start.p0(i64 2, ptr %10) #11
  %26 = load i32, ptr %5, align 4, !tbaa !9
  %27 = icmp eq i32 %26, 0
  br i1 %27, label %28, label %37

28:                                               ; preds = %2
  %29 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 5
  %30 = load i32, ptr %29, align 8, !tbaa !11
  store i32 %30, ptr %6, align 4, !tbaa !9
  %31 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 6
  %32 = load i32, ptr %31, align 4, !tbaa !29
  store i32 %32, ptr %7, align 4, !tbaa !9
  %33 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 7
  %34 = load i32, ptr %33, align 8, !tbaa !30
  store i32 %34, ptr %8, align 4, !tbaa !9
  %35 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 8
  %36 = load i16, ptr %35, align 4, !tbaa !31
  store i16 %36, ptr %9, align 2, !tbaa !32
  br label %66

37:                                               ; preds = %2
  %38 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 9
  %39 = load i32, ptr %5, align 4, !tbaa !9
  %40 = sub nsw i32 %39, 1
  %41 = sext i32 %40 to i64
  %42 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %41) #11
  %43 = getelementptr inbounds %"class.cascadb::Pivot", ptr %42, i32 0, i32 4
  %44 = load i32, ptr %43, align 8, !tbaa !33
  store i32 %44, ptr %6, align 4, !tbaa !9
  %45 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 9
  %46 = load i32, ptr %5, align 4, !tbaa !9
  %47 = sub nsw i32 %46, 1
  %48 = sext i32 %47 to i64
  %49 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %45, i64 noundef %48) #11
  %50 = getelementptr inbounds %"class.cascadb::Pivot", ptr %49, i32 0, i32 5
  %51 = load i32, ptr %50, align 4, !tbaa !35
  store i32 %51, ptr %7, align 4, !tbaa !9
  %52 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 9
  %53 = load i32, ptr %5, align 4, !tbaa !9
  %54 = sub nsw i32 %53, 1
  %55 = sext i32 %54 to i64
  %56 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %52, i64 noundef %55) #11
  %57 = getelementptr inbounds %"class.cascadb::Pivot", ptr %56, i32 0, i32 6
  %58 = load i32, ptr %57, align 8, !tbaa !36
  store i32 %58, ptr %8, align 4, !tbaa !9
  %59 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 9
  %60 = load i32, ptr %5, align 4, !tbaa !9
  %61 = sub nsw i32 %60, 1
  %62 = sext i32 %61 to i64
  %63 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %59, i64 noundef %62) #11
  %64 = getelementptr inbounds %"class.cascadb::Pivot", ptr %63, i32 0, i32 7
  %65 = load i16, ptr %64, align 4, !tbaa !37
  store i16 %65, ptr %9, align 2, !tbaa !32
  br label %66

66:                                               ; preds = %37, %28
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #11
  %67 = getelementptr inbounds %"class.cascadb::DataNode", ptr %25, i32 0, i32 1
  %68 = load ptr, ptr %67, align 8, !tbaa !38
  %69 = getelementptr inbounds %"class.cascadb::Tree", ptr %68, i32 0, i32 3
  %70 = load ptr, ptr %69, align 8, !tbaa !39
  %71 = getelementptr inbounds %"class.cascadb::Node", ptr %25, i32 0, i32 2
  %72 = load i64, ptr %71, align 8, !tbaa !43
  %73 = load i32, ptr %6, align 4, !tbaa !9
  %74 = load i32, ptr %7, align 4, !tbaa !9
  %75 = call noundef ptr @_ZN7cascadb6Layout4readEmjj(ptr noundef nonnull align 8 dereferenceable(600) %70, i64 noundef %72, i32 noundef %73, i32 noundef %74)
  store ptr %75, ptr %11, align 8, !tbaa !5
  %76 = load ptr, ptr %11, align 8, !tbaa !5
  %77 = icmp eq ptr %76, null
  br i1 %77, label %78, label %131

78:                                               ; preds = %66
  %79 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !44
  %80 = icmp sge i32 3, %79
  br i1 %80, label %81, label %130

81:                                               ; preds = %78
  call void @llvm.lifetime.start.p0(i64 384, ptr %12) #11
  %82 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %12, ptr noundef %82)
  %83 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %12, i32 noundef 3)
          to label %84 unwind label %126

84:                                               ; preds = %81
  %85 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %83, ptr noundef @.str.19)
          to label %86 unwind label %126

86:                                               ; preds = %84
  %87 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #12
  %88 = icmp ne ptr %87, null
  br i1 %88, label %89, label %92

89:                                               ; preds = %86
  %90 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #12
  %91 = getelementptr inbounds i8, ptr %90, i64 1
  br label %93

92:                                               ; preds = %86
  br label %93

93:                                               ; preds = %92, %89
  %94 = phi ptr [ %91, %89 ], [ @.str.1, %92 ]
  %95 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %85, ptr noundef %94)
          to label %96 unwind label %126

96:                                               ; preds = %93
  %97 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %95, ptr noundef @.str.20)
          to label %98 unwind label %126

98:                                               ; preds = %96
  %99 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %97, i32 noundef 686)
          to label %100 unwind label %126

100:                                              ; preds = %98
  %101 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %99, ptr noundef @.str.19)
          to label %102 unwind label %126

102:                                              ; preds = %100
  %103 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %101, ptr noundef @.str.21)
          to label %104 unwind label %126

104:                                              ; preds = %102
  %105 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %103, ptr noundef @.str.22)
          to label %106 unwind label %126

106:                                              ; preds = %104
  %107 = getelementptr inbounds %"class.cascadb::Node", ptr %25, i32 0, i32 2
  %108 = load i64, ptr %107, align 8, !tbaa !43
  %109 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %105, i64 noundef %108)
          to label %110 unwind label %126

110:                                              ; preds = %106
  %111 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %109, ptr noundef @.str.23)
          to label %112 unwind label %126

112:                                              ; preds = %110
  %113 = load i32, ptr %5, align 4, !tbaa !9
  %114 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %111, i32 noundef %113)
          to label %115 unwind label %126

115:                                              ; preds = %112
  %116 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %114, ptr noundef @.str.24)
          to label %117 unwind label %126

117:                                              ; preds = %115
  %118 = load i32, ptr %6, align 4, !tbaa !9
  %119 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %116, i32 noundef %118)
          to label %120 unwind label %126

120:                                              ; preds = %117
  %121 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %119, ptr noundef @.str.25)
          to label %122 unwind label %126

122:                                              ; preds = %120
  %123 = load i32, ptr %7, align 4, !tbaa !9
  %124 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %121, i32 noundef %123)
          to label %125 unwind label %126

125:                                              ; preds = %122
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %12) #11
  call void @llvm.lifetime.end.p0(i64 384, ptr %12) #11
  br label %130

126:                                              ; preds = %122, %120, %117, %115, %112, %110, %106, %104, %102, %100, %98, %96, %93, %84, %81
  %127 = landingpad { ptr, i32 }
          cleanup
  %128 = extractvalue { ptr, i32 } %127, 0
  store ptr %128, ptr %13, align 8
  %129 = extractvalue { ptr, i32 } %127, 1
  store i32 %129, ptr %14, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %12) #11
  call void @llvm.lifetime.end.p0(i64 384, ptr %12) #11
  br label %349

130:                                              ; preds = %125, %78
  store i1 false, ptr %3, align 1
  store i32 1, ptr %15, align 4
  br label %347

131:                                              ; preds = %66
  %132 = load ptr, ptr %11, align 8, !tbaa !5
  %133 = call noundef ptr @_ZN7cascadb5Block5startEv(ptr noundef nonnull align 8 dereferenceable(32) %132)
  %134 = load i32, ptr %7, align 4, !tbaa !9
  %135 = call noundef zeroext i16 @_ZN7cascadb5crc16EPKcj(ptr noundef %133, i32 noundef %134)
  store i16 %135, ptr %10, align 2, !tbaa !32
  %136 = load i16, ptr %10, align 2, !tbaa !32
  %137 = zext i16 %136 to i32
  %138 = load i16, ptr %9, align 2, !tbaa !32
  %139 = zext i16 %138 to i32
  %140 = icmp ne i32 %137, %139
  br i1 %140, label %141, label %209

141:                                              ; preds = %131
  %142 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !44
  %143 = icmp sge i32 3, %142
  br i1 %143, label %144, label %203

144:                                              ; preds = %141
  call void @llvm.lifetime.start.p0(i64 384, ptr %16) #11
  %145 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %16, ptr noundef %145)
  %146 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %16, i32 noundef 3)
          to label %147 unwind label %199

147:                                              ; preds = %144
  %148 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %146, ptr noundef @.str.19)
          to label %149 unwind label %199

149:                                              ; preds = %147
  %150 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #12
  %151 = icmp ne ptr %150, null
  br i1 %151, label %152, label %155

152:                                              ; preds = %149
  %153 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #12
  %154 = getelementptr inbounds i8, ptr %153, i64 1
  br label %156

155:                                              ; preds = %149
  br label %156

156:                                              ; preds = %155, %152
  %157 = phi ptr [ %154, %152 ], [ @.str.1, %155 ]
  %158 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %148, ptr noundef %157)
          to label %159 unwind label %199

159:                                              ; preds = %156
  %160 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %158, ptr noundef @.str.20)
          to label %161 unwind label %199

161:                                              ; preds = %159
  %162 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %160, i32 noundef 696)
          to label %163 unwind label %199

163:                                              ; preds = %161
  %164 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %162, ptr noundef @.str.19)
          to label %165 unwind label %199

165:                                              ; preds = %163
  %166 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %164, ptr noundef @.str.26)
          to label %167 unwind label %199

167:                                              ; preds = %165
  %168 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %166, ptr noundef @.str.22)
          to label %169 unwind label %199

169:                                              ; preds = %167
  %170 = getelementptr inbounds %"class.cascadb::Node", ptr %25, i32 0, i32 2
  %171 = load i64, ptr %170, align 8, !tbaa !43
  %172 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %168, i64 noundef %171)
          to label %173 unwind label %199

173:                                              ; preds = %169
  %174 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %172, ptr noundef @.str.23)
          to label %175 unwind label %199

175:                                              ; preds = %173
  %176 = load i32, ptr %5, align 4, !tbaa !9
  %177 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %174, i32 noundef %176)
          to label %178 unwind label %199

178:                                              ; preds = %175
  %179 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %177, ptr noundef @.str.27)
          to label %180 unwind label %199

180:                                              ; preds = %178
  %181 = load i16, ptr %9, align 2, !tbaa !32
  %182 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEt(ptr noundef nonnull align 8 dereferenceable(8) %179, i16 noundef zeroext %181)
          to label %183 unwind label %199

183:                                              ; preds = %180
  %184 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %182, ptr noundef @.str.28)
          to label %185 unwind label %199

185:                                              ; preds = %183
  %186 = load i16, ptr %10, align 2, !tbaa !32
  %187 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEt(ptr noundef nonnull align 8 dereferenceable(8) %184, i16 noundef zeroext %186)
          to label %188 unwind label %199

188:                                              ; preds = %185
  %189 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %187, ptr noundef @.str.24)
          to label %190 unwind label %199

190:                                              ; preds = %188
  %191 = load i32, ptr %6, align 4, !tbaa !9
  %192 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %189, i32 noundef %191)
          to label %193 unwind label %199

193:                                              ; preds = %190
  %194 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %192, ptr noundef @.str.25)
          to label %195 unwind label %199

195:                                              ; preds = %193
  %196 = load i32, ptr %7, align 4, !tbaa !9
  %197 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %194, i32 noundef %196)
          to label %198 unwind label %199

198:                                              ; preds = %195
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %16) #11
  call void @llvm.lifetime.end.p0(i64 384, ptr %16) #11
  br label %203

199:                                              ; preds = %195, %193, %190, %188, %185, %183, %180, %178, %175, %173, %169, %167, %165, %163, %161, %159, %156, %147, %144
  %200 = landingpad { ptr, i32 }
          cleanup
  %201 = extractvalue { ptr, i32 } %200, 0
  store ptr %201, ptr %13, align 8
  %202 = extractvalue { ptr, i32 } %200, 1
  store i32 %202, ptr %14, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %16) #11
  call void @llvm.lifetime.end.p0(i64 384, ptr %16) #11
  br label %349

203:                                              ; preds = %198, %141
  %204 = getelementptr inbounds %"class.cascadb::DataNode", ptr %25, i32 0, i32 1
  %205 = load ptr, ptr %204, align 8, !tbaa !38
  %206 = getelementptr inbounds %"class.cascadb::Tree", ptr %205, i32 0, i32 3
  %207 = load ptr, ptr %206, align 8, !tbaa !39
  %208 = load ptr, ptr %11, align 8, !tbaa !5
  call void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600) %207, ptr noundef %208)
  store i1 false, ptr %3, align 1
  store i32 1, ptr %15, align 4
  br label %347

209:                                              ; preds = %131
  call void @llvm.lifetime.start.p0(i64 16, ptr %17) #11
  %210 = load ptr, ptr %11, align 8, !tbaa !5
  call void @_ZN7cascadb11BlockReaderC2EPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(16) %17, ptr noundef %210)
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #11
  call void @_ZN7cascadb5SliceC2Ev(ptr noundef nonnull align 8 dereferenceable(12) %18)
  %211 = getelementptr inbounds %"class.cascadb::DataNode", ptr %25, i32 0, i32 1
  %212 = load ptr, ptr %211, align 8, !tbaa !38
  %213 = getelementptr inbounds %"class.cascadb::Tree", ptr %212, i32 0, i32 5
  %214 = load ptr, ptr %213, align 8, !tbaa !46
  %215 = icmp ne ptr %214, null
  br i1 %215, label %216, label %220

216:                                              ; preds = %209
  call void @llvm.lifetime.start.p0(i64 16, ptr %19) #11
  %217 = load i32, ptr %8, align 4, !tbaa !9
  %218 = zext i32 %217 to i64
  %219 = call { ptr, i32 } @_ZN7cascadb5Slice5allocEm(i64 noundef %218)
  store { ptr, i32 } %219, ptr %20, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %19, ptr align 8 %20, i64 12, i1 false)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %18, ptr align 8 %19, i64 12, i1 false), !tbaa.struct !47
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #11
  br label %220

220:                                              ; preds = %216, %209
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #11
  %221 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 104) #13
  %222 = getelementptr inbounds %"class.cascadb::DataNode", ptr %25, i32 0, i32 1
  %223 = load ptr, ptr %222, align 8, !tbaa !38
  %224 = getelementptr inbounds %"class.cascadb::Tree", ptr %223, i32 0, i32 1
  %225 = getelementptr inbounds %"class.cascadb::Options", ptr %224, i32 0, i32 1
  %226 = load ptr, ptr %225, align 8, !tbaa !48
  invoke void @_ZN7cascadb6MsgBufC2EPNS_10ComparatorE(ptr noundef nonnull align 8 dereferenceable(104) %221, ptr noundef %226)
          to label %227 unwind label %232

227:                                              ; preds = %220
  store ptr %221, ptr %21, align 8, !tbaa !5
  %228 = load ptr, ptr %21, align 8, !tbaa !5
  %229 = icmp ne ptr %228, null
  br i1 %229, label %230, label %231

230:                                              ; preds = %227
  br label %237

231:                                              ; preds = %227
  call void @__assert_fail(ptr noundef @.str.5, ptr noundef @.str.1, i32 noundef 710, ptr noundef @__PRETTY_FUNCTION__._ZN7cascadb9InnerNode11load_msgbufEi) #14
  unreachable

232:                                              ; preds = %220
  %233 = landingpad { ptr, i32 }
          cleanup
  %234 = extractvalue { ptr, i32 } %233, 0
  store ptr %234, ptr %13, align 8
  %235 = extractvalue { ptr, i32 } %233, 1
  store i32 %235, ptr %14, align 4
  call void @_ZdlPvm(ptr noundef %221, i64 noundef 104) #15
  br label %346

236:                                              ; No predecessors!
  br label %237

237:                                              ; preds = %236, %230
  %238 = load i32, ptr %7, align 4, !tbaa !9
  %239 = zext i32 %238 to i64
  %240 = load i32, ptr %8, align 4, !tbaa !9
  %241 = zext i32 %240 to i64
  %242 = load ptr, ptr %21, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %22, ptr align 8 %18, i64 16, i1 false), !tbaa.struct !47
  %243 = call noundef zeroext i1 @_ZN7cascadb9InnerNode11read_msgbufERNS_11BlockReaderEmmPNS_6MsgBufENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312) %25, ptr noundef nonnull align 8 dereferenceable(16) %17, i64 noundef %239, i64 noundef %241, ptr noundef %242, ptr noundef byval(%"class.cascadb::Slice") align 8 %22)
  br i1 %243, label %300, label %244

244:                                              ; preds = %237
  %245 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !44
  %246 = icmp sge i32 3, %245
  br i1 %246, label %247, label %286

247:                                              ; preds = %244
  call void @llvm.lifetime.start.p0(i64 384, ptr %23) #11
  %248 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %23, ptr noundef %248)
  %249 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %23, i32 noundef 3)
          to label %250 unwind label %282

250:                                              ; preds = %247
  %251 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %249, ptr noundef @.str.19)
          to label %252 unwind label %282

252:                                              ; preds = %250
  %253 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #12
  %254 = icmp ne ptr %253, null
  br i1 %254, label %255, label %258

255:                                              ; preds = %252
  %256 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #12
  %257 = getelementptr inbounds i8, ptr %256, i64 1
  br label %259

258:                                              ; preds = %252
  br label %259

259:                                              ; preds = %258, %255
  %260 = phi ptr [ %257, %255 ], [ @.str.1, %258 ]
  %261 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %251, ptr noundef %260)
          to label %262 unwind label %282

262:                                              ; preds = %259
  %263 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %261, ptr noundef @.str.20)
          to label %264 unwind label %282

264:                                              ; preds = %262
  %265 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %263, i32 noundef 713)
          to label %266 unwind label %282

266:                                              ; preds = %264
  %267 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %265, ptr noundef @.str.19)
          to label %268 unwind label %282

268:                                              ; preds = %266
  %269 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %267, ptr noundef @.str.29)
          to label %270 unwind label %282

270:                                              ; preds = %268
  %271 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %269, ptr noundef @.str.22)
          to label %272 unwind label %282

272:                                              ; preds = %270
  %273 = getelementptr inbounds %"class.cascadb::Node", ptr %25, i32 0, i32 2
  %274 = load i64, ptr %273, align 8, !tbaa !43
  %275 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %271, i64 noundef %274)
          to label %276 unwind label %282

276:                                              ; preds = %272
  %277 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %275, ptr noundef @.str.23)
          to label %278 unwind label %282

278:                                              ; preds = %276
  %279 = load i32, ptr %5, align 4, !tbaa !9
  %280 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %277, i32 noundef %279)
          to label %281 unwind label %282

281:                                              ; preds = %278
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %23) #11
  call void @llvm.lifetime.end.p0(i64 384, ptr %23) #11
  br label %286

282:                                              ; preds = %278, %276, %272, %270, %268, %266, %264, %262, %259, %250, %247
  %283 = landingpad { ptr, i32 }
          cleanup
  %284 = extractvalue { ptr, i32 } %283, 0
  store ptr %284, ptr %13, align 8
  %285 = extractvalue { ptr, i32 } %283, 1
  store i32 %285, ptr %14, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %23) #11
  call void @llvm.lifetime.end.p0(i64 384, ptr %23) #11
  br label %346

286:                                              ; preds = %281, %244
  %287 = load ptr, ptr %21, align 8, !tbaa !5
  %288 = icmp eq ptr %287, null
  br i1 %288, label %290, label %289

289:                                              ; preds = %286
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %287) #11
  call void @_ZdlPvm(ptr noundef %287, i64 noundef 104) #15
  br label %290

290:                                              ; preds = %289, %286
  %291 = call noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12) %18)
  %292 = icmp ne i64 %291, 0
  br i1 %292, label %293, label %294

293:                                              ; preds = %290
  call void @_ZN7cascadb5Slice7destroyEv(ptr noundef nonnull align 8 dereferenceable(12) %18)
  br label %294

294:                                              ; preds = %293, %290
  %295 = getelementptr inbounds %"class.cascadb::DataNode", ptr %25, i32 0, i32 1
  %296 = load ptr, ptr %295, align 8, !tbaa !38
  %297 = getelementptr inbounds %"class.cascadb::Tree", ptr %296, i32 0, i32 3
  %298 = load ptr, ptr %297, align 8, !tbaa !39
  %299 = load ptr, ptr %11, align 8, !tbaa !5
  call void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600) %298, ptr noundef %299)
  store i1 false, ptr %3, align 1
  store i32 1, ptr %15, align 4
  br label %345

300:                                              ; preds = %237
  %301 = call noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12) %18)
  %302 = icmp ne i64 %301, 0
  br i1 %302, label %303, label %304

303:                                              ; preds = %300
  call void @_ZN7cascadb5Slice7destroyEv(ptr noundef nonnull align 8 dereferenceable(12) %18)
  br label %304

304:                                              ; preds = %303, %300
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %25)
  call void @_ZN7cascadb4Node10write_lockEv(ptr noundef nonnull align 8 dereferenceable(200) %25)
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #11
  %305 = load i32, ptr %5, align 4, !tbaa !9
  %306 = icmp eq i32 %305, 0
  br i1 %306, label %307, label %309

307:                                              ; preds = %304
  %308 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 3
  br label %316

309:                                              ; preds = %304
  %310 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 9
  %311 = load i32, ptr %5, align 4, !tbaa !9
  %312 = sub nsw i32 %311, 1
  %313 = sext i32 %312 to i64
  %314 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %310, i64 noundef %313) #11
  %315 = getelementptr inbounds %"class.cascadb::Pivot", ptr %314, i32 0, i32 3
  br label %316

316:                                              ; preds = %309, %307
  %317 = phi ptr [ %308, %307 ], [ %315, %309 ]
  store ptr %317, ptr %24, align 8, !tbaa !5
  %318 = load ptr, ptr %24, align 8, !tbaa !5
  %319 = load ptr, ptr %318, align 8, !tbaa !5
  %320 = icmp eq ptr %319, null
  br i1 %320, label %321, label %334

321:                                              ; preds = %316
  %322 = load ptr, ptr %21, align 8, !tbaa !5
  %323 = load ptr, ptr %24, align 8, !tbaa !5
  store ptr %322, ptr %323, align 8, !tbaa !5
  %324 = load ptr, ptr %21, align 8, !tbaa !5
  %325 = call noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104) %324)
  %326 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 11
  %327 = load i64, ptr %326, align 8, !tbaa !49
  %328 = add i64 %327, %325
  store i64 %328, ptr %326, align 8, !tbaa !49
  %329 = load ptr, ptr %21, align 8, !tbaa !5
  %330 = call noundef i64 @_ZNK7cascadb6MsgBuf4sizeEv(ptr noundef nonnull align 8 dereferenceable(104) %329)
  %331 = getelementptr inbounds %"class.cascadb::InnerNode", ptr %25, i32 0, i32 12
  %332 = load i64, ptr %331, align 8, !tbaa !50
  %333 = add i64 %332, %330
  store i64 %333, ptr %331, align 8, !tbaa !50
  br label %339

334:                                              ; preds = %316
  %335 = load ptr, ptr %21, align 8, !tbaa !5
  %336 = icmp eq ptr %335, null
  br i1 %336, label %338, label %337

337:                                              ; preds = %334
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %335) #11
  call void @_ZdlPvm(ptr noundef %335, i64 noundef 104) #15
  br label %338

338:                                              ; preds = %337, %334
  br label %339

339:                                              ; preds = %338, %321
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %25)
  call void @_ZN7cascadb4Node9read_lockEv(ptr noundef nonnull align 8 dereferenceable(200) %25)
  %340 = getelementptr inbounds %"class.cascadb::DataNode", ptr %25, i32 0, i32 1
  %341 = load ptr, ptr %340, align 8, !tbaa !38
  %342 = getelementptr inbounds %"class.cascadb::Tree", ptr %341, i32 0, i32 3
  %343 = load ptr, ptr %342, align 8, !tbaa !39
  %344 = load ptr, ptr %11, align 8, !tbaa !5
  call void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600) %343, ptr noundef %344)
  store i1 true, ptr %3, align 1
  store i32 1, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #11
  br label %345

345:                                              ; preds = %339, %294
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #11
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #11
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #11
  br label %347

346:                                              ; preds = %282, %232
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #11
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #11
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #11
  br label %349

347:                                              ; preds = %345, %203, %130
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #11
  call void @llvm.lifetime.end.p0(i64 2, ptr %10) #11
  call void @llvm.lifetime.end.p0(i64 2, ptr %9) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #11
  %348 = load i1, ptr %3, align 1
  ret i1 %348

349:                                              ; preds = %346, %199, %126
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #11
  call void @llvm.lifetime.end.p0(i64 2, ptr %10) #11
  call void @llvm.lifetime.end.p0(i64 2, ptr %9) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #11
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #11
  br label %350

350:                                              ; preds = %349
  %351 = load ptr, ptr %13, align 8
  %352 = load i32, ptr %14, align 4
  %353 = insertvalue { ptr, i32 } poison, ptr %351, 0
  %354 = insertvalue { ptr, i32 } %353, i32 %352, 1
  resume { ptr, i32 } %354
}

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

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

declare noundef ptr @_ZN7cascadb6Layout4readEmjj(ptr noundef nonnull align 8 dereferenceable(600), i64 noundef, i32 noundef, i32 noundef) #8

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #9

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

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

; Function Attrs: nounwind willreturn memory(read)
declare noundef ptr @strrchr(ptr noundef, i32 noundef) #10

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #8

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

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

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

declare noundef zeroext i16 @_ZN7cascadb5crc16EPKcj(ptr noundef, i32 noundef) #8

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN7cascadb5Block5startEv(ptr noundef nonnull align 8 dereferenceable(32)) #9 align 2

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEt(ptr noundef nonnull align 8 dereferenceable(8), i16 noundef zeroext) #3 align 2

declare void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600), ptr noundef) #8

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i32 } @_ZN7cascadb5Slice5allocEm(i64 noundef) #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb9InnerNode11read_msgbufERNS_11BlockReaderEmmPNS_6MsgBufENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312), ptr noundef nonnull align 8 dereferenceable(16), i64 noundef, i64 noundef, ptr noundef, ptr noundef byval(%"class.cascadb::Slice") align 8) #3 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 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 = { 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 #5 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { 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 #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 = { 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 #10 = { nounwind willreturn memory(read) "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 #11 = { nounwind }
attributes #12 = { nounwind willreturn memory(read) }
attributes #13 = { builtin allocsize(0) }
attributes #14 = { noreturn nounwind }
attributes #15 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 248}
!12 = !{!"_ZTSN7cascadb9InnerNodeE", !13, i64 0, !19, i64 212, !17, i64 216, !6, i64 224, !23, i64 232, !10, i64 248, !10, i64 252, !10, i64 256, !24, i64 260, !25, i64 264, !17, i64 288, !17, i64 296, !17, i64 304}
!13 = !{!"_ZTSN7cascadb8DataNodeE", !14, i64 0, !6, i64 200, !22, i64 208}
!14 = !{!"_ZTSN7cascadb4NodeE", !15, i64 8, !17, i64 40, !18, i64 48, !19, i64 96, !19, i64 97, !19, i64 98, !20, i64 104, !20, i64 120, !10, i64 136, !10, i64 140, !21, i64 144}
!15 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !16, i64 0, !17, i64 8, !7, i64 16}
!16 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!17 = !{!"long", !7, i64 0}
!18 = !{!"_ZTSN7cascadb5MutexE", !19, i64 0, !7, i64 8}
!19 = !{!"bool", !7, i64 0}
!20 = !{!"_ZTS7timeval", !17, i64 0, !17, i64 8}
!21 = !{!"_ZTSN7cascadb6RWLockE", !7, i64 0}
!22 = !{!"_ZTSN7cascadb10NodeStatusE", !7, i64 0}
!23 = !{!"_ZTSN7cascadb5SliceE", !6, i64 0, !10, 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 = !{!12, !10, i64 252}
!30 = !{!12, !10, i64 256}
!31 = !{!12, !24, i64 260}
!32 = !{!24, !24, i64 0}
!33 = !{!34, !10, i64 48}
!34 = !{!"_ZTSN7cascadb5PivotE", !23, i64 0, !23, i64 16, !17, i64 32, !6, i64 40, !10, i64 48, !10, i64 52, !10, i64 56, !24, i64 60}
!35 = !{!34, !10, i64 52}
!36 = !{!34, !10, i64 56}
!37 = !{!34, !24, i64 60}
!38 = !{!13, !6, i64 200}
!39 = !{!40, !6, i64 144}
!40 = !{!"_ZTSN7cascadb4TreeE", !15, i64 0, !41, i64 32, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176}
!41 = !{!"_ZTSN7cascadb7OptionsE", !6, i64 0, !6, i64 8, !17, i64 16, !17, i64 24, !17, i64 32, !17, i64 40, !17, i64 48, !17, i64 56, !17, i64 64, !10, i64 72, !10, i64 76, !10, i64 80, !10, i64 84, !10, i64 88, !10, i64 92, !42, i64 96, !19, i64 100}
!42 = !{!"_ZTSN7cascadb8CompressE", !7, i64 0}
!43 = !{!14, !17, i64 40}
!44 = !{!45, !45, i64 0}
!45 = !{!"_ZTSN7cascadb11LoggerLevelE", !7, i64 0}
!46 = !{!40, !6, i64 160}
!47 = !{i64 0, i64 8, !5, i64 8, i64 4, !9}
!48 = !{!40, !6, i64 40}
!49 = !{!12, !17, i64 296}
!50 = !{!12, !17, i64 304}


; 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.cascadb::LoggerFormat" = type { ptr, %"class.std::__cxx11::basic_ostringstream" }
%"class.std::__cxx11::basic_ostringstream" = type { %"class.std::basic_ostream.base", %"class.std::__cxx11::basic_stringbuf", %"class.std::basic_ios" }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.cascadb::BlockReader" = type { ptr, i64 }
%"class.cascadb::Slice" = type <{ ptr, i32, [4 x i8] }>

@.str.1 = external hidden unnamed_addr constant [66 x i8], align 1
@_ZN7cascadb14g_logger_levelE = external local_unnamed_addr global i32, align 4
@_ZN7cascadb8g_loggerE = external local_unnamed_addr global ptr, align 8
@.str.19 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.29 = external hidden unnamed_addr constant [19 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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #2

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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) local_unnamed_addr #4

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104)) 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 #3 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 #5 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN7cascadb9InnerNode11load_msgbufEi(ptr noundef nonnull align 8 dereferenceable(312) %0, i32 noundef %1) local_unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.cascadb::LoggerFormat", align 8
  %4 = alloca %"class.cascadb::LoggerFormat", align 8
  %5 = alloca %"class.cascadb::BlockReader", align 8
  %6 = alloca %"class.cascadb::Slice", align 8
  %7 = alloca %"class.cascadb::LoggerFormat", align 8
  %8 = icmp eq i32 %1, 0
  br i1 %8, label %9, label %17

9:                                                ; preds = %2
  %10 = getelementptr inbounds i8, ptr %0, i64 248
  %11 = load i32, ptr %10, align 8, !tbaa !5
  %12 = getelementptr inbounds i8, ptr %0, i64 252
  %13 = load i32, ptr %12, align 4, !tbaa !27
  %14 = getelementptr inbounds i8, ptr %0, i64 256
  %15 = load i32, ptr %14, align 8, !tbaa !28
  %16 = getelementptr inbounds i8, ptr %0, i64 260
  br label %32

17:                                               ; preds = %2
  %18 = getelementptr inbounds i8, ptr %0, i64 264
  %19 = add nsw i32 %1, -1
  %20 = sext i32 %19 to i64
  %21 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %18, i64 noundef %20) #9
  %22 = getelementptr inbounds i8, ptr %21, i64 48
  %23 = load i32, ptr %22, align 8, !tbaa !29
  %24 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %18, i64 noundef %20) #9
  %25 = getelementptr inbounds i8, ptr %24, i64 52
  %26 = load i32, ptr %25, align 4, !tbaa !31
  %27 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %18, i64 noundef %20) #9
  %28 = getelementptr inbounds i8, ptr %27, i64 56
  %29 = load i32, ptr %28, align 8, !tbaa !32
  %30 = tail call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %18, i64 noundef %20) #9
  %31 = getelementptr inbounds i8, ptr %30, i64 60
  br label %32

32:                                               ; preds = %17, %9
  %.046.in = phi ptr [ %16, %9 ], [ %31, %17 ]
  %.045 = phi i32 [ %15, %9 ], [ %29, %17 ]
  %.044 = phi i32 [ %13, %9 ], [ %26, %17 ]
  %.043 = phi i32 [ %11, %9 ], [ %23, %17 ]
  %.046 = load i16, ptr %.046.in, align 4, !tbaa !33
  %33 = getelementptr inbounds i8, ptr %0, i64 200
  %34 = load ptr, ptr %33, align 8, !tbaa !34
  %35 = getelementptr inbounds i8, ptr %34, i64 144
  %36 = load ptr, ptr %35, align 8, !tbaa !35
  %37 = getelementptr inbounds i8, ptr %0, i64 40
  %38 = load i64, ptr %37, align 8, !tbaa !39
  %39 = tail call noundef ptr @_ZN7cascadb6Layout4readEmjj(ptr noundef nonnull align 8 dereferenceable(600) %36, i64 noundef %38, i32 noundef %.043, i32 noundef %.044)
  %40 = icmp eq ptr %39, null
  br i1 %40, label %41, label %81

41:                                               ; preds = %32
  %42 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !40
  %43 = icmp slt i32 %42, 4
  br i1 %43, label %44, label %221

44:                                               ; preds = %41
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %3) #9
  %45 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !42
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %3, ptr noundef %45)
  %46 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %3, i32 noundef 3)
          to label %47 unwind label %79

47:                                               ; preds = %44
  %48 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %46, ptr noundef nonnull @.str.19)
          to label %49 unwind label %79

49:                                               ; preds = %47
  %50 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #10
  %.not63 = icmp eq ptr %50, null
  %51 = getelementptr inbounds i8, ptr %50, i64 1
  %spec.select = select i1 %.not63, ptr @.str.1, ptr %51
  %52 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %48, ptr noundef nonnull %spec.select)
          to label %53 unwind label %79

53:                                               ; preds = %49
  %54 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %52, ptr noundef nonnull @.str.20)
          to label %55 unwind label %79

55:                                               ; preds = %53
  %56 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %54, i32 noundef 686)
          to label %57 unwind label %79

57:                                               ; preds = %55
  %58 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %56, ptr noundef nonnull @.str.19)
          to label %59 unwind label %79

59:                                               ; preds = %57
  %60 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %58, ptr noundef nonnull @.str.21)
          to label %61 unwind label %79

61:                                               ; preds = %59
  %62 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %60, ptr noundef nonnull @.str.22)
          to label %63 unwind label %79

63:                                               ; preds = %61
  %64 = load i64, ptr %37, align 8, !tbaa !39
  %65 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %62, i64 noundef %64)
          to label %66 unwind label %79

66:                                               ; preds = %63
  %67 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %65, ptr noundef nonnull @.str.23)
          to label %68 unwind label %79

68:                                               ; preds = %66
  %69 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %67, i32 noundef %1)
          to label %70 unwind label %79

70:                                               ; preds = %68
  %71 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %69, ptr noundef nonnull @.str.24)
          to label %72 unwind label %79

72:                                               ; preds = %70
  %73 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %71, i32 noundef %.043)
          to label %74 unwind label %79

74:                                               ; preds = %72
  %75 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %73, ptr noundef nonnull @.str.25)
          to label %76 unwind label %79

76:                                               ; preds = %74
  %77 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %75, i32 noundef %.044)
          to label %78 unwind label %79

78:                                               ; preds = %76
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %3) #9
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %3) #9
  br label %221

79:                                               ; preds = %76, %74, %72, %70, %68, %66, %63, %61, %59, %57, %55, %53, %49, %47, %44
  %80 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %3) #9
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %3) #9
  br label %222

81:                                               ; preds = %32
  %82 = tail call noundef ptr @_ZN7cascadb5Block5startEv(ptr noundef nonnull align 8 dereferenceable(32) %39)
  %83 = tail call noundef zeroext i16 @_ZN7cascadb5crc16EPKcj(ptr noundef %82, i32 noundef %.044)
  %.not = icmp eq i16 %83, %.046
  br i1 %.not, label %136, label %84

84:                                               ; preds = %81
  %85 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !40
  %86 = icmp slt i32 %85, 4
  br i1 %86, label %87, label %132

87:                                               ; preds = %84
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %4) #9
  %88 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !42
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %4, ptr noundef %88)
  %89 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %4, i32 noundef 3)
          to label %90 unwind label %130

90:                                               ; preds = %87
  %91 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %89, ptr noundef nonnull @.str.19)
          to label %92 unwind label %130

92:                                               ; preds = %90
  %93 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #10
  %.not62 = icmp eq ptr %93, null
  %94 = getelementptr inbounds i8, ptr %93, i64 1
  %spec.select66 = select i1 %.not62, ptr @.str.1, ptr %94
  %95 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %91, ptr noundef nonnull %spec.select66)
          to label %96 unwind label %130

96:                                               ; preds = %92
  %97 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %95, ptr noundef nonnull @.str.20)
          to label %98 unwind label %130

98:                                               ; preds = %96
  %99 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %97, i32 noundef 696)
          to label %100 unwind label %130

100:                                              ; preds = %98
  %101 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %99, ptr noundef nonnull @.str.19)
          to label %102 unwind label %130

102:                                              ; preds = %100
  %103 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %101, ptr noundef nonnull @.str.26)
          to label %104 unwind label %130

104:                                              ; preds = %102
  %105 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %103, ptr noundef nonnull @.str.22)
          to label %106 unwind label %130

106:                                              ; preds = %104
  %107 = load i64, ptr %37, align 8, !tbaa !39
  %108 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %105, i64 noundef %107)
          to label %109 unwind label %130

109:                                              ; preds = %106
  %110 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %108, ptr noundef nonnull @.str.23)
          to label %111 unwind label %130

111:                                              ; preds = %109
  %112 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %110, i32 noundef %1)
          to label %113 unwind label %130

113:                                              ; preds = %111
  %114 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %112, ptr noundef nonnull @.str.27)
          to label %115 unwind label %130

115:                                              ; preds = %113
  %116 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEt(ptr noundef nonnull align 8 dereferenceable(8) %114, i16 noundef zeroext %.046)
          to label %117 unwind label %130

117:                                              ; preds = %115
  %118 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %116, ptr noundef nonnull @.str.28)
          to label %119 unwind label %130

119:                                              ; preds = %117
  %120 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEt(ptr noundef nonnull align 8 dereferenceable(8) %118, i16 noundef zeroext %83)
          to label %121 unwind label %130

121:                                              ; preds = %119
  %122 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %120, ptr noundef nonnull @.str.24)
          to label %123 unwind label %130

123:                                              ; preds = %121
  %124 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %122, i32 noundef %.043)
          to label %125 unwind label %130

125:                                              ; preds = %123
  %126 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %124, ptr noundef nonnull @.str.25)
          to label %127 unwind label %130

127:                                              ; preds = %125
  %128 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEj(ptr noundef nonnull align 8 dereferenceable(8) %126, i32 noundef %.044)
          to label %129 unwind label %130

129:                                              ; preds = %127
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %4) #9
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %4) #9
  br label %132

130:                                              ; preds = %127, %125, %123, %121, %119, %117, %115, %113, %111, %109, %106, %104, %102, %100, %98, %96, %92, %90, %87
  %131 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %4) #9
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %4) #9
  br label %222

132:                                              ; preds = %129, %84
  %133 = load ptr, ptr %33, align 8, !tbaa !34
  %134 = getelementptr inbounds i8, ptr %133, i64 144
  %135 = load ptr, ptr %134, align 8, !tbaa !35
  call void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600) %135, ptr noundef nonnull %39)
  br label %221

136:                                              ; preds = %81
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #9
  call void @_ZN7cascadb11BlockReaderC2EPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull %39)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #9
  call void @_ZN7cascadb5SliceC2Ev(ptr noundef nonnull align 8 dereferenceable(12) %6)
  %137 = load ptr, ptr %33, align 8, !tbaa !34
  %138 = getelementptr inbounds i8, ptr %137, i64 160
  %139 = load ptr, ptr %138, align 8, !tbaa !43
  %.not57 = icmp eq ptr %139, null
  br i1 %.not57, label %143, label %140

140:                                              ; preds = %136
  %141 = zext i32 %.045 to i64
  %142 = call { ptr, i32 } @_ZN7cascadb5Slice5allocEm(i64 noundef %141)
  %.fca.0.extract = extractvalue { ptr, i32 } %142, 0
  %.fca.1.extract = extractvalue { ptr, i32 } %142, 1
  store ptr %.fca.0.extract, ptr %6, align 8, !tbaa !42
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %6, i64 8
  store i32 %.fca.1.extract, ptr %.sroa.4.0..sroa_idx, align 8, !tbaa !44
  %.pre = load ptr, ptr %33, align 8, !tbaa !34
  br label %143

143:                                              ; preds = %140, %136
  %144 = phi ptr [ %.pre, %140 ], [ %137, %136 ]
  %145 = call noalias noundef nonnull dereferenceable(104) ptr @_Znwm(i64 noundef 104) #11
  %146 = getelementptr inbounds i8, ptr %144, i64 40
  %147 = load ptr, ptr %146, align 8, !tbaa !45
  invoke void @_ZN7cascadb6MsgBufC2EPNS_10ComparatorE(ptr noundef nonnull align 8 dereferenceable(104) %145, ptr noundef %147)
          to label %150 unwind label %148

148:                                              ; preds = %143
  %149 = landingpad { ptr, i32 }
          cleanup
  call void @_ZdlPvm(ptr noundef nonnull %145, i64 noundef 104) #12
  br label %220

150:                                              ; preds = %143
  %151 = zext i32 %.044 to i64
  %152 = zext i32 %.045 to i64
  %153 = call noundef zeroext i1 @_ZN7cascadb9InnerNode11read_msgbufERNS_11BlockReaderEmmPNS_6MsgBufENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312) %0, ptr noundef nonnull align 8 dereferenceable(16) %5, i64 noundef %151, i64 noundef %152, ptr noundef nonnull %145, ptr noundef nonnull byval(%"class.cascadb::Slice") align 8 %6)
  br i1 %153, label %189, label %154

154:                                              ; preds = %150
  %155 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !40
  %156 = icmp slt i32 %155, 4
  br i1 %156, label %157, label %186

157:                                              ; preds = %154
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %7) #9
  %158 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !42
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %7, ptr noundef %158)
  %159 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %7, i32 noundef 3)
          to label %160 unwind label %184

160:                                              ; preds = %157
  %161 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %159, ptr noundef nonnull @.str.19)
          to label %162 unwind label %184

162:                                              ; preds = %160
  %163 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #10
  %.not58 = icmp eq ptr %163, null
  %164 = getelementptr inbounds i8, ptr %163, i64 1
  %spec.select67 = select i1 %.not58, ptr @.str.1, ptr %164
  %165 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %161, ptr noundef nonnull %spec.select67)
          to label %166 unwind label %184

166:                                              ; preds = %162
  %167 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %165, ptr noundef nonnull @.str.20)
          to label %168 unwind label %184

168:                                              ; preds = %166
  %169 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %167, i32 noundef 713)
          to label %170 unwind label %184

170:                                              ; preds = %168
  %171 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %169, ptr noundef nonnull @.str.19)
          to label %172 unwind label %184

172:                                              ; preds = %170
  %173 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %171, ptr noundef nonnull @.str.29)
          to label %174 unwind label %184

174:                                              ; preds = %172
  %175 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %173, ptr noundef nonnull @.str.22)
          to label %176 unwind label %184

176:                                              ; preds = %174
  %177 = load i64, ptr %37, align 8, !tbaa !39
  %178 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEm(ptr noundef nonnull align 8 dereferenceable(8) %175, i64 noundef %177)
          to label %179 unwind label %184

179:                                              ; preds = %176
  %180 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %178, ptr noundef nonnull @.str.23)
          to label %181 unwind label %184

181:                                              ; preds = %179
  %182 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %180, i32 noundef %1)
          to label %183 unwind label %184

183:                                              ; preds = %181
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %7) #9
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %7) #9
  br label %186

184:                                              ; preds = %181, %179, %176, %174, %172, %170, %168, %166, %162, %160, %157
  %185 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %7) #9
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %7) #9
  br label %220

186:                                              ; preds = %154, %183
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %145) #9
  call void @_ZdlPvm(ptr noundef nonnull %145, i64 noundef 104) #12
  %187 = call noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12) %6)
  %.not60 = icmp eq i64 %187, 0
  br i1 %.not60, label %216, label %188

188:                                              ; preds = %186
  call void @_ZN7cascadb5Slice7destroyEv(ptr noundef nonnull align 8 dereferenceable(12) %6)
  br label %216

189:                                              ; preds = %150
  %190 = call noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12) %6)
  %.not61 = icmp eq i64 %190, 0
  br i1 %.not61, label %192, label %191

191:                                              ; preds = %189
  call void @_ZN7cascadb5Slice7destroyEv(ptr noundef nonnull align 8 dereferenceable(12) %6)
  br label %192

192:                                              ; preds = %191, %189
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %0)
  call void @_ZN7cascadb4Node10write_lockEv(ptr noundef nonnull align 8 dereferenceable(200) %0)
  br i1 %8, label %193, label %195

193:                                              ; preds = %192
  %194 = getelementptr inbounds i8, ptr %0, i64 224
  br label %201

195:                                              ; preds = %192
  %196 = getelementptr inbounds i8, ptr %0, i64 264
  %197 = add nsw i32 %1, -1
  %198 = sext i32 %197 to i64
  %199 = call noundef nonnull align 8 dereferenceable(62) ptr @_ZNSt6vectorIN7cascadb5PivotESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %196, i64 noundef %198) #9
  %200 = getelementptr inbounds i8, ptr %199, i64 40
  br label %201

201:                                              ; preds = %195, %193
  %202 = phi ptr [ %194, %193 ], [ %200, %195 ]
  %203 = load ptr, ptr %202, align 8, !tbaa !42
  %204 = icmp eq ptr %203, null
  br i1 %204, label %205, label %214

205:                                              ; preds = %201
  store ptr %145, ptr %202, align 8, !tbaa !42
  %206 = call noundef i64 @_ZNK7cascadb6MsgBuf5countEv(ptr noundef nonnull align 8 dereferenceable(104) %145)
  %207 = getelementptr inbounds i8, ptr %0, i64 296
  %208 = load i64, ptr %207, align 8, !tbaa !46
  %209 = add i64 %208, %206
  store i64 %209, ptr %207, align 8, !tbaa !46
  %210 = call noundef i64 @_ZNK7cascadb6MsgBuf4sizeEv(ptr noundef nonnull align 8 dereferenceable(104) %145)
  %211 = getelementptr inbounds i8, ptr %0, i64 304
  %212 = load i64, ptr %211, align 8, !tbaa !47
  %213 = add i64 %212, %210
  store i64 %213, ptr %211, align 8, !tbaa !47
  br label %215

214:                                              ; preds = %201
  call void @_ZN7cascadb6MsgBufD1Ev(ptr noundef nonnull align 8 dereferenceable(104) %145) #9
  call void @_ZdlPvm(ptr noundef nonnull %145, i64 noundef 104) #12
  br label %215

215:                                              ; preds = %214, %205
  call void @_ZN7cascadb4Node6unlockEv(ptr noundef nonnull align 8 dereferenceable(200) %0)
  call void @_ZN7cascadb4Node9read_lockEv(ptr noundef nonnull align 8 dereferenceable(200) %0)
  br label %216

216:                                              ; preds = %186, %188, %215
  %217 = load ptr, ptr %33, align 8, !tbaa !34
  %218 = getelementptr inbounds i8, ptr %217, i64 144
  %219 = load ptr, ptr %218, align 8, !tbaa !35
  call void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600) %219, ptr noundef nonnull %39)
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #9
  br label %221

220:                                              ; preds = %184, %148
  %.pn = phi { ptr, i32 } [ %185, %184 ], [ %149, %148 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #9
  br label %222

221:                                              ; preds = %41, %78, %216, %132
  %.1 = phi i1 [ false, %132 ], [ %153, %216 ], [ false, %78 ], [ false, %41 ]
  ret i1 %.1

222:                                              ; preds = %220, %130, %79
  %.pn64 = phi { ptr, i32 } [ %80, %79 ], [ %131, %130 ], [ %.pn, %220 ]
  resume { ptr, i32 } %.pn64
}

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12)) local_unnamed_addr #5 align 2

declare noundef ptr @_ZN7cascadb6Layout4readEmjj(ptr noundef nonnull align 8 dereferenceable(600), i64 noundef, i32 noundef, i32 noundef) local_unnamed_addr #6

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #7

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

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare noundef ptr @strrchr(ptr noundef, i32 noundef) local_unnamed_addr #8

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #6

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

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

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

declare noundef zeroext i16 @_ZN7cascadb5crc16EPKcj(ptr noundef, i32 noundef) local_unnamed_addr #6

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN7cascadb5Block5startEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #7 align 2

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEt(ptr noundef nonnull align 8 dereferenceable(8), i16 noundef zeroext) local_unnamed_addr #3 align 2

declare void @_ZN7cascadb6Layout7destroyEPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(600), ptr noundef) local_unnamed_addr #6

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i32 } @_ZN7cascadb5Slice5allocEm(i64 noundef) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb9InnerNode11read_msgbufERNS_11BlockReaderEmmPNS_6MsgBufENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(312), ptr noundef nonnull align 8 dereferenceable(16), i64 noundef, i64 noundef, ptr noundef, ptr noundef byval(%"class.cascadb::Slice") align 8) local_unnamed_addr #3 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 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 = { nobuiltin allocsize(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 = { 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 #6 = { "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 = { 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 #8 = { mustprogress nofree nounwind willreturn memory(argmem: read) "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 = { nounwind willreturn memory(read) }
attributes #11 = { builtin allocsize(0) }
attributes #12 = { 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, !18, i64 248}
!6 = !{!"_ZTSN7cascadb9InnerNodeE", !7, i64 0, !16, i64 212, !14, i64 216, !11, i64 224, !21, i64 232, !18, i64 248, !18, i64 252, !18, i64 256, !22, i64 260, !23, i64 264, !14, i64 288, !14, i64 296, !14, i64 304}
!7 = !{!"_ZTSN7cascadb8DataNodeE", !8, i64 0, !11, i64 200, !20, i64 208}
!8 = !{!"_ZTSN7cascadb4NodeE", !9, 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}
!9 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !10, i64 0, !14, i64 8, !12, i64 16}
!10 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !11, i64 0}
!11 = !{!"any pointer", !12, i64 0}
!12 = !{!"omnipotent char", !13, i64 0}
!13 = !{!"Simple C++ TBAA"}
!14 = !{!"long", !12, i64 0}
!15 = !{!"_ZTSN7cascadb5MutexE", !16, i64 0, !12, i64 8}
!16 = !{!"bool", !12, i64 0}
!17 = !{!"_ZTS7timeval", !14, i64 0, !14, i64 8}
!18 = !{!"int", !12, i64 0}
!19 = !{!"_ZTSN7cascadb6RWLockE", !12, i64 0}
!20 = !{!"_ZTSN7cascadb10NodeStatusE", !12, i64 0}
!21 = !{!"_ZTSN7cascadb5SliceE", !11, i64 0, !18, i64 8}
!22 = !{!"short", !12, i64 0}
!23 = !{!"_ZTSSt6vectorIN7cascadb5PivotESaIS1_EE", !24, i64 0}
!24 = !{!"_ZTSSt12_Vector_baseIN7cascadb5PivotESaIS1_EE", !25, i64 0}
!25 = !{!"_ZTSNSt12_Vector_baseIN7cascadb5PivotESaIS1_EE12_Vector_implE", !26, i64 0}
!26 = !{!"_ZTSNSt12_Vector_baseIN7cascadb5PivotESaIS1_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!27 = !{!6, !18, i64 252}
!28 = !{!6, !18, i64 256}
!29 = !{!30, !18, i64 48}
!30 = !{!"_ZTSN7cascadb5PivotE", !21, i64 0, !21, i64 16, !14, i64 32, !11, i64 40, !18, i64 48, !18, i64 52, !18, i64 56, !22, i64 60}
!31 = !{!30, !18, i64 52}
!32 = !{!30, !18, i64 56}
!33 = !{!22, !22, i64 0}
!34 = !{!7, !11, i64 200}
!35 = !{!36, !11, i64 144}
!36 = !{!"_ZTSN7cascadb4TreeE", !9, i64 0, !37, i64 32, !11, i64 136, !11, i64 144, !11, i64 152, !11, i64 160, !11, i64 168, !11, i64 176}
!37 = !{!"_ZTSN7cascadb7OptionsE", !11, i64 0, !11, i64 8, !14, i64 16, !14, i64 24, !14, i64 32, !14, i64 40, !14, i64 48, !14, i64 56, !14, i64 64, !18, i64 72, !18, i64 76, !18, i64 80, !18, i64 84, !18, i64 88, !18, i64 92, !38, i64 96, !16, i64 100}
!38 = !{!"_ZTSN7cascadb8CompressE", !12, i64 0}
!39 = !{!8, !14, i64 40}
!40 = !{!41, !41, i64 0}
!41 = !{!"_ZTSN7cascadb11LoggerLevelE", !12, i64 0}
!42 = !{!11, !11, i64 0}
!43 = !{!36, !11, i64 160}
!44 = !{!18, !18, i64 0}
!45 = !{!36, !11, i64 40}
!46 = !{!6, !14, i64 296}
!47 = !{!6, !14, i64 304}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,MemCpyOptPass,SROAPass,SimplifyCFGPass,TailCallElimPass