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

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.cascadb::Slice" = type <{ ptr, i32, [4 x i8] }>
%"class.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::Block" = type { %"class.cascadb::Slice", i64, i64 }
%"class.cascadb::BlockReader" = type { ptr, i64 }

@.str.1 = external hidden unnamed_addr constant [73 x i8], align 1
@_ZN7cascadb14g_logger_levelE = external global i32, align 4
@_ZN7cascadb8g_loggerE = external global ptr, align 8
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.32 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.34 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [23 x i8], align 1

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN7cascadb6Layout15load_superblockEv(ptr noundef nonnull align 8 dereferenceable(600) %0) #3 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca i1, align 1
  %3 = alloca ptr, align 8
  %4 = alloca %"class.cascadb::Slice", align 8
  %5 = alloca { ptr, i32 }, align 8
  %6 = alloca %"class.cascadb::LoggerFormat", align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca %"class.cascadb::LoggerFormat", align 8
  %11 = alloca %"class.cascadb::LoggerFormat", align 8
  %12 = alloca %"class.cascadb::Block", align 8
  %13 = alloca %"class.cascadb::Slice", align 8
  %14 = alloca %"class.cascadb::BlockReader", align 8
  %15 = alloca %"class.cascadb::LoggerFormat", align 8
  %16 = alloca %"class.cascadb::Slice", align 8
  %17 = alloca %"class.cascadb::LoggerFormat", align 8
  %18 = alloca %"class.cascadb::Slice", align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  %19 = load ptr, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %4) #7
  %20 = call { ptr, i32 } @_ZN7cascadb6Layout20alloc_aligned_bufferEm(ptr noundef nonnull align 8 dereferenceable(600) %19, i64 noundef 4096)
  store { ptr, i32 } %20, ptr %5, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %4, ptr align 8 %5, i64 12, i1 false)
  %21 = call noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12) %4)
  %22 = icmp ne i64 %21, 0
  br i1 %22, label %57, label %23

23:                                               ; preds = %1
  %24 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !9
  %25 = icmp sge i32 3, %24
  br i1 %25, label %26, label %56

26:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 384, ptr %6) #7
  %27 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %6, ptr noundef %27)
  %28 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %6, i32 noundef 3)
          to label %29 unwind label %52

29:                                               ; preds = %26
  %30 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %28, ptr noundef @.str.2)
          to label %31 unwind label %52

31:                                               ; preds = %29
  %32 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %33 = icmp ne ptr %32, null
  br i1 %33, label %34, label %37

34:                                               ; preds = %31
  %35 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %36 = getelementptr inbounds i8, ptr %35, i64 1
  br label %38

37:                                               ; preds = %31
  br label %38

38:                                               ; preds = %37, %34
  %39 = phi ptr [ %36, %34 ], [ @.str.1, %37 ]
  %40 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %30, ptr noundef %39)
          to label %41 unwind label %52

41:                                               ; preds = %38
  %42 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %40, ptr noundef @.str.3)
          to label %43 unwind label %52

43:                                               ; preds = %41
  %44 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %42, i32 noundef 345)
          to label %45 unwind label %52

45:                                               ; preds = %43
  %46 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %44, ptr noundef @.str.2)
          to label %47 unwind label %52

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

49:                                               ; preds = %47
  %50 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %48, i32 noundef 4096)
          to label %51 unwind label %52

51:                                               ; preds = %49
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %6) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %6) #7
  br label %56

52:                                               ; preds = %49, %47, %45, %43, %41, %38, %29, %26
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %7, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %8, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %6) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %6) #7
  br label %206

56:                                               ; preds = %51, %23
  store i1 false, ptr %2, align 1
  store i32 1, ptr %9, align 4
  br label %204

57:                                               ; preds = %1
  %58 = call noundef zeroext i1 @_ZN7cascadb6Layout9read_dataEmRNS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600) %19, i64 noundef 0, ptr noundef nonnull align 8 dereferenceable(12) %4)
  br i1 %58, label %92, label %59

59:                                               ; preds = %57
  %60 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !9
  %61 = icmp sge i32 3, %60
  br i1 %61, label %62, label %90

62:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 384, ptr %10) #7
  %63 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %10, ptr noundef %63)
  %64 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %10, i32 noundef 3)
          to label %65 unwind label %86

65:                                               ; preds = %62
  %66 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %64, ptr noundef @.str.2)
          to label %67 unwind label %86

67:                                               ; preds = %65
  %68 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %69 = icmp ne ptr %68, null
  br i1 %69, label %70, label %73

70:                                               ; preds = %67
  %71 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %72 = getelementptr inbounds i8, ptr %71, i64 1
  br label %74

73:                                               ; preds = %67
  br label %74

74:                                               ; preds = %73, %70
  %75 = phi ptr [ %72, %70 ], [ @.str.1, %73 ]
  %76 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %66, ptr noundef %75)
          to label %77 unwind label %86

77:                                               ; preds = %74
  %78 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %76, ptr noundef @.str.3)
          to label %79 unwind label %86

79:                                               ; preds = %77
  %80 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %78, i32 noundef 350)
          to label %81 unwind label %86

81:                                               ; preds = %79
  %82 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %80, ptr noundef @.str.2)
          to label %83 unwind label %86

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

85:                                               ; preds = %83
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %10) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %10) #7
  br label %90

86:                                               ; preds = %83, %81, %79, %77, %74, %65, %62
  %87 = landingpad { ptr, i32 }
          cleanup
  %88 = extractvalue { ptr, i32 } %87, 0
  store ptr %88, ptr %7, align 8
  %89 = extractvalue { ptr, i32 } %87, 1
  store i32 %89, ptr %8, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %10) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %10) #7
  br label %206

90:                                               ; preds = %85, %59
  %91 = call noundef zeroext i1 @_ZN7cascadb6Layout19load_2nd_superblockEv(ptr noundef nonnull align 8 dereferenceable(600) %19)
  store i1 %91, ptr %2, align 1
  store i32 1, ptr %9, align 4
  br label %204

92:                                               ; preds = %57
  %93 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !9
  %94 = icmp sge i32 0, %93
  br i1 %94, label %95, label %123

95:                                               ; preds = %92
  call void @llvm.lifetime.start.p0(i64 384, ptr %11) #7
  %96 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %11, ptr noundef %96)
  %97 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %11, i32 noundef 0)
          to label %98 unwind label %119

98:                                               ; preds = %95
  %99 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %97, ptr noundef @.str.2)
          to label %100 unwind label %119

100:                                              ; preds = %98
  %101 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %102 = icmp ne ptr %101, null
  br i1 %102, label %103, label %106

103:                                              ; preds = %100
  %104 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %105 = getelementptr inbounds i8, ptr %104, i64 1
  br label %107

106:                                              ; preds = %100
  br label %107

107:                                              ; preds = %106, %103
  %108 = phi ptr [ %105, %103 ], [ @.str.1, %106 ]
  %109 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %99, ptr noundef %108)
          to label %110 unwind label %119

110:                                              ; preds = %107
  %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.3)
          to label %112 unwind label %119

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

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

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

118:                                              ; preds = %116
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %11) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %11) #7
  br label %123

119:                                              ; preds = %116, %114, %112, %110, %107, %98, %95
  %120 = landingpad { ptr, i32 }
          cleanup
  %121 = extractvalue { ptr, i32 } %120, 0
  store ptr %121, ptr %7, align 8
  %122 = extractvalue { ptr, i32 } %120, 1
  store i32 %122, ptr %8, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %11) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %11) #7
  br label %206

123:                                              ; preds = %118, %92
  call void @llvm.lifetime.start.p0(i64 32, ptr %12) #7
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %13, ptr align 8 %4, i64 16, i1 false), !tbaa.struct !11
  %124 = getelementptr inbounds { ptr, i32 }, ptr %13, i32 0, i32 0
  %125 = load ptr, ptr %124, align 8
  %126 = getelementptr inbounds { ptr, i32 }, ptr %13, i32 0, i32 1
  %127 = load i32, ptr %126, align 8
  call void @_ZN7cascadb5BlockC2ENS_5SliceEmm(ptr noundef nonnull align 8 dereferenceable(32) %12, ptr %125, i32 %127, i64 noundef 0, i64 noundef 4096)
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #7
  call void @_ZN7cascadb11BlockReaderC2EPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef %12)
  %128 = call noundef zeroext i1 @_ZN7cascadb6Layout15read_superblockERNS_11BlockReaderE(ptr noundef nonnull align 8 dereferenceable(600) %19, ptr noundef nonnull align 8 dereferenceable(16) %14)
  br i1 %128, label %166, label %129

