; LLVM IR from erthink/libmdbx :: src (api-txn-data)

; 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.0 }
%struct.anon.0 = 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.cursor_couple = type { %struct.MDBX_cursor, ptr, %struct.inner_cursor }
%struct.MDBX_cursor = type { i32, %union.anon, i8, i8, ptr, ptr, ptr, ptr, ptr, [32 x ptr], [32 x i16], ptr, ptr }
%union.anon = type { i16 }
%struct.inner_cursor = type { %struct.MDBX_cursor, %struct.tree }
%struct.tree = type { i16, i16, i32, i32, i32, i32, i32, i64, i64, i64 }
%struct.cursor_set_result = type { i32, i8 }

@globals = external global %struct.libmdbx_globals, align 8
@.str.3 = external hidden unnamed_addr constant [25 x i8], align 1
@__func__.mdbx_get_ex = external hidden unnamed_addr constant [12 x i8], align 1

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

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @log_if_error(i32 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: alwaysinline nounwind uwtable
declare hidden i32 @check_txn(ptr noundef, i32 noundef) #3

declare i32 @cursor_init(ptr noundef, ptr noundef, i64 noundef) #4

declare void @debug_log(i32 noundef, ptr noundef, i32 noundef, ptr noundef, ...) #4

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

declare ptr @mdbx_dump_val(ptr noundef, ptr noundef, i64 noundef) #4

declare i64 @cursor_seek(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #4

; Function Attrs: nounwind uwtable
define dso_local i32 @mdbx_get_ex(ptr noundef %0, i32 noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4) #5 {
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca [510 x i8], align 16
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca %struct.cursor_couple, align 8
  %16 = alloca %struct.cursor_set_result, align 4
  store ptr %0, ptr %7, align 8, !tbaa !5
  store i32 %1, ptr %8, align 4, !tbaa !9
  store ptr %2, ptr %9, align 8, !tbaa !5
  store ptr %3, ptr %10, align 8, !tbaa !5
  store ptr %4, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 510, ptr %12) #7
  br label %17

17:                                               ; preds = %5
  %18 = load i8, ptr getelementptr inbounds (%struct.libmdbx_globals, ptr @globals, i32 0, i32 5), align 2, !tbaa !11
  %19 = zext i8 %18 to i32
  %20 = icmp sle i32 5, %19
  %21 = xor i1 %20, true
  %22 = xor i1 %21, true
  %23 = zext i1 %22 to i32
  %24 = sext i32 %23 to i64
  %25 = call i64 @llvm.expect.i64(i64 %24, i64 0)
  %26 = icmp ne i64 %25, 0
  br i1 %26, label %27, label %32

27:                                               ; preds = %17
  %28 = load i32, ptr %8, align 4, !tbaa !9
  %29 = load ptr, ptr %9, align 8, !tbaa !5
  %30 = getelementptr inbounds [510 x i8], ptr %12, i64 0, i64 0
  %31 = call ptr @mdbx_dump_val(ptr noundef %29, ptr noundef %30, i64 noundef 255)
  call void (i32, ptr, i32, ptr, ...) @debug_log(i32 noundef 5, ptr noundef @__func__.mdbx_get_ex, i32 noundef 104, ptr noundef @.str.3, i32 noundef %28, ptr noundef %31)
  br label %32

32:                                               ; preds = %27, %17
  br label %33

33:                                               ; preds = %32
  br label %34

34:                                               ; preds = %33
  %35 = load ptr, ptr %9, align 8, !tbaa !5
  %36 = icmp ne ptr %35, null
  br i1 %36, label %37, label %41

37:                                               ; preds = %34
  %38 = load ptr, ptr %10, align 8, !tbaa !5
  %39 = icmp ne ptr %38, null
  %40 = xor i1 %39, true
  br label %41

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

49:                                               ; preds = %41
  %50 = call i32 @log_if_error(i32 noundef 22, ptr noundef @__func__.mdbx_get_ex, i32 noundef 107)
  store i32 %50, ptr %6, align 4
  store i32 1, ptr %13, align 4
  br label %122

51:                                               ; preds = %41
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #7
  %52 = load ptr, ptr %7, align 8, !tbaa !5
  %53 = call i32 @check_txn(ptr noundef %52, i32 noundef 51)
  store i32 %53, ptr %14, align 4, !tbaa !9
  %54 = load i32, ptr %14, align 4, !tbaa !9
  %55 = icmp ne i32 %54, 0
  %56 = xor i1 %55, true
  %57 = xor i1 %56, true
  %58 = zext i1 %57 to i32
  %59 = sext i32 %58 to i64
  %60 = call i64 @llvm.expect.i64(i64 %59, i64 0)
  %61 = icmp ne i64 %60, 0
  br i1 %61, label %62, label %65

62:                                               ; preds = %51
  %63 = load i32, ptr %14, align 4, !tbaa !9
  %64 = call i32 @log_if_error(i32 noundef %63, ptr noundef @__func__.mdbx_get_ex, i32 noundef 111)
  store i32 %64, ptr %6, align 4
  store i32 1, ptr %13, align 4
  br label %121

65:                                               ; preds = %51
  call void @llvm.lifetime.start.p0(i64 824, ptr %15) #7
  %66 = getelementptr inbounds %struct.cursor_couple, ptr %15, i32 0, i32 0
  %67 = load ptr, ptr %7, align 8, !tbaa !5
  %68 = load i32, ptr %8, align 4, !tbaa !9
  %69 = zext i32 %68 to i64
  %70 = call i32 @cursor_init(ptr noundef %66, ptr noundef %67, i64 noundef %69)
  store i32 %70, ptr %14, align 4, !tbaa !9
  %71 = load i32, ptr %14, align 4, !tbaa !9
  %72 = icmp ne i32 %71, 0
  %73 = xor i1 %72, true
  %74 = xor i1 %73, true
  %75 = zext i1 %74 to i32
  %76 = sext i32 %75 to i64
  %77 = call i64 @llvm.expect.i64(i64 %76, i64 0)
  %78 = icmp ne i64 %77, 0
  br i1 %78, label %79, label %82

79:                                               ; preds = %65
  %80 = load i32, ptr %14, align 4, !tbaa !9
  %81 = call i32 @log_if_error(i32 noundef %80, ptr noundef @__func__.mdbx_get_ex, i32 noundef 116)
  store i32 %81, ptr %6, align 4
  store i32 1, ptr %13, align 4
  br label %120

82:                                               ; preds = %65
  %83 = getelementptr inbounds %struct.cursor_couple, ptr %15, i32 0, i32 0
  %84 = load ptr, ptr %9, align 8, !tbaa !5
  %85 = load ptr, ptr %10, align 8, !tbaa !5
  %86 = call i64 @cursor_seek(ptr noundef %83, ptr noundef %84, ptr noundef %85, i32 noundef 16)
  store i64 %86, ptr %16, align 4
  %87 = getelementptr inbounds %struct.cursor_set_result, ptr %16, i32 0, i32 0
  %88 = load i32, ptr %87, align 4, !tbaa !15
  store i32 %88, ptr %14, align 4, !tbaa !9
  %89 = load i32, ptr %14, align 4, !tbaa !9
  %90 = icmp ne i32 %89, 0
  %91 = xor i1 %90, true
  %92 = xor i1 %91, true
  %93 = zext i1 %92 to i32
  %94 = sext i32 %93 to i64
  %95 = call i64 @llvm.expect.i64(i64 %94, i64 0)
  %96 = icmp ne i64 %95, 0
  br i1 %96, label %97, label %105

97:                                               ; preds = %82
  %98 = load ptr, ptr %11, align 8, !tbaa !5
  %99 = icmp ne ptr %98, null
  br i1 %99, label %100, label %102

100:                                              ; preds = %97
  %101 = load ptr, ptr %11, align 8, !tbaa !5
  store i64 0, ptr %101, align 8, !tbaa !17
  br label %102

102:                                              ; preds = %100, %97
  %103 = load i32, ptr %14, align 4, !tbaa !9
  %104 = call i32 @log_if_error(i32 noundef %103, ptr noundef @__func__.mdbx_get_ex, i32 noundef 122)
  store i32 %104, ptr %6, align 4
  store i32 1, ptr %13, align 4
  br label %120

105:                                              ; preds = %82
  %106 = load ptr, ptr %11, align 8, !tbaa !5
  %107 = icmp ne ptr %106, null
  br i1 %107, label %108, label %119

108:                                              ; preds = %105
  %109 = load ptr, ptr %11, align 8, !tbaa !5
  store i64 1, ptr %109, align 8, !tbaa !17
  %110 = getelementptr inbounds %struct.cursor_couple, ptr %15, i32 0, i32 0
  %111 = call zeroext i1 @inner_pointed(ptr noundef %110) #8
  br i1 %111, label %112, label %118

112:                                              ; preds = %108
  %113 = getelementptr inbounds %struct.cursor_couple, ptr %15, i32 0, i32 2
  %114 = getelementptr inbounds %struct.inner_cursor, ptr %113, i32 0, i32 1
  %115 = getelementptr inbounds %struct.tree, ptr %114, i32 0, i32 8
  %116 = load i64, ptr %115, align 8, !tbaa !18
  %117 = load ptr, ptr %11, align 8, !tbaa !5
  store i64 %116, ptr %117, align 8, !tbaa !17
  br label %118

118:                                              ; preds = %112, %108
  br label %119

119:                                              ; preds = %118, %105
  store i32 0, ptr %6, align 4
  store i32 1, ptr %13, align 4
  br label %120

120:                                              ; preds = %119, %102, %79
  call void @llvm.lifetime.end.p0(i64 824, ptr %15) #7
  br label %121

121:                                              ; preds = %120, %62
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #7
  br label %122

122:                                              ; preds = %121, %49
  call void @llvm.lifetime.end.p0(i64 510, ptr %12) #7
  %123 = load i32, ptr %6, align 4
  ret i32 %123
}

