; LLVM IR from nsccgz-storage/nvlsm :: table_nvm (table_cache_nvm)

; 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.leveldb::Status" = type { ptr }
%"class.leveldb::Slice" = type { ptr, i64 }
%"class.std::vector.3" = type { %"struct.std::_Vector_base.4" }
%"struct.std::_Vector_base.4" = type { %"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl" }
%"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl" = type { %"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl" }
%"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl" = type { %"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.leveldb::FileMetaData" = type { i32, i32, i64, i64, %"class.leveldb::InternalKey", %"class.leveldb::InternalKey", i8, %"class.std::vector.8" }
%"class.leveldb::InternalKey" = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::vector.8" = type { %"struct.std::_Vector_base.9" }
%"struct.std::_Vector_base.9" = type { %"struct.std::_Vector_base<leveldb::SegmentMeta *, std::allocator<leveldb::SegmentMeta *>>::_Vector_impl" }
%"struct.std::_Vector_base<leveldb::SegmentMeta *, std::allocator<leveldb::SegmentMeta *>>::_Vector_impl" = type { %"struct.std::_Vector_base<leveldb::SegmentMeta *, std::allocator<leveldb::SegmentMeta *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<leveldb::SegmentMeta *, std::allocator<leveldb::SegmentMeta *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.leveldb::TableCacheNVM" = type { ptr, %"class.std::__cxx11::basic_string", ptr, ptr, ptr, ptr, %"class.std::__cxx11::basic_string" }
%"struct.leveldb::SegmentAndFileHandle" = type { ptr, ptr, ptr }
%"struct.leveldb::TableAndSegHandles" = type { ptr, ptr, %"class.std::vector" }

@.str.2 = external hidden unnamed_addr constant [83 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [17 x i8], align 1
@__PRETTY_FUNCTION__._ZN7leveldb13TableCacheNVM12FindTableNVMEPKNS_12FileMetaDataEPPNS_5Cache6HandleE = external hidden unnamed_addr constant [84 x i8], align 1

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7leveldb13TableCacheNVM12FindTableNVMEPKNS_12FileMetaDataEPPNS_5Cache6HandleE(ptr dead_on_unwind noalias writable sret(%"class.leveldb::Status") align 8 %0, ptr noundef nonnull align 8 dereferenceable(104) %1, ptr noundef %2, ptr noundef %3) #1 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i1, align 1
  %10 = alloca [9 x i8], align 1
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.leveldb::Slice", align 8
  %14 = alloca ptr, align 8
  %15 = alloca %"class.std::vector.3", align 8
  %16 = alloca %"class.std::vector", align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca ptr, align 8
  %20 = alloca %"class.leveldb::Status", align 8
  %21 = alloca %"class.leveldb::Status", align 8
  %22 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  store ptr %3, ptr %8, align 8, !tbaa !5
  %23 = load ptr, ptr %6, align 8
  store i1 false, ptr %9, align 1
  call void @_ZN7leveldb6StatusC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #7
  call void @llvm.lifetime.start.p0(i64 9, ptr %10) #7
  %24 = getelementptr inbounds [9 x i8], ptr %10, i64 0, i64 0
  store i8 84, ptr %24, align 1, !tbaa !9
  %25 = getelementptr inbounds [9 x i8], ptr %10, i64 0, i64 0
  %26 = getelementptr inbounds i8, ptr %25, i64 1
  %27 = load ptr, ptr %7, align 8, !tbaa !5
  %28 = getelementptr inbounds %"struct.leveldb::FileMetaData", ptr %27, i32 0, i32 2
  %29 = load i64, ptr %28, align 8, !tbaa !10
  invoke void @_ZN7leveldb13EncodeFixed64EPcm(ptr noundef %26, i64 noundef %29)
          to label %30 unwind label %53

30:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 16, ptr %13) #7
  %31 = getelementptr inbounds [9 x i8], ptr %10, i64 0, i64 0
  invoke void @_ZN7leveldb5SliceC2EPKcm(ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef %31, i64 noundef 9)
          to label %32 unwind label %57

32:                                               ; preds = %30
  %33 = getelementptr inbounds %"class.leveldb::TableCacheNVM", ptr %23, i32 0, i32 3
  %34 = load ptr, ptr %33, align 8, !tbaa !22
  %35 = load ptr, ptr %34, align 8, !tbaa !24
  %36 = getelementptr inbounds ptr, ptr %35, i64 3
  %37 = load ptr, ptr %36, align 8
  %38 = invoke noundef ptr %37(ptr noundef nonnull align 8 dereferenceable(16) %34, ptr noundef nonnull align 8 dereferenceable(16) %13)
          to label %39 unwind label %57

39:                                               ; preds = %32
  %40 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %38, ptr %40, align 8, !tbaa !5
  %41 = load ptr, ptr %8, align 8, !tbaa !5
  %42 = load ptr, ptr %41, align 8, !tbaa !5
  %43 = icmp eq ptr %42, null
  br i1 %43, label %44, label %155

44:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #7
  store ptr null, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #7
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #7
  store i32 0, ptr %17, align 4, !tbaa !26
  br label %45

45:                                               ; preds = %96, %44
  %46 = load i32, ptr %17, align 4, !tbaa !26
  %47 = sext i32 %46 to i64
  %48 = load ptr, ptr %7, align 8, !tbaa !5
  %49 = getelementptr inbounds %"struct.leveldb::FileMetaData", ptr %48, i32 0, i32 7
  %50 = call noundef i64 @_ZNKSt6vectorIPN7leveldb11SegmentMetaESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %49) #7
  %51 = icmp ult i64 %47, %50
  br i1 %51, label %61, label %52

52:                                               ; preds = %45
  store i32 2, ptr %18, align 4
  br label %100

53:                                               ; preds = %4
  %54 = landingpad { ptr, i32 }
          cleanup
  %55 = extractvalue { ptr, i32 } %54, 0
  store ptr %55, ptr %11, align 8
  %56 = extractvalue { ptr, i32 } %54, 1
  store i32 %56, ptr %12, align 4
  br label %159

57:                                               ; preds = %32, %30
  %58 = landingpad { ptr, i32 }
          cleanup
  %59 = extractvalue { ptr, i32 } %58, 0
  store ptr %59, ptr %11, align 8
  %60 = extractvalue { ptr, i32 } %58, 1
  store i32 %60, ptr %12, align 4
  br label %158

61:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #7
  store ptr null, ptr %19, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #7
  %62 = load ptr, ptr %7, align 8, !tbaa !5
  %63 = getelementptr inbounds %"struct.leveldb::FileMetaData", ptr %62, i32 0, i32 7
  %64 = load i32, ptr %17, align 4, !tbaa !26
  %65 = sext i32 %64 to i64
  %66 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN7leveldb11SegmentMetaESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %63, i64 noundef %65) #7
  %67 = load ptr, ptr %66, align 8, !tbaa !5
  invoke void @_ZN7leveldb13TableCacheNVM11FindSegmentEPKNS_11SegmentMetaEPPNS_5Cache6HandleE(ptr dead_on_unwind writable sret(%"class.leveldb::Status") align 8 %20, ptr noundef nonnull align 8 dereferenceable(104) %23, ptr noundef %67, ptr noundef %19)
          to label %68 unwind label %73

