; LLVM IR from weicao/cascadb :: src/serialize/layout.ll (ZN7cascadb6LayoutC2EPNS_7AIOFileEmRKNS_7OptionsE)

; 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::Layout" = type { ptr, i64, %"class.cascadb::Options", %"class.cascadb::Mutex", i64, ptr, %"class.cascadb::Mutex", %"class.std::map", %"class.std::map", %"class.cascadb::Mutex", %"class.cascadb::Mutex", %"class.std::deque", %"class.std::deque", i64, i64 }
%"class.cascadb::Options" = type <{ ptr, ptr, i64, i64, i64, i64, i64, i64, i64, i32, i32, i32, i32, i32, i32, i32, i8, [3 x i8] }>
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned long, std::pair<const unsigned long, cascadb::BlockMeta *>, std::_Select1st<std::pair<const unsigned long, cascadb::BlockMeta *>>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, std::pair<const unsigned long, cascadb::BlockMeta *>, std::_Select1st<std::pair<const unsigned long, cascadb::BlockMeta *>>, std::less<unsigned long>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"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 }
%"class.std::deque" = type { %"class.std::_Deque_base" }
%"class.std::_Deque_base" = type { %"struct.std::_Deque_base<cascadb::Layout::Hole, std::allocator<cascadb::Layout::Hole>>::_Deque_impl" }
%"struct.std::_Deque_base<cascadb::Layout::Hole, std::allocator<cascadb::Layout::Hole>>::_Deque_impl" = type { %"struct.std::_Deque_base<cascadb::Layout::Hole, std::allocator<cascadb::Layout::Hole>>::_Deque_impl_data" }
%"struct.std::_Deque_base<cascadb::Layout::Hole, std::allocator<cascadb::Layout::Hole>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator", %"struct.std::_Deque_iterator" }
%"struct.std::_Deque_iterator" = type { ptr, ptr, ptr, ptr }

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7cascadb6LayoutC2EPNS_7AIOFileEmRKNS_7OptionsE(ptr noundef nonnull align 8 dereferenceable(600) %0, ptr noundef %1, i64 noundef %2, ptr noundef nonnull align 8 dereferenceable(101) %3) unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store i64 %2, ptr %7, align 8, !tbaa !9
  store ptr %3, ptr %8, align 8, !tbaa !5
  %11 = load ptr, ptr %5, align 8
  %12 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 0
  %13 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %13, ptr %12, align 8, !tbaa !11
  %14 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 1
  %15 = load i64, ptr %7, align 8, !tbaa !9
  store i64 %15, ptr %14, align 8, !tbaa !31
  %16 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 2
  %17 = load ptr, ptr %8, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %16, ptr align 8 %17, i64 104, i1 false), !tbaa.struct !32
  %18 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 3
  call void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18)
  %19 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 4
  store i64 0, ptr %19, align 8, !tbaa !36
  %20 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 5
  %21 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef 32) #7
          to label %22 unwind label %38

22:                                               ; preds = %4
  invoke void @_ZN7cascadb10SuperBlockC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %21)
          to label %23 unwind label %42

23:                                               ; preds = %22
  store ptr %21, ptr %20, align 8, !tbaa !37
  %24 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 6
  invoke void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %24)
          to label %25 unwind label %38

25:                                               ; preds = %23
  %26 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 7
  call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %26) #8
  %27 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 8
  call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %27) #8
  %28 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 9
  invoke void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %28)
          to label %29 unwind label %46

29:                                               ; preds = %25
  %30 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 10
  invoke void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %30)
          to label %31 unwind label %50

31:                                               ; preds = %29
  %32 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 11
  invoke void @_ZNSt5dequeIN7cascadb6Layout4HoleESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(80) %32)
          to label %33 unwind label %54

33:                                               ; preds = %31
  %34 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 12
  invoke void @_ZNSt5dequeIN7cascadb6Layout4HoleESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(80) %34)
          to label %35 unwind label %58

35:                                               ; preds = %33
  %36 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 13
  store i64 0, ptr %36, align 8, !tbaa !38
  %37 = getelementptr inbounds %"class.cascadb::Layout", ptr %11, i32 0, i32 14
  store i64 0, ptr %37, align 8, !tbaa !39
  ret void

38:                                               ; preds = %23, %4
  %39 = landingpad { ptr, i32 }
          cleanup
  %40 = extractvalue { ptr, i32 } %39, 0
  store ptr %40, ptr %9, align 8
  %41 = extractvalue { ptr, i32 } %39, 1
  store i32 %41, ptr %10, align 4
  br label %65

