	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ng_pred1_decompress
_ng_pred1_decompress:                   ## @ng_pred1_decompress
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %rbx
	movl	%edi, %r15d
	callq	_NG_NODE_PRIVATE
	movq	%rax, %r13
	movq	$0, (%r14)
	movslq	(%rbx), %r12
	movq	_PRED1_BUF_SIZE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r12d
	jle	LBB0_2
## %bb.1:
	incl	28(%r13)
	movq	%rbx, %rdi
	callq	_NG_FREE_M
	jmp	LBB0_12
LBB0_2:
	movq	_M_NOWAIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_m_unshare
	testq	%rax, %rax
	je	LBB0_11
## %bb.3:
	movl	(%r13), %ecx
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	%rax, %rdi
	xorl	%esi, %esi
	movl	%r12d, %edx
	callq	_m_copydata
	addl	%r12d, 16(%r13)
	movq	(%r13), %rsi
	movl	(%rsi), %eax
	shll	$8, %eax
	addl	4(%rsi), %eax
	movl	%eax, %ebx
	andl	$32767, %ebx                    ## imm = 0x7FFF
	testl	$32768, %eax                    ## imm = 0x8000
	jne	LBB0_7
## %bb.4:
	incl	32(%r13)
	addl	$-4, %r12d
	cmpl	%r12d, %ebx
	jne	LBB0_13
## %bb.5:
	addq	$8, %rsi
	movl	%r15d, %edi
	movl	%ebx, %edx
	callq	_Pred1SyncTable
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	$2, %esi
	callq	_m_adj
	movq	%r15, %rdi
	movl	$-2, %esi
	callq	_m_adj
LBB0_6:
	movq	%r15, (%r14)
	incl	24(%r13)
	addl	%ebx, 20(%r13)
	xorl	%eax, %eax
	jmp	LBB0_18
LBB0_7:
	incl	36(%r13)
	addq	$8, %rsi
	movq	8(%r13), %rdx
	leal	-4(%r12), %ecx
	movq	_PRED1_BUF_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movl	%r15d, %edi
	callq	_Pred1Decompress
	cmpl	%eax, %ebx
	jne	LBB0_14
## %bb.8:
	movl	%ebx, %edi
	callq	_htons
	movl	%eax, -52(%rbp)
	movq	_PPP_INITFCS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-52(%rbp), %rsi
	movl	$2, %edx
	callq	_Crc16
	movq	8(%r13), %rsi
	movl	%eax, %edi
	movl	%ebx, %edx
	callq	_Crc16
	movq	(%r13), %rcx
	leaq	(%rcx,%r12,4), %rsi
	addq	$-8, %rsi
	movl	%eax, %edi
	movl	$2, %edx
	callq	_Crc16
	movq	_PPP_GOODFCS@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_15
## %bb.9:
	movl	8(%r13), %ecx
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	%ebx, %edx
	callq	_m_copyback
	movl	%ebx, %esi
	subl	(%r15), %esi
	jle	LBB0_19
## %bb.10:
	movq	%r15, %rdi
	callq	_m_freem
LBB0_11:
	incl	28(%r13)
LBB0_12:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_13:
	incl	28(%r13)
	movq	_LOG_NOTICE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	movl	%ebx, %edx
	movl	%r12d, %ecx
	xorl	%eax, %eax
	callq	_log
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_NG_FREE_M
	jmp	LBB0_16
LBB0_14:
	movl	%eax, %r15d
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_m_freem
	incl	28(%r13)
	movq	_LOG_NOTICE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	movl	%r15d, %ecx
	xorl	%eax, %eax
	callq	_log
	jmp	LBB0_16
LBB0_15:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_m_freem
	incl	28(%r13)
	movq	_LOG_NOTICE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_log
LBB0_16:
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_17:
	movl	(%rax), %eax
LBB0_18:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	jge	LBB0_6
## %bb.20:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_m_adj
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_PRED1_BUF_SIZE,4,2             ## @PRED1_BUF_SIZE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_M_NOWAIT,4,2                   ## @M_NOWAIT
	.comm	_LOG_NOTICE,4,2                 ## @LOG_NOTICE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ng_pred1: Comp length error (%d) --> len (%d)\n"

	.comm	_EIO,4,2                        ## @EIO
	.comm	_PPP_INITFCS,4,2                ## @PPP_INITFCS
	.comm	_PPP_GOODFCS,4,2                ## @PPP_GOODFCS
L_.str.1:                               ## @.str.1
	.asciz	"ng_pred1: Pred1: Bad CRC-16\n"

L_.str.2:                               ## @.str.2
	.asciz	"ng_pred1: Uncomp length error (%d) --> len (%d)\n"

	.no_dead_strip	_ng_pred1_decompress
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ng_pred1_decompress
_ng_pred1_decompress:                   ; @ng_pred1_decompress
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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, x2
	mov	x21, x1
	mov	x24, x0
	bl	_NG_NODE_PRIVATE
	mov	x19, x0
	str	xzr, [x20]
	ldrsw	x23, [x21]
Lloh0:
	adrp	x25, _PRED1_BUF_SIZE@GOTPAGE
Lloh1:
	ldr	x25, [x25, _PRED1_BUF_SIZE@GOTPAGEOFF]
	ldr	w8, [x25]
	cmp	w23, w8
	b.le	LBB0_2
