	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___bch_bucket_alloc_set         ## -- Begin function __bch_bucket_alloc_set
	.p2align	4, 0x90
___bch_bucket_alloc_set:                ## @__bch_bucket_alloc_set
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r13d
	movl	%ecx, %ebx
	movq	%rdx, %r15
	movl	%esi, %r12d
	movq	%rdi, %r14
	movq	_CACHE_SET_IO_DISABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	20(%r14), %rsi
	callq	_test_bit
	movl	%eax, %edi
	callq	_unlikely
	movl	$-1, %ecx
	testq	%rax, %rax
	jne	LBB0_1
## %bb.2:
	leaq	16(%r14), %rdi
	callq	_lockdep_assert_held
	movl	$1, %edi
	testl	%ebx, %ebx
	je	LBB0_5
## %bb.3:
	cmpl	%ebx, (%r14)
	jl	LBB0_5
## %bb.4:
	movq	_MAX_CACHES_PER_SET@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	%ebx, (%rax)
	setl	%dil
LBB0_5:
	callq	_BUG_ON
	movq	%r15, %rdi
	callq	_bkey_init
	testl	%ebx, %ebx
	jle	LBB0_10
## %bb.6:
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	movl	%ebx, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	movq	%r15, -64(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rax
	movq	(%rax,%rbx,8), %r12
	movq	%r12, %rdi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movl	%r13d, %edx
	callq	_bch_bucket_alloc
	cmpq	$-1, %rax
	je	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	8(%r12), %rcx
	movl	%r13d, %r15d
	movl	(%rcx,%rax,4), %r13d
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_bucket_to_sector
	movl	(%r12), %edx
	movl	%r13d, %edi
	movl	%r15d, %r13d
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movl	%eax, %esi
	callq	_MAKE_PTR
	movq	(%r15), %rcx
	movl	%eax, (%rcx,%rbx,4)
	incq	%rbx
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_SET_KEY_PTRS
	cmpq	%rbx, -56(%rbp)                 ## 8-byte Folded Reload
	jne	LBB0_7
LBB0_10:
	xorl	%ecx, %ecx
	jmp	LBB0_1
LBB0_11:
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_bch_bucket_free
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_bkey_put
	movl	$-1, %ecx
LBB0_1:
	movl	%ecx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CACHE_SET_IO_DISABLE,4,2       ## @CACHE_SET_IO_DISABLE
	.comm	_MAX_CACHES_PER_SET,4,2         ## @MAX_CACHES_PER_SET
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___bch_bucket_alloc_set         ; -- Begin function __bch_bucket_alloc_set
	.p2align	2
___bch_bucket_alloc_set:                ; @__bch_bucket_alloc_set
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x21, x4
	mov	x23, x3
	mov	x19, x2
	mov	x22, x1
	mov	x20, x0
	add	x1, x0, #20
Lloh0:
	adrp	x8, _CACHE_SET_IO_DISABLE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CACHE_SET_IO_DISABLE@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_test_bit
	bl	_unlikely
	cbz	x0, LBB0_2
LBB0_1:
	mov	w0, #-1
	b	LBB0_11
LBB0_2:
	add	x0, x20, #16
	bl	_lockdep_assert_held
	cbz	w23, LBB0_4
; %bb.3:
	ldr	w8, [x20]
	cmp	w8, w23
	b.ge	LBB0_5
LBB0_4:
	mov	w0, #1
	b	LBB0_6
LBB0_5:
Lloh3:
	adrp	x8, _MAX_CACHES_PER_SET@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_CACHES_PER_SET@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w8, w23
	cset	w0, lt
LBB0_6:
	bl	_BUG_ON
	mov	x0, x19
	bl	_bkey_init
	cmp	w23, #1
	b.lt	LBB0_10
; %bb.7:
	mov	x24, #0
	mov	w26, w23
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x20, #8]
	ldr	x23, [x8, x24, lsl #3]
	mov	x0, x23
	mov	x1, x22
	mov	x2, x21
	bl	_bch_bucket_alloc
	cmn	x0, #1
	b.eq	LBB0_12
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x1, x0
	ldr	x8, [x23, #8]
	ldr	w25, [x8, x0, lsl #2]
	mov	x0, x20
	bl	_bucket_to_sector
	mov	x1, x0
	ldr	w2, [x23]
	mov	x0, x25
	bl	_MAKE_PTR
	ldr	x8, [x19]
	str	w0, [x8, x24, lsl #2]
	add	x24, x24, #1
	mov	x0, x19
	mov	x1, x24
	bl	_SET_KEY_PTRS
	cmp	x26, x24
	b.ne	LBB0_8
LBB0_10:
	mov	w0, #0
LBB0_11:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_12:
	mov	x0, x20
	mov	x1, x19
	bl	_bch_bucket_free
	mov	x0, x20
	mov	x1, x19
	bl	_bkey_put
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_CACHE_SET_IO_DISABLE,4,2       ; @CACHE_SET_IO_DISABLE
	.comm	_MAX_CACHES_PER_SET,4,2         ; @MAX_CACHES_PER_SET
.subsections_via_symbols