42:                                               ; preds = %22
  %43 = landingpad { ptr, i32 }
          cleanup
  %44 = extractvalue { ptr, i32 } %43, 0
  store ptr %44, ptr %9, align 8
  %45 = extractvalue { ptr, i32 } %43, 1
  store i32 %45, ptr %10, align 4
  call void @_ZdlPvm(ptr noundef %21, i64 noundef 32) #9
  br label %65

46:                                               ; preds = %25
  %47 = landingpad { ptr, i32 }
          cleanup
  %48 = extractvalue { ptr, i32 } %47, 0
  store ptr %48, ptr %9, align 8
  %49 = extractvalue { ptr, i32 } %47, 1
  store i32 %49, ptr %10, align 4
  br label %64

50:                                               ; preds = %29
  %51 = landingpad { ptr, i32 }
          cleanup
  %52 = extractvalue { ptr, i32 } %51, 0
  store ptr %52, ptr %9, align 8
  %53 = extractvalue { ptr, i32 } %51, 1
  store i32 %53, ptr %10, align 4
  br label %63

54:                                               ; preds = %31
  %55 = landingpad { ptr, i32 }
          cleanup
  %56 = extractvalue { ptr, i32 } %55, 0
  store ptr %56, ptr %9, align 8
  %57 = extractvalue { ptr, i32 } %55, 1
  store i32 %57, ptr %10, align 4
  br label %62

58:                                               ; preds = %33
  %59 = landingpad { ptr, i32 }
          cleanup
  %60 = extractvalue { ptr, i32 } %59, 0
  store ptr %60, ptr %9, align 8
  %61 = extractvalue { ptr, i32 } %59, 1
  store i32 %61, ptr %10, align 4
  call void @_ZNSt5dequeIN7cascadb6Layout4HoleESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %32) #8
  br label %62

62:                                               ; preds = %58, %54
  call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %30) #8
  br label %63

63:                                               ; preds = %62, %50
  call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %28) #8
  br label %64

64:                                               ; preds = %63, %46
  call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %27) #8
  call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %26) #8
  call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %24) #8
  br label %65

65:                                               ; preds = %64, %42, %38
  call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18) #8
  br label %66

66:                                               ; preds = %65
  %67 = load ptr, ptr %9, align 8
  %68 = load i32, ptr %10, align 4
  %69 = insertvalue { ptr, i32 } poison, ptr %67, 0
  %70 = insertvalue { ptr, i32 } %69, i32 %68, 1
  resume { ptr, i32 } %70
}

; 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) #1

declare void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #2

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

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