129:                                              ; preds = %123
  %130 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !9
  %131 = icmp sge i32 3, %130
  br i1 %131, label %132, label %160

132:                                              ; preds = %129
  call void @llvm.lifetime.start.p0(i64 384, ptr %15) #7
  %133 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %15, ptr noundef %133)
  %134 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %15, i32 noundef 3)
          to label %135 unwind label %156

135:                                              ; preds = %132
  %136 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %134, ptr noundef @.str.2)
          to label %137 unwind label %156

137:                                              ; preds = %135
  %138 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %139 = icmp ne ptr %138, null
  br i1 %139, label %140, label %143

140:                                              ; preds = %137
  %141 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %142 = getelementptr inbounds i8, ptr %141, i64 1
  br label %144

143:                                              ; preds = %137
  br label %144

144:                                              ; preds = %143, %140
  %145 = phi ptr [ %142, %140 ], [ @.str.1, %143 ]
  %146 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %136, ptr noundef %145)
          to label %147 unwind label %156

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.3)
          to label %149 unwind label %156

149:                                              ; preds = %147
  %150 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %148, i32 noundef 358)
          to label %151 unwind label %156

151:                                              ; preds = %149
  %152 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %150, ptr noundef @.str.2)
          to label %153 unwind label %156

153:                                              ; preds = %151
  %154 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %152, ptr noundef @.str.35)
          to label %155 unwind label %156

155:                                              ; preds = %153
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %15) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %15) #7
  br label %160

156:                                              ; preds = %153, %151, %149, %147, %144, %135, %132
  %157 = landingpad { ptr, i32 }
          cleanup
  %158 = extractvalue { ptr, i32 } %157, 0
  store ptr %158, ptr %7, align 8
  %159 = extractvalue { ptr, i32 } %157, 1
  store i32 %159, ptr %8, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %15) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %15) #7
  br label %203

160:                                              ; preds = %155, %129
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %16, ptr align 8 %4, i64 16, i1 false), !tbaa.struct !11
  %161 = getelementptr inbounds { ptr, i32 }, ptr %16, i32 0, i32 0
  %162 = load ptr, ptr %161, align 8
  %163 = getelementptr inbounds { ptr, i32 }, ptr %16, i32 0, i32 1
  %164 = load i32, ptr %163, align 8
  call void @_ZN7cascadb6Layout11free_bufferENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600) %19, ptr %162, i32 %164)
  %165 = call noundef zeroext i1 @_ZN7cascadb6Layout19load_2nd_superblockEv(ptr noundef nonnull align 8 dereferenceable(600) %19)
  store i1 %165, ptr %2, align 1
  store i32 1, ptr %9, align 4
  br label %202

166:                                              ; preds = %123
  %167 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !9
  %168 = icmp sge i32 0, %167
  br i1 %168, label %169, label %197

169:                                              ; preds = %166
  call void @llvm.lifetime.start.p0(i64 384, ptr %17) #7
  %170 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !5
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %17, ptr noundef %170)
  %171 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %17, i32 noundef 0)
          to label %172 unwind label %193

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

174:                                              ; preds = %172
  %175 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %176 = icmp ne ptr %175, null
  br i1 %176, label %177, label %180

177:                                              ; preds = %174
  %178 = call noundef ptr @strrchr(ptr noundef @.str.1, i32 noundef 47) #8
  %179 = getelementptr inbounds i8, ptr %178, i64 1
  br label %181

180:                                              ; preds = %174
  br label %181

181:                                              ; preds = %180, %177
  %182 = phi ptr [ %179, %177 ], [ @.str.1, %180 ]
  %183 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %173, ptr noundef %182)
          to label %184 unwind label %193

184:                                              ; preds = %181
  %185 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %183, ptr noundef @.str.3)
          to label %186 unwind label %193

