	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rtsp_write_packet
_rtsp_write_packet:                     ## @rtsp_write_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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	movq	%rdi, %rbx
	movq	(%rdi), %r13
	movl	32(%r13), %edi
	callq	_ffurl_get_file_handle
	movl	%eax, -56(%rbp)
	movq	_POLLIN@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	movl	%eax, -52(%rbp)
	movq	$0, -48(%rbp)
	leaq	-56(%rbp), %rdi
	movl	$1, %esi
	xorl	%edx, %edx
	callq	_poll
	testl	%eax, %eax
	jle	LBB0_9
## %bb.1:
	leaq	-56(%rbp), %r15
	leaq	-68(%rbp), %r12
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	(%r13), %rax
	movq	_RTSP_STATE_STREAMING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_7
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movl	$1, %esi
	xorl	%edx, %edx
	callq	_poll
	testl	%eax, %eax
	jle	LBB0_9
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %eax
	testl	%eax, -52(%rbp)
	je	LBB0_8
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rbx, %rdi
	movq	%r12, %rsi
	xorl	%edx, %edx
	movl	$1, %ecx
	xorl	%r8d, %r8d
	callq	_ff_rtsp_read_reply
	testl	%eax, %eax
	js	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$1, %eax
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rbx, %rdi
	callq	_ff_rtsp_skip_packet
	jmp	LBB0_6
LBB0_9:
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	movq	(%rdx), %rax
	cmpq	8(%r13), %rax
	jae	LBB0_10
## %bb.11:
	movq	24(%r13), %rcx
	movq	(%rcx,%rax,8), %r15
	movq	(%r15), %rdi
	xorl	%esi, %esi
	movq	%rbx, %rcx
	xorl	%r8d, %r8d
	callq	_ff_write_chained
	testl	%eax, %eax
	jne	LBB0_14
## %bb.12:
	movq	16(%r13), %rcx
	movq	_RTSP_LOWER_TRANSPORT_TCP@GOTPCREL(%rip), %rdx
	movl	$0, %eax
	cmpq	(%rdx), %rcx
	jne	LBB0_14
## %bb.13:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_ff_rtsp_tcp_write_packet
	jmp	LBB0_14
LBB0_7:
	movq	_EPIPE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	jmp	LBB0_14
LBB0_10:
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_14:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_POLLIN,4,2                     ## @POLLIN
	.comm	_EPIPE,4,2                      ## @EPIPE
	.comm	_RTSP_STATE_STREAMING,8,3       ## @RTSP_STATE_STREAMING
	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.comm	_RTSP_LOWER_TRANSPORT_TCP,8,3   ## @RTSP_LOWER_TRANSPORT_TCP
	.no_dead_strip	_rtsp_write_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rtsp_write_packet
_rtsp_write_packet:                     ; @rtsp_write_packet
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	ldr	x22, [x0]
	ldr	w0, [x22, #32]
	bl	_ffurl_get_file_handle
Lloh0:
	adrp	x21, _POLLIN@GOTPAGE
Lloh1:
	ldr	x21, [x21, _POLLIN@GOTPAGEOFF]
	ldr	w8, [x21]
	stp	w0, w8, [sp, #16]
	str	xzr, [sp, #24]
	add	x0, sp, #16
	mov	w1, #1
	mov	w2, #0
	bl	_poll
	cmp	w0, #1
	b.lt	LBB0_8
; %bb.1:
Lloh2:
	adrp	x23, _RTSP_STATE_STREAMING@GOTPAGE
Lloh3:
	ldr	x23, [x23, _RTSP_STATE_STREAMING@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x22]
	ldr	x9, [x23]
	cmp	x8, x9
	b.ne	LBB0_12
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x0, sp, #16
	mov	w1, #1
	mov	w2, #0
	bl	_poll
	cmp	w0, #0
	b.le	LBB0_8
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [sp, #20]
	ldr	w9, [x21]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	x1, sp, #12
	mov	x0, x19
	mov	x2, #0
	mov	w3, #1
	mov	x4, #0
	bl	_ff_rtsp_read_reply
	tbnz	w0, #31, LBB0_12
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	cmp	w0, #1
	b.ne	LBB0_2
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	bl	_ff_rtsp_skip_packet
	b	LBB0_2
LBB0_8:
	ldr	x8, [x20]
	ldr	x9, [x22, #8]
	cmp	x8, x9
	b.hs	LBB0_13
; %bb.9:
	ldr	x9, [x22, #24]
	ldr	x21, [x9, x8, lsl #3]
	ldr	x0, [x21]
	mov	w1, #0
	mov	x2, x20
	mov	x3, x19
	mov	w4, #0
	bl	_ff_write_chained
	cbnz	w0, LBB0_14
; %bb.10:
	ldr	x8, [x22, #16]
Lloh4:
	adrp	x9, _RTSP_LOWER_TRANSPORT_TCP@GOTPAGE
Lloh5:
	ldr	x9, [x9, _RTSP_LOWER_TRANSPORT_TCP@GOTPAGEOFF]
Lloh6:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_15
; %bb.11:
	mov	x0, x19
	mov	x1, x21
	bl	_ff_rtsp_tcp_write_packet
	b	LBB0_14
LBB0_12:
Lloh7:
	adrp	x8, _EPIPE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EPIPE@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	bl	_AVERROR
	b	LBB0_14
LBB0_13:
Lloh10:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh11:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
LBB0_14:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_15:
	mov	w0, #0
	b	LBB0_14
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_POLLIN,4,2                     ; @POLLIN
	.comm	_EPIPE,4,2                      ; @EPIPE
	.comm	_RTSP_STATE_STREAMING,8,3       ; @RTSP_STATE_STREAMING
	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.comm	_RTSP_LOWER_TRANSPORT_TCP,8,3   ; @RTSP_LOWER_TRANSPORT_TCP
	.no_dead_strip	_rtsp_write_packet
.subsections_via_symbols
