	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_context_surface_update         ## -- Begin function context_surface_update
	.p2align	4, 0x90
_context_surface_update:                ## @context_surface_update
	.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	8(%rdi), %rdx
	testq	%rdx, %rdx
	je	LBB0_8
## %bb.1:
	movq	%rdi, %rbx
	cmpq	$0, (%rdi)
	jne	LBB0_8
## %bb.2:
	movq	16(%rbx), %rax
	movl	(%rax), %r8d
	incl	%r8d
	je	LBB0_8
## %bb.3:
	movq	(%rsi), %rax
	movq	8(%rax), %r9
	movq	(%rdx), %rdi
	movl	%r8d, %r8d
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rdi,%rdx,8), %rcx
	cmpq	%rcx, %r9
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpq	%rcx, (%rax)
	je	LBB0_6
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	incq	%rdx
	cmpq	%rdx, %r8
	jne	LBB0_4
	jmp	LBB0_8
LBB0_6:
	leaq	L_.str(%rip), %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_TRACE
	movq	_TRUE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%rbx)
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Updated surface %p is bound as attachment %u to the current FBO.\n"

	.comm	_TRUE,8,3                       ## @TRUE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_context_surface_update         ; -- Begin function context_surface_update
	.p2align	2
_context_surface_update:                ; @context_surface_update
	.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
	ldr	x11, [x0, #8]
	cbz	x11, LBB0_8
; %bb.1:
	mov	x19, x0
	ldr	x8, [x0]
	cbnz	x8, LBB0_8
; %bb.2:
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	adds	w8, w8, #1
	b.hs	LBB0_8
; %bb.3:
	mov	x2, #0
	ldr	x9, [x1]
	ldr	x10, [x9, #8]
	ldr	x11, [x11]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x12, [x11, x2, lsl #3]
	cmp	x10, x12
	b.eq	LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x13, [x9]
	cmp	x13, x12
	b.eq	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	add	x2, x2, #1
	cmp	x8, x2
	b.ne	LBB0_4
	b	LBB0_8
LBB0_7:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_TRACE
Lloh2:
	adrp	x8, _TRUE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	str	x8, [x19]
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Updated surface %p is bound as attachment %u to the current FBO.\n"

	.comm	_TRUE,8,3                       ; @TRUE
.subsections_via_symbols