186:                                              ; preds = %184
  %187 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %185, i32 noundef 363)
          to label %188 unwind label %193

188:                                              ; preds = %186
  %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.2)
          to label %190 unwind label %193

190:                                              ; preds = %188
  %191 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %189, ptr noundef @.str.36)
          to label %192 unwind label %193

192:                                              ; preds = %190
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %17) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %17) #7
  br label %197

193:                                              ; preds = %190, %188, %186, %184, %181, %172, %169
  %194 = landingpad { ptr, i32 }
          cleanup
  %195 = extractvalue { ptr, i32 } %194, 0
  store ptr %195, ptr %7, align 8
  %196 = extractvalue { ptr, i32 } %194, 1
  store i32 %196, ptr %8, align 4
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %17) #7
  call void @llvm.lifetime.end.p0(i64 384, ptr %17) #7
  br label %203

197:                                              ; preds = %192, %166
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %18, ptr align 8 %4, i64 16, i1 false), !tbaa.struct !11
  %198 = getelementptr inbounds { ptr, i32 }, ptr %18, i32 0, i32 0
  %199 = load ptr, ptr %198, align 8
  %200 = getelementptr inbounds { ptr, i32 }, ptr %18, i32 0, i32 1
  %201 = load i32, ptr %200, align 8
  call void @_ZN7cascadb6Layout11free_bufferENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600) %19, ptr %199, i32 %201)
  store i1 true, ptr %2, align 1
  store i32 1, ptr %9, align 4
  br label %202

202:                                              ; preds = %197, %160
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #7
  br label %204

203:                                              ; preds = %193, %156
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %12) #7
  br label %206

204:                                              ; preds = %202, %90, %56
  call void @llvm.lifetime.end.p0(i64 16, ptr %4) #7
  %205 = load i1, ptr %2, align 1
  ret i1 %205

206:                                              ; preds = %203, %119, %86, %52
  call void @llvm.lifetime.end.p0(i64 16, ptr %4) #7
  br label %207

207:                                              ; preds = %206
  %208 = load ptr, ptr %7, align 8
  %209 = load i32, ptr %8, align 4
  %210 = insertvalue { ptr, i32 } poison, ptr %208, 0
  %211 = insertvalue { ptr, i32 } %210, i32 %209, 1
  resume { ptr, i32 } %211
}

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i32 } @_ZN7cascadb6Layout20alloc_aligned_bufferEm(ptr noundef nonnull align 8 dereferenceable(600), i64 noundef) #3 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb6Layout9read_dataEmRNS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600), i64 noundef, ptr noundef nonnull align 8 dereferenceable(12)) #3 align 2

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

; 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 uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb6Layout15read_superblockERNS_11BlockReaderE(ptr noundef nonnull align 8 dereferenceable(600), ptr noundef nonnull align 8 dereferenceable(16)) #3 align 2

attributes #0 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #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 = { 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 #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 = { 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 = { nounwind }
attributes #8 = { nounwind willreturn memory(read) }

!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 = !{!"_ZTSN7cascadb11LoggerLevelE", !7, i64 0}
!11 = !{i64 0, i64 8, !5, i64 8, i64 4, !12}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}


; 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::Slice" = type <{ ptr, i32, [4 x i8] }>
%"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::Block" = type { %"class.cascadb::Slice", i64, i64 }
%"class.cascadb::BlockReader" = type { ptr, i64 }