68:                                               ; preds = %61
  %69 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN7leveldb6StatusaSEOS0_(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 8 dereferenceable(8) %20) #7
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %20) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #7
  %70 = invoke noundef zeroext i1 @_ZNK7leveldb6Status2okEv(ptr noundef nonnull align 8 dereferenceable(8) %0)
          to label %71 unwind label %77

71:                                               ; preds = %68
  br i1 %70, label %81, label %72

72:                                               ; preds = %71
  store i1 true, ptr %9, align 1
  store i32 1, ptr %18, align 4
  br label %93

73:                                               ; preds = %61
  %74 = landingpad { ptr, i32 }
          cleanup
  %75 = extractvalue { ptr, i32 } %74, 0
  store ptr %75, ptr %11, align 8
  %76 = extractvalue { ptr, i32 } %74, 1
  store i32 %76, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #7
  br label %99

77:                                               ; preds = %90, %82, %81, %68
  %78 = landingpad { ptr, i32 }
          cleanup
  %79 = extractvalue { ptr, i32 } %78, 0
  store ptr %79, ptr %11, align 8
  %80 = extractvalue { ptr, i32 } %78, 1
  store i32 %80, ptr %12, align 4
  br label %99

81:                                               ; preds = %71
  invoke void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EE9push_backERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %16, ptr noundef nonnull align 8 dereferenceable(8) %19)
          to label %82 unwind label %77

