; LLVM IR from erthink/libmdbx :: src (dbi)

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

%struct.libmdbx_globals = type { %union.bin128, i32, i32, i8, i8, i8, i8, i32, %union.logger_union, %union.pthread_mutex_t, i64, ptr }
%union.bin128 = type { %struct.anon }
%struct.anon = type { i64, i64 }
%union.logger_union = type { ptr }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%struct.MDBX_txn = type { i32, i32, i64, i64, ptr, ptr, %struct.geo, i64, i64, ptr, ptr, ptr, ptr, ptr, ptr, %struct.MDBX_canary, ptr, %union.anon.2 }
%struct.geo = type { i16, i16, i32, i32, %union.anon, %union.anon.1 }
%union.anon = type { i32 }
%union.anon.1 = type { i32 }
%struct.MDBX_canary = type { i64, i64, i64, i64 }
%union.anon.2 = type { %struct.anon.4 }
%struct.anon.4 = type { %struct.troika, ptr, %struct.anon.5, i8, i32, i32, i64, ptr, ptr, ptr, i64, %union.anon.6 }
%struct.troika = type { i8, i8, i8, i8, i32, [3 x i64] }
%struct.anon.5 = type { %struct.MDBX_rkl, i64, %struct.MDBX_rkl }
%struct.MDBX_rkl = type { i64, i64, i32, i32, ptr, [12 x i64] }
%union.anon.6 = type { %struct.anon.7 }
%struct.anon.7 = type { i64, ptr }
%struct.MDBX_env = type { %union.mdbx_atomic_uint32_t, i32, i32, %struct.osal_mmap, i32, i32, %struct.osal_mmap, ptr, i16, i16, i16, i16, i16, i16, %union.mdbx_atomic_uint32_t, i8, i8, i16, i32, i32, i32, i32, %struct.anon.9, ptr, ptr, ptr, ptr, ptr, i32, i32, i32, ptr, ptr, i64, %struct.anon.10, %struct.anon.14, i8, ptr, ptr, ptr, %struct.anon.15, %union.pthread_mutex_t, i32, i32, ptr, %struct.osal_ioring, %union.pthread_mutex_t, [71 x %union.mdbx_atomic_uint64_t] }
%struct.osal_mmap = type { %union.anon.8, i32, i64, i64, i64 }
%union.anon.8 = type { ptr }
%union.mdbx_atomic_uint32_t = type { i32 }
%struct.anon.9 = type { ptr, ptr, ptr, ptr }
%struct.anon.10 = type { i32, i32, i32, i32, i64, i8, i8, i8, i8, i32, i32, i8, i8, i8, %struct.anon.11, %union.anon.12 }
%struct.anon.11 = type { i16, i16, i16, i16 }
%union.anon.12 = type { i32 }
%struct.anon.14 = type { i64, i64, i64, i64, i64 }
%struct.anon.15 = type { i64 }
%struct.osal_ioring = type { i32, i32, i32, ptr, ptr, ptr }
%union.mdbx_atomic_uint64_t = type { i64 }
%struct.tree = type { i16, i16, i32, i32, i32, i32, i32, i64, i64, i64 }
%struct.kvx = type { %struct.clc2, %struct.iovec }
%struct.clc2 = type { %struct.clc, %struct.clc }
%struct.clc = type { ptr, i64, i64 }
%struct.iovec = type { ptr, i64 }
%struct.defer_free_item = type { ptr, i64 }