@.str.1 = external hidden unnamed_addr constant [73 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.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.32 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.34 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [23 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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN7cascadb6Layout15load_superblockEv(ptr noundef nonnull align 8 dereferenceable(600) %0) local_unnamed_addr #2 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"class.cascadb::Slice", align 8
  %3 = alloca %"class.cascadb::LoggerFormat", align 8
  %4 = alloca %"class.cascadb::LoggerFormat", align 8
  %5 = alloca %"class.cascadb::LoggerFormat", align 8
  %6 = alloca %"class.cascadb::Block", align 8
  %7 = alloca %"class.cascadb::BlockReader", align 8
  %8 = alloca %"class.cascadb::LoggerFormat", align 8
  %9 = alloca %"class.cascadb::LoggerFormat", align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %2) #6
  %10 = tail call { ptr, i32 } @_ZN7cascadb6Layout20alloc_aligned_bufferEm(ptr noundef nonnull align 8 dereferenceable(600) %0, i64 noundef 4096)
  %.fca.0.extract = extractvalue { ptr, i32 } %10, 0
  %.fca.1.extract = extractvalue { ptr, i32 } %10, 1
  store ptr %.fca.0.extract, ptr %2, align 8
  %.sroa.28.0..sroa_idx = getelementptr inbounds i8, ptr %2, i64 8
  store i32 %.fca.1.extract, ptr %.sroa.28.0..sroa_idx, align 8
  %11 = call noundef i64 @_ZNK7cascadb5Slice4sizeEv(ptr noundef nonnull align 8 dereferenceable(12) %2)
  %.not = icmp eq i64 %11, 0
  br i1 %.not, label %12, label %37

12:                                               ; preds = %1
  %13 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !5
  %14 = icmp slt i32 %13, 4
  br i1 %14, label %15, label %138

15:                                               ; preds = %12
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %3) #6
  %16 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !9
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %3, ptr noundef %16)
  %17 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %3, i32 noundef 3)
          to label %18 unwind label %35

18:                                               ; preds = %15
  %19 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull @.str.2)
          to label %20 unwind label %35

20:                                               ; preds = %18
  %21 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #7
  %.not20 = icmp eq ptr %21, null
  %22 = getelementptr inbounds i8, ptr %21, i64 1
  %spec.select = select i1 %.not20, ptr @.str.1, ptr %22
  %23 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %19, ptr noundef nonnull %spec.select)
          to label %24 unwind label %35

24:                                               ; preds = %20
  %25 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull @.str.3)
          to label %26 unwind label %35

26:                                               ; preds = %24
  %27 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %25, i32 noundef 345)
          to label %28 unwind label %35

28:                                               ; preds = %26
  %29 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull @.str.2)
          to label %30 unwind label %35

30:                                               ; preds = %28
  %31 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %29, ptr noundef nonnull @.str.32)
          to label %32 unwind label %35

32:                                               ; preds = %30
  %33 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %31, i32 noundef 4096)
          to label %34 unwind label %35

34:                                               ; preds = %32
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %3) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %3) #6
  br label %138

35:                                               ; preds = %32, %30, %28, %26, %24, %20, %18, %15
  %36 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %3) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %3) #6
  br label %139

37:                                               ; preds = %1
  %38 = call noundef zeroext i1 @_ZN7cascadb6Layout9read_dataEmRNS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600) %0, i64 noundef 0, ptr noundef nonnull align 8 dereferenceable(12) %2)
  %39 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !5
  br i1 %38, label %64, label %40

40:                                               ; preds = %37
  %41 = icmp slt i32 %39, 4
  br i1 %41, label %42, label %62

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

45:                                               ; preds = %42
  %46 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %44, ptr noundef nonnull @.str.2)
          to label %47 unwind label %60

47:                                               ; preds = %45
  %48 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #7
  %.not21 = icmp eq ptr %48, null
  %49 = getelementptr inbounds i8, ptr %48, i64 1
  %spec.select27 = select i1 %.not21, ptr @.str.1, ptr %49
  %50 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %46, ptr noundef nonnull %spec.select27)
          to label %51 unwind label %60

51:                                               ; preds = %47
  %52 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %50, ptr noundef nonnull @.str.3)
          to label %53 unwind label %60

53:                                               ; preds = %51
  %54 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %52, i32 noundef 350)
          to label %55 unwind label %60

55:                                               ; preds = %53
  %56 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %54, ptr noundef nonnull @.str.2)
          to label %57 unwind label %60

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.33)
          to label %59 unwind label %60

59:                                               ; preds = %57
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %4) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %4) #6
  br label %62

60:                                               ; preds = %57, %55, %53, %51, %47, %45, %42
  %61 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %4) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %4) #6
  br label %139

62:                                               ; preds = %59, %40
  %63 = call noundef zeroext i1 @_ZN7cascadb6Layout19load_2nd_superblockEv(ptr noundef nonnull align 8 dereferenceable(600) %0)
  br label %138

