	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function write_begin
_write_begin:                           ## @write_begin
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %r15
	movl	$0, -32(%rbp)
	movq	$0, -40(%rbp)
	movq	_RTMP_NETWORK_CHANNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_RTMP_PT_USER_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-40(%rbp), %rdi
	xorl	%ecx, %ecx
	movl	$6, %r8d
	callq	_ff_rtmp_packet_create
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movl	-40(%rbp), %edx
	movl	-36(%rbp), %esi
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_bytestream2_init_writer
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bytestream2_put_be16
	movl	24(%r15), %esi
	movq	%rbx, %rdi
	callq	_bytestream2_put_be32
	movl	20(%r15), %edi
	movl	16(%r15), %edx
	movq	(%r15), %r8
	movq	8(%r15), %rcx
	addq	$4, %rcx
	addq	$4, %r8
	leaq	-40(%rbp), %r14
	movq	%r14, %rsi
	callq	_ff_rtmp_packet_write
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_ff_rtmp_packet_destroy
	jmp	LBB0_3
LBB0_1:
	movl	%eax, %ebx
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	callq	_av_log
LBB0_3:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RTMP_NETWORK_CHANNEL,4,2       ## @RTMP_NETWORK_CHANNEL
	.comm	_RTMP_PT_USER_CONTROL,4,2       ## @RTMP_PT_USER_CONTROL
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unable to create response packet\n"

	.no_dead_strip	_write_begin
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function write_begin
_write_begin:                           ; @write_begin
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	ldr	x21, [x0]
	str	wzr, [sp, #8]
	str	xzr, [sp]
Lloh0:
	adrp	x8, _RTMP_NETWORK_CHANNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RTMP_NETWORK_CHANNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _RTMP_PT_USER_CONTROL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _RTMP_PT_USER_CONTROL@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, sp
	mov	w3, #0
	mov	w4, #6
	bl	_ff_rtmp_packet_create
	tbnz	w0, #31, LBB0_2
; %bb.1:
	ldp	w2, w1, [sp]
	add	x0, sp, #12
	bl	_bytestream2_init_writer
	add	x0, sp, #12
	mov	w1, #0
	bl	_bytestream2_put_be16
	ldr	w1, [x21, #24]
	add	x0, sp, #12
	bl	_bytestream2_put_be32
	ldp	w2, w0, [x21, #16]
	ldp	x9, x8, [x21]
	add	x3, x8, #4
	add	x4, x9, #4
	mov	x1, sp
	bl	_ff_rtmp_packet_write
	mov	x20, x0
	mov	x0, sp
	bl	_ff_rtmp_packet_destroy
	b	LBB0_3
LBB0_2:
	mov	x20, x0
Lloh6:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
Lloh9:
	adrp	x2, l_.str@PAGE
Lloh10:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_3:
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_RTMP_NETWORK_CHANNEL,4,2       ; @RTMP_NETWORK_CHANNEL
	.comm	_RTMP_PT_USER_CONTROL,4,2       ; @RTMP_PT_USER_CONTROL
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unable to create response packet\n"

	.no_dead_strip	_write_begin
.subsections_via_symbols
