	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amd8111e_calc_coalesce
_amd8111e_calc_coalesce:                ## @amd8111e_calc_coalesce
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_netdev_priv
	movq	%rax, %rbx
	movl	(%rax), %eax
	movl	8(%rbx), %ecx
	movl	%eax, %r12d
	subl	4(%rbx), %r12d
	movl	%eax, 4(%rbx)
	movl	%ecx, %r15d
	subl	12(%rbx), %r15d
	movl	%ecx, 12(%rbx)
	movl	16(%rbx), %eax
	movl	%eax, %ecx
	subl	20(%rbx), %ecx
	movl	%eax, 20(%rbx)
	movl	24(%rbx), %eax
	movl	28(%rbx), %edx
	movl	%eax, 28(%rbx)
	cmpl	$799, %ecx                      ## imm = 0x31F
	jle	LBB0_1
## %bb.2:
	subl	%edx, %eax
	cltd
	idivl	%ecx
	cmpl	$127, %eax
	jg	LBB0_3
LBB0_1:
	movq	32(%rbx), %rdx
	movq	_NO_COALESCE@GOTPCREL(%rip), %r13
	xorl	%eax, %eax
	movl	$0, %ecx
	cmpq	(%r13), %rdx
	jne	LBB0_10
	jmp	LBB0_11
LBB0_3:
	cmpl	$511, %eax                      ## imm = 0x1FF
	ja	LBB0_6
## %bb.4:
	movq	32(%rbx), %rax
	movq	_LOW_COALESCE@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rax
	jne	LBB0_5
	jmp	LBB0_11
LBB0_6:
	movq	32(%rbx), %rcx
	cmpl	$1023, %eax                     ## imm = 0x3FF
	ja	LBB0_8
## %bb.7:
	movq	_MEDIUM_COALESCE@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rcx
	je	LBB0_11
LBB0_5:
	movl	$4, %ecx
	movl	$1, %eax
	jmp	LBB0_10
LBB0_8:
	movq	_HIGH_COALESCE@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rcx
	je	LBB0_11
## %bb.9:
	movl	$3, %ecx
	movl	$2, %eax
LBB0_10:
	movl	%eax, 40(%rbx)
	movl	%ecx, 44(%rbx)
	movq	_RX_INTR_COAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_amd8111e_set_coalesce
	movq	(%r13), %rax
	movq	%rax, 32(%rbx)
LBB0_11:
	cmpl	$799, %r12d                     ## imm = 0x31F
	jle	LBB0_12
## %bb.13:
	movl	%r15d, %eax
	cltd
	idivl	%r12d
	cmpl	$127, %eax
	jg	LBB0_14
LBB0_12:
	movq	48(%rbx), %rdx
	movq	_NO_COALESCE@GOTPCREL(%rip), %r15
	xorl	%eax, %eax
	movl	$0, %ecx
	cmpq	(%r15), %rdx
	je	LBB0_23
LBB0_22:
	movl	%eax, 56(%rbx)
	movl	%ecx, 60(%rbx)
	movq	_TX_INTR_COAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_amd8111e_set_coalesce
	movq	(%r15), %rax
	movq	%rax, 48(%rbx)
LBB0_23:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	cmpl	$511, %eax                      ## imm = 0x1FF
	ja	LBB0_17
## %bb.15:
	movq	48(%rbx), %rax
	movq	_LOW_COALESCE@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	je	LBB0_23
## %bb.16:
	movl	$2, %ecx
	movl	$1, %eax
	jmp	LBB0_22
LBB0_17:
	movq	48(%rbx), %rcx
	cmpl	$1023, %eax                     ## imm = 0x3FF
	ja	LBB0_20
## %bb.18:
	movq	_MEDIUM_COALESCE@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rcx
	je	LBB0_23
## %bb.19:
	movl	$5, %ecx
	movl	$2, %eax
	jmp	LBB0_22
LBB0_20:
	movq	_HIGH_COALESCE@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rcx
	je	LBB0_23
## %bb.21:
	movl	$8, %ecx
	movl	$4, %eax
	jmp	LBB0_22
	.cfi_endproc
                                        ## -- End function
	.comm	_NO_COALESCE,8,3                ## @NO_COALESCE
	.comm	_RX_INTR_COAL,4,2               ## @RX_INTR_COAL
	.comm	_LOW_COALESCE,8,3               ## @LOW_COALESCE
	.comm	_MEDIUM_COALESCE,8,3            ## @MEDIUM_COALESCE
	.comm	_HIGH_COALESCE,8,3              ## @HIGH_COALESCE
	.comm	_TX_INTR_COAL,4,2               ## @TX_INTR_COAL
	.no_dead_strip	_amd8111e_calc_coalesce
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function amd8111e_calc_coalesce
lCPI0_0:
	.long	2                               ; 0x2
	.long	3                               ; 0x3
lCPI0_1:
	.long	1                               ; 0x1
	.long	4                               ; 0x4
lCPI0_2:
	.long	4                               ; 0x4
	.long	8                               ; 0x8
lCPI0_3:
	.long	2                               ; 0x2
	.long	5                               ; 0x5