82:                                               ; preds = %81
  %83 = getelementptr inbounds %"class.leveldb::TableCacheNVM", ptr %23, i32 0, i32 4
  %84 = load ptr, ptr %83, align 8, !tbaa !27
  %85 = load ptr, ptr %19, align 8, !tbaa !5
  %86 = load ptr, ptr %84, align 8, !tbaa !24
  %87 = getelementptr inbounds ptr, ptr %86, i64 5
  %88 = load ptr, ptr %87, align 8
  %89 = invoke noundef ptr %88(ptr noundef nonnull align 8 dereferenceable(16) %84, ptr noundef %85)
          to label %90 unwind label %77

90:                                               ; preds = %82
  %91 = getelementptr inbounds %"struct.leveldb::SegmentAndFileHandle", ptr %89, i32 0, i32 1
  invoke void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(8) %91)
          to label %92 unwind label %77

92:                                               ; preds = %90
  store i32 0, ptr %18, align 4
  br label %93

93:                                               ; preds = %92, %72
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #7
  %94 = load i32, ptr %18, align 4
  switch i32 %94, label %100 [
    i32 0, label %95
  ]

95:                                               ; preds = %93
  br label %96

96:                                               ; preds = %95
  %97 = load i32, ptr %17, align 4, !tbaa !26
  %98 = add nsw i32 %97, 1
  store i32 %98, ptr %17, align 4, !tbaa !26
  br label %45, !llvm.loop !28

99:                                               ; preds = %77, %73
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #7
  br label %154

100:                                              ; preds = %93, %52
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #7
  %101 = load i32, ptr %18, align 4
  switch i32 %101, label %151 [
    i32 2, label %102
  ]

102:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #7
  %103 = getelementptr inbounds %"class.leveldb::TableCacheNVM", ptr %23, i32 0, i32 2
  %104 = load ptr, ptr %103, align 8, !tbaa !30
  invoke void @_ZN7leveldb8TableNVM4OpenERKNS_7OptionsERSt6vectorIPNS_7SegmentESaIS6_EEPPS0_(ptr dead_on_unwind writable sret(%"class.leveldb::Status") align 8 %21, ptr noundef nonnull align 8 dereferenceable(104) %104, ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef %14)
          to label %105 unwind label %114

105:                                              ; preds = %102
  %106 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN7leveldb6StatusaSEOS0_(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 8 dereferenceable(8) %21) #7
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %21) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #7
  %107 = invoke noundef zeroext i1 @_ZNK7leveldb6Status2okEv(ptr noundef nonnull align 8 dereferenceable(8) %0)
          to label %108 unwind label %118

108:                                              ; preds = %105
  br i1 %107, label %124, label %109

109:                                              ; preds = %108
  %110 = load ptr, ptr %14, align 8, !tbaa !5
  %111 = icmp eq ptr %110, null
  br i1 %111, label %112, label %113

112:                                              ; preds = %109
  br label %123

113:                                              ; preds = %109
  call void @__assert_fail(ptr noundef @.str.5, ptr noundef @.str.2, i32 noundef 228, ptr noundef @__PRETTY_FUNCTION__._ZN7leveldb13TableCacheNVM12FindTableNVMEPKNS_12FileMetaDataEPPNS_5Cache6HandleE) #8
  unreachable

114:                                              ; preds = %102
  %115 = landingpad { ptr, i32 }
          cleanup
  %116 = extractvalue { ptr, i32 } %115, 0
  store ptr %116, ptr %11, align 8
  %117 = extractvalue { ptr, i32 } %115, 1
  store i32 %117, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #7
  br label %154

118:                                              ; preds = %105
  %119 = landingpad { ptr, i32 }
          cleanup
  %120 = extractvalue { ptr, i32 } %119, 0
  store ptr %120, ptr %11, align 8
  %121 = extractvalue { ptr, i32 } %119, 1
  store i32 %121, ptr %12, align 4
  br label %154

