	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function context_set_pixel_format
_context_set_pixel_format:              ## @context_set_pixel_format
	.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	%rdi, %rbx
	movq	48(%rdi), %r12
	movq	40(%rdi), %r13
	movl	(%rdi), %r15d
	movl	32(%rdi), %r14d
	testq	%r13, %r13
	je	LBB0_6
## %bb.1:
	cmpq	$0, 8(%rbx)
	je	LBB0_2
LBB0_23:
	movq	_TRUE@GOTPCREL(%rip), %rax
	jmp	LBB0_24
LBB0_6:
	movl	%r14d, %edi
	callq	_WindowFromDC
	cmpq	24(%rbx), %rax
	je	LBB0_2
## %bb.7:
	movq	_FALSE@GOTPCREL(%rip), %rax
	jmp	LBB0_24
LBB0_2:
	movl	%r14d, %edi
	callq	*8(%r12)
	cmpl	%r15d, %eax
	jne	LBB0_3
LBB0_19:
	movq	_TRUE@GOTPCREL(%rip), %rax
	testq	%r13, %r13
	je	LBB0_24
## %bb.20:
	movq	(%rax), %rcx
	movq	%rcx, 8(%rbx)
LBB0_24:
	movq	(%rax), %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	testl	%eax, %eax
	je	LBB0_4
## %bb.12:
	movq	(%r12), %rdx
	movq	_WGL_WINE_PIXEL_FORMAT_PASSTHROUGH@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	$0, (%rdx,%rcx,8)
	je	LBB0_22
## %bb.13:
	movl	%eax, %r12d
	movl	%r14d, %edi
	movl	%r15d, %esi
	callq	_wglSetPixelFormatWINE
	movl	%eax, %edi
	callq	_GL_EXTCALL
	testl	%eax, %eax
	je	LBB0_21
## %bb.14:
	testq	%r13, %r13
	je	LBB0_16
## %bb.15:
	xorl	%r14d, %r14d
	jmp	LBB0_17
LBB0_4:
	movl	%r14d, %edi
	movl	%r15d, %esi
	xorl	%edx, %edx
	callq	_SetPixelFormat
	testl	%eax, %eax
	je	LBB0_5
## %bb.8:
	movl	$0, 4(%rbx)
	testq	%r13, %r13
	je	LBB0_10
## %bb.9:
	xorl	%eax, %eax
	movq	%rax, 16(%rbx)
	jmp	LBB0_19
LBB0_22:
	leaq	L_.str.2(%rip), %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_ERR
	jmp	LBB0_23
LBB0_21:
	leaq	L_.str.1(%rip), %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_ERR
	movq	_FALSE@GOTPCREL(%rip), %rax
	jmp	LBB0_24
LBB0_5:
	xorl	%eax, %eax
	callq	_GetLastError
	leaq	L_.str(%rip), %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	movl	%eax, %ecx
	callq	_WARN
	movq	_FALSE@GOTPCREL(%rip), %rax
	jmp	LBB0_24
LBB0_16:
	movl	%r14d, %edi
	callq	_WindowFromDC
	movq	%rax, %r14
LBB0_17:
	cmpq	16(%rbx), %r14
	je	LBB0_19
## %bb.18:
	movq	%rbx, %rdi
	callq	_context_restore_pixel_format
	xorl	%eax, %eax
	testq	%r13, %r13
	cmovel	%r12d, %eax
	movl	%eax, 4(%rbx)
	movq	%r14, 16(%rbx)
	jmp	LBB0_19
LBB0_10:
	movl	%r14d, %edi
	callq	_WindowFromDC
	movq	%rax, 16(%rbx)
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_TRUE,8,3                       ## @TRUE
	.comm	_FALSE,8,3                      ## @FALSE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to set pixel format %d on device context %p, last error %#x.\n"

	.comm	_WGL_WINE_PIXEL_FORMAT_PASSTHROUGH,8,3 ## @WGL_WINE_PIXEL_FORMAT_PASSTHROUGH
L_.str.1:                               ## @.str.1
	.asciz	"wglSetPixelFormatWINE failed to set pixel format %d on device context %p.\n"

