	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function swapchain_gdi_frontbuffer_updated
_swapchain_gdi_frontbuffer_updated:     ## @swapchain_gdi_frontbuffer_updated
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -64(%rbp)
	movq	$0, -48(%rbp)
	leaq	L_.str(%rip), %rdi
	movq	%r13, %rsi
	callq	_TRACE
	movq	8(%r13), %rax
	movq	40(%r13), %rdi
	movq	8(%rax), %rax
	movq	(%rax), %rbx
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.1:
	movl	28(%rbx), %esi
	callq	_wined3d_palette_apply_to_dc
LBB0_2:
	movq	32(%rbx), %rax
	cmpq	$0, (%rax)
	je	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	callq	_ERR
LBB0_4:
	leaq	L_.str.2(%rip), %rdi
	movq	%rbx, %rsi
	callq	_TRACE
	movl	28(%rbx), %r15d
	movl	24(%r13), %r14d
	movq	_DCX_CLIPSIBLINGS@GOTPCREL(%rip), %rax
	movq	_DCX_CACHE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movl	%r14d, %edi
	xorl	%esi, %esi
	callq	_GetDCEx
	movl	%eax, %r12d
	cmpq	$0, 16(%r13)
	je	LBB0_6
## %bb.5:
	leaq	-64(%rbp), %rsi
	movl	%r14d, %edi
	callq	_ClientToScreen
LBB0_6:
	leaq	-64(%rbp), %rdi
	callq	_wine_dbgstr_point
	leaq	L_.str.3(%rip), %rdi
	movq	%rax, %rsi
	callq	_TRACE
	movq	8(%r13), %rax
	movl	(%rax), %r8d
	movl	4(%rax), %ecx
	leaq	-96(%rbp), %rbx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_SetRect
	movq	%rbx, %rdi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	callq	_IntersectRect
	movq	-96(%rbp), %rax
	movq	-88(%rbp), %rbx
	movq	%rbx, %rsi
	subq	-56(%rbp), %rsi
	movq	%rax, %rdx
	subq	-64(%rbp), %rdx
	movq	-72(%rbp), %rcx
	subq	%rbx, %rcx
	movq	-80(%rbp), %r8
	subq	%rax, %r8
	movq	_SRCCOPY@GOTPCREL(%rip), %rdi
	movl	(%rdi), %r10d
	subq	$8, %rsp
	movl	%r12d, %edi
	movl	%r15d, %r9d
	pushq	%r10
	pushq	%rax
	pushq	%rbx
	callq	_BitBlt
	addq	$32, %rsp
	movl	%r14d, %edi
	movl	%r12d, %esi
	callq	_ReleaseDC
	movq	%r13, %rdi
	callq	_SetRectEmpty
	addq	$56, %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	"swapchain %p.\n"

L_.str.1:                               ## @.str.1
	.asciz	"Trying to blit a mapped surface.\n"

L_.str.2:                               ## @.str.2
	.asciz	"Copying surface %p to screen.\n"

	.comm	_DCX_CLIPSIBLINGS,4,2           ## @DCX_CLIPSIBLINGS
	.comm	_DCX_CACHE,4,2                  ## @DCX_CACHE
L_.str.3:                               ## @.str.3
	.asciz	"offset %s.\n"

	.comm	_SRCCOPY,4,2                    ## @SRCCOPY
	.no_dead_strip	_swapchain_gdi_frontbuffer_updated
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function swapchain_gdi_frontbuffer_updated
_swapchain_gdi_frontbuffer_updated:     ; @swapchain_gdi_frontbuffer_updated
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x19, x0
	stp	xzr, xzr, [sp, #40]
	str	xzr, [sp, #56]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_TRACE
	ldr	x8, [x19, #8]
	ldr	x8, [x8, #8]
	ldr	x20, [x8]
	ldr	x0, [x19, #40]
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w1, [x20, #28]
	bl	_wined3d_palette_apply_to_dc
LBB0_2:
	ldr	x8, [x20, #32]
	ldr	x8, [x8]
	cbz	x8, LBB0_4
; %bb.3:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_ERR
LBB0_4:
Lloh4:
	adrp	x0, l_.str.2@PAGE
Lloh5:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x20
	bl	_TRACE
	ldr	w21, [x20, #28]
Lloh6:
	adrp	x8, _DCX_CLIPSIBLINGS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DCX_CLIPSIBLINGS@GOTPAGEOFF]
	ldr	w20, [x19, #24]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _DCX_CACHE@GOTPAGE
Lloh10:
	ldr	x9, [x9, _DCX_CACHE@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	x0, x20
	mov	w1, #0
	bl	_GetDCEx
	mov	x22, x0
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_6
; %bb.5:
	add	x1, sp, #40
	mov	x0, x20
	bl	_ClientToScreen
LBB0_6:
	add	x0, sp, #40
	bl	_wine_dbgstr_point
	mov	x1, x0
Lloh12:
	adrp	x0, l_.str.3@PAGE
Lloh13:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_TRACE
	ldr	x8, [x19, #8]
	ldp	w4, w3, [x8]
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #0
	bl	_SetRect
	add	x0, sp, #8
	add	x1, sp, #8
	mov	x2, x19
	bl	_IntersectRect
	ldp	x7, x6, [sp, #8]
	ldp	x9, x8, [sp, #40]
	sub	x1, x6, x8
	sub	x2, x7, x9
	ldp	x9, x8, [sp, #24]
	sub	x3, x8, x6
	sub	x4, x9, x7
Lloh14:
	adrp	x8, _SRCCOPY@GOTPAGE
Lloh15:
	ldr	x8, [x8, _SRCCOPY@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	str	w8, [sp]
	mov	x0, x22
	mov	x5, x21
	bl	_BitBlt
	mov	x0, x20
	mov	x1, x22
	bl	_ReleaseDC
	mov	x0, x19
	bl	_SetRectEmpty
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"swapchain %p.\n"

l_.str.1:                               ; @.str.1
	.asciz	"Trying to blit a mapped surface.\n"

l_.str.2:                               ; @.str.2
	.asciz	"Copying surface %p to screen.\n"

	.comm	_DCX_CLIPSIBLINGS,4,2           ; @DCX_CLIPSIBLINGS
	.comm	_DCX_CACHE,4,2                  ; @DCX_CACHE
l_.str.3:                               ; @.str.3
	.asciz	"offset %s.\n"

	.comm	_SRCCOPY,4,2                    ; @SRCCOPY
	.no_dead_strip	_swapchain_gdi_frontbuffer_updated
.subsections_via_symbols