@globals = external global %struct.libmdbx_globals, align 8
@.str.1 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [38 x i8], align 1
@__func__.dbi_update = external hidden unnamed_addr constant [11 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [78 x i8], align 1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(none)
declare i64 @llvm.expect.i64(i64, i64) #0

; Function Attrs: noreturn
declare void @mdbx_assert_fail(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #1

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @dbi_defer_release(ptr noundef, ptr noundef) #3

; Function Attrs: nounwind uwtable
define dso_local i32 @dbi_update(ptr noundef %0, i1 noundef zeroext %1) #3 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca i8, align 1
  %6 = alloca ptr, align 8
  %7 = alloca i8, align 1
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i64, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  %16 = zext i1 %1 to i8
  store i8 %16, ptr %5, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #7
  %17 = load ptr, ptr %4, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.MDBX_txn, ptr %17, i32 0, i32 9
  %19 = load ptr, ptr %18, align 8, !tbaa !11
  store ptr %19, ptr %6, align 8, !tbaa !5
  br label %20

20:                                               ; preds = %2
  %21 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %22 = zext i8 %21 to i32
  %23 = and i32 %22, 1
  %24 = icmp ne i32 %23, 0
  %25 = xor i1 %24, true
  %26 = xor i1 %25, true
  %27 = zext i1 %26 to i32
  %28 = sext i32 %27 to i64
  %29 = call i64 @llvm.expect.i64(i64 %28, i64 1)
  %30 = icmp ne i64 %29, 0
  br i1 %30, label %31, label %59

31:                                               ; preds = %20
  br label %32

32:                                               ; preds = %31
  %33 = load ptr, ptr %4, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.MDBX_txn, ptr %33, i32 0, i32 4
  %35 = load ptr, ptr %34, align 8, !tbaa !20
  %36 = icmp ne ptr %35, null
  br i1 %36, label %43, label %37

37:                                               ; preds = %32
  %38 = load ptr, ptr %4, align 8, !tbaa !5
  %39 = load ptr, ptr %6, align 8, !tbaa !5
  %40 = getelementptr inbounds %struct.MDBX_env, ptr %39, i32 0, i32 24
  %41 = load ptr, ptr %40, align 8, !tbaa !21
  %42 = icmp eq ptr %38, %41
  br label %43

43:                                               ; preds = %37, %32
  %44 = phi i1 [ false, %32 ], [ %42, %37 ]
  %45 = xor i1 %44, true
  %46 = xor i1 %45, true
  %47 = xor i1 %46, true
  %48 = zext i1 %47 to i32
  %49 = sext i32 %48 to i64
  %50 = call i64 @llvm.expect.i64(i64 %49, i64 0)
  %51 = icmp ne i64 %50, 0
  br i1 %51, label %52, label %56

52:                                               ; preds = %43
  %53 = load ptr, ptr %4, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.MDBX_txn, ptr %53, i32 0, i32 9
  %55 = load ptr, ptr %54, align 8, !tbaa !11
  call void @mdbx_assert_fail(ptr noundef %55, ptr noundef @.str.12, ptr noundef @__func__.dbi_update, i32 noundef 181) #8
  unreachable

56:                                               ; preds = %43
  br label %57

57:                                               ; preds = %56
  br label %58

58:                                               ; preds = %57
  br label %59

59:                                               ; preds = %58, %20
  br label %60

60:                                               ; preds = %59
  br label %61

61:                                               ; preds = %60
  call void @llvm.lifetime.start.p0(i64 1, ptr %7) #7
  store i8 0, ptr %7, align 1, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #7
  store ptr null, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  %62 = load ptr, ptr %4, align 8, !tbaa !5
  %63 = getelementptr inbounds %struct.MDBX_txn, ptr %62, i32 0, i32 11
  %64 = load ptr, ptr %63, align 8, !tbaa !30
  %65 = getelementptr inbounds i32, ptr %64, i64 0
  %66 = load i32, ptr %65, align 4, !tbaa !31
  %67 = lshr i32 %66, 2
  %68 = zext i32 %67 to i64
  store i64 %68, ptr %9, align 8, !tbaa !32
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #7
  store i64 2, ptr %10, align 8, !tbaa !32
  br label %69

69:                                               ; preds = %302, %61
  %70 = load i64, ptr %10, align 8, !tbaa !32
  %71 = load ptr, ptr %4, align 8, !tbaa !5
  %72 = getelementptr inbounds %struct.MDBX_txn, ptr %71, i32 0, i32 2
  %73 = load i64, ptr %72, align 8, !tbaa !33
  %74 = icmp ult i64 %70, %73
  br i1 %74, label %76, label %75

75:                                               ; preds = %69
  store i32 6, ptr %11, align 4
  br label %305

76:                                               ; preds = %69
  %77 = load ptr, ptr %4, align 8, !tbaa !5
  %78 = call zeroext i1 @dbi_foreach_step(ptr noundef %77, ptr noundef %9, ptr noundef %10)
  br i1 %78, label %79, label %301

79:                                               ; preds = %76
  %80 = load ptr, ptr %4, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.MDBX_txn, ptr %80, i32 0, i32 12
  %82 = load ptr, ptr %81, align 8, !tbaa !34
  %83 = load i64, ptr %10, align 8, !tbaa !32
  %84 = getelementptr inbounds i8, ptr %82, i64 %83
  %85 = load i8, ptr %84, align 1, !tbaa !35
  %86 = zext i8 %85 to i32
  %87 = and i32 %86, 8
  %88 = icmp eq i32 %87, 0
  %89 = xor i1 %88, true
  %90 = xor i1 %89, true
  %91 = zext i1 %90 to i32
  %92 = sext i32 %91 to i64
  %93 = call i64 @llvm.expect.i64(i64 %92, i64 1)
  %94 = icmp ne i64 %93, 0
  br i1 %94, label %95, label %96

95:                                               ; preds = %79
  br label %302

96:                                               ; preds = %79
  %97 = load i8, ptr %7, align 1, !tbaa !9, !range !36, !noundef !37
  %98 = trunc i8 %97 to i1
  br i1 %98, label %125, label %99

99:                                               ; preds = %96
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #7
  %100 = load ptr, ptr %6, align 8, !tbaa !5
  %101 = getelementptr inbounds %struct.MDBX_env, ptr %100, i32 0, i32 41
  %102 = call i32 @osal_fastmutex_acquire(ptr noundef %101)
  store i32 %102, ptr %12, align 4, !tbaa !31
  %103 = load i32, ptr %12, align 4, !tbaa !31
  %104 = icmp ne i32 %103, 0
  %105 = xor i1 %104, true
  %106 = xor i1 %105, true
  %107 = zext i1 %106 to i32
  %108 = sext i32 %107 to i64
  %109 = call i64 @llvm.expect.i64(i64 %108, i64 0)
  %110 = icmp ne i64 %109, 0
  br i1 %110, label %111, label %113

111:                                              ; preds = %99
  %112 = load i32, ptr %12, align 4, !tbaa !31
  store i32 %112, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %122

113:                                              ; preds = %99
  store i8 1, ptr %7, align 1, !tbaa !9
  %114 = load i64, ptr %10, align 8, !tbaa !32
  %115 = load ptr, ptr %6, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.MDBX_env, ptr %115, i32 0, i32 42
  %117 = load i32, ptr %116, align 8, !tbaa !38
  %118 = zext i32 %117 to i64
  %119 = icmp uge i64 %114, %118
  br i1 %119, label %120, label %121

120:                                              ; preds = %113
  store i32 8, ptr %11, align 4
  br label %122

121:                                              ; preds = %113
  store i32 0, ptr %11, align 4
  br label %122

122:                                              ; preds = %121, %120, %111
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  %123 = load i32, ptr %11, align 4
  switch i32 %123, label %305 [
    i32 0, label %124
    i32 8, label %302
  ]

124:                                              ; preds = %122
  br label %125

125:                                              ; preds = %124, %96
  br label %126

126:                                              ; preds = %125
  %127 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %128 = zext i8 %127 to i32
  %129 = and i32 %128, 1
  %130 = icmp ne i32 %129, 0
  %131 = xor i1 %130, true
  %132 = xor i1 %131, true
  %133 = zext i1 %132 to i32
  %134 = sext i32 %133 to i64
  %135 = call i64 @llvm.expect.i64(i64 %134, i64 1)
  %136 = icmp ne i64 %135, 0
  br i1 %136, label %137, label %159

137:                                              ; preds = %126
  br label %138

138:                                              ; preds = %137
  %139 = load i64, ptr %10, align 8, !tbaa !32
  %140 = load ptr, ptr %6, align 8, !tbaa !5
  %141 = getelementptr inbounds %struct.MDBX_env, ptr %140, i32 0, i32 42
  %142 = load i32, ptr %141, align 8, !tbaa !38
  %143 = zext i32 %142 to i64
  %144 = icmp ult i64 %139, %143
  %145 = xor i1 %144, true
  %146 = xor i1 %145, true
  %147 = xor i1 %146, true
  %148 = zext i1 %147 to i32
  %149 = sext i32 %148 to i64
  %150 = call i64 @llvm.expect.i64(i64 %149, i64 0)
  %151 = icmp ne i64 %150, 0
  br i1 %151, label %152, label %156

152:                                              ; preds = %138
  %153 = load ptr, ptr %4, align 8, !tbaa !5
  %154 = getelementptr inbounds %struct.MDBX_txn, ptr %153, i32 0, i32 9
  %155 = load ptr, ptr %154, align 8, !tbaa !11
  call void @mdbx_assert_fail(ptr noundef %155, ptr noundef @.str.1, ptr noundef @__func__.dbi_update, i32 noundef 196) #8
  unreachable

156:                                              ; preds = %138
  br label %157

157:                                              ; preds = %156
  br label %158

158:                                              ; preds = %157
  br label %159

159:                                              ; preds = %158, %126
  br label %160

160:                                              ; preds = %159
  br label %161

161:                                              ; preds = %160
  %162 = load i8, ptr %5, align 1, !tbaa !9, !range !36, !noundef !37
  %163 = trunc i8 %162 to i1
  br i1 %163, label %164, label %180

164:                                              ; preds = %161
  %165 = load ptr, ptr %4, align 8, !tbaa !5
  %166 = getelementptr inbounds %struct.MDBX_txn, ptr %165, i32 0, i32 10
  %167 = load ptr, ptr %166, align 8, !tbaa !39
  %168 = load i64, ptr %10, align 8, !tbaa !32
  %169 = getelementptr inbounds %struct.tree, ptr %167, i64 %168
  %170 = getelementptr inbounds %struct.tree, ptr %169, i32 0, i32 0
  %171 = load i16, ptr %170, align 4, !tbaa !40
  %172 = zext i16 %171 to i32
  %173 = or i32 %172, 128
  %174 = trunc i32 %173 to i8
  %175 = load ptr, ptr %6, align 8, !tbaa !5
  %176 = getelementptr inbounds %struct.MDBX_env, ptr %175, i32 0, i32 26
  %177 = load ptr, ptr %176, align 8, !tbaa !42
  %178 = load i64, ptr %10, align 8, !tbaa !32
  %179 = getelementptr inbounds i8, ptr %177, i64 %178
  store i8 %174, ptr %179, align 1, !tbaa !35
  br label %300

180:                                              ; preds = %161
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  %181 = load ptr, ptr %6, align 8, !tbaa !5
  %182 = load i64, ptr %10, align 8, !tbaa !32
  %183 = call i32 @dbi_seq_next(ptr noundef %181, i64 noundef %182)
  store i32 %183, ptr %13, align 4, !tbaa !31
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #7
  %184 = load ptr, ptr %6, align 8, !tbaa !5
  %185 = getelementptr inbounds %struct.MDBX_env, ptr %184, i32 0, i32 25
  %186 = load ptr, ptr %185, align 8, !tbaa !43
  %187 = load i64, ptr %10, align 8, !tbaa !32
  %188 = getelementptr inbounds %struct.kvx, ptr %186, i64 %187
  %189 = getelementptr inbounds %struct.kvx, ptr %188, i32 0, i32 1
  %190 = getelementptr inbounds %struct.iovec, ptr %189, i32 0, i32 0
  %191 = load ptr, ptr %190, align 8, !tbaa !44
  store ptr %191, ptr %14, align 8, !tbaa !5
  %192 = load ptr, ptr %14, align 8, !tbaa !5
  %193 = icmp ne ptr %192, null
  br i1 %193, label %194, label %225

194:                                              ; preds = %180
  %195 = load ptr, ptr %6, align 8, !tbaa !5
  %196 = getelementptr inbounds %struct.MDBX_env, ptr %195, i32 0, i32 26
  %197 = load ptr, ptr %196, align 8, !tbaa !42
  %198 = load i64, ptr %10, align 8, !tbaa !32
  %199 = getelementptr inbounds i8, ptr %197, i64 %198
  store i8 0, ptr %199, align 1, !tbaa !35
  %200 = load ptr, ptr %6, align 8, !tbaa !5
  %201 = getelementptr inbounds %struct.MDBX_env, ptr %200, i32 0, i32 25
  %202 = load ptr, ptr %201, align 8, !tbaa !43
  %203 = load i64, ptr %10, align 8, !tbaa !32
  %204 = getelementptr inbounds %struct.kvx, ptr %202, i64 %203
  %205 = getelementptr inbounds %struct.kvx, ptr %204, i32 0, i32 1
  %206 = getelementptr inbounds %struct.iovec, ptr %205, i32 0, i32 1
  store i64 0, ptr %206, align 8, !tbaa !49
  %207 = load ptr, ptr %6, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.MDBX_env, ptr %207, i32 0, i32 25
  %209 = load ptr, ptr %208, align 8, !tbaa !43
  %210 = load i64, ptr %10, align 8, !tbaa !32
  %211 = getelementptr inbounds %struct.kvx, ptr %209, i64 %210
  %212 = getelementptr inbounds %struct.kvx, ptr %211, i32 0, i32 1
  %213 = getelementptr inbounds %struct.iovec, ptr %212, i32 0, i32 0
  store ptr null, ptr %213, align 8, !tbaa !44
  %214 = load ptr, ptr %6, align 8, !tbaa !5
  %215 = getelementptr inbounds %struct.MDBX_env, ptr %214, i32 0, i32 27
  %216 = load ptr, ptr %215, align 8, !tbaa !50
  %217 = load i64, ptr %10, align 8, !tbaa !32
  %218 = getelementptr inbounds %union.mdbx_atomic_uint32_t, ptr %216, i64 %217
  %219 = load i32, ptr %13, align 4, !tbaa !31
  %220 = call i32 @atomic_store32(ptr noundef %218, i32 noundef %219, i32 noundef 1)
  call void @osal_compiler_barrier()
  %221 = load ptr, ptr %8, align 8, !tbaa !5
  %222 = load ptr, ptr %14, align 8, !tbaa !5
  %223 = getelementptr inbounds %struct.defer_free_item, ptr %222, i32 0, i32 0
  store ptr %221, ptr %223, align 8, !tbaa !51
  %224 = load ptr, ptr %14, align 8, !tbaa !5
  store ptr %224, ptr %8, align 8, !tbaa !5
  br label %299

225:                                              ; preds = %180
  br label %226

226:                                              ; preds = %225
  %227 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %228 = zext i8 %227 to i32
  %229 = and i32 %228, 1
  %230 = icmp ne i32 %229, 0
  %231 = xor i1 %230, true
  %232 = xor i1 %231, true
  %233 = zext i1 %232 to i32
  %234 = sext i32 %233 to i64
  %235 = call i64 @llvm.expect.i64(i64 %234, i64 1)
  %236 = icmp ne i64 %235, 0
  br i1 %236, label %237, label %260

237:                                              ; preds = %226
  br label %238

238:                                              ; preds = %237
  %239 = load ptr, ptr %6, align 8, !tbaa !5
  %240 = getelementptr inbounds %struct.MDBX_env, ptr %239, i32 0, i32 25
  %241 = load ptr, ptr %240, align 8, !tbaa !43
  %242 = load i64, ptr %10, align 8, !tbaa !32
  %243 = getelementptr inbounds %struct.kvx, ptr %241, i64 %242
  %244 = getelementptr inbounds %struct.kvx, ptr %243, i32 0, i32 1
  %245 = getelementptr inbounds %struct.iovec, ptr %244, i32 0, i32 1
  %246 = load i64, ptr %245, align 8, !tbaa !49
  %247 = icmp eq i64 %246, 0
  %248 = xor i1 %247, true
  %249 = xor i1 %248, true
  %250 = xor i1 %249, true
  %251 = zext i1 %250 to i32
  %252 = sext i32 %251 to i64
  %253 = call i64 @llvm.expect.i64(i64 %252, i64 0)
  %254 = icmp ne i64 %253, 0
  br i1 %254, label %255, label %257

255:                                              ; preds = %238
  %256 = load ptr, ptr %6, align 8, !tbaa !5
  call void @mdbx_assert_fail(ptr noundef %256, ptr noundef @.str.13, ptr noundef @__func__.dbi_update, i32 noundef 211) #8
  unreachable

257:                                              ; preds = %238
  br label %258

258:                                              ; preds = %257
  br label %259

259:                                              ; preds = %258
  br label %260

260:                                              ; preds = %259, %226
  br label %261

261:                                              ; preds = %260
  br label %262

262:                                              ; preds = %261
  br label %263

263:                                              ; preds = %262
  %264 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %265 = zext i8 %264 to i32
  %266 = and i32 %265, 1
  %267 = icmp ne i32 %266, 0
  %268 = xor i1 %267, true
  %269 = xor i1 %268, true
  %270 = zext i1 %269 to i32
  %271 = sext i32 %270 to i64
  %272 = call i64 @llvm.expect.i64(i64 %271, i64 1)
  %273 = icmp ne i64 %272, 0
  br i1 %273, label %274, label %296

274:                                              ; preds = %263
  br label %275

275:                                              ; preds = %274
  %276 = load ptr, ptr %6, align 8, !tbaa !5
  %277 = getelementptr inbounds %struct.MDBX_env, ptr %276, i32 0, i32 26
  %278 = load ptr, ptr %277, align 8, !tbaa !42
  %279 = load i64, ptr %10, align 8, !tbaa !32
  %280 = getelementptr inbounds i8, ptr %278, i64 %279
  %281 = load i8, ptr %280, align 1, !tbaa !35
  %282 = zext i8 %281 to i32
  %283 = icmp eq i32 %282, 0
  %284 = xor i1 %283, true
  %285 = xor i1 %284, true
  %286 = xor i1 %285, true
  %287 = zext i1 %286 to i32
  %288 = sext i32 %287 to i64
  %289 = call i64 @llvm.expect.i64(i64 %288, i64 0)
  %290 = icmp ne i64 %289, 0
  br i1 %290, label %291, label %293

291:                                              ; preds = %275
  %292 = load ptr, ptr %6, align 8, !tbaa !5
  call void @mdbx_assert_fail(ptr noundef %292, ptr noundef @.str.14, ptr noundef @__func__.dbi_update, i32 noundef 212) #8
  unreachable

293:                                              ; preds = %275
  br label %294

294:                                              ; preds = %293
  br label %295

295:                                              ; preds = %294
  br label %296

296:                                              ; preds = %295, %263
  br label %297

297:                                              ; preds = %296
  br label %298

298:                                              ; preds = %297
  br label %299

299:                                              ; preds = %298, %194
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  br label %300

300:                                              ; preds = %299, %164
  br label %301

301:                                              ; preds = %300, %76
  br label %302

302:                                              ; preds = %301, %122, %95
  %303 = load i64, ptr %10, align 8, !tbaa !32
  %304 = add i64 %303, 1
  store i64 %304, ptr %10, align 8, !tbaa !32
  br label %69, !llvm.loop !53

305:                                              ; preds = %122, %75
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  %306 = load i32, ptr %11, align 4
  switch i32 %306, label %458 [
    i32 6, label %307
  ]

307:                                              ; preds = %305
  %308 = load i8, ptr %7, align 1, !tbaa !9, !range !36, !noundef !37
  %309 = trunc i8 %308 to i1
  br i1 %309, label %310, label %457

310:                                              ; preds = %307
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  %311 = load ptr, ptr %6, align 8, !tbaa !5
  %312 = getelementptr inbounds %struct.MDBX_env, ptr %311, i32 0, i32 42
  %313 = load i32, ptr %312, align 8, !tbaa !38
  %314 = zext i32 %313 to i64
  store i64 %314, ptr %15, align 8, !tbaa !32
  br label %315

315:                                              ; preds = %310
  %316 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %317 = zext i8 %316 to i32
  %318 = and i32 %317, 1
  %319 = icmp ne i32 %318, 0
  %320 = xor i1 %319, true
  %321 = xor i1 %320, true
  %322 = zext i1 %321 to i32
  %323 = sext i32 %322 to i64
  %324 = call i64 @llvm.expect.i64(i64 %323, i64 1)
  %325 = icmp ne i64 %324, 0
  br i1 %325, label %326, label %344

326:                                              ; preds = %315
  br label %327

327:                                              ; preds = %326
  %328 = load ptr, ptr %6, align 8, !tbaa !5
  %329 = getelementptr inbounds %struct.MDBX_env, ptr %328, i32 0, i32 42
  %330 = load i32, ptr %329, align 8, !tbaa !38
  %331 = icmp uge i32 %330, 2
  %332 = xor i1 %331, true
  %333 = xor i1 %332, true
  %334 = xor i1 %333, true
  %335 = zext i1 %334 to i32
  %336 = sext i32 %335 to i64
  %337 = call i64 @llvm.expect.i64(i64 %336, i64 0)
  %338 = icmp ne i64 %337, 0
  br i1 %338, label %339, label %341

339:                                              ; preds = %327
  %340 = load ptr, ptr %6, align 8, !tbaa !5
  call void @mdbx_assert_fail(ptr noundef %340, ptr noundef @.str.15, ptr noundef @__func__.dbi_update, i32 noundef 219) #8
  unreachable

341:                                              ; preds = %327
  br label %342

342:                                              ; preds = %341
  br label %343

343:                                              ; preds = %342
  br label %344

344:                                              ; preds = %343, %315
  br label %345

345:                                              ; preds = %344
  br label %346

346:                                              ; preds = %345
  br label %347

347:                                              ; preds = %448, %346
  %348 = load ptr, ptr %6, align 8, !tbaa !5
  %349 = getelementptr inbounds %struct.MDBX_env, ptr %348, i32 0, i32 26
  %350 = load ptr, ptr %349, align 8, !tbaa !42
  %351 = load i64, ptr %15, align 8, !tbaa !32
  %352 = sub i64 %351, 1
  %353 = getelementptr inbounds i8, ptr %350, i64 %352
  %354 = load i8, ptr %353, align 1, !tbaa !35
  %355 = zext i8 %354 to i32
  %356 = and i32 %355, 128
  %357 = icmp eq i32 %356, 0
  br i1 %357, label %358, label %449

358:                                              ; preds = %347
  %359 = load i64, ptr %15, align 8, !tbaa !32
  %360 = add i64 %359, -1
  store i64 %360, ptr %15, align 8, !tbaa !32
  br label %361

361:                                              ; preds = %358
  %362 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %363 = zext i8 %362 to i32
  %364 = and i32 %363, 1
  %365 = icmp ne i32 %364, 0
  %366 = xor i1 %365, true
  %367 = xor i1 %366, true
  %368 = zext i1 %367 to i32
  %369 = sext i32 %368 to i64
  %370 = call i64 @llvm.expect.i64(i64 %369, i64 1)
  %371 = icmp ne i64 %370, 0
  br i1 %371, label %372, label %388

372:                                              ; preds = %361
  br label %373

373:                                              ; preds = %372
  %374 = load i64, ptr %15, align 8, !tbaa !32
  %375 = icmp uge i64 %374, 2
  %376 = xor i1 %375, true
  %377 = xor i1 %376, true
  %378 = xor i1 %377, true
  %379 = zext i1 %378 to i32
  %380 = sext i32 %379 to i64
  %381 = call i64 @llvm.expect.i64(i64 %380, i64 0)
  %382 = icmp ne i64 %381, 0
  br i1 %382, label %383, label %385

383:                                              ; preds = %373
  %384 = load ptr, ptr %6, align 8, !tbaa !5
  call void @mdbx_assert_fail(ptr noundef %384, ptr noundef @.str.16, ptr noundef @__func__.dbi_update, i32 noundef 222) #8
  unreachable

385:                                              ; preds = %373
  br label %386

386:                                              ; preds = %385
  br label %387

387:                                              ; preds = %386
  br label %388

388:                                              ; preds = %387, %361
  br label %389

389:                                              ; preds = %388
  br label %390

390:                                              ; preds = %389
  br label %391

391:                                              ; preds = %390
  %392 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 4), align 1, !tbaa !18
  %393 = zext i8 %392 to i32
  %394 = and i32 %393, 1
  %395 = icmp ne i32 %394, 0
  %396 = xor i1 %395, true
  %397 = xor i1 %396, true
  %398 = zext i1 %397 to i32
  %399 = sext i32 %398 to i64
  %400 = call i64 @llvm.expect.i64(i64 %399, i64 1)
  %401 = icmp ne i64 %400, 0
  br i1 %401, label %402, label %446

402:                                              ; preds = %391
  br label %403

403:                                              ; preds = %402
  %404 = load ptr, ptr %6, align 8, !tbaa !5
  %405 = getelementptr inbounds %struct.MDBX_env, ptr %404, i32 0, i32 26
  %406 = load ptr, ptr %405, align 8, !tbaa !42
  %407 = load i64, ptr %15, align 8, !tbaa !32
  %408 = getelementptr inbounds i8, ptr %406, i64 %407
  %409 = load i8, ptr %408, align 1, !tbaa !35
  %410 = icmp ne i8 %409, 0
  br i1 %410, label %432, label %411

411:                                              ; preds = %403
  %412 = load ptr, ptr %6, align 8, !tbaa !5
  %413 = getelementptr inbounds %struct.MDBX_env, ptr %412, i32 0, i32 25
  %414 = load ptr, ptr %413, align 8, !tbaa !43
  %415 = load i64, ptr %15, align 8, !tbaa !32
  %416 = getelementptr inbounds %struct.kvx, ptr %414, i64 %415
  %417 = getelementptr inbounds %struct.kvx, ptr %416, i32 0, i32 1
  %418 = getelementptr inbounds %struct.iovec, ptr %417, i32 0, i32 1
  %419 = load i64, ptr %418, align 8, !tbaa !49
  %420 = icmp ne i64 %419, 0
  br i1 %420, label %432, label %421

421:                                              ; preds = %411
  %422 = load ptr, ptr %6, align 8, !tbaa !5
  %423 = getelementptr inbounds %struct.MDBX_env, ptr %422, i32 0, i32 25
  %424 = load ptr, ptr %423, align 8, !tbaa !43
  %425 = load i64, ptr %15, align 8, !tbaa !32
  %426 = getelementptr inbounds %struct.kvx, ptr %424, i64 %425
  %427 = getelementptr inbounds %struct.kvx, ptr %426, i32 0, i32 1
  %428 = getelementptr inbounds %struct.iovec, ptr %427, i32 0, i32 0
  %429 = load ptr, ptr %428, align 8, !tbaa !44
  %430 = icmp ne ptr %429, null
  %431 = xor i1 %430, true
  br label %432

432:                                              ; preds = %421, %411, %403
  %433 = phi i1 [ false, %411 ], [ false, %403 ], [ %431, %421 ]
  %434 = xor i1 %433, true
  %435 = xor i1 %434, true
  %436 = xor i1 %435, true
  %437 = zext i1 %436 to i32
  %438 = sext i32 %437 to i64
  %439 = call i64 @llvm.expect.i64(i64 %438, i64 0)
  %440 = icmp ne i64 %439, 0
  br i1 %440, label %441, label %443

441:                                              ; preds = %432
  %442 = load ptr, ptr %6, align 8, !tbaa !5
  call void @mdbx_assert_fail(ptr noundef %442, ptr noundef @.str.17, ptr noundef @__func__.dbi_update, i32 noundef 223) #8
  unreachable

443:                                              ; preds = %432
  br label %444

444:                                              ; preds = %443
  br label %445

445:                                              ; preds = %444
  br label %446

446:                                              ; preds = %445, %391
  br label %447

447:                                              ; preds = %446
  br label %448

448:                                              ; preds = %447
  br label %347, !llvm.loop !55

449:                                              ; preds = %347
  %450 = load i64, ptr %15, align 8, !tbaa !32
  %451 = trunc i64 %450 to i32
  %452 = load ptr, ptr %6, align 8, !tbaa !5
  %453 = getelementptr inbounds %struct.MDBX_env, ptr %452, i32 0, i32 42
  store i32 %451, ptr %453, align 8, !tbaa !38
  %454 = load ptr, ptr %6, align 8, !tbaa !5
  %455 = load ptr, ptr %8, align 8, !tbaa !5
  %456 = call i32 @dbi_defer_release(ptr noundef %454, ptr noundef %455)
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  br label %457

457:                                              ; preds = %449, %307
  store i32 0, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %458

458:                                              ; preds = %457, %305
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  %459 = load i32, ptr %3, align 4
  ret i32 %459
}

