	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function VMR9_ImagePresenter_PresentTexture
_VMR9_ImagePresenter_PresentTexture:    ## @VMR9_ImagePresenter_PresentTexture
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	$0, -32(%rbp)
	movl	(%rdi), %edi
	movq	_USED_FVF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_IDirect3DDevice9_SetFVF
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_FAILED
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_2
LBB0_3:
	movl	(%r14), %edi
	movl	4(%r14), %edx
	xorl	%esi, %esi
	xorl	%ecx, %ecx
	movl	$4, %r8d
	callq	_IDirect3DDevice9_SetStreamSource
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_FAILED
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rdi
LBB0_2:
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_FIXME
LBB0_12:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	_IID_IDirect3DTexture9@GOTPCREL(%rip), %rsi
	leaq	-32(%rbp), %rdx
	movq	%r15, %rdi
	callq	_IDirect3DSurface9_GetContainer
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_FAILED
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_FIXME
	jmp	LBB0_12
LBB0_7:
	movl	(%r14), %edi
	movq	-32(%rbp), %rdx
	xorl	%esi, %esi
	callq	_IDirect3DDevice9_SetTexture
	movl	%eax, %ebx
	movq	-32(%rbp), %rdi
	callq	_IDirect3DTexture9_Release
	movl	%ebx, %edi
	callq	_FAILED
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_2
LBB0_9:
	movl	(%r14), %edi
	movq	_D3DPT_TRIANGLESTRIP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	movl	$2, %ecx
	callq	_IDirect3DDevice9_DrawPrimitive
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_FAILED
	testq	%rax, %rax
	je	LBB0_11
## %bb.10:
	leaq	L_.str.4(%rip), %rdi
	jmp	LBB0_2
LBB0_11:
	movq	_S_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_USED_FVF,4,2                   ## @USED_FVF
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SetFVF: %08x\n"

L_.str.1:                               ## @.str.1
	.asciz	"SetStreamSource: %08x\n"

	.comm	_IID_IDirect3DTexture9,4,2      ## @IID_IDirect3DTexture9
L_.str.2:                               ## @.str.2
	.asciz	"IDirect3DSurface9_GetContainer failed\n"

L_.str.3:                               ## @.str.3
	.asciz	"SetTexture: %08x\n"

	.comm	_D3DPT_TRIANGLESTRIP,4,2        ## @D3DPT_TRIANGLESTRIP
L_.str.4:                               ## @.str.4
	.asciz	"DrawPrimitive: %08x\n"

	.comm	_S_OK,4,2                       ## @S_OK
	.no_dead_strip	_VMR9_ImagePresenter_PresentTexture
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function VMR9_ImagePresenter_PresentTexture
_VMR9_ImagePresenter_PresentTexture:    ; @VMR9_ImagePresenter_PresentTexture
	.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	x21, x1
	mov	x19, x0
	str	xzr, [sp, #8]
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _USED_FVF@GOTPAGE
Lloh1:
	ldr	x8, [x8, _USED_FVF@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_IDirect3DDevice9_SetFVF
	mov	x20, x0
	bl	_FAILED
	cbz	x0, LBB0_2
; %bb.1:
	str	x20, [sp]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_FIXME
	b	LBB0_7
LBB0_2:
	ldp	w0, w2, [x19]
	mov	w1, #0
	mov	w3, #0
	mov	w4, #4
	bl	_IDirect3DDevice9_SetStreamSource
	mov	x20, x0
	bl	_FAILED
	cbz	x0, LBB0_5
; %bb.3:
	str	x20, [sp]
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_4:
	bl	_FIXME
                                        ; kill: def $w20 killed $w20 killed $x20 def $x20
	b	LBB0_7
LBB0_5:
Lloh7:
	adrp	x1, _IID_IDirect3DTexture9@GOTPAGE
Lloh8:
	ldr	x1, [x1, _IID_IDirect3DTexture9@GOTPAGEOFF]
	add	x2, sp, #8
	mov	x0, x21
	bl	_IDirect3DSurface9_GetContainer
	mov	x20, x0
	bl	_FAILED
	cbz	x0, LBB0_8
; %bb.6:
Lloh9:
	adrp	x0, l_.str.2@PAGE
Lloh10:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_FIXME
LBB0_7:
	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
LBB0_8:
	ldr	w0, [x19]
	ldr	x2, [sp, #8]
	mov	w1, #0
	bl	_IDirect3DDevice9_SetTexture
	mov	x20, x0
	ldr	x0, [sp, #8]
	bl	_IDirect3DTexture9_Release
	mov	x0, x20
	bl	_FAILED
	cbz	x0, LBB0_10
; %bb.9:
	str	x20, [sp]
Lloh11:
	adrp	x0, l_.str.3@PAGE
Lloh12:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_4
LBB0_10:
	ldr	w0, [x19]
Lloh13:
	adrp	x8, _D3DPT_TRIANGLESTRIP@GOTPAGE
Lloh14:
	ldr	x8, [x8, _D3DPT_TRIANGLESTRIP@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	mov	w2, #0
	mov	w3, #2
	bl	_IDirect3DDevice9_DrawPrimitive
	mov	x20, x0
	bl	_FAILED
	cbz	x0, LBB0_12
; %bb.11:
	str	x20, [sp]
Lloh16:
	adrp	x0, l_.str.4@PAGE
Lloh17:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_4
LBB0_12:
Lloh18:
	adrp	x8, _S_OK@GOTPAGE
Lloh19:
	ldr	x8, [x8, _S_OK@GOTPAGEOFF]
Lloh20:
	ldr	w20, [x8]
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_USED_FVF,4,2                   ; @USED_FVF
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SetFVF: %08x\n"

l_.str.1:                               ; @.str.1
	.asciz	"SetStreamSource: %08x\n"

	.comm	_IID_IDirect3DTexture9,4,2      ; @IID_IDirect3DTexture9
l_.str.2:                               ; @.str.2
	.asciz	"IDirect3DSurface9_GetContainer failed\n"

l_.str.3:                               ; @.str.3
	.asciz	"SetTexture: %08x\n"

	.comm	_D3DPT_TRIANGLESTRIP,4,2        ; @D3DPT_TRIANGLESTRIP
l_.str.4:                               ; @.str.4
	.asciz	"DrawPrimitive: %08x\n"

	.comm	_S_OK,4,2                       ; @S_OK
	.no_dead_strip	_VMR9_ImagePresenter_PresentTexture
.subsections_via_symbols
