	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function process_packet
_process_packet:                        ## @process_packet
	.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	%rsi, %r15
	movq	%rdi, %r14
	movq	_NES_PKT_TYPE_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	%rsi, %rdi
	callq	_tcp_hdr
	movq	%rax, %rbx
	movq	%r15, %rdi
	callq	_ip_hdr
	movl	(%rax), %esi
	shll	$2, %esi
	movq	%r15, %rdi
	callq	_skb_pull
	movq	_NES_DBG_CM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r14), %ecx
	movq	16(%rbx), %r8
	movq	8(%rbx), %r9
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdx
	pushq	(%rbx)
	pushq	24(%rbx)
	callq	_nes_debug
	addq	$16, %rsp
	cmpq	$0, 24(%rbx)
	je	LBB0_1
LBB0_11:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_handle_rst_pkt                 ## TAILCALL
LBB0_1:
	cmpq	$0, 16(%rbx)
	movq	8(%rbx), %rax
	je	LBB0_4
## %bb.2:
	testq	%rax, %rax
	je	LBB0_3
LBB0_7:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_handle_synack_pkt              ## TAILCALL
LBB0_4:
	movq	(%rbx), %r13
	testq	%rax, %rax
	je	LBB0_5
LBB0_8:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	callq	_handle_ack_pkt
	testq	%r13, %r13
	je	LBB0_16
## %bb.9:
	testl	%eax, %eax
	jne	LBB0_16
## %bb.10:
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_handle_fin_pkt                 ## TAILCALL
LBB0_5:
	addl	$-128, %r12d
	cmpl	$3, %r12d
	ja	LBB0_12
## %bb.6:
	leaq	LJTI0_0(%rip), %rax
	movslq	(%rax,%r12,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_3:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_handle_syn_pkt                 ## TAILCALL
LBB0_16:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	testq	%r13, %r13
	je	LBB0_15
## %bb.13:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%r15, %rdx
	callq	_check_seq
	testl	%eax, %eax
	jne	LBB0_15
## %bb.14:
	movq	%r14, %rdi
	callq	_handle_fin_pkt
LBB0_15:
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_drop_packet                    ## TAILCALL
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
LJTI0_0:
	.long	L0_0_set_7
	.long	L0_0_set_3
	.long	L0_0_set_11
	.long	L0_0_set_8
	.end_data_region
                                        ## -- End function
	.comm	_NES_PKT_TYPE_UNKNOWN,4,2       ## @NES_PKT_TYPE_UNKNOWN
	.comm	_NES_DBG_CM,4,2                 ## @NES_DBG_CM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"process_packet: cm_node=%p state =%d syn=%d ack=%d rst=%d fin=%d\n"

	.no_dead_strip	_process_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function process_packet
_process_packet:                        ; @process_packet
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _NES_PKT_TYPE_UNKNOWN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NES_PKT_TYPE_UNKNOWN@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	mov	x0, x1
	bl	_tcp_hdr
	mov	x21, x0
	mov	x0, x20
	bl	_ip_hdr
	ldr	w8, [x0]
	lsl	w1, w8, #2
	mov	x0, x20
	bl	_skb_pull
Lloh3:
	adrp	x8, _NES_DBG_CM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NES_DBG_CM@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	ldr	w3, [x19]
	ldp	x4, x6, [x21, #16]
	ldp	x7, x5, [x21]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	bl	_nes_debug
	ldr	x8, [x21, #24]
	cbz	x8, LBB0_2
LBB0_1:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	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
	b	_handle_rst_pkt
LBB0_2:
	ldp	x8, x9, [x21, #8]
	cbz	x9, LBB0_5
; %bb.3:
	cbz	x8, LBB0_11
LBB0_4:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	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
	b	_handle_synack_pkt
LBB0_5:
	ldr	x23, [x21]
	cbz	x8, LBB0_9
LBB0_6:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_handle_ack_pkt
	cbz	x23, LBB0_12
; %bb.7:
	cbnz	w0, LBB0_12
; %bb.8:
	mov	x0, x19
	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
	b	_handle_fin_pkt
LBB0_9:
	sub	w8, w22, #128
	cmp	w8, #3
	b.hi	LBB0_13
; %bb.10:
Lloh8:
	adrp	x9, lJTI0_0@PAGE
Lloh9:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_1
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_11:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	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
	b	_handle_syn_pkt
LBB0_12:
	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_13:
	cbz	x23, LBB0_16
; %bb.14:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_check_seq
	cbnz	w0, LBB0_16
; %bb.15:
	mov	x0, x19
	bl	_handle_fin_pkt
LBB0_16:
	mov	x0, x20
	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
	b	_drop_packet
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_4-LBB0_1)>>2
	.byte	(LBB0_11-LBB0_1)>>2
	.byte	(LBB0_1-LBB0_1)>>2
	.byte	(LBB0_6-LBB0_1)>>2
                                        ; -- End function
	.comm	_NES_PKT_TYPE_UNKNOWN,4,2       ; @NES_PKT_TYPE_UNKNOWN
	.comm	_NES_DBG_CM,4,2                 ; @NES_DBG_CM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"process_packet: cm_node=%p state =%d syn=%d ack=%d rst=%d fin=%d\n"

	.no_dead_strip	_process_packet
.subsections_via_symbols