; Function Attrs: nounwind
declare void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #6

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

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

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !6, i64 0}
!12 = !{!"_ZTSN7cascadb6LayoutE", !6, i64 0, !10, i64 8, !13, i64 16, !17, i64 120, !10, i64 168, !6, i64 176, !17, i64 184, !18, i64 232, !18, i64 280, !17, i64 328, !17, i64 376, !26, i64 424, !26, i64 504, !10, i64 584, !10, i64 592}
!13 = !{!"_ZTSN7cascadb7OptionsE", !6, i64 0, !6, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !14, i64 72, !14, i64 76, !14, i64 80, !14, i64 84, !14, i64 88, !14, i64 92, !15, i64 96, !16, i64 100}
!14 = !{!"int", !7, i64 0}
!15 = !{!"_ZTSN7cascadb8CompressE", !7, i64 0}
!16 = !{!"bool", !7, i64 0}
!17 = !{!"_ZTSN7cascadb5MutexE", !16, i64 0, !7, i64 8}
!18 = !{!"_ZTSSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEE", !19, i64 0}
!19 = !{!"_ZTSSt8_Rb_treeImSt4pairIKmPN7cascadb9BlockMetaEESt10_Select1stIS5_ESt4lessImESaIS5_EE", !20, i64 0}
!20 = !{!"_ZTSNSt8_Rb_treeImSt4pairIKmPN7cascadb9BlockMetaEESt10_Select1stIS5_ESt4lessImESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !21, i64 0, !23, i64 8}
!21 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessImEE", !22, i64 0}
!22 = !{!"_ZTSSt4lessImE"}
!23 = !{!"_ZTSSt15_Rb_tree_header", !24, i64 0, !10, i64 32}
!24 = !{!"_ZTSSt18_Rb_tree_node_base", !25, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!25 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!26 = !{!"_ZTSSt5dequeIN7cascadb6Layout4HoleESaIS2_EE", !27, i64 0}
!27 = !{!"_ZTSSt11_Deque_baseIN7cascadb6Layout4HoleESaIS2_EE", !28, i64 0}
!28 = !{!"_ZTSNSt11_Deque_baseIN7cascadb6Layout4HoleESaIS2_EE11_Deque_implE", !29, i64 0}
!29 = !{!"_ZTSNSt11_Deque_baseIN7cascadb6Layout4HoleESaIS2_EE16_Deque_impl_dataE", !6, i64 0, !10, i64 8, !30, i64 16, !30, i64 48}
!30 = !{!"_ZTSSt15_Deque_iteratorIN7cascadb6Layout4HoleERS2_PS2_E", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!31 = !{!12, !10, i64 8}
!32 = !{i64 0, i64 8, !5, i64 8, i64 8, !5, i64 16, i64 8, !9, i64 24, i64 8, !9, i64 32, i64 8, !9, i64 40, i64 8, !9, i64 48, i64 8, !9, i64 56, i64 8, !9, i64 64, i64 8, !9, i64 72, i64 4, !33, i64 76, i64 4, !33, i64 80, i64 4, !33, i64 84, i64 4, !33, i64 88, i64 4, !33, i64 92, i64 4, !33, i64 96, i64 4, !34, i64 100, i64 1, !35}
!33 = !{!14, !14, i64 0}
!34 = !{!15, !15, i64 0}
!35 = !{!16, !16, i64 0}
!36 = !{!12, !10, i64 168}
!37 = !{!12, !6, i64 176}
!38 = !{!12, !10, i64 584}
!39 = !{!12, !10, i64 592}


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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7cascadb6LayoutC2EPNS_7AIOFileEmRKNS_7OptionsE(ptr noundef nonnull align 8 dereferenceable(600) %0, ptr noundef %1, i64 noundef %2, ptr nocapture noundef nonnull readonly align 8 dereferenceable(101) %3) unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  store ptr %1, ptr %0, align 8, !tbaa !5
  %5 = getelementptr inbounds i8, ptr %0, i64 8
  store i64 %2, ptr %5, align 8, !tbaa !29
  %6 = getelementptr inbounds i8, ptr %0, i64 16
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(104) %6, ptr noundef nonnull align 8 dereferenceable(104) %3, i64 104, i1 false), !tbaa.struct !30
  %7 = getelementptr inbounds i8, ptr %0, i64 120
  tail call void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %7)
  %8 = getelementptr inbounds i8, ptr %0, i64 168
  store i64 0, ptr %8, align 8, !tbaa !36
  %9 = invoke noalias noundef nonnull dereferenceable(32) ptr @_Znwm(i64 noundef 32) #7
          to label %10 unwind label %25

10:                                               ; preds = %4
  %11 = getelementptr inbounds i8, ptr %0, i64 176
  tail call void @_ZN7cascadb10SuperBlockC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9)
  store ptr %9, ptr %11, align 8, !tbaa !37
  %12 = getelementptr inbounds i8, ptr %0, i64 184
  invoke void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %12)
          to label %13 unwind label %25

13:                                               ; preds = %10
  %14 = getelementptr inbounds i8, ptr %0, i64 232
  tail call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %14) #8
  %15 = getelementptr inbounds i8, ptr %0, i64 280
  tail call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #8
  %16 = getelementptr inbounds i8, ptr %0, i64 328
  invoke void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %16)
          to label %17 unwind label %27

17:                                               ; preds = %13
  %18 = getelementptr inbounds i8, ptr %0, i64 376
  invoke void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18)
          to label %19 unwind label %29

19:                                               ; preds = %17
  %20 = getelementptr inbounds i8, ptr %0, i64 424
  invoke void @_ZNSt5dequeIN7cascadb6Layout4HoleESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(80) %20)
          to label %21 unwind label %31

21:                                               ; preds = %19
  %22 = getelementptr inbounds i8, ptr %0, i64 504
  invoke void @_ZNSt5dequeIN7cascadb6Layout4HoleESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(80) %22)
          to label %23 unwind label %33

23:                                               ; preds = %21
  %24 = getelementptr inbounds i8, ptr %0, i64 584
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %24, i8 0, i64 16, i1 false)
  ret void

25:                                               ; preds = %10, %4
  %26 = landingpad { ptr, i32 }
          cleanup
  br label %38

27:                                               ; preds = %13
  %28 = landingpad { ptr, i32 }
          cleanup
  br label %37

29:                                               ; preds = %17
  %30 = landingpad { ptr, i32 }
          cleanup
  br label %36

31:                                               ; preds = %19
  %32 = landingpad { ptr, i32 }
          cleanup
  br label %35

33:                                               ; preds = %21
  %34 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZNSt5dequeIN7cascadb6Layout4HoleESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %20) #8
  br label %35

35:                                               ; preds = %33, %31
  %.pn = phi { ptr, i32 } [ %34, %33 ], [ %32, %31 ]
  tail call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18) #8
  br label %36

