	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_SDL_VoutAMediaCodec_CreateOverlay ## -- Begin function SDL_VoutAMediaCodec_CreateOverlay
	.p2align	4, 0x90
_SDL_VoutAMediaCodec_CreateOverlay:     ## @SDL_VoutAMediaCodec_CreateOverlay
	.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, %r12
	movl	%esi, %r14d
	movl	%edi, %r15d
	leaq	L_.str(%rip), %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	movq	%r12, %rcx
	callq	_SDLTRACE
	movl	$40, %edi
	callq	_SDL_VoutOverlay_CreateInternal
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	64(%rax), %r13
	xorl	%eax, %eax
	callq	_SDL_CreateMutex
	movl	%eax, (%r13)
	movq	%r12, 32(%r13)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%r13)
	movq	_g_vout_overlay_amediacodec_class@GOTPCREL(%rip), %rcx
	movq	%rcx, 56(%rbx)
	movq	_SDL_FCC__AMC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 48(%rbx)
	movl	8(%r13), %ecx
	movl	%ecx, 44(%rbx)
	movl	4(%r13), %ecx
	movl	%ecx, 40(%rbx)
	movl	%r15d, (%rbx)
	movl	%r14d, 4(%rbx)
	movl	$1, 8(%rbx)
	movq	_overlay_free_l@GOTPCREL(%rip), %rcx
	movq	%rcx, 32(%rbx)
	movq	_overlay_lock@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 24(%rbx)
	movq	_overlay_unlock@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 20(%rbx)
	movq	_overlay_unref@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 16(%rbx)
	movq	_func_fill_frame@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 12(%rbx)
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:
	leaq	L_.str.2(%rip), %rdi
	callq	_ALOGE
	movq	%rbx, %rdi
	callq	_overlay_free_l
	jmp	LBB0_4
LBB0_1:
	leaq	L_.str.1(%rip), %rdi
	callq	_ALOGE
LBB0_4:
	xorl	%ebx, %ebx
LBB0_5:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SDL_VoutAMediaCodec_CreateOverlay(w=%d, h=%d, fmt=_AMC vout=%p)\n"

L_.str.1:                               ## @.str.1
	.asciz	"overlay allocation failed"

	.comm	_g_vout_overlay_amediacodec_class,4,2 ## @g_vout_overlay_amediacodec_class
	.comm	_SDL_FCC__AMC,4,2               ## @SDL_FCC__AMC
	.comm	_overlay_lock,4,2               ## @overlay_lock
	.comm	_overlay_unlock,4,2             ## @overlay_unlock
	.comm	_overlay_unref,4,2              ## @overlay_unref
	.comm	_func_fill_frame,4,2            ## @func_fill_frame
L_.str.2:                               ## @.str.2
	.asciz	"SDL_CreateMutex failed"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_SDL_VoutAMediaCodec_CreateOverlay ; -- Begin function SDL_VoutAMediaCodec_CreateOverlay
	.p2align	2
_SDL_VoutAMediaCodec_CreateOverlay:     ; @SDL_VoutAMediaCodec_CreateOverlay
	.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	x22, x2
	mov	x20, x1
	mov	x21, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	mov	x2, x20
	mov	x3, x22
	bl	_SDLTRACE
	mov	w0, #40
	bl	_SDL_VoutOverlay_CreateInternal
	mov	x19, x0
	cbz	x0, LBB0_3
; %bb.1:
	ldr	x23, [x19, #64]
	bl	_SDL_CreateMutex
	str	w0, [x23]
	stp	xzr, x22, [x23, #24]
	str	xzr, [x23, #16]
Lloh2:
	adrp	x8, _g_vout_overlay_amediacodec_class@GOTPAGE
Lloh3:
	ldr	x8, [x8, _g_vout_overlay_amediacodec_class@GOTPAGEOFF]
	str	x8, [x19, #56]
Lloh4:
	adrp	x8, _SDL_FCC__AMC@GOTPAGE
Lloh5:
	ldr	x8, [x8, _SDL_FCC__AMC@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	str	w8, [x19, #48]
	ldur	d0, [x23, #4]
	str	d0, [x19, #40]
	stp	w21, w20, [x19]
	mov	w8, #1
Lloh7:
	adrp	x9, _overlay_free_l@GOTPAGE
Lloh8:
	ldr	x9, [x9, _overlay_free_l@GOTPAGEOFF]
	str	x9, [x19, #32]
Lloh9:
	adrp	x9, _overlay_lock@GOTPAGE
Lloh10:
	ldr	x9, [x9, _overlay_lock@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
Lloh12:
	adrp	x10, _overlay_unlock@GOTPAGE
Lloh13:
	ldr	x10, [x10, _overlay_unlock@GOTPAGEOFF]
	str	w9, [x19, #24]
Lloh14:
	ldr	w9, [x10]
Lloh15:
	adrp	x10, _overlay_unref@GOTPAGE
Lloh16:
	ldr	x10, [x10, _overlay_unref@GOTPAGEOFF]
Lloh17:
	ldr	w10, [x10]
	stp	w10, w9, [x19, #16]
Lloh18:
	adrp	x9, _func_fill_frame@GOTPAGE
Lloh19:
	ldr	x9, [x9, _func_fill_frame@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	stp	w8, w9, [x19, #8]
	cbnz	w0, LBB0_4
; %bb.2:
Lloh21:
	adrp	x0, l_.str.2@PAGE
Lloh22:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_ALOGE
	mov	x0, x19
	bl	_overlay_free_l
	mov	x19, #0
	b	LBB0_4
LBB0_3:
Lloh23:
	adrp	x0, l_.str.1@PAGE
Lloh24:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_ALOGE
LBB0_4:
	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
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SDL_VoutAMediaCodec_CreateOverlay(w=%d, h=%d, fmt=_AMC vout=%p)\n"

l_.str.1:                               ; @.str.1
	.asciz	"overlay allocation failed"

	.comm	_g_vout_overlay_amediacodec_class,4,2 ; @g_vout_overlay_amediacodec_class
	.comm	_SDL_FCC__AMC,4,2               ; @SDL_FCC__AMC
	.comm	_overlay_lock,4,2               ; @overlay_lock
	.comm	_overlay_unlock,4,2             ; @overlay_unlock
	.comm	_overlay_unref,4,2              ; @overlay_unref
	.comm	_func_fill_frame,4,2            ; @func_fill_frame
l_.str.2:                               ; @.str.2
	.asciz	"SDL_CreateMutex failed"

.subsections_via_symbols