; Function Attrs: inlinehint nounwind uwtable
declare hidden zeroext i1 @dbi_foreach_step(ptr noundef, ptr noundef, ptr noundef) #4

declare i32 @osal_fastmutex_acquire(ptr noundef) #5

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @dbi_seq_next(ptr noundef, i64 noundef) #4

; Function Attrs: alwaysinline nounwind uwtable
declare hidden i32 @atomic_store32(ptr noundef, i32 noundef, i32 noundef) #6

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @osal_compiler_barrier() #4

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

!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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"_Bool", !7, i64 0}
!11 = !{!12, !6, i64 80}
!12 = !{!"MDBX_txn", !13, i64 0, !13, i64 4, !14, i64 8, !14, i64 16, !6, i64 24, !6, i64 32, !15, i64 40, !14, i64 64, !14, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !17, i64 128, !6, i64 160, !7, i64 168}
!13 = !{!"int", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!"geo", !16, i64 0, !16, i64 2, !13, i64 4, !13, i64 8, !7, i64 12, !7, i64 16}
!16 = !{!"short", !7, i64 0}
!17 = !{!"MDBX_canary", !14, i64 0, !14, i64 8, !14, i64 16, !14, i64 24}
!18 = !{!19, !7, i64 25}
!19 = !{!"libmdbx_globals", !7, i64 0, !13, i64 16, !13, i64 20, !7, i64 24, !7, i64 25, !7, i64 26, !10, i64 27, !13, i64 28, !7, i64 32, !7, i64 40, !14, i64 80, !6, i64 88}
!20 = !{!12, !6, i64 24}
!21 = !{!22, !6, i64 192}
!22 = !{!"MDBX_env", !7, i64 0, !13, i64 4, !13, i64 8, !23, i64 16, !13, i64 56, !13, i64 60, !23, i64 64, !6, i64 104, !16, i64 112, !16, i64 114, !16, i64 116, !16, i64 118, !16, i64 120, !16, i64 122, !7, i64 124, !7, i64 128, !7, i64 129, !16, i64 130, !13, i64 132, !13, i64 136, !13, i64 140, !13, i64 144, !24, i64 152, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !13, i64 224, !13, i64 228, !13, i64 232, !6, i64 240, !6, i64 248, !14, i64 256, !25, i64 264, !27, i64 320, !10, i64 360, !6, i64 368, !6, i64 376, !6, i64 384, !28, i64 392, !7, i64 400, !13, i64 440, !13, i64 444, !6, i64 448, !29, i64 456, !7, i64 496, !7, i64 536}
!23 = !{!"osal_mmap", !7, i64 0, !13, i64 8, !14, i64 16, !14, i64 24, !14, i64 32}
!24 = !{!"", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!25 = !{!"", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !14, i64 16, !7, i64 24, !7, i64 25, !7, i64 26, !7, i64 27, !13, i64 28, !13, i64 32, !10, i64 36, !10, i64 37, !10, i64 38, !26, i64 40, !7, i64 48}
!26 = !{!"", !16, i64 0, !16, i64 2, !16, i64 4, !16, i64 6}
!27 = !{!"", !14, i64 0, !14, i64 8, !14, i64 16, !14, i64 24, !14, i64 32}
!28 = !{!"", !14, i64 0}
!29 = !{!"osal_ioring", !13, i64 0, !13, i64 4, !13, i64 8, !6, i64 16, !6, i64 24, !6, i64 32}
!30 = !{!12, !6, i64 96}
!31 = !{!13, !13, i64 0}
!32 = !{!14, !14, i64 0}
!33 = !{!12, !14, i64 8}
!34 = !{!12, !6, i64 104}
!35 = !{!7, !7, i64 0}
!36 = !{i8 0, i8 2}
!37 = !{}
!38 = !{!22, !13, i64 440}
!39 = !{!12, !6, i64 88}
!40 = !{!41, !16, i64 0}
!41 = !{!"tree", !16, i64 0, !16, i64 2, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !14, i64 24, !14, i64 32, !14, i64 40}
!42 = !{!22, !6, i64 208}
!43 = !{!22, !6, i64 200}
!44 = !{!45, !6, i64 48}
!45 = !{!"kvx", !46, i64 0, !48, i64 48}
!46 = !{!"clc2", !47, i64 0, !47, i64 24}
!47 = !{!"clc", !6, i64 0, !14, i64 8, !14, i64 16}
!48 = !{!"iovec", !6, i64 0, !14, i64 8}
!49 = !{!45, !14, i64 56}
!50 = !{!22, !6, i64 216}
!51 = !{!52, !6, i64 0}
!52 = !{!"defer_free_item", !6, i64 0, !14, i64 8}
!53 = distinct !{!53, !54}
!54 = !{!"llvm.loop.mustprogress"}
!55 = distinct !{!55, !54}


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

%struct.libmdbx_globals = type { %union.bin128, i32, i32, i8, i8, i8, i8, i32, %union.logger_union, %union.pthread_mutex_t, i64, ptr }
%union.bin128 = type { %struct.anon }
%struct.anon = type { i64, i64 }
%union.logger_union = type { ptr }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%struct.tree = type { i16, i16, i32, i32, i32, i32, i32, i64, i64, i64 }
%struct.kvx = type { %struct.clc2, %struct.iovec }
%struct.clc2 = type { %struct.clc, %struct.clc }
%struct.clc = type { ptr, i64, i64 }
%struct.iovec = type { ptr, i64 }
%union.mdbx_atomic_uint32_t = type { i32 }

@globals = external local_unnamed_addr global %struct.libmdbx_globals, align 8
@.str.1 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [38 x i8], align 1
@__func__.dbi_update = external hidden unnamed_addr constant [11 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [78 x i8], align 1

; Function Attrs: noreturn
declare void @mdbx_assert_fail(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @dbi_defer_release(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
define dso_local i32 @dbi_update(ptr noundef %0, i1 noundef zeroext %1) local_unnamed_addr #2 {
  %3 = alloca i64, align 8
  %4 = alloca i64, align 8
  %5 = getelementptr inbounds i8, ptr %0, i64 80
  %6 = load ptr, ptr %5, align 8, !tbaa !5
  %7 = load i8, ptr getelementptr inbounds (i8, ptr @globals, i64 25), align 1, !tbaa !15
  %8 = and i8 %7, 1
  %.not = icmp eq i8 %8, 0
  br i1 %.not, label %16, label %9, !prof !18

9:                                                ; preds = %2
  %10 = getelementptr inbounds i8, ptr %0, i64 24
  %11 = load ptr, ptr %10, align 8, !tbaa !19
  %.not69 = icmp eq ptr %11, null
  br i1 %.not69, label %12, label %.critedge, !prof !20

12:                                               ; preds = %9
  %13 = getelementptr inbounds i8, ptr %6, i64 192
  %14 = load ptr, ptr %13, align 8, !tbaa !21
  %15 = icmp eq ptr %14, %0
  br i1 %15, label %16, label %.critedge, !prof !20

.critedge:                                        ; preds = %9, %12
  tail call void @mdbx_assert_fail(ptr noundef %6, ptr noundef nonnull @.str.12, ptr noundef nonnull @__func__.dbi_update, i32 noundef 181) #6
  unreachable

16:                                               ; preds = %12, %2
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #7
  %17 = getelementptr inbounds i8, ptr %0, i64 96
  %18 = load ptr, ptr %17, align 8, !tbaa !30
  %19 = load i32, ptr %18, align 4, !tbaa !31
  %20 = lshr i32 %19, 2
  %21 = zext nneg i32 %20 to i64
  store i64 %21, ptr %3, align 8, !tbaa !32
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #7
  %22 = getelementptr inbounds i8, ptr %0, i64 8
  store i64 2, ptr %4, align 8, !tbaa !32
  %23 = load i64, ptr %22, align 8, !tbaa !33
  %.not72109 = icmp ugt i64 %23, 2
  br i1 %.not72109, label %.lr.ph, label %._crit_edge.thread

._crit_edge.thread:                               ; preds = %16
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  br label %166

.lr.ph:                                           ; preds = %16
  %24 = getelementptr inbounds i8, ptr %0, i64 104
  %25 = getelementptr inbounds i8, ptr %6, i64 400
  %26 = getelementptr inbounds i8, ptr %6, i64 440
  %27 = getelementptr inbounds i8, ptr %6, i64 200
  %28 = getelementptr inbounds i8, ptr %6, i64 208
  %29 = getelementptr inbounds i8, ptr %6, i64 216
  %30 = getelementptr inbounds i8, ptr %0, i64 88
  br i1 %1, label %.lr.ph.split.us, label %.lr.ph.split

.lr.ph.split.us:                                  ; preds = %.lr.ph, %.thread96.us
  %.057111.us = phi i8 [ %.360.us, %.thread96.us ], [ 0, %.lr.ph ]
  %31 = call zeroext i1 @dbi_foreach_step(ptr noundef nonnull %0, ptr noundef nonnull %3, ptr noundef nonnull %4)
  %.pre149 = load i64, ptr %4, align 8, !tbaa !32
  br i1 %31, label %32, label %.thread96.us

32:                                               ; preds = %.lr.ph.split.us
  %33 = load ptr, ptr %24, align 8, !tbaa !34
  %34 = getelementptr inbounds i8, ptr %33, i64 %.pre149
  %35 = load i8, ptr %34, align 1, !tbaa !35
  %36 = and i8 %35, 8
  %37 = icmp eq i8 %36, 0
  br i1 %37, label %.thread96.us, label %38, !prof !20

38:                                               ; preds = %32
  %39 = trunc nuw i8 %.057111.us to i1
  br i1 %39, label %.thread92.us, label %40

40:                                               ; preds = %38
  %41 = call i32 @osal_fastmutex_acquire(ptr noundef nonnull %25) #7
  %.not70.us = icmp eq i32 %41, 0
  br i1 %.not70.us, label %42, label %.thread97, !prof !20

42:                                               ; preds = %40
  %43 = load i64, ptr %4, align 8, !tbaa !32
  %44 = load i32, ptr %26, align 8, !tbaa !36
  %45 = zext i32 %44 to i64
  %.not71.us = icmp ult i64 %43, %45
  br i1 %.not71.us, label %.thread92.us, label %.thread96.us

.thread92.us:                                     ; preds = %42, %38
  %46 = phi i64 [ %.pre149, %38 ], [ %43, %42 ]
  %.259.us = phi i8 [ %.057111.us, %38 ], [ 1, %42 ]
  %47 = load i8, ptr getelementptr inbounds (i8, ptr @globals, i64 25), align 1, !tbaa !15
  %48 = and i8 %47, 1
  %.not79.us = icmp eq i8 %48, 0
  br i1 %.not79.us, label %52, label %49, !prof !18

49:                                               ; preds = %.thread92.us
  %50 = load i32, ptr %26, align 8, !tbaa !36
  %51 = zext i32 %50 to i64
  %.not80.us = icmp ult i64 %46, %51
  br i1 %.not80.us, label %52, label %.split.us, !prof !20

52:                                               ; preds = %49, %.thread92.us
  %53 = load ptr, ptr %30, align 8, !tbaa !37
  %54 = getelementptr inbounds %struct.tree, ptr %53, i64 %46
  %55 = load i16, ptr %54, align 4, !tbaa !38
  %56 = trunc i16 %55 to i8
  %57 = or i8 %56, -128
  %58 = load ptr, ptr %28, align 8, !tbaa !40
  %59 = getelementptr inbounds i8, ptr %58, i64 %46
  store i8 %57, ptr %59, align 1, !tbaa !35
  %.pre148 = load i64, ptr %4, align 8, !tbaa !32
  br label %.thread96.us

.thread96.us:                                     ; preds = %52, %42, %32, %.lr.ph.split.us
  %60 = phi i64 [ %.pre149, %32 ], [ %.pre148, %52 ], [ %.pre149, %.lr.ph.split.us ], [ %43, %42 ]
  %.360.us = phi i8 [ %.057111.us, %32 ], [ %.259.us, %52 ], [ %.057111.us, %.lr.ph.split.us ], [ 1, %42 ]
  %61 = add i64 %60, 1
  store i64 %61, ptr %4, align 8, !tbaa !32
  %62 = load i64, ptr %22, align 8, !tbaa !33
  %.not72.us = icmp ult i64 %61, %62
  br i1 %.not72.us, label %.lr.ph.split.us, label %._crit_edge, !llvm.loop !41

.lr.ph.split:                                     ; preds = %.lr.ph, %.thread96
  %.057111 = phi i8 [ %.360, %.thread96 ], [ 0, %.lr.ph ]
  %.062110 = phi ptr [ %.264, %.thread96 ], [ null, %.lr.ph ]
  %63 = call zeroext i1 @dbi_foreach_step(ptr noundef nonnull %0, ptr noundef nonnull %3, ptr noundef nonnull %4)
  %.pre147 = load i64, ptr %4, align 8, !tbaa !32
  br i1 %63, label %64, label %.thread96

64:                                               ; preds = %.lr.ph.split
  %65 = load ptr, ptr %24, align 8, !tbaa !34
  %66 = getelementptr inbounds i8, ptr %65, i64 %.pre147
  %67 = load i8, ptr %66, align 1, !tbaa !35
  %68 = and i8 %67, 8
  %69 = icmp eq i8 %68, 0
  br i1 %69, label %.thread96, label %70, !prof !20

70:                                               ; preds = %64
  %71 = trunc nuw i8 %.057111 to i1
  br i1 %71, label %.thread92, label %72

72:                                               ; preds = %70
  %73 = call i32 @osal_fastmutex_acquire(ptr noundef nonnull %25) #7
  %.not70 = icmp eq i32 %73, 0
  br i1 %.not70, label %74, label %.thread97, !prof !20

.thread97:                                        ; preds = %72, %40
  %.us-phi = phi i32 [ %41, %40 ], [ %73, %72 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  br label %166

74:                                               ; preds = %72
  %75 = load i64, ptr %4, align 8, !tbaa !32
  %76 = load i32, ptr %26, align 8, !tbaa !36
  %77 = zext i32 %76 to i64
  %.not71 = icmp ult i64 %75, %77
  br i1 %.not71, label %.thread92, label %.thread96

.thread92:                                        ; preds = %74, %70
  %78 = phi i64 [ %.pre147, %70 ], [ %75, %74 ]
  %.259 = phi i8 [ %.057111, %70 ], [ 1, %74 ]
  %79 = load i8, ptr getelementptr inbounds (i8, ptr @globals, i64 25), align 1, !tbaa !15
  %80 = and i8 %79, 1
  %.not79 = icmp eq i8 %80, 0
  br i1 %.not79, label %85, label %81, !prof !18

81:                                               ; preds = %.thread92
  %82 = load i32, ptr %26, align 8, !tbaa !36
  %83 = zext i32 %82 to i64
  %.not80 = icmp ult i64 %78, %83
  br i1 %.not80, label %85, label %.split.us, !prof !20

.split.us:                                        ; preds = %81, %49
  %84 = load ptr, ptr %5, align 8, !tbaa !5
  call void @mdbx_assert_fail(ptr noundef %84, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.dbi_update, i32 noundef 196) #6
  unreachable

85:                                               ; preds = %81, %.thread92
  %86 = call i32 @dbi_seq_next(ptr noundef %6, i64 noundef %78)
  %87 = load ptr, ptr %27, align 8, !tbaa !43
  %88 = load i64, ptr %4, align 8, !tbaa !32
  %89 = getelementptr inbounds %struct.kvx, ptr %87, i64 %88, i32 1
  %90 = load ptr, ptr %89, align 8, !tbaa !44
  %.not81 = icmp eq ptr %90, null
  br i1 %.not81, label %102, label %91

91:                                               ; preds = %85
  %92 = load ptr, ptr %28, align 8, !tbaa !40
  %93 = getelementptr inbounds i8, ptr %92, i64 %88
  store i8 0, ptr %93, align 1, !tbaa !35
  %94 = load ptr, ptr %27, align 8, !tbaa !43
  %95 = load i64, ptr %4, align 8, !tbaa !32
  %96 = getelementptr inbounds %struct.kvx, ptr %94, i64 %95, i32 1, i32 1
  store i64 0, ptr %96, align 8, !tbaa !49
  %97 = load i64, ptr %4, align 8, !tbaa !32
  %98 = getelementptr inbounds %struct.kvx, ptr %94, i64 %97, i32 1
  store ptr null, ptr %98, align 8, !tbaa !44
  %99 = load ptr, ptr %29, align 8, !tbaa !50
  %100 = getelementptr inbounds %union.mdbx_atomic_uint32_t, ptr %99, i64 %97
  %101 = call i32 @atomic_store32(ptr noundef %100, i32 noundef %86, i32 noundef 1)
  call void @osal_compiler_barrier()
  store ptr %.062110, ptr %90, align 8, !tbaa !51
  %.pre = load i64, ptr %4, align 8, !tbaa !32
  br label %.thread96

102:                                              ; preds = %85
  %103 = load i8, ptr getelementptr inbounds (i8, ptr @globals, i64 25), align 1, !tbaa !15
  %104 = and i8 %103, 1
  %.not82 = icmp eq i8 %104, 0
  br i1 %.not82, label %.thread96, label %105, !prof !18

105:                                              ; preds = %102
  %106 = getelementptr inbounds i8, ptr %89, i64 8
  %107 = load i64, ptr %106, align 8, !tbaa !49
  %.not83 = icmp eq i64 %107, 0
  br i1 %.not83, label %109, label %108, !prof !20

108:                                              ; preds = %105
  call void @mdbx_assert_fail(ptr noundef nonnull %6, ptr noundef nonnull @.str.13, ptr noundef nonnull @__func__.dbi_update, i32 noundef 211) #6
  unreachable

109:                                              ; preds = %105
  %110 = load ptr, ptr %28, align 8, !tbaa !40
  %111 = getelementptr inbounds i8, ptr %110, i64 %88
  %112 = load i8, ptr %111, align 1, !tbaa !35
  %.not85 = icmp eq i8 %112, 0
  br i1 %.not85, label %.thread96, label %113, !prof !20

113:                                              ; preds = %109
  call void @mdbx_assert_fail(ptr noundef nonnull %6, ptr noundef nonnull @.str.14, ptr noundef nonnull @__func__.dbi_update, i32 noundef 212) #6
  unreachable

.thread96:                                        ; preds = %102, %74, %91, %109, %.lr.ph.split, %64
  %114 = phi i64 [ %.pre147, %64 ], [ %.pre147, %.lr.ph.split ], [ %.pre, %91 ], [ %88, %109 ], [ %75, %74 ], [ %88, %102 ]
  %.264 = phi ptr [ %.062110, %64 ], [ %.062110, %.lr.ph.split ], [ %90, %91 ], [ %.062110, %109 ], [ %.062110, %74 ], [ %.062110, %102 ]
  %.360 = phi i8 [ %.057111, %64 ], [ %.057111, %.lr.ph.split ], [ %.259, %91 ], [ %.259, %109 ], [ 1, %74 ], [ %.259, %102 ]
  %115 = add i64 %114, 1
  store i64 %115, ptr %4, align 8, !tbaa !32
  %116 = load i64, ptr %22, align 8, !tbaa !33
  %.not72 = icmp ult i64 %115, %116
  br i1 %.not72, label %.lr.ph.split, label %._crit_edge, !llvm.loop !41

._crit_edge:                                      ; preds = %.thread96, %.thread96.us
  %.062.lcssa = phi ptr [ null, %.thread96.us ], [ %.264, %.thread96 ]
  %.057.lcssa = phi i8 [ %.360.us, %.thread96.us ], [ %.360, %.thread96 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  %117 = trunc nuw i8 %.057.lcssa to i1
  br i1 %117, label %118, label %166

118:                                              ; preds = %._crit_edge
  %119 = getelementptr inbounds i8, ptr %6, i64 440
  %120 = load i32, ptr %119, align 8, !tbaa !36
  %121 = zext i32 %120 to i64
  %122 = load i8, ptr getelementptr inbounds (i8, ptr @globals, i64 25), align 1, !tbaa !15
  %.fr130 = freeze i8 %122
  %123 = and i8 %.fr130, 1
  %.not73 = icmp ne i8 %123, 0
  %124 = icmp ult i32 %120, 2
  %or.cond = select i1 %.not73, i1 %124, i1 false
  br i1 %or.cond, label %148, label %.preheader, !prof !53

.preheader:                                       ; preds = %118
  %125 = getelementptr inbounds i8, ptr %6, i64 208
  %126 = load ptr, ptr %125, align 8, !tbaa !40
  %invariant.gep = getelementptr i8, ptr %126, i64 -1
  %gep115 = getelementptr i8, ptr %invariant.gep, i64 %121
  %127 = load i8, ptr %gep115, align 1, !tbaa !35
  %128 = icmp sgt i8 %127, -1
  br i1 %128, label %.lr.ph117, label %._crit_edge118

.lr.ph117:                                        ; preds = %.preheader
  %.not75 = icmp eq i8 %123, 0
  %129 = getelementptr inbounds i8, ptr %6, i64 200
  br i1 %.not75, label %.lr.ph117.split.us.split.us, label %.lr.ph117.split.split.peel, !prof !18

.lr.ph117.split.split.peel:                       ; preds = %.lr.ph117
  %130 = add nsw i64 %121, -1
  %131 = icmp ult i64 %130, 2
  br i1 %131, label %.split121.us, label %132, !prof !53

132:                                              ; preds = %.lr.ph117.split.split.peel
  %133 = getelementptr inbounds i8, ptr %126, i64 %130
  %134 = load i8, ptr %133, align 1, !tbaa !35
  %.not76.peel = icmp eq i8 %134, 0
  br i1 %.not76.peel, label %135, label %.critedge88, !prof !54

135:                                              ; preds = %132
  %136 = load ptr, ptr %129, align 8, !tbaa !43
  %137 = getelementptr inbounds %struct.kvx, ptr %136, i64 %130, i32 1
  %138 = getelementptr inbounds i8, ptr %137, i64 8
  %139 = load i64, ptr %138, align 8, !tbaa !49
  %.not77.peel = icmp eq i64 %139, 0
  br i1 %.not77.peel, label %140, label %.critedge88, !prof !54

140:                                              ; preds = %135
  %141 = load ptr, ptr %137, align 8, !tbaa !44
  %.not78.peel = icmp eq ptr %141, null
  br i1 %.not78.peel, label %142, label %.critedge88, !prof !54

142:                                              ; preds = %140
  %gep.peel = getelementptr i8, ptr %invariant.gep, i64 %130
  %143 = load i8, ptr %gep.peel, align 1, !tbaa !35
  %144 = icmp sgt i8 %143, -1
  br i1 %144, label %.lr.ph117.split.split, label %._crit_edge118

.lr.ph117.split.us.split.us:                      ; preds = %.lr.ph117, %.lr.ph117.split.us.split.us
  %.0116.us.us = phi i64 [ %145, %.lr.ph117.split.us.split.us ], [ %121, %.lr.ph117 ]
  %145 = add i64 %.0116.us.us, -1
  %gep.us.us = getelementptr i8, ptr %invariant.gep, i64 %145
  %146 = load i8, ptr %gep.us.us, align 1, !tbaa !35
  %147 = icmp sgt i8 %146, -1
  br i1 %147, label %.lr.ph117.split.us.split.us, label %._crit_edge118, !llvm.loop !55

148:                                              ; preds = %118
  call void @mdbx_assert_fail(ptr noundef nonnull %6, ptr noundef nonnull @.str.15, ptr noundef nonnull @__func__.dbi_update, i32 noundef 219) #6
  unreachable

.lr.ph117.split.split:                            ; preds = %142, %161
  %.0116 = phi i64 [ %149, %161 ], [ %130, %142 ]
  %149 = add i64 %.0116, -1
  %150 = icmp ult i64 %.0116, 3
  br i1 %150, label %.split121.us, label %151, !prof !56

.split121.us:                                     ; preds = %.lr.ph117.split.split, %.lr.ph117.split.split.peel
  call void @mdbx_assert_fail(ptr noundef nonnull %6, ptr noundef nonnull @.str.16, ptr noundef nonnull @__func__.dbi_update, i32 noundef 222) #6
  unreachable

151:                                              ; preds = %.lr.ph117.split.split
  %152 = getelementptr inbounds i8, ptr %126, i64 %149
  %153 = load i8, ptr %152, align 1, !tbaa !35
  %.not76 = icmp eq i8 %153, 0
  br i1 %.not76, label %154, label %.critedge88, !prof !57

154:                                              ; preds = %151
  %155 = load ptr, ptr %129, align 8, !tbaa !43
  %156 = getelementptr inbounds %struct.kvx, ptr %155, i64 %149, i32 1
  %157 = getelementptr inbounds i8, ptr %156, i64 8
  %158 = load i64, ptr %157, align 8, !tbaa !49
  %.not77 = icmp eq i64 %158, 0
  br i1 %.not77, label %159, label %.critedge88, !prof !57

159:                                              ; preds = %154
  %160 = load ptr, ptr %156, align 8, !tbaa !44
  %.not78 = icmp eq ptr %160, null
  br i1 %.not78, label %161, label %.critedge88, !prof !57

.critedge88:                                      ; preds = %159, %151, %154, %140, %135, %132
  call void @mdbx_assert_fail(ptr noundef %6, ptr noundef nonnull @.str.17, ptr noundef nonnull @__func__.dbi_update, i32 noundef 223) #6
  unreachable

161:                                              ; preds = %159
  %gep = getelementptr i8, ptr %invariant.gep, i64 %149
  %162 = load i8, ptr %gep, align 1, !tbaa !35
  %163 = icmp sgt i8 %162, -1
  br i1 %163, label %.lr.ph117.split.split, label %._crit_edge118, !llvm.loop !58

._crit_edge118:                                   ; preds = %142, %161, %.lr.ph117.split.us.split.us, %.preheader
  %.0.lcssa = phi i64 [ %121, %.preheader ], [ %145, %.lr.ph117.split.us.split.us ], [ %130, %142 ], [ %149, %161 ]
  %164 = trunc i64 %.0.lcssa to i32
  store i32 %164, ptr %119, align 8, !tbaa !36
  %165 = call i32 @dbi_defer_release(ptr noundef nonnull %6, ptr noundef %.062.lcssa)
  br label %166

166:                                              ; preds = %._crit_edge.thread, %.thread97, %._crit_edge, %._crit_edge118
  %.5 = phi i32 [ 0, %._crit_edge118 ], [ 0, %._crit_edge ], [ %.us-phi, %.thread97 ], [ 0, %._crit_edge.thread ]
  ret i32 %.5
}

; Function Attrs: inlinehint nounwind uwtable
declare hidden zeroext i1 @dbi_foreach_step(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare i32 @osal_fastmutex_acquire(ptr noundef) local_unnamed_addr #4

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @dbi_seq_next(ptr noundef, i64 noundef) local_unnamed_addr #3

; Function Attrs: alwaysinline nounwind uwtable
declare hidden i32 @atomic_store32(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #5

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @osal_compiler_barrier() local_unnamed_addr #3

attributes #0 = { noreturn "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 nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 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 = { "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 = { alwaysinline 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 = { noreturn nounwind }
attributes #7 = { 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, !11, i64 80}
!6 = !{!"MDBX_txn", !7, i64 0, !7, i64 4, !10, i64 8, !10, i64 16, !11, i64 24, !11, i64 32, !12, i64 40, !10, i64 64, !10, i64 72, !11, i64 80, !11, i64 88, !11, i64 96, !11, i64 104, !11, i64 112, !11, i64 120, !14, i64 128, !11, i64 160, !8, i64 168}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"long", !8, i64 0}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!"geo", !13, i64 0, !13, i64 2, !7, i64 4, !7, i64 8, !8, i64 12, !8, i64 16}
!13 = !{!"short", !8, i64 0}
!14 = !{!"MDBX_canary", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24}
!15 = !{!16, !8, i64 25}
!16 = !{!"libmdbx_globals", !8, i64 0, !7, i64 16, !7, i64 20, !8, i64 24, !8, i64 25, !8, i64 26, !17, i64 27, !7, i64 28, !8, i64 32, !8, i64 40, !10, i64 80, !11, i64 88}
!17 = !{!"_Bool", !8, i64 0}
!18 = !{!"branch_weights", !"expected", i32 1, i32 2000}
!19 = !{!6, !11, i64 24}
!20 = !{!"branch_weights", !"expected", i32 2000, i32 1}
!21 = !{!22, !11, i64 192}
!22 = !{!"MDBX_env", !8, i64 0, !7, i64 4, !7, i64 8, !23, i64 16, !7, i64 56, !7, i64 60, !23, i64 64, !11, i64 104, !13, i64 112, !13, i64 114, !13, i64 116, !13, i64 118, !13, i64 120, !13, i64 122, !8, i64 124, !8, i64 128, !8, i64 129, !13, i64 130, !7, i64 132, !7, i64 136, !7, i64 140, !7, i64 144, !24, i64 152, !11, i64 184, !11, i64 192, !11, i64 200, !11, i64 208, !11, i64 216, !7, i64 224, !7, i64 228, !7, i64 232, !11, i64 240, !11, i64 248, !10, i64 256, !25, i64 264, !27, i64 320, !17, i64 360, !11, i64 368, !11, i64 376, !11, i64 384, !28, i64 392, !8, i64 400, !7, i64 440, !7, i64 444, !11, i64 448, !29, i64 456, !8, i64 496, !8, i64 536}
!23 = !{!"osal_mmap", !8, i64 0, !7, i64 8, !10, i64 16, !10, i64 24, !10, i64 32}
!24 = !{!"", !11, i64 0, !11, i64 8, !11, i64 16, !11, i64 24}
!25 = !{!"", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !10, i64 16, !8, i64 24, !8, i64 25, !8, i64 26, !8, i64 27, !7, i64 28, !7, i64 32, !17, i64 36, !17, i64 37, !17, i64 38, !26, i64 40, !8, i64 48}
!26 = !{!"", !13, i64 0, !13, i64 2, !13, i64 4, !13, i64 6}
!27 = !{!"", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32}
!28 = !{!"", !10, i64 0}
!29 = !{!"osal_ioring", !7, i64 0, !7, i64 4, !7, i64 8, !11, i64 16, !11, i64 24, !11, i64 32}
!30 = !{!6, !11, i64 96}
!31 = !{!7, !7, i64 0}
!32 = !{!10, !10, i64 0}
!33 = !{!6, !10, i64 8}
!34 = !{!6, !11, i64 104}
!35 = !{!8, !8, i64 0}
!36 = !{!22, !7, i64 440}
!37 = !{!6, !11, i64 88}
!38 = !{!39, !13, i64 0}
!39 = !{!"tree", !13, i64 0, !13, i64 2, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !10, i64 24, !10, i64 32, !10, i64 40}
!40 = !{!22, !11, i64 208}
!41 = distinct !{!41, !42}
!42 = !{!"llvm.loop.mustprogress"}
!43 = !{!22, !11, i64 200}
!44 = !{!45, !11, i64 48}
!45 = !{!"kvx", !46, i64 0, !48, i64 48}
!46 = !{!"clc2", !47, i64 0, !47, i64 24}
!47 = !{!"clc", !11, i64 0, !10, i64 8, !10, i64 16}
!48 = !{!"iovec", !11, i64 0, !10, i64 8}
!49 = !{!45, !10, i64 56}
!50 = !{!22, !11, i64 216}
!51 = !{!52, !11, i64 0}
!52 = !{!"defer_free_item", !11, i64 0, !10, i64 8}
!53 = !{!"branch_weights", i32 2000, i32 4002001}
!54 = !{!"branch_weights", i32 2000, i32 1}
!55 = distinct !{!55, !42}
!56 = !{!"branch_weights", i32 2000, i32 4000001}
!57 = !{!"branch_weights", i32 1999, i32 1}
!58 = distinct !{!58, !42, !59}
!59 = !{!"llvm.loop.peeled.count", i32 1}


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