L_.str.2:                               ## @.str.2
	.asciz	"Unable to set pixel format %d on device context %p. Already using format %d.\n"

	.no_dead_strip	_context_set_pixel_format
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function context_set_pixel_format
_context_set_pixel_format:              ; @context_set_pixel_format
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	ldp	x23, x24, [x0, #40]
	ldr	w21, [x0]
	ldr	w20, [x0, #32]
	cbz	x23, LBB0_3
; %bb.1:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_5
LBB0_2:
Lloh0:
	adrp	x8, _TRUE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
	b	LBB0_8
LBB0_3:
	mov	x0, x20
	bl	_WindowFromDC
	ldr	x8, [x19, #24]
	cmp	x0, x8
	b.eq	LBB0_5
LBB0_4:
Lloh2:
	adrp	x8, _FALSE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
	b	LBB0_8
LBB0_5:
	ldr	x8, [x24, #8]
	mov	x0, x20
	blr	x8
	cmp	w0, w21
	b.ne	LBB0_9
LBB0_6:
Lloh4:
	adrp	x8, _TRUE@GOTPAGE
Lloh5:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
	cbz	x23, LBB0_8
; %bb.7:
	ldr	x9, [x8]
	str	x9, [x19, #8]
LBB0_8:
	ldr	x0, [x8]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_9:
	mov	x22, x0
	cbz	w0, LBB0_14
; %bb.10:
	ldr	x8, [x24]
Lloh6:
	adrp	x9, _WGL_WINE_PIXEL_FORMAT_PASSTHROUGH@GOTPAGE
Lloh7:
	ldr	x9, [x9, _WGL_WINE_PIXEL_FORMAT_PASSTHROUGH@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	ldr	x8, [x8, x9, lsl #3]
	cbz	x8, LBB0_17
; %bb.11:
	mov	x0, x20
	mov	x1, x21
	bl	_wglSetPixelFormatWINE
	bl	_GL_EXTCALL
	cbz	w0, LBB0_18
; %bb.12:
	cbz	x23, LBB0_20
; %bb.13:
	mov	x20, #0
	b	LBB0_21
LBB0_14:
	mov	x0, x20
	mov	x1, x21
	mov	x2, #0
	bl	_SetPixelFormat
	cbz	w0, LBB0_19
; %bb.15:
	str	wzr, [x19, #4]
	cbz	x23, LBB0_23
; %bb.16:
	mov	x0, #0
	str	xzr, [x19, #16]
	b	LBB0_6
LBB0_17:
	str	x22, [sp]
Lloh9:
	adrp	x0, l_.str.2@PAGE
Lloh10:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x21
	mov	x2, x20
	bl	_ERR
	b	LBB0_2
LBB0_18:
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x21
	mov	x2, x20
	bl	_ERR
	b	LBB0_4
LBB0_19:
	bl	_GetLastError
	mov	x3, x0
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	mov	x2, x20
	bl	_WARN
	b	LBB0_4
LBB0_20:
	mov	x0, x20
	bl	_WindowFromDC
	mov	x20, x0
LBB0_21:
	ldr	x8, [x19, #16]
	cmp	x20, x8
	b.eq	LBB0_6
; %bb.22:
	mov	x0, x19
	bl	_context_restore_pixel_format
	cmp	x23, #0
	csel	w8, w22, wzr, eq
	str	w8, [x19, #4]
	str	x20, [x19, #16]
	b	LBB0_6
LBB0_23:
	mov	x0, x20
	bl	_WindowFromDC
	str	x0, [x19, #16]
	b	LBB0_6
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_TRUE,8,3                       ; @TRUE
	.comm	_FALSE,8,3                      ; @FALSE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to set pixel format %d on device context %p, last error %#x.\n"

	.comm	_WGL_WINE_PIXEL_FORMAT_PASSTHROUGH,8,3 ; @WGL_WINE_PIXEL_FORMAT_PASSTHROUGH
l_.str.1:                               ; @.str.1
	.asciz	"wglSetPixelFormatWINE failed to set pixel format %d on device context %p.\n"

l_.str.2:                               ; @.str.2
	.asciz	"Unable to set pixel format %d on device context %p. Already using format %d.\n"

	.no_dead_strip	_context_set_pixel_format
.subsections_via_symbols