122:                                              ; No predecessors!
  br label %123

123:                                              ; preds = %122, %112
  br label %150

124:                                              ; preds = %108
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #7
  %125 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef 40) #9
          to label %126 unwind label %146

126:                                              ; preds = %124
  call void @_ZN7leveldb18TableAndSegHandlesC2Ev(ptr noundef nonnull align 8 dereferenceable(40) %125) #7
  store ptr %125, ptr %22, align 8, !tbaa !5
  %127 = getelementptr inbounds %"class.leveldb::TableCacheNVM", ptr %23, i32 0, i32 4
  %128 = load ptr, ptr %127, align 8, !tbaa !27
  %129 = load ptr, ptr %22, align 8, !tbaa !5
  %130 = getelementptr inbounds %"struct.leveldb::TableAndSegHandles", ptr %129, i32 0, i32 0
  store ptr %128, ptr %130, align 8, !tbaa !31
  %131 = load ptr, ptr %14, align 8, !tbaa !5
  %132 = load ptr, ptr %22, align 8, !tbaa !5
  %133 = getelementptr inbounds %"struct.leveldb::TableAndSegHandles", ptr %132, i32 0, i32 1
  store ptr %131, ptr %133, align 8, !tbaa !37
  %134 = load ptr, ptr %22, align 8, !tbaa !5
  %135 = getelementptr inbounds %"struct.leveldb::TableAndSegHandles", ptr %134, i32 0, i32 2
  %136 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EEaSEOS5_(ptr noundef nonnull align 8 dereferenceable(24) %135, ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  %137 = getelementptr inbounds %"class.leveldb::TableCacheNVM", ptr %23, i32 0, i32 3
  %138 = load ptr, ptr %137, align 8, !tbaa !22
  %139 = load ptr, ptr %22, align 8, !tbaa !5
  %140 = load ptr, ptr %138, align 8, !tbaa !24
  %141 = getelementptr inbounds ptr, ptr %140, i64 2
  %142 = load ptr, ptr %141, align 8
  %143 = invoke noundef ptr %142(ptr noundef nonnull align 8 dereferenceable(16) %138, ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef %139, i64 noundef 1, ptr noundef @_ZN7leveldbL14DeleteEntryNVMERKNS_5SliceEPv)
          to label %144 unwind label %146

144:                                              ; preds = %126
  %145 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %143, ptr %145, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #7
  br label %150

146:                                              ; preds = %126, %124
  %147 = landingpad { ptr, i32 }
          cleanup
  %148 = extractvalue { ptr, i32 } %147, 0
  store ptr %148, ptr %11, align 8
  %149 = extractvalue { ptr, i32 } %147, 1
  store i32 %149, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #7
  br label %154

150:                                              ; preds = %144, %123
  store i32 0, ptr %18, align 4
  br label %151

151:                                              ; preds = %150, %100
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  %152 = load i32, ptr %18, align 4
  switch i32 %152, label %156 [
    i32 0, label %153
  ]

153:                                              ; preds = %151
  br label %155

154:                                              ; preds = %146, %118, %114, %99
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  br label %158

155:                                              ; preds = %153, %39
  store i1 true, ptr %9, align 1
  store i32 1, ptr %18, align 4
  br label %156

156:                                              ; preds = %155, %151
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 9, ptr %10) #7
  %157 = load i1, ptr %9, align 1
  br i1 %157, label %161, label %160

158:                                              ; preds = %154, %57
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #7
  br label %159

159:                                              ; preds = %158, %53
  call void @llvm.lifetime.end.p0(i64 9, ptr %10) #7
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #7
  br label %162

160:                                              ; preds = %156
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #7
  br label %161

161:                                              ; preds = %160, %156
  ret void

