	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bch_btree_node_read
_bch_btree_node_read:                   ## @bch_btree_node_read
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	xorl	%eax, %eax
	callq	_local_clock
	movl	%eax, %r14d
	movq	%r15, %rdi
	callq	_trace_bcache_btree_read
	leaq	-40(%rbp), %r12
	movq	%r12, %rdi
	callq	_closure_init_stack
	movq	8(%r15), %rdi
	callq	_bch_bbio_alloc
	movq	%rax, %rbx
	movq	%r15, %rdi
	callq	_KEY_SIZE
	shll	$9, %eax
	movl	%eax, 28(%rbx)
	movq	_btree_node_read_endio@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movq	%r12, 16(%rbx)
	movq	_REQ_OP_READ@GOTPCREL(%rip), %rax
	movq	_REQ_META@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movl	%ecx, (%rbx)
	movq	16(%r15), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bch_bio_map
	movq	8(%r15), %rsi
	movq	%rbx, %rdi
	movq	%r15, %rdx
	xorl	%ecx, %ecx
	callq	_bch_submit_bbio
	movq	%r12, %rdi
	callq	_closure_sync
	cmpq	$0, 8(%rbx)
	je	LBB0_2
## %bb.1:
	movq	%r15, %rdi
	callq	_set_btree_node_io_error
LBB0_2:
	movq	8(%r15), %rsi
	movq	%rbx, %rdi
	callq	_bch_bbio_free
	movq	%r15, %rdi
	callq	_btree_node_io_error
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	8(%r15), %rbx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	xorl	%edx, %edx
	callq	_PTR_BUCKET_NR
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_bch_cache_set_error
	jmp	LBB0_5
LBB0_3:
	movq	%r15, %rdi
	callq	_bch_btree_node_read_done
	movq	8(%r15), %rdi
	movl	%r14d, %esi
	callq	_bch_time_stats_update
LBB0_5:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_btree_node_read_endio,4,2      ## @btree_node_read_endio
	.comm	_REQ_OP_READ,4,2                ## @REQ_OP_READ
	.comm	_REQ_META,4,2                   ## @REQ_META
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"io error reading bucket %zu"

	.no_dead_strip	_bch_btree_node_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bch_btree_node_read
_bch_btree_node_read:                   ; @bch_btree_node_read
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
	bl	_local_clock
	mov	x20, x0
	mov	x0, x19
	bl	_trace_bcache_btree_read
	add	x22, sp, #8
	add	x0, sp, #8
	bl	_closure_init_stack
	ldr	x0, [x19, #8]
	bl	_bch_bbio_alloc
	mov	x21, x0
	mov	x0, x19
	bl	_KEY_SIZE
	lsl	w8, w0, #9
Lloh0:
	adrp	x9, _btree_node_read_endio@GOTPAGE
Lloh1:
	ldr	x9, [x9, _btree_node_read_endio@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	stp	w9, w8, [x21, #24]
	str	x22, [x21, #16]
Lloh3:
	adrp	x8, _REQ_OP_READ@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REQ_OP_READ@GOTPAGEOFF]
Lloh5:
	adrp	x9, _REQ_META@GOTPAGE
Lloh6:
	ldr	x9, [x9, _REQ_META@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x21]
	ldr	x8, [x19, #16]
	ldr	w1, [x8]
	mov	x0, x21
	bl	_bch_bio_map
	ldr	x1, [x19, #8]
	mov	x0, x21
	mov	x2, x19
	mov	w3, #0
	bl	_bch_submit_bbio
	add	x0, sp, #8
	bl	_closure_sync
	ldr	x8, [x21, #8]
	cbz	x8, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_set_btree_node_io_error
LBB0_2:
	ldr	x1, [x19, #8]
	mov	x0, x21
	bl	_bch_bbio_free
	mov	x0, x19
	bl	_btree_node_io_error
	cbz	x0, LBB0_4
; %bb.3:
	ldr	x20, [x19, #8]
	mov	x0, x20
	mov	x1, x19
	mov	w2, #0
	bl	_PTR_BUCKET_NR
	mov	x2, x0
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_bch_cache_set_error
	b	LBB0_5
LBB0_4:
	mov	x0, x19
	bl	_bch_btree_node_read_done
	ldr	x0, [x19, #8]
	mov	x1, x20
	bl	_bch_time_stats_update
LBB0_5:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_btree_node_read_endio,4,2      ; @btree_node_read_endio
	.comm	_REQ_OP_READ,4,2                ; @REQ_OP_READ
	.comm	_REQ_META,4,2                   ; @REQ_META
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"io error reading bucket %zu"

	.no_dead_strip	_bch_btree_node_read
.subsections_via_symbols
