	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sdl_sync_timer_callback
_sdl_sync_timer_callback:               ## @sdl_sync_timer_callback
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$48, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%edi, %r14d
	movq	_sdl_sync@GOTPCREL(%rip), %rbx
	movl	4(%rbx), %edi
	callq	_SDL_SemPost
	movl	(%rbx), %eax
	incl	%eax
	movl	%eax, (%rbx)
	movq	_vdp_pal@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rsi
	testq	%rsi, %rsi
	movl	$20, %ecx
	movl	$50, %edx
	cmovel	%ecx, %edx
	cmpl	%edx, %eax
	jne	LBB0_4
## %bb.1:
	movq	_SDL_USEREVENT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_sdl_video@GOTPCREL(%rip), %rdx
	movl	(%rdx), %ecx
	testq	%rsi, %rsi
	je	LBB0_3
## %bb.2:
	movslq	%ecx, %rcx
	imulq	$1431655766, %rcx, %rcx         ## imm = 0x55555556
	movq	%rcx, %rsi
	shrq	$63, %rsi
	shrq	$32, %rcx
	addl	%esi, %ecx
LBB0_3:
	movl	$0, (%rdx)
	movl	$0, (%rbx)
	movq	%rax, -24(%rbp)
	movl	%ecx, -56(%rbp)
	xorps	%xmm0, %xmm0
	movups	%xmm0, -48(%rbp)
	movq	%rax, -32(%rbp)
	leaq	-56(%rbp), %rdi
	callq	_SDL_PushEvent
LBB0_4:
	movl	%r14d, %eax
	addq	$48, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_sdl_sync,8,2                   ## @sdl_sync
	.comm	_vdp_pal,8,3                    ## @vdp_pal
	.comm	_SDL_USEREVENT,8,3              ## @SDL_USEREVENT
	.comm	_sdl_video,4,2                  ## @sdl_video
	.no_dead_strip	_sdl_sync_timer_callback
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sdl_sync_timer_callback
_sdl_sync_timer_callback:               ; @sdl_sync_timer_callback
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x20, _sdl_sync@GOTPAGE
Lloh1:
	ldr	x20, [x20, _sdl_sync@GOTPAGEOFF]
	ldr	w0, [x20, #4]
	bl	_SDL_SemPost
	ldr	w8, [x20]
	add	w9, w8, #1
	str	w9, [x20]
Lloh2:
	adrp	x8, _vdp_pal@GOTPAGE
Lloh3:
	ldr	x8, [x8, _vdp_pal@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	cmp	x8, #0
	mov	w10, #50
	mov	w11, #20
	csel	w10, w11, w10, eq
	cmp	w9, w10
	b.ne	LBB0_2
; %bb.1:
Lloh5:
	adrp	x9, _SDL_USEREVENT@GOTPAGE
Lloh6:
	ldr	x9, [x9, _SDL_USEREVENT@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
Lloh8:
	adrp	x10, _sdl_video@GOTPAGE
Lloh9:
	ldr	x10, [x10, _sdl_video@GOTPAGEOFF]
	ldrsw	x11, [x10]
	mov	w12, #21846
	movk	w12, #21845, lsl #16
	mul	x12, x11, x12
	lsr	x13, x12, #63
	lsr	x12, x12, #32
	add	w12, w12, w13
	cmp	x8, #0
	csel	w8, w11, w12, eq
	str	wzr, [x10]
	str	wzr, [x20]
	str	w8, [sp, #8]
	stp	xzr, xzr, [sp, #16]
	stp	x9, x9, [sp, #32]
	add	x0, sp, #8
	bl	_SDL_PushEvent
LBB0_2:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_sdl_sync,8,2                   ; @sdl_sync
	.comm	_vdp_pal,8,3                    ; @vdp_pal
	.comm	_SDL_USEREVENT,8,3              ; @SDL_USEREVENT
	.comm	_sdl_video,4,2                  ; @sdl_video
	.no_dead_strip	_sdl_sync_timer_callback
.subsections_via_symbols