162:                                              ; preds = %159
  %163 = load ptr, ptr %11, align 8
  %164 = load i32, ptr %12, align 4
  %165 = insertvalue { ptr, i32 } poison, ptr %163, 0
  %166 = insertvalue { ptr, i32 } %165, i32 %164, 1
  resume { ptr, i32 } %166
}

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7leveldb13TableCacheNVM11FindSegmentEPKNS_11SegmentMetaEPPNS_5Cache6HandleE(ptr dead_on_unwind noalias writable sret(%"class.leveldb::Status") align 8, ptr noundef nonnull align 8 dereferenceable(104), ptr noundef, ptr noundef) #1 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7leveldb13EncodeFixed64EPcm(ptr noundef, i64 noundef) #3

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

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

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

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

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

declare void @_ZN7leveldb8TableNVM4OpenERKNS_7OptionsERSt6vectorIPNS_7SegmentESaIS6_EEPPS0_(ptr dead_on_unwind writable sret(%"class.leveldb::Status") align 8, ptr noundef nonnull align 8 dereferenceable(104), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef) #5

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

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

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN7leveldbL14DeleteEntryNVMERKNS_5SliceEPv(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #1

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 = { "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 = { 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 #7 = { nounwind }
attributes #8 = { noreturn nounwind }
attributes #9 = { builtin allocsize(0) }

!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 = !{!7, !7, i64 0}
!10 = !{!11, !13, i64 8}
!11 = !{!"_ZTSN7leveldb12FileMetaDataE", !12, i64 0, !12, i64 4, !13, i64 8, !13, i64 16, !14, i64 24, !14, i64 56, !17, i64 88, !18, i64 96}
!12 = !{!"int", !7, i64 0}
!13 = !{!"long", !7, i64 0}
!14 = !{!"_ZTSN7leveldb11InternalKeyE", !15, i64 0}
!15 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !16, i64 0, !13, i64 8, !7, i64 16}
!16 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!17 = !{!"bool", !7, i64 0}
!18 = !{!"_ZTSSt6vectorIPN7leveldb11SegmentMetaESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseIPN7leveldb11SegmentMetaESaIS2_EE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb11SegmentMetaESaIS2_EE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb11SegmentMetaESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!22 = !{!23, !6, i64 48}
!23 = !{!"_ZTSN7leveldb13TableCacheNVME", !6, i64 0, !15, i64 8, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !15, i64 72}
!24 = !{!25, !25, i64 0}
!25 = !{!"vtable pointer", !8, i64 0}
!26 = !{!12, !12, i64 0}
!27 = !{!23, !6, i64 56}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.mustprogress"}
!30 = !{!23, !6, i64 40}
!31 = !{!32, !6, i64 0}
!32 = !{!"_ZTSN7leveldb18TableAndSegHandlesE", !6, i64 0, !6, i64 8, !33, i64 16}
!33 = !{!"_ZTSSt6vectorIPN7leveldb5Cache6HandleESaIS3_EE", !34, i64 0}
!34 = !{!"_ZTSSt12_Vector_baseIPN7leveldb5Cache6HandleESaIS3_EE", !35, i64 0}
!35 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb5Cache6HandleESaIS3_EE12_Vector_implE", !36, i64 0}
!36 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb5Cache6HandleESaIS3_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!37 = !{!32, !6, i64 8}


; 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.leveldb::Status" = type { ptr }
%"class.leveldb::Slice" = type { ptr, i64 }
%"class.std::vector.3" = type { %"struct.std::_Vector_base.4" }
%"struct.std::_Vector_base.4" = type { %"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl" }
%"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl" = type { %"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<leveldb::Segment *, std::allocator<leveldb::Segment *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl" }
%"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl" = type { %"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<leveldb::Cache::Handle *, std::allocator<leveldb::Cache::Handle *>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@.str.2 = external hidden unnamed_addr constant [83 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [17 x i8], align 1
@__PRETTY_FUNCTION__._ZN7leveldb13TableCacheNVM12FindTableNVMEPKNS_12FileMetaDataEPPNS_5Cache6HandleE = external hidden unnamed_addr constant [84 x i8], align 1

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7leveldb13TableCacheNVM12FindTableNVMEPKNS_12FileMetaDataEPPNS_5Cache6HandleE(ptr dead_on_unwind noalias nonnull writable sret(%"class.leveldb::Status") align 8 %0, ptr noundef nonnull align 8 dereferenceable(104) %1, ptr noundef %2, ptr nocapture noundef writeonly %3) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca [9 x i8], align 1
  %6 = alloca %"class.leveldb::Slice", align 8
  %7 = alloca ptr, align 8
  %8 = alloca %"class.std::vector.3", align 8
  %9 = alloca %"class.std::vector", align 8
  %10 = alloca ptr, align 8
  %11 = alloca %"class.leveldb::Status", align 8
  %12 = alloca %"class.leveldb::Status", align 8
  tail call void @_ZN7leveldb6StatusC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #7
  call void @llvm.lifetime.start.p0(i64 9, ptr nonnull %5) #7
  store i8 84, ptr %5, align 1, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %5, i64 1
  %14 = getelementptr inbounds i8, ptr %2, i64 8
  %15 = load i64, ptr %14, align 8, !tbaa !8
  call void @_ZN7leveldb13EncodeFixed64EPcm(ptr noundef nonnull %13, i64 noundef %15)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #7
  call void @_ZN7leveldb5SliceC2EPKcm(ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull %5, i64 noundef 9)
  %16 = getelementptr inbounds i8, ptr %1, i64 48
  %17 = load ptr, ptr %16, align 8, !tbaa !21
  %18 = load ptr, ptr %17, align 8, !tbaa !23
  %19 = getelementptr inbounds i8, ptr %18, i64 24
  %20 = load ptr, ptr %19, align 8
  %21 = invoke noundef ptr %20(ptr noundef nonnull align 8 dereferenceable(16) %17, ptr noundef nonnull align 8 dereferenceable(16) %6)
          to label %22 unwind label %28

22:                                               ; preds = %4
  store ptr %21, ptr %3, align 8, !tbaa !25
  %23 = icmp eq ptr %21, null
  br i1 %23, label %24, label %.critedge37

24:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #7
  store ptr null, ptr %7, align 8, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #7
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #7
  %25 = getelementptr inbounds i8, ptr %2, i64 96
  %26 = call noundef i64 @_ZNKSt6vectorIPN7leveldb11SegmentMetaESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %25) #7
  %.not.not44.not = icmp eq i64 %26, 0
  br i1 %.not.not44.not, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %24
  %27 = getelementptr inbounds i8, ptr %1, i64 56
  br label %30

28:                                               ; preds = %4
  %29 = landingpad { ptr, i32 }
          cleanup
  br label %84

30:                                               ; preds = %.lr.ph, %50
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %50 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #7
  store ptr null, ptr %10, align 8, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #7
  %31 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN7leveldb11SegmentMetaESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %25, i64 noundef %indvars.iv) #7
  %32 = load ptr, ptr %31, align 8, !tbaa !25
  invoke void @_ZN7leveldb13TableCacheNVM11FindSegmentEPKNS_11SegmentMetaEPPNS_5Cache6HandleE(ptr dead_on_unwind nonnull writable sret(%"class.leveldb::Status") align 8 %11, ptr noundef nonnull align 8 dereferenceable(104) %1, ptr noundef %32, ptr noundef nonnull %10)
          to label %33 unwind label %36

33:                                               ; preds = %30
  %34 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN7leveldb6StatusaSEOS0_(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 8 dereferenceable(8) %11) #7
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %11) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #7
  %35 = call noundef zeroext i1 @_ZNK7leveldb6Status2okEv(ptr noundef nonnull align 8 dereferenceable(8) %0)
  br i1 %35, label %40, label %83