64:                                               ; preds = %37
  %65 = icmp slt i32 %39, 1
  br i1 %65, label %66, label %86

66:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %5) #6
  %67 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !9
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %5, ptr noundef %67)
  %68 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %5, i32 noundef 0)
          to label %69 unwind label %84

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

71:                                               ; preds = %69
  %72 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #7
  %.not22 = icmp eq ptr %72, null
  %73 = getelementptr inbounds i8, ptr %72, i64 1
  %spec.select28 = select i1 %.not22, ptr @.str.1, ptr %73
  %74 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %70, ptr noundef nonnull %spec.select28)
          to label %75 unwind label %84

75:                                               ; preds = %71
  %76 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %74, ptr noundef nonnull @.str.3)
          to label %77 unwind label %84

77:                                               ; preds = %75
  %78 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %76, i32 noundef 354)
          to label %79 unwind label %84

79:                                               ; preds = %77
  %80 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %78, ptr noundef nonnull @.str.2)
          to label %81 unwind label %84

81:                                               ; preds = %79
  %82 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %80, ptr noundef nonnull @.str.34)
          to label %83 unwind label %84

83:                                               ; preds = %81
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %5) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %5) #6
  br label %86

84:                                               ; preds = %81, %79, %77, %75, %71, %69, %66
  %85 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %5) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %5) #6
  br label %139

86:                                               ; preds = %83, %64
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #6
  %.sroa.04.0.copyload = load ptr, ptr %2, align 8, !tbaa !9
  %.sroa.25.0.copyload = load i32, ptr %.sroa.28.0..sroa_idx, align 8, !tbaa !11
  call void @_ZN7cascadb5BlockC2ENS_5SliceEmm(ptr noundef nonnull align 8 dereferenceable(32) %6, ptr %.sroa.04.0.copyload, i32 %.sroa.25.0.copyload, i64 noundef 0, i64 noundef 4096)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #6
  call void @_ZN7cascadb11BlockReaderC2EPNS_5BlockE(ptr noundef nonnull align 8 dereferenceable(16) %7, ptr noundef nonnull %6)
  %87 = call noundef zeroext i1 @_ZN7cascadb6Layout15read_superblockERNS_11BlockReaderE(ptr noundef nonnull align 8 dereferenceable(600) %0, ptr noundef nonnull align 8 dereferenceable(16) %7)
  %88 = load i32, ptr @_ZN7cascadb14g_logger_levelE, align 4, !tbaa !5
  br i1 %87, label %113, label %89

89:                                               ; preds = %86
  %90 = icmp slt i32 %88, 4
  br i1 %90, label %91, label %111

91:                                               ; preds = %89
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %8) #6
  %92 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !9
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %8, ptr noundef %92)
  %93 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %8, i32 noundef 3)
          to label %94 unwind label %109

94:                                               ; preds = %91
  %95 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %93, ptr noundef nonnull @.str.2)
          to label %96 unwind label %109

96:                                               ; preds = %94
  %97 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #7
  %.not23 = icmp eq ptr %97, null
  %98 = getelementptr inbounds i8, ptr %97, i64 1
  %spec.select29 = select i1 %.not23, ptr @.str.1, ptr %98
  %99 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %95, ptr noundef nonnull %spec.select29)
          to label %100 unwind label %109

100:                                              ; preds = %96
  %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.3)
          to label %102 unwind label %109

102:                                              ; preds = %100
  %103 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %101, i32 noundef 358)
          to label %104 unwind label %109

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.2)
          to label %106 unwind label %109

106:                                              ; preds = %104
  %107 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %105, ptr noundef nonnull @.str.35)
          to label %108 unwind label %109

108:                                              ; preds = %106
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %8) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %8) #6
  br label %111

109:                                              ; preds = %106, %104, %102, %100, %96, %94, %91
  %110 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %8) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %8) #6
  br label %137

111:                                              ; preds = %108, %89
  %.sroa.01.0.copyload = load ptr, ptr %2, align 8, !tbaa !9
  %.sroa.22.0.copyload = load i32, ptr %.sroa.28.0..sroa_idx, align 8, !tbaa !11
  call void @_ZN7cascadb6Layout11free_bufferENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600) %0, ptr %.sroa.01.0.copyload, i32 %.sroa.22.0.copyload)
  %112 = call noundef zeroext i1 @_ZN7cascadb6Layout19load_2nd_superblockEv(ptr noundef nonnull align 8 dereferenceable(600) %0)
  br label %136