; Function Attrs: inlinehint nounwind willreturn memory(read) uwtable
declare hidden zeroext i1 @inner_pointed(ptr noundef) #6

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(none) }
attributes #1 = { 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 #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #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 = { 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 = { inlinehint nounwind willreturn memory(read) 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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !7, i64 26}
!12 = !{!"libmdbx_globals", !7, i64 0, !10, i64 16, !10, i64 20, !7, i64 24, !7, i64 25, !7, i64 26, !13, i64 27, !10, i64 28, !7, i64 32, !7, i64 40, !14, i64 80, !6, i64 88}
!13 = !{!"_Bool", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!16, !10, i64 0}
!16 = !{!"cursor_set_result", !10, i64 0, !13, i64 4}
!17 = !{!14, !14, i64 0}
!18 = !{!19, !14, i64 808}
!19 = !{!"cursor_couple", !20, i64 0, !6, i64 384, !21, i64 392}
!20 = !{!"MDBX_cursor", !10, i64 0, !7, i64 4, !7, i64 6, !7, i64 7, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !7, i64 48, !7, i64 304, !6, i64 368, !6, i64 376}
!21 = !{!"inner_cursor", !20, i64 0, !22, i64 384}
!22 = !{!"tree", !23, i64 0, !23, i64 2, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !14, i64 24, !14, i64 32, !14, i64 40}
!23 = !{!"short", !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"

%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.0 }
%struct.anon.0 = 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.cursor_couple = type { %struct.MDBX_cursor, ptr, %struct.inner_cursor }
%struct.MDBX_cursor = type { i32, %union.anon, i8, i8, ptr, ptr, ptr, ptr, ptr, [32 x ptr], [32 x i16], ptr, ptr }
%union.anon = type { i16 }
%struct.inner_cursor = type { %struct.MDBX_cursor, %struct.tree }
%struct.tree = type { i16, i16, i32, i32, i32, i32, i32, i64, i64, i64 }

@globals = external local_unnamed_addr global %struct.libmdbx_globals, align 8
@.str.3 = external hidden unnamed_addr constant [25 x i8], align 1
@__func__.mdbx_get_ex = external hidden unnamed_addr constant [12 x i8], align 1

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @log_if_error(i32 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: alwaysinline nounwind uwtable
declare hidden i32 @check_txn(ptr noundef, i32 noundef) local_unnamed_addr #2

declare i32 @cursor_init(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

declare void @debug_log(i32 noundef, ptr noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #3

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

declare ptr @mdbx_dump_val(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #3

declare i64 @cursor_seek(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local i32 @mdbx_get_ex(ptr noundef %0, i32 noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef writeonly %4) local_unnamed_addr #4 {
  %6 = alloca [510 x i8], align 16
  %7 = alloca %struct.cursor_couple, align 8
  call void @llvm.lifetime.start.p0(i64 510, ptr nonnull %6) #6
  %8 = load i8, ptr getelementptr inbounds (i8, ptr @globals, i64 26), align 2, !tbaa !5
  %9 = icmp ugt i8 %8, 4
  br i1 %9, label %10, label %12, !prof !13

10:                                               ; preds = %5
  %11 = call ptr @mdbx_dump_val(ptr noundef %2, ptr noundef nonnull %6, i64 noundef 255) #6
  call void (i32, ptr, i32, ptr, ...) @debug_log(i32 noundef 5, ptr noundef nonnull @__func__.mdbx_get_ex, i32 noundef 104, ptr noundef nonnull @.str.3, i32 noundef %1, ptr noundef %11) #6
  br label %12

12:                                               ; preds = %10, %5
  %.not = icmp eq ptr %2, null
  %.not24 = icmp eq ptr %3, null
  %13 = or i1 %.not, %.not24
  br i1 %13, label %14, label %16, !prof !13

14:                                               ; preds = %12
  %15 = call i32 @log_if_error(i32 noundef 22, ptr noundef nonnull @__func__.mdbx_get_ex, i32 noundef 107)
  br label %38

16:                                               ; preds = %12
  %17 = call i32 @check_txn(ptr noundef %0, i32 noundef 51)
  %.not25 = icmp eq i32 %17, 0
  br i1 %.not25, label %20, label %18, !prof !14

18:                                               ; preds = %16
  %19 = call i32 @log_if_error(i32 noundef %17, ptr noundef nonnull @__func__.mdbx_get_ex, i32 noundef 111)
  br label %38

20:                                               ; preds = %16
  call void @llvm.lifetime.start.p0(i64 824, ptr nonnull %7) #6
  %21 = zext i32 %1 to i64
  %22 = call i32 @cursor_init(ptr noundef nonnull %7, ptr noundef %0, i64 noundef %21) #6
  %.not26 = icmp eq i32 %22, 0
  br i1 %.not26, label %25, label %23, !prof !14

23:                                               ; preds = %20
  %24 = call i32 @log_if_error(i32 noundef %22, ptr noundef nonnull @__func__.mdbx_get_ex, i32 noundef 116)
  br label %37

25:                                               ; preds = %20
  %26 = call i64 @cursor_seek(ptr noundef nonnull %7, ptr noundef nonnull %2, ptr noundef nonnull %3, i32 noundef 16) #6
  %.sroa.0.0.extract.trunc = trunc i64 %26 to i32
  %.not27 = icmp eq i32 %.sroa.0.0.extract.trunc, 0
  %.not28 = icmp eq ptr %4, null
  br i1 %.not27, label %31, label %27, !prof !14

27:                                               ; preds = %25
  br i1 %.not28, label %29, label %28

28:                                               ; preds = %27
  store i64 0, ptr %4, align 8, !tbaa !15
  br label %29

29:                                               ; preds = %28, %27
  %30 = call i32 @log_if_error(i32 noundef %.sroa.0.0.extract.trunc, ptr noundef nonnull @__func__.mdbx_get_ex, i32 noundef 122)
  br label %37

31:                                               ; preds = %25
  br i1 %.not28, label %37, label %32

32:                                               ; preds = %31
  store i64 1, ptr %4, align 8, !tbaa !15
  %33 = call zeroext i1 @inner_pointed(ptr noundef nonnull %7) #7
  br i1 %33, label %34, label %37

34:                                               ; preds = %32
  %35 = getelementptr inbounds i8, ptr %7, i64 808
  %36 = load i64, ptr %35, align 8, !tbaa !16
  store i64 %36, ptr %4, align 8, !tbaa !15
  br label %37

37:                                               ; preds = %31, %34, %32, %29, %23
  %.0 = phi i32 [ %24, %23 ], [ %30, %29 ], [ 0, %32 ], [ 0, %34 ], [ 0, %31 ]
  call void @llvm.lifetime.end.p0(i64 824, ptr nonnull %7) #6
  br label %38

38:                                               ; preds = %18, %37, %14
  %.2 = phi i32 [ %15, %14 ], [ %19, %18 ], [ %.0, %37 ]
  call void @llvm.lifetime.end.p0(i64 510, ptr nonnull %6) #6
  ret i32 %.2
}

; Function Attrs: inlinehint mustprogress nofree nounwind willreturn memory(read) uwtable
declare hidden zeroext i1 @inner_pointed(ptr noundef) local_unnamed_addr #5

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { "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 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 = { inlinehint mustprogress nofree nounwind willreturn memory(read) 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, !7, i64 26}
!6 = !{!"libmdbx_globals", !7, i64 0, !9, i64 16, !9, i64 20, !7, i64 24, !7, i64 25, !7, i64 26, !10, i64 27, !9, i64 28, !7, i64 32, !7, i64 40, !11, i64 80, !12, i64 88}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!"int", !7, i64 0}
!10 = !{!"_Bool", !7, i64 0}
!11 = !{!"long", !7, i64 0}
!12 = !{!"any pointer", !7, i64 0}
!13 = !{!"branch_weights", !"expected", i32 1, i32 2000}
!14 = !{!"branch_weights", !"expected", i32 2000, i32 1}
!15 = !{!11, !11, i64 0}
!16 = !{!17, !11, i64 808}
!17 = !{!"cursor_couple", !18, i64 0, !12, i64 384, !19, i64 392}
!18 = !{!"MDBX_cursor", !9, i64 0, !7, i64 4, !7, i64 6, !7, i64 7, !12, i64 8, !12, i64 16, !12, i64 24, !12, i64 32, !12, i64 40, !7, i64 48, !7, i64 304, !12, i64 368, !12, i64 376}
!19 = !{!"inner_cursor", !18, i64 0, !20, i64 384}
!20 = !{!"tree", !21, i64 0, !21, i64 2, !9, i64 4, !9, i64 8, !9, i64 12, !9, i64 16, !9, i64 20, !11, i64 24, !11, i64 32, !11, i64 40}
!21 = !{!"short", !7, i64 0}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,LowerExpectIntrinsicPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass