	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function i40iw_puda_allocbufs
_i40iw_puda_allocbufs:                  ## @i40iw_puda_allocbufs
	.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, %r15
	testq	%rsi, %rsi
	jle	LBB0_1
## %bb.2:
	movq	%rsi, %r14
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_3 Depth=1
	decq	%r14
	je	LBB0_8
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	28(%r15), %esi
	movl	32(%r15), %edi
	callq	_i40iw_puda_alloc_buf
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	%rax, %rbx
	movq	%r15, %rdi
	movq	%rax, %rsi
	callq	_i40iw_puda_ret_bufpool
	movq	(%r15), %rax
	movq	16(%r15), %rcx
	incq	%rax
	movq	%rax, (%r15)
	movq	%rbx, 16(%r15)
	testq	%rcx, %rcx
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	%rcx, (%rbx)
	jmp	LBB0_7
LBB0_1:
	movq	(%r15), %rax
LBB0_8:
	movq	%rax, 8(%r15)
	xorl	%eax, %eax
	jmp	LBB0_9
LBB0_4:
	incl	24(%r15)
	movq	_I40IW_ERR_NO_MEMORY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_I40IW_ERR_NO_MEMORY,4,2        ## @I40IW_ERR_NO_MEMORY
	.no_dead_strip	_i40iw_puda_allocbufs
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function i40iw_puda_allocbufs
_i40iw_puda_allocbufs:                  ; @i40iw_puda_allocbufs
	.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
	cmp	x1, #0
	b.le	LBB0_6
; %bb.1:
	mov	x20, x1
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	subs	x20, x20, #1
	b.eq	LBB0_7
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldp	w1, w0, [x19, #28]
	bl	_i40iw_puda_alloc_buf
	cbz	x0, LBB0_8
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x21, x0
	mov	x0, x19
	mov	x1, x21
	bl	_i40iw_puda_ret_bufpool
	ldr	x8, [x19]
	add	x8, x8, #1
	str	x8, [x19]
	ldr	x9, [x19, #16]
	str	x21, [x19, #16]
	cbz	x9, LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	str	x9, [x21]
	b	LBB0_2
LBB0_6:
	ldr	x8, [x19]
LBB0_7:
	mov	w0, #0
	str	x8, [x19, #8]
	b	LBB0_9
LBB0_8:
	ldr	w8, [x19, #24]
	add	w8, w8, #1
	str	w8, [x19, #24]
Lloh0:
	adrp	x8, _I40IW_ERR_NO_MEMORY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _I40IW_ERR_NO_MEMORY@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
LBB0_9:
	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	_I40IW_ERR_NO_MEMORY,4,2        ; @I40IW_ERR_NO_MEMORY
	.no_dead_strip	_i40iw_puda_allocbufs
.subsections_via_symbols