; %bb.1:
	ldr	w8, [x19, #28]
	add	w8, w8, #1
	str	w8, [x19, #28]
	mov	x0, x21
	bl	_NG_FREE_M
	b	LBB0_13
LBB0_2:
Lloh2:
	adrp	x8, _M_NOWAIT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _M_NOWAIT@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_m_unshare
	cbz	x0, LBB0_12
; %bb.3:
	mov	x21, x0
	ldr	w3, [x19]
	mov	w1, #0
	mov	x2, x23
	bl	_m_copydata
	ldr	w8, [x19, #16]
	add	w8, w8, w23
	str	w8, [x19, #16]
	ldr	x8, [x19]
	ldp	w9, w10, [x8]
	add	w9, w10, w9, lsl #8
	and	w22, w9, #0x7fff
	tbnz	w9, #15, LBB0_8
; %bb.4:
	ldr	w9, [x19, #32]
	add	w9, w9, #1
	str	w9, [x19, #32]
	sub	w9, w23, #4
	cmp	w22, w9
	b.ne	LBB0_14
; %bb.5:
	add	x1, x8, #8
	mov	x0, x24
	mov	x2, x22
	bl	_Pred1SyncTable
	mov	x0, x21
	mov	w1, #2
	bl	_m_adj
	mov	x0, x21
	mov	w1, #-2
LBB0_6:
	bl	_m_adj
LBB0_7:
	mov	w0, #0
	str	x21, [x20]
	ldur	d0, [x19, #20]
	movi.2s	v1, #1
	mov.s	v1[0], w22
	add.2s	v0, v0, v1
	stur	d0, [x19, #20]
	b	LBB0_20
LBB0_8:
	ldr	w9, [x19, #36]
	add	w9, w9, #1
	str	w9, [x19, #36]
	add	x1, x8, #8
	ldr	x2, [x19, #8]
	sub	w3, w23, #4
	ldr	w4, [x25]
	mov	x0, x24
	bl	_Pred1Decompress
	cmp	w22, w0
	b.ne	LBB0_15
; %bb.9:
	mov	x0, x22
	bl	_htons
	str	w0, [sp, #28]
Lloh5:
	adrp	x8, _PPP_INITFCS@GOTPAGE
Lloh6:
	ldr	x8, [x8, _PPP_INITFCS@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	add	x1, sp, #28
	mov	w2, #2
	bl	_Crc16
	ldr	x1, [x19, #8]
	mov	x2, x22
	bl	_Crc16
	ldr	x8, [x19]
	add	x8, x8, x23, lsl #2
	sub	x1, x8, #8
	mov	w2, #2
	bl	_Crc16
Lloh8:
	adrp	x8, _PPP_GOODFCS@GOTPAGE
Lloh9:
	ldr	x8, [x8, _PPP_GOODFCS@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_16
; %bb.10:
	ldr	w3, [x19, #8]
	mov	x0, x21
	mov	w1, #0
	mov	x2, x22
	bl	_m_copyback
	ldr	w8, [x21]
	subs	w1, w22, w8
	b.le	LBB0_21
; %bb.11:
	mov	x0, x21
	bl	_m_freem
LBB0_12:
	ldr	w8, [x19, #28]
	add	w8, w8, #1
	str	w8, [x19, #28]
LBB0_13:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_19
LBB0_14:
	ldr	w8, [x19, #28]
	add	w8, w8, #1
	str	w8, [x19, #28]
Lloh13:
	adrp	x8, _LOG_NOTICE@GOTPAGE
Lloh14:
	ldr	x8, [x8, _LOG_NOTICE@GOTPAGEOFF]
Lloh15:
	ldr	w0, [x8]
                                        ; kill: def $w22 killed $w22 killed $x22 def $x22
	stp	x22, x9, [sp]
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_log
	mov	x0, x21
	bl	_NG_FREE_M
	b	LBB0_18
LBB0_15:
	mov	x24, x0
	mov	x0, x21
	bl	_m_freem
	ldr	w8, [x19, #28]
	add	w8, w8, #1
	str	w8, [x19, #28]
Lloh18:
	adrp	x8, _LOG_NOTICE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _LOG_NOTICE@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	stp	x22, x24, [sp]
Lloh21:
	adrp	x1, l_.str@PAGE
Lloh22:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_17
LBB0_16:
	mov	x0, x21
	bl	_m_freem
	ldr	w8, [x19, #28]
	add	w8, w8, #1
	str	w8, [x19, #28]
Lloh23:
	adrp	x8, _LOG_NOTICE@GOTPAGE
Lloh24:
	ldr	x8, [x8, _LOG_NOTICE@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
Lloh26:
	adrp	x1, l_.str.1@PAGE
Lloh27:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_17:
	bl	_log
LBB0_18:
Lloh28:
	adrp	x8, _EIO@GOTPAGE
Lloh29:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_19:
	ldr	w0, [x8]
LBB0_20:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_21:
	b.ge	LBB0_7
; %bb.22:
	mov	x0, x21
	b	LBB0_6
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_PRED1_BUF_SIZE,4,2             ; @PRED1_BUF_SIZE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_M_NOWAIT,4,2                   ; @M_NOWAIT
	.comm	_LOG_NOTICE,4,2                 ; @LOG_NOTICE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ng_pred1: Comp length error (%d) --> len (%d)\n"

	.comm	_EIO,4,2                        ; @EIO
	.comm	_PPP_INITFCS,4,2                ; @PPP_INITFCS
	.comm	_PPP_GOODFCS,4,2                ; @PPP_GOODFCS
l_.str.1:                               ; @.str.1
	.asciz	"ng_pred1: Pred1: Bad CRC-16\n"

l_.str.2:                               ; @.str.2
	.asciz	"ng_pred1: Uncomp length error (%d) --> len (%d)\n"

	.no_dead_strip	_ng_pred1_decompress
.subsections_via_symbols