36:                                               ; preds = %30
  %37 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #7
  br label %52

38:                                               ; preds = %48, %41, %40
  %39 = landingpad { ptr, i32 }
          cleanup
  br label %52

40:                                               ; preds = %33
  invoke void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EE9push_backERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %41 unwind label %38

41:                                               ; preds = %40
  %42 = load ptr, ptr %27, align 8, !tbaa !26
  %43 = load ptr, ptr %10, align 8, !tbaa !25
  %44 = load ptr, ptr %42, align 8, !tbaa !23
  %45 = getelementptr inbounds i8, ptr %44, i64 40
  %46 = load ptr, ptr %45, align 8
  %47 = invoke noundef ptr %46(ptr noundef nonnull align 8 dereferenceable(16) %42, ptr noundef %43)
          to label %48 unwind label %38

48:                                               ; preds = %41
  %49 = getelementptr inbounds i8, ptr %47, i64 8
  invoke void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull align 8 dereferenceable(8) %49)
          to label %50 unwind label %38

50:                                               ; preds = %48
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %51 = call noundef i64 @_ZNKSt6vectorIPN7leveldb11SegmentMetaESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %25) #7
  %.not.not = icmp ugt i64 %51, %indvars.iv.next
  br i1 %.not.not, label %30, label %._crit_edge, !llvm.loop !27