36:                                               ; preds = %35, %29
  %.pn.pn = phi { ptr, i32 } [ %.pn, %35 ], [ %30, %29 ]
  tail call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %16) #8
  br label %37

37:                                               ; preds = %36, %27
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %36 ], [ %28, %27 ]
  tail call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #8
  tail call void @_ZNSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %14) #8
  tail call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #8
  br label %38

38:                                               ; preds = %37, %25
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %37 ], [ %26, %25 ]
  tail call void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #8
  resume { ptr, i32 } %.pn.pn.pn.pn
}

; Function Attrs: mustprogress 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) #1

declare void @_ZN7cascadb5MutexC1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #2

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

declare i32 @__gxx_personality_v0(...)

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

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

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

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

; Function Attrs: nounwind
declare void @_ZN7cascadb5MutexD1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #5

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 = { 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 #4 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { builtin allocsize(0) }
attributes #8 = { 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, !7, i64 0}
!6 = !{!"_ZTSN7cascadb6LayoutE", !7, i64 0, !10, i64 8, !11, i64 16, !15, i64 120, !10, i64 168, !7, i64 176, !15, i64 184, !16, i64 232, !16, i64 280, !15, i64 328, !15, i64 376, !24, i64 424, !24, i64 504, !10, i64 584, !10, i64 592}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"long", !8, i64 0}
!11 = !{!"_ZTSN7cascadb7OptionsE", !7, i64 0, !7, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !12, i64 72, !12, i64 76, !12, i64 80, !12, i64 84, !12, i64 88, !12, i64 92, !13, i64 96, !14, i64 100}
!12 = !{!"int", !8, i64 0}
!13 = !{!"_ZTSN7cascadb8CompressE", !8, i64 0}
!14 = !{!"bool", !8, i64 0}
!15 = !{!"_ZTSN7cascadb5MutexE", !14, i64 0, !8, i64 8}
!16 = !{!"_ZTSSt3mapImPN7cascadb9BlockMetaESt4lessImESaISt4pairIKmS2_EEE", !17, i64 0}
!17 = !{!"_ZTSSt8_Rb_treeImSt4pairIKmPN7cascadb9BlockMetaEESt10_Select1stIS5_ESt4lessImESaIS5_EE", !18, i64 0}
!18 = !{!"_ZTSNSt8_Rb_treeImSt4pairIKmPN7cascadb9BlockMetaEESt10_Select1stIS5_ESt4lessImESaIS5_EE13_Rb_tree_implIS9_Lb1EEE", !19, i64 0, !21, i64 8}
!19 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessImEE", !20, i64 0}
!20 = !{!"_ZTSSt4lessImE"}
!21 = !{!"_ZTSSt15_Rb_tree_header", !22, i64 0, !10, i64 32}
!22 = !{!"_ZTSSt18_Rb_tree_node_base", !23, i64 0, !7, i64 8, !7, i64 16, !7, i64 24}
!23 = !{!"_ZTSSt14_Rb_tree_color", !8, i64 0}
!24 = !{!"_ZTSSt5dequeIN7cascadb6Layout4HoleESaIS2_EE", !25, i64 0}
!25 = !{!"_ZTSSt11_Deque_baseIN7cascadb6Layout4HoleESaIS2_EE", !26, i64 0}
!26 = !{!"_ZTSNSt11_Deque_baseIN7cascadb6Layout4HoleESaIS2_EE11_Deque_implE", !27, i64 0}
!27 = !{!"_ZTSNSt11_Deque_baseIN7cascadb6Layout4HoleESaIS2_EE16_Deque_impl_dataE", !7, i64 0, !10, i64 8, !28, i64 16, !28, i64 48}
!28 = !{!"_ZTSSt15_Deque_iteratorIN7cascadb6Layout4HoleERS2_PS2_E", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24}
!29 = !{!6, !10, i64 8}
!30 = !{i64 0, i64 8, !31, i64 8, i64 8, !31, i64 16, i64 8, !32, i64 24, i64 8, !32, i64 32, i64 8, !32, i64 40, i64 8, !32, i64 48, i64 8, !32, i64 56, i64 8, !32, i64 64, i64 8, !32, i64 72, i64 4, !33, i64 76, i64 4, !33, i64 80, i64 4, !33, i64 84, i64 4, !33, i64 88, i64 4, !33, i64 92, i64 4, !33, i64 96, i64 4, !34, i64 100, i64 1, !35}
!31 = !{!7, !7, i64 0}
!32 = !{!10, !10, i64 0}
!33 = !{!12, !12, i64 0}
!34 = !{!13, !13, i64 0}
!35 = !{!14, !14, i64 0}
!36 = !{!6, !10, i64 168}
!37 = !{!6, !7, i64 176}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,MemCpyOptPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass