	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function get_free_pipe_id_locked
_get_free_pipe_id_locked:               ## @get_free_pipe_id_locked
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	(%rdi), %ebx
	testl	%ebx, %ebx
	jle	LBB0_4
## %bb.1:
	movq	8(%r14), %rcx
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$0, (%rcx,%rax,8)
	je	LBB0_7
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	incq	%rax
	cmpq	%rax, %rbx
	jne	LBB0_2
LBB0_4:
	addl	%ebx, %ebx
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%ebx, %edi
	movl	$8, %esi
	callq	_kcalloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	%rax, %r15
	movq	8(%r14), %rsi
	movl	(%r14), %edx
	shll	$3, %edx
	movq	%rax, %rdi
	callq	_memcpy
	movq	8(%r14), %rdi
	callq	_kfree
	movq	%r15, 8(%r14)
	movl	(%r14), %eax
	movl	%ebx, (%r14)
	jmp	LBB0_7
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_7:
                                        ## kill: def $eax killed $eax killed $rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_get_free_pipe_id_locked
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function get_free_pipe_id_locked
_get_free_pipe_id_locked:               ; @get_free_pipe_id_locked
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_4
; %bb.1:
	mov	x0, #0
	ldr	x9, [x19, #8]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x9, x0, lsl #3]
	cbz	x10, LBB0_7
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x0, x0, #1
	cmp	x8, x0
	b.ne	LBB0_2
LBB0_4:
	lsl	w20, w8, #1
Lloh0:
	adrp	x8, _GFP_ATOMIC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_ATOMIC@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x20
	mov	w1, #8
	bl	_kcalloc
	cbz	x0, LBB0_6
; %bb.5:
	mov	x21, x0
	ldr	x1, [x19, #8]
	ldr	w8, [x19]
	lsl	w2, w8, #3
	bl	_memcpy
	ldr	x0, [x19, #8]
	bl	_kfree
	str	x21, [x19, #8]
	ldr	w0, [x19]
	str	w20, [x19]
	b	LBB0_7
LBB0_6:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_7:
                                        ; kill: def $w0 killed $w0 killed $x0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_get_free_pipe_id_locked
.subsections_via_symbols