52:                                               ; preds = %38, %36
  %.pn = phi { ptr, i32 } [ %39, %38 ], [ %37, %36 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  br label %82

._crit_edge:                                      ; preds = %50, %24
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #7
  %53 = getelementptr inbounds i8, ptr %1, i64 40
  %54 = load ptr, ptr %53, align 8, !tbaa !29
  invoke void @_ZN7leveldb8TableNVM4OpenERKNS_7OptionsERSt6vectorIPNS_7SegmentESaIS6_EEPPS0_(ptr dead_on_unwind nonnull writable sret(%"class.leveldb::Status") align 8 %12, ptr noundef nonnull align 8 dereferenceable(104) %54, ptr noundef nonnull align 8 dereferenceable(24) %8, ptr noundef nonnull %7)
          to label %55 unwind label %62

55:                                               ; preds = %._crit_edge
  %56 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN7leveldb6StatusaSEOS0_(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 8 dereferenceable(8) %12) #7
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %12) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #7
  %57 = call noundef zeroext i1 @_ZNK7leveldb6Status2okEv(ptr noundef nonnull align 8 dereferenceable(8) %0)
  br i1 %57, label %64, label %58

58:                                               ; preds = %55
  %59 = load ptr, ptr %7, align 8, !tbaa !25
  %60 = icmp eq ptr %59, null
  br i1 %60, label %81, label %61

61:                                               ; preds = %58
  call void @__assert_fail(ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.2, i32 noundef 228, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN7leveldb13TableCacheNVM12FindTableNVMEPKNS_12FileMetaDataEPPNS_5Cache6HandleE) #8
  unreachable

62:                                               ; preds = %._crit_edge
  %63 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #7
  br label %82

64:                                               ; preds = %55
  %65 = invoke noalias noundef nonnull dereferenceable(40) ptr @_Znwm(i64 noundef 40) #9
          to label %66 unwind label %79

66:                                               ; preds = %64
  call void @_ZN7leveldb18TableAndSegHandlesC2Ev(ptr noundef nonnull align 8 dereferenceable(40) %65) #7
  %67 = getelementptr inbounds i8, ptr %1, i64 56
  %68 = load ptr, ptr %67, align 8, !tbaa !26
  store ptr %68, ptr %65, align 8, !tbaa !30
  %69 = load ptr, ptr %7, align 8, !tbaa !25
  %70 = getelementptr inbounds i8, ptr %65, i64 8
  store ptr %69, ptr %70, align 8, !tbaa !36
  %71 = getelementptr inbounds i8, ptr %65, i64 16
  %72 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EEaSEOS5_(ptr noundef nonnull align 8 dereferenceable(24) %71, ptr noundef nonnull align 8 dereferenceable(24) %9) #7
  %73 = load ptr, ptr %16, align 8, !tbaa !21
  %74 = load ptr, ptr %73, align 8, !tbaa !23
  %75 = getelementptr inbounds i8, ptr %74, i64 16
  %76 = load ptr, ptr %75, align 8
  %77 = invoke noundef ptr %76(ptr noundef nonnull align 8 dereferenceable(16) %73, ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull %65, i64 noundef 1, ptr noundef nonnull @_ZN7leveldbL14DeleteEntryNVMERKNS_5SliceEPv)
          to label %78 unwind label %79

78:                                               ; preds = %66
  store ptr %77, ptr %3, align 8, !tbaa !25
  br label %81

79:                                               ; preds = %66, %64
  %80 = landingpad { ptr, i32 }
          cleanup
  br label %82

81:                                               ; preds = %78, %58
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  br label %.critedge37

82:                                               ; preds = %79, %62, %52
  %.pn33 = phi { ptr, i32 } [ %80, %79 ], [ %63, %62 ], [ %.pn, %52 ]
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  br label %84

.critedge37:                                      ; preds = %81, %22
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 9, ptr nonnull %5) #7
  br label %85

83:                                               ; preds = %33
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  call void @_ZNSt6vectorIPN7leveldb5Cache6HandleESaIS3_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #7
  call void @_ZNSt6vectorIPN7leveldb7SegmentESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 9, ptr nonnull %5) #7
  br label %85

84:                                               ; preds = %82, %28
  %.pn33.pn = phi { ptr, i32 } [ %.pn33, %82 ], [ %29, %28 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 9, ptr nonnull %5) #7
  call void @_ZN7leveldb6StatusD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #7
  resume { ptr, i32 } %.pn33.pn

85:                                               ; preds = %83, %.critedge37
  ret void
}

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7leveldb13TableCacheNVM11FindSegmentEPKNS_11SegmentMetaEPPNS_5Cache6HandleE(ptr dead_on_unwind noalias writable sret(%"class.leveldb::Status") align 8, ptr noundef nonnull align 8 dereferenceable(104), ptr noundef, ptr noundef) local_unnamed_addr #1 align 2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7leveldb13EncodeFixed64EPcm(ptr noundef, i64 noundef) local_unnamed_addr #3

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

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

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

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

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

declare void @_ZN7leveldb8TableNVM4OpenERKNS_7OptionsERSt6vectorIPNS_7SegmentESaIS6_EEPPS0_(ptr dead_on_unwind writable sret(%"class.leveldb::Status") align 8, ptr noundef nonnull align 8 dereferenceable(104), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef) local_unnamed_addr #5

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

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

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN7leveldbL14DeleteEntryNVMERKNS_5SliceEPv(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #1

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

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 = { "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 = { 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 #7 = { nounwind }
attributes #8 = { noreturn nounwind }
attributes #9 = { builtin allocsize(0) }

!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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !11, i64 8}
!9 = !{!"_ZTSN7leveldb12FileMetaDataE", !10, i64 0, !10, i64 4, !11, i64 8, !11, i64 16, !12, i64 24, !12, i64 56, !16, i64 88, !17, i64 96}
!10 = !{!"int", !6, i64 0}
!11 = !{!"long", !6, i64 0}
!12 = !{!"_ZTSN7leveldb11InternalKeyE", !13, i64 0}
!13 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !14, i64 0, !11, i64 8, !6, i64 16}
!14 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !15, i64 0}
!15 = !{!"any pointer", !6, i64 0}
!16 = !{!"bool", !6, i64 0}
!17 = !{!"_ZTSSt6vectorIPN7leveldb11SegmentMetaESaIS2_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseIPN7leveldb11SegmentMetaESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb11SegmentMetaESaIS2_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb11SegmentMetaESaIS2_EE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!21 = !{!22, !15, i64 48}
!22 = !{!"_ZTSN7leveldb13TableCacheNVME", !15, i64 0, !13, i64 8, !15, i64 40, !15, i64 48, !15, i64 56, !15, i64 64, !13, i64 72}
!23 = !{!24, !24, i64 0}
!24 = !{!"vtable pointer", !7, i64 0}
!25 = !{!15, !15, i64 0}
!26 = !{!22, !15, i64 56}
!27 = distinct !{!27, !28}
!28 = !{!"llvm.loop.mustprogress"}
!29 = !{!22, !15, i64 40}
!30 = !{!31, !15, i64 0}
!31 = !{!"_ZTSN7leveldb18TableAndSegHandlesE", !15, i64 0, !15, i64 8, !32, i64 16}
!32 = !{!"_ZTSSt6vectorIPN7leveldb5Cache6HandleESaIS3_EE", !33, i64 0}
!33 = !{!"_ZTSSt12_Vector_baseIPN7leveldb5Cache6HandleESaIS3_EE", !34, i64 0}
!34 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb5Cache6HandleESaIS3_EE12_Vector_implE", !35, i64 0}
!35 = !{!"_ZTSNSt12_Vector_baseIPN7leveldb5Cache6HandleESaIS3_EE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!36 = !{!31, !15, i64 8}


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