	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ng_bpf_newhook
_ng_bpf_newhook:                        ## @ng_bpf_newhook
	.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	%rdx, %r14
	movl	%esi, %r15d
	movl	%edi, %r12d
	movq	_M_NETGRAPH_BPF@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_M_NOWAIT@GOTPCREL(%rip), %rax
	movq	_M_ZERO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movl	$16, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movl	%r15d, 8(%rax)
	movl	%r15d, %edi
	movq	%rax, %rsi
	callq	_NG_HOOK_SET_PRIVATE
	movq	_ng_bpf_addrefs@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r12d, %edi
	movl	%r15d, %edx
	callq	_NG_NODE_FOREACH_HOOK
	movq	_ng_bpf_default_prog@GOTPCREL(%rip), %rsi
	movl	%r15d, %edi
	callq	_ng_bpf_setprog
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	movl	%eax, %r12d
	movl	(%r13), %esi
	movq	%rbx, %rdi
	callq	_free
	movl	%r15d, %edi
	xorl	%esi, %esi
	callq	_NG_HOOK_SET_PRIVATE
	jmp	LBB0_5
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	jmp	LBB0_5
LBB0_4:
	movq	(%rbx), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	movl	$4, %edx
	callq	_strlcpy
	xorl	%r12d, %r12d
LBB0_5:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_M_NETGRAPH_BPF,4,2             ## @M_NETGRAPH_BPF
	.comm	_M_NOWAIT,4,2                   ## @M_NOWAIT
	.comm	_M_ZERO,4,2                     ## @M_ZERO
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ng_bpf_addrefs,4,2             ## @ng_bpf_addrefs
	.comm	_ng_bpf_default_prog,4,2        ## @ng_bpf_default_prog
	.no_dead_strip	_ng_bpf_newhook
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ng_bpf_newhook
_ng_bpf_newhook:                        ; @ng_bpf_newhook
	.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, x2
	mov	x19, x1
	mov	x22, x0
Lloh0:
	adrp	x23, _M_NETGRAPH_BPF@GOTPAGE
Lloh1:
	ldr	x23, [x23, _M_NETGRAPH_BPF@GOTPAGEOFF]
Lloh2:
	adrp	x8, _M_NOWAIT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _M_NOWAIT@GOTPAGEOFF]
	ldr	w1, [x23]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _M_ZERO@GOTPAGE
Lloh6:
	ldr	x9, [x9, _M_ZERO@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	w0, #16
	bl	_malloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x21, x0
	str	w19, [x0, #8]
	mov	x0, x19
	mov	x1, x21
	bl	_NG_HOOK_SET_PRIVATE
Lloh8:
	adrp	x8, _ng_bpf_addrefs@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ng_bpf_addrefs@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x22
	mov	x2, x19
	bl	_NG_NODE_FOREACH_HOOK
Lloh11:
	adrp	x1, _ng_bpf_default_prog@GOTPAGE
Lloh12:
	ldr	x1, [x1, _ng_bpf_default_prog@GOTPAGEOFF]
	mov	x0, x19
	bl	_ng_bpf_setprog
	mov	x22, x0
	cbz	w0, LBB0_4
; %bb.2:
	ldr	w1, [x23]
	mov	x0, x21
	bl	_free
	mov	x0, x19
	mov	x1, #0
	bl	_NG_HOOK_SET_PRIVATE
	b	LBB0_5
LBB0_3:
Lloh13:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh15:
	ldr	w22, [x8]
	b	LBB0_5
LBB0_4:
	ldr	x8, [x21]
	ldr	w0, [x8]
	mov	x1, x20
	mov	w2, #4
	bl	_strlcpy
LBB0_5:
	mov	x0, x22
	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
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_M_NETGRAPH_BPF,4,2             ; @M_NETGRAPH_BPF
	.comm	_M_NOWAIT,4,2                   ; @M_NOWAIT
	.comm	_M_ZERO,4,2                     ; @M_ZERO
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ng_bpf_addrefs,4,2             ; @ng_bpf_addrefs
	.comm	_ng_bpf_default_prog,4,2        ; @ng_bpf_default_prog
	.no_dead_strip	_ng_bpf_newhook
.subsections_via_symbols
