	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt76_wcid_alloc                ## -- Begin function mt76_wcid_alloc
	.p2align	4, 0x90
_mt76_wcid_alloc:                       ## @mt76_wcid_alloc
	.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
	movq	_BITS_PER_LONG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%esi, %eax
	cltd
	idivl	%edi
	movl	%eax, %ecx
	movl	$-1, %eax
	testl	%ecx, %ecx
	jle	LBB0_6
## %bb.1:
	movl	%esi, %r8d
	movl	%ecx, %edx
	xorl	%ecx, %ecx
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r14,%rbx,8), %rsi
	cmpq	$-1, %rsi
	jne	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	incq	%rbx
	subl	%edi, %ecx
	cmpq	%rbx, %rdx
	jne	LBB0_2
	jmp	LBB0_6
LBB0_3:
	notq	%rsi
	bsfq	%rsi, %rdi
	movl	%edi, %r15d
	subl	%ecx, %r15d
	cmpl	%r8d, %r15d
	jge	LBB0_6
## %bb.4:
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_BIT
	orq	%rax, (%r14,%rbx,8)
	movl	%r15d, %eax
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BITS_PER_LONG,4,2              ## @BITS_PER_LONG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt76_wcid_alloc                ; -- Begin function mt76_wcid_alloc
	.p2align	2
_mt76_wcid_alloc:                       ; @mt76_wcid_alloc
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, _BITS_PER_LONG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BITS_PER_LONG@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	sdiv	w9, w1, w8
	cmp	w9, #1
	b.lt	LBB0_6
; %bb.1:
	mov	x19, x0
	mov	w10, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x19]
	cmn	x11, #1
	b.ne	LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x19, x19, #8
	sub	w10, w10, w8
	subs	x9, x9, #1
	b.ne	LBB0_2
	b	LBB0_6
LBB0_4:
	mvn	x8, x11
	rbit	x8, x8
	clz	x0, x8
	sub	w20, w0, w10
	cmp	w20, w1
	b.ge	LBB0_6
; %bb.5:
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_BIT
	ldr	x8, [x19]
	orr	x8, x8, x0
	str	x8, [x19]
	b	LBB0_7
LBB0_6:
	mov	w20, #-1
LBB0_7:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_BITS_PER_LONG,4,2              ; @BITS_PER_LONG
.subsections_via_symbols