lCPI0_4:
	.long	1                               ; 0x1
	.long	2                               ; 0x2
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_amd8111e_calc_coalesce:                ; @amd8111e_calc_coalesce
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x20, x0
	bl	_netdev_priv
	mov	x19, x0
	ldp	w8, w9, [x0]
	sub	w21, w8, w9
	str	w8, [x0, #4]
	ldp	w22, w23, [x0, #8]
	str	w22, [x0, #12]
	ldp	w9, w8, [x0, #16]
	sub	w8, w9, w8
	str	w9, [x0, #20]
	ldp	w9, w10, [x0, #24]
	str	w9, [x0, #28]
	cmp	w8, #799
	b.le	LBB0_2
; %bb.1:
	sub	w9, w9, w10
	sdiv	w9, w9, w8
	cmp	w9, #127
	b.gt	LBB0_4
LBB0_2:
	ldr	x8, [x19, #32]
Lloh0:
	adrp	x24, _NO_COALESCE@GOTPAGE
Lloh1:
	ldr	x24, [x24, _NO_COALESCE@GOTPAGEOFF]
	ldr	x9, [x24]
	cmp	x8, x9
	b.eq	LBB0_13
; %bb.3:
	movi.2d	v0, #0000000000000000
	b	LBB0_12
LBB0_4:
	cmp	w9, #511
	b.hi	LBB0_6
; %bb.5:
	ldr	x8, [x19, #32]
Lloh2:
	adrp	x24, _LOW_COALESCE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _LOW_COALESCE@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
	ldr	x8, [x19, #32]
	cmp	w9, #1023
	b.hi	LBB0_10
; %bb.7:
Lloh4:
	adrp	x24, _MEDIUM_COALESCE@GOTPAGE
Lloh5:
	ldr	x24, [x24, _MEDIUM_COALESCE@GOTPAGEOFF]
LBB0_8:
	ldr	x9, [x24]
	cmp	x8, x9
	b.eq	LBB0_13
; %bb.9:
Lloh6:
	adrp	x8, lCPI0_1@PAGE
Lloh7:
	ldr	d0, [x8, lCPI0_1@PAGEOFF]
	b	LBB0_12
LBB0_10:
Lloh8:
	adrp	x24, _HIGH_COALESCE@GOTPAGE
Lloh9:
	ldr	x24, [x24, _HIGH_COALESCE@GOTPAGEOFF]
	ldr	x9, [x24]
	cmp	x8, x9
	b.eq	LBB0_13
; %bb.11:
Lloh10:
	adrp	x8, lCPI0_0@PAGE
Lloh11:
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
LBB0_12:
	str	d0, [x19, #40]
Lloh12:
	adrp	x8, _RX_INTR_COAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _RX_INTR_COAL@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_amd8111e_set_coalesce
	ldr	x8, [x24]
	str	x8, [x19, #32]
LBB0_13:
	cmp	w21, #799
	b.le	LBB0_15
; %bb.14:
	sub	w8, w22, w23
	sdiv	w9, w8, w21
	cmp	w9, #127
	b.gt	LBB0_19
LBB0_15:
	ldr	x8, [x19, #48]
Lloh15:
	adrp	x21, _NO_COALESCE@GOTPAGE
Lloh16:
	ldr	x21, [x21, _NO_COALESCE@GOTPAGEOFF]
	ldr	x9, [x21]
	cmp	x8, x9
	b.eq	LBB0_18
; %bb.16:
	movi.2d	v0, #0000000000000000
LBB0_17:
	str	d0, [x19, #56]
Lloh17:
	adrp	x8, _TX_INTR_COAL@GOTPAGE
Lloh18:
	ldr	x8, [x8, _TX_INTR_COAL@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_amd8111e_set_coalesce
	ldr	x8, [x21]
	str	x8, [x19, #48]
LBB0_18:
	mov	w0, #0
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_19:
	cmp	w9, #511
	b.hi	LBB0_22
; %bb.20:
	ldr	x8, [x19, #48]
Lloh20:
	adrp	x21, _LOW_COALESCE@GOTPAGE
Lloh21:
	ldr	x21, [x21, _LOW_COALESCE@GOTPAGEOFF]
	ldr	x9, [x21]
	cmp	x8, x9
	b.eq	LBB0_18
; %bb.21:
Lloh22:
	adrp	x8, lCPI0_4@PAGE
Lloh23:
	ldr	d0, [x8, lCPI0_4@PAGEOFF]
	b	LBB0_17
LBB0_22:
	ldr	x8, [x19, #48]
	cmp	w9, #1023
	b.hi	LBB0_25
; %bb.23:
Lloh24:
	adrp	x21, _MEDIUM_COALESCE@GOTPAGE
Lloh25:
	ldr	x21, [x21, _MEDIUM_COALESCE@GOTPAGEOFF]
	ldr	x9, [x21]
	cmp	x8, x9
	b.eq	LBB0_18
; %bb.24:
Lloh26:
	adrp	x8, lCPI0_3@PAGE
Lloh27:
	ldr	d0, [x8, lCPI0_3@PAGEOFF]
	b	LBB0_17
LBB0_25:
Lloh28:
	adrp	x21, _HIGH_COALESCE@GOTPAGE
Lloh29:
	ldr	x21, [x21, _HIGH_COALESCE@GOTPAGEOFF]
	ldr	x9, [x21]
	cmp	x8, x9
	b.eq	LBB0_18
; %bb.26:
Lloh30:
	adrp	x8, lCPI0_2@PAGE
Lloh31:
	ldr	d0, [x8, lCPI0_2@PAGEOFF]
	b	LBB0_17
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdr	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdr	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdr	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdr	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdr	Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_NO_COALESCE,8,3                ; @NO_COALESCE
	.comm	_RX_INTR_COAL,4,2               ; @RX_INTR_COAL
	.comm	_LOW_COALESCE,8,3               ; @LOW_COALESCE
	.comm	_MEDIUM_COALESCE,8,3            ; @MEDIUM_COALESCE
	.comm	_HIGH_COALESCE,8,3              ; @HIGH_COALESCE
	.comm	_TX_INTR_COAL,4,2               ; @TX_INTR_COAL
	.no_dead_strip	_amd8111e_calc_coalesce
.subsections_via_symbols