113:                                              ; preds = %86
  %114 = icmp slt i32 %88, 1
  br i1 %114, label %115, label %135

115:                                              ; preds = %113
  call void @llvm.lifetime.start.p0(i64 384, ptr nonnull %9) #6
  %116 = load ptr, ptr @_ZN7cascadb8g_loggerE, align 8, !tbaa !9
  call void @_ZN7cascadb12LoggerFormatC2EPNS_6LoggerE(ptr noundef nonnull align 8 dereferenceable(384) %9, ptr noundef %116)
  %117 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN7cascadb12LoggerFormat3getENS_11LoggerLevelE(ptr noundef nonnull align 8 dereferenceable(384) %9, i32 noundef 0)
          to label %118 unwind label %133

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

120:                                              ; preds = %118
  %121 = call noundef ptr @strrchr(ptr noundef nonnull dereferenceable(1) @.str.1, i32 noundef 47) #7
  %.not24 = icmp eq ptr %121, null
  %122 = getelementptr inbounds i8, ptr %121, i64 1
  %spec.select30 = select i1 %.not24, ptr @.str.1, ptr %122
  %123 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %119, ptr noundef nonnull %spec.select30)
          to label %124 unwind label %133

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

126:                                              ; preds = %124
  %127 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %125, i32 noundef 363)
          to label %128 unwind label %133

128:                                              ; preds = %126
  %129 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %127, ptr noundef nonnull @.str.2)
          to label %130 unwind label %133

130:                                              ; preds = %128
  %131 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %129, ptr noundef nonnull @.str.36)
          to label %132 unwind label %133

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

133:                                              ; preds = %130, %128, %126, %124, %120, %118, %115
  %134 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7cascadb12LoggerFormatD2Ev(ptr noundef nonnull align 8 dereferenceable(384) %9) #6
  call void @llvm.lifetime.end.p0(i64 384, ptr nonnull %9) #6
  br label %137

135:                                              ; preds = %132, %113
  %.sroa.0.0.copyload = load ptr, ptr %2, align 8, !tbaa !9
  %.sroa.2.0.copyload = load i32, ptr %.sroa.28.0..sroa_idx, align 8, !tbaa !11
  call void @_ZN7cascadb6Layout11free_bufferENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600) %0, ptr %.sroa.0.0.copyload, i32 %.sroa.2.0.copyload)
  br label %136

136:                                              ; preds = %135, %111
  %.0 = phi i1 [ true, %135 ], [ %112, %111 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  br label %138

137:                                              ; preds = %133, %109
  %.pn = phi { ptr, i32 } [ %134, %133 ], [ %110, %109 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #6
  br label %139

138:                                              ; preds = %12, %34, %136, %62
  %.1 = phi i1 [ %.0, %136 ], [ %63, %62 ], [ false, %34 ], [ false, %12 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %2) #6
  ret i1 %.1

139:                                              ; preds = %137, %84, %60, %35
  %.pn.pn = phi { ptr, i32 } [ %.pn, %137 ], [ %85, %84 ], [ %61, %60 ], [ %36, %35 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %2) #6
  resume { ptr, i32 } %.pn.pn
}

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i32 } @_ZN7cascadb6Layout20alloc_aligned_bufferEm(ptr noundef nonnull align 8 dereferenceable(600), i64 noundef) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7cascadb6Layout11free_bufferENS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600), ptr, i32) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb6Layout9read_dataEmRNS_5SliceE(ptr noundef nonnull align 8 dereferenceable(600), i64 noundef, ptr noundef nonnull align 8 dereferenceable(12)) local_unnamed_addr #2 align 2

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

; 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 uwtable
declare dso_local noundef zeroext i1 @_ZN7cascadb6Layout15read_superblockERNS_11BlockReaderE(ptr noundef nonnull align 8 dereferenceable(600), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #2 align 2

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

!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 = !{!"_ZTSN7cascadb11LoggerLevelE", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}


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