	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ocelot_update_stats
_ocelot_update_stats:                   ## @ocelot_update_stats
	.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
	addq	$16, %rdi
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	callq	_mutex_lock
	cmpl	$0, (%r14)
	jle	LBB0_6
## %bb.1:
	xorl	%ebx, %ebx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	incl	%ebx
	cmpl	(%rdi), %ebx
	movq	%rdi, %r14
	jge	LBB0_6
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	movl	%ebx, %edi
	callq	_SYS_STAT_CFG_STAT_VIEW
	movq	_SYS_STAT_CFG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_ocelot_write
	movq	%r14, %rdi
	movl	4(%r14), %r12d
	testl	%r12d, %r12d
	movq	_SYS_COUNT_RX_OCTETS@GOTPCREL(%rip), %rax
	movq	_U32_MAX@GOTPCREL(%rip), %r15
	jle	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	imull	%ebx, %r12d
	addl	%r13d, %r12d
	movl	(%rax), %esi
	movq	24(%rdi), %rax
	movl	(%rax,%r13,4), %edx
	movq	%rdi, %r14
	callq	_ocelot_read_rix
	movq	%r14, %rdi
	movq	8(%r14), %rcx
	movl	(%r15), %edx
	notl	%edx
	andl	(%rcx,%r12,4), %edx
	addl	%eax, %edx
	movq	_SYS_COUNT_RX_OCTETS@GOTPCREL(%rip), %rax
	movl	%edx, (%rcx,%r12,4)
	incq	%r13
	movslq	4(%r14), %r12
	cmpq	%r12, %r13
	jl	LBB0_4
	jmp	LBB0_5
LBB0_6:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SYS_STAT_CFG,4,2               ## @SYS_STAT_CFG
	.comm	_SYS_COUNT_RX_OCTETS,4,2        ## @SYS_COUNT_RX_OCTETS
	.comm	_U32_MAX,4,2                    ## @U32_MAX
	.no_dead_strip	_ocelot_update_stats
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ocelot_update_stats
_ocelot_update_stats:                   ; @ocelot_update_stats
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x0
	add	x19, x0, #16
	mov	x0, x19
	bl	_mutex_lock
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.1:
	mov	w21, #0
Lloh0:
	adrp	x22, _SYS_STAT_CFG@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SYS_STAT_CFG@GOTPAGEOFF]
Lloh2:
	adrp	x23, _SYS_COUNT_RX_OCTETS@GOTPAGE
Lloh3:
	ldr	x23, [x23, _SYS_COUNT_RX_OCTETS@GOTPAGEOFF]
Lloh4:
	adrp	x24, _U32_MAX@GOTPAGE
Lloh5:
	ldr	x24, [x24, _U32_MAX@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w21, w21, #1
	ldr	w8, [x20]
	cmp	w21, w8
	b.ge	LBB0_6
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	mov	x0, x21
	bl	_SYS_STAT_CFG_STAT_VIEW
	mov	x1, x0
	ldr	w2, [x22]
	mov	x0, x20
	bl	_ocelot_write
	ldr	w8, [x20, #4]
	cmp	w8, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x25, #0
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	madd	w26, w21, w8, w25
	ldr	w1, [x23]
	ldr	x8, [x20, #24]
	ldr	w2, [x8, x25, lsl #2]
	mov	x0, x20
	bl	_ocelot_read_rix
	ldr	x8, [x20, #8]
	lsl	x9, x26, #2
	ldr	w10, [x8, x9]
	ldr	w11, [x24]
	bic	w10, w10, w11
	add	w10, w10, w0
	str	w10, [x8, x9]
	add	x25, x25, #1
	ldrsw	x8, [x20, #4]
	cmp	x25, x8
	b.lt	LBB0_5
	b	LBB0_2
LBB0_6:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_mutex_unlock
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_SYS_STAT_CFG,4,2               ; @SYS_STAT_CFG
	.comm	_SYS_COUNT_RX_OCTETS,4,2        ; @SYS_COUNT_RX_OCTETS
	.comm	_U32_MAX,4,2                    ; @U32_MAX
	.no_dead_strip	_ocelot_update_stats
.subsections_via_symbols
