	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__cx18_enqueue                  ## -- Begin function _cx18_enqueue
	.p2align	4, 0x90
__cx18_enqueue:                         ## @_cx18_enqueue
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r15d
	movq	%rdx, %rbx
	movq	%rsi, %r14
	movq	%rdi, %r12
	leaq	32(%rdi), %rax
	cmpq	%rdx, %rax
	je	LBB0_2
## %bb.1:
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%r14)
	movups	%xmm0, 24(%r14)
	movq	$0, 40(%r14)
LBB0_2:
	leaq	16(%r12), %rax
	cmpq	%rbx, %rax
	jne	LBB0_4
## %bb.3:
	leaq	4(%rbx), %rdi
	callq	_atomic_read
	movq	_CX18_MAX_FW_MDLS_PER_STREAM@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	cmovgeq	%r12, %rbx
LBB0_4:
	movq	%rbx, %rdi
	callq	_spin_lock
	leaq	16(%r14), %rdi
	leaq	12(%rbx), %rsi
	testl	%r15d, %r15d
	je	LBB0_6
## %bb.5:
	callq	_list_add
	jmp	LBB0_7
LBB0_6:
	callq	_list_add_tail
LBB0_7:
	movl	8(%r14), %eax
	subl	(%r14), %eax
	addl	%eax, 8(%rbx)
	leaq	4(%rbx), %rdi
	callq	_atomic_inc
	movq	%rbx, %rdi
	callq	_spin_unlock
	movq	%rbx, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CX18_MAX_FW_MDLS_PER_STREAM,8,3 ## @CX18_MAX_FW_MDLS_PER_STREAM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__cx18_enqueue                  ; -- Begin function _cx18_enqueue
	.p2align	2
__cx18_enqueue:                         ; @_cx18_enqueue
	.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	x21, x3
	mov	x19, x2
	mov	x20, x1
	mov	x22, x0
	add	x8, x0, #32
	cmp	x8, x2
	b.eq	LBB0_2
; %bb.1:
	stp	xzr, xzr, [x20]
	stp	xzr, xzr, [x20, #32]
	str	xzr, [x20, #24]
LBB0_2:
	add	x8, x22, #16
	cmp	x8, x19
	b.ne	LBB0_4
; %bb.3:
	add	x0, x19, #4
	bl	_atomic_read
Lloh0:
	adrp	x8, _CX18_MAX_FW_MDLS_PER_STREAM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CX18_MAX_FW_MDLS_PER_STREAM@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x0, x8
	csel	x19, x19, x22, lt
LBB0_4:
	mov	x0, x19
	bl	_spin_lock
	add	x0, x20, #16
	add	x1, x19, #12
	cbz	w21, LBB0_6
; %bb.5:
	bl	_list_add
	b	LBB0_7
LBB0_6:
	bl	_list_add_tail
LBB0_7:
	ldr	w8, [x20, #8]
	ldr	w9, [x20]
	ldr	w10, [x19, #8]
	sub	w8, w8, w9
	add	w8, w10, w8
	str	w8, [x19, #8]
	add	x0, x19, #4
	bl	_atomic_inc
	mov	x0, x19
	bl	_spin_unlock
	mov	x0, x19
	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
	.cfi_endproc
                                        ; -- End function
	.comm	_CX18_MAX_FW_MDLS_PER_STREAM,8,3 ; @CX18_MAX_FW_MDLS_PER_STREAM
.subsections_via_symbols
