	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gfx_ctx_vivante_set_video_mode
_gfx_ctx_vivante_set_video_mode:        ## @gfx_ctx_vivante_set_video_mode
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	testl	%r8d, %r8d
	movl	$1280, %r8d                     ## imm = 0x500
	movl	$1280, %esi                     ## imm = 0x500
	cmovnel	%edx, %esi
	movl	$1024, %edi                     ## imm = 0x400
	movl	$1024, %eax                     ## imm = 0x400
	cmovnel	%ecx, %eax
	testl	%edx, %edx
	cmovel	%r8d, %esi
	testl	%ecx, %ecx
	cmovel	%edi, %eax
	movl	%esi, (%rbx)
	movl	%eax, 4(%rbx)
	xorl	%edi, %edi
	callq	_fbGetDisplayByIndex
	movl	%eax, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_fbCreateWindow
	movl	%eax, 8(%rbx)
	movl	$1, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_gfx_ctx_vivante_set_video_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gfx_ctx_vivante_set_video_mode
_gfx_ctx_vivante_set_video_mode:        ; @gfx_ctx_vivante_set_video_mode
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	cmp	w2, #0
	cset	w8, ne
	cmp	w4, #0
	cset	w9, ne
	tst	w8, w9
	mov	w8, #1280
	csel	w8, w2, w8, ne
	cmp	w3, #0
	cset	w10, ne
	tst	w10, w9
	mov	w9, #1024
	csel	w9, w3, w9, ne
	stp	w8, w9, [x0]
	mov	w0, #0
	bl	_fbGetDisplayByIndex
	mov	w1, #0
	mov	w2, #0
	mov	w3, #0
	mov	w4, #0
	bl	_fbCreateWindow
	str	w0, [x19, #8]
	mov	w0, #1
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_gfx_ctx_vivante_set_video_mode
.subsections_via_symbols
