	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_render_target
_set_render_target:                     ## @set_render_target
	.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
	movl	%r8d, %r13d
	movl	%ecx, %ebx
	movl	%edx, %r12d
	movl	%esi, %r14d
	movq	%rdi, %r15
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG
	movl	%ebx, %edi
	movl	$8, %esi
	callq	_ALIGN
	movq	_RADEON_FAMILY_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	(%r15), %ecx
	movl	%eax, %r15d
	movq	_CHIP_R600@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ecx
	jle	LBB0_3
## %bb.1:
	movq	_CHIP_RV770@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ecx
	jge	LBB0_3
## %bb.2:
	movl	$23, %edi
	callq	_BEGIN_RING
	movq	_R600_IT_SET_CONTEXT_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_R600_SET_CONTEXT_REG_OFFSET@GOTPCREL(%rip), %rax
	subl	(%rax), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	sarl	$8, %r13d
	movl	%r13d, %edi
	callq	_OUT_RING
	movq	_R600_IT_SURFACE_BASE_UPDATE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movl	$2, %r13d
	jmp	LBB0_4
LBB0_3:
	movl	$21, %edi
	callq	_BEGIN_RING
	movq	_R600_IT_SET_CONTEXT_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_R600_SET_CONTEXT_REG_OFFSET@GOTPCREL(%rip), %rax
	subl	(%rax), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	sarl	$8, %r13d
LBB0_4:
	movl	%r13d, %edi
	callq	_OUT_RING
	cmpl	$9, %r15d
	movl	$8, %eax
	cmovgel	%r15d, %eax
	imull	%r12d, %eax
	leal	63(%rax), %ebx
	testl	%eax, %eax
	cmovnsl	%eax, %ebx
	andl	$-64, %ebx
	shll	$4, %ebx
	leal	7(%r12), %r13d
	testl	%r12d, %r12d
	cmovnsl	%r12d, %r13d
	sarl	$3, %r13d
	decl	%r13d
	shll	$2, %r14d
	orl	$134217728, %r14d               ## imm = 0x8000000
	movq	_R600_IT_SET_CONTEXT_REG@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_R600_SET_CONTEXT_REG_OFFSET@GOTPCREL(%rip), %r12
	subl	(%r12), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	addl	$-1024, %ebx                    ## imm = 0xFC00
	orl	%r13d, %ebx
	movl	%ebx, %edi
	callq	_OUT_RING
	movl	(%r15), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_VIEW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	(%r12), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	xorl	%edi, %edi
	callq	_OUT_RING
	movl	(%r15), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	(%r12), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	movl	%r14d, %edi
	callq	_OUT_RING
	movl	(%r15), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_TILE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	(%r12), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	xorl	%edi, %edi
	callq	_OUT_RING
	movl	(%r15), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_FRAG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	(%r12), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	xorl	%edi, %edi
	callq	_OUT_RING
	movl	(%r15), %edi
	movl	$1, %esi
	callq	_CP_PACKET3
	movl	%eax, %edi
	callq	_OUT_RING
	movq	_R600_CB_COLOR0_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	subl	(%r12), %edi
	sarl	$2, %edi
	callq	_OUT_RING
	xorl	%edi, %edi
	callq	_OUT_RING
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ADVANCE_RING                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_RING_LOCALS,4,2                ## @RING_LOCALS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"\n"

	.comm	_RADEON_FAMILY_MASK,4,2         ## @RADEON_FAMILY_MASK
	.comm	_CHIP_R600,4,2                  ## @CHIP_R600
	.comm	_CHIP_RV770,4,2                 ## @CHIP_RV770
	.comm	_R600_IT_SET_CONTEXT_REG,4,2    ## @R600_IT_SET_CONTEXT_REG
	.comm	_R600_CB_COLOR0_BASE,4,2        ## @R600_CB_COLOR0_BASE
	.comm	_R600_SET_CONTEXT_REG_OFFSET,4,2 ## @R600_SET_CONTEXT_REG_OFFSET
	.comm	_R600_IT_SURFACE_BASE_UPDATE,4,2 ## @R600_IT_SURFACE_BASE_UPDATE
	.comm	_R600_CB_COLOR0_SIZE,4,2        ## @R600_CB_COLOR0_SIZE
	.comm	_R600_CB_COLOR0_VIEW,4,2        ## @R600_CB_COLOR0_VIEW
	.comm	_R600_CB_COLOR0_INFO,4,2        ## @R600_CB_COLOR0_INFO
	.comm	_R600_CB_COLOR0_TILE,4,2        ## @R600_CB_COLOR0_TILE
	.comm	_R600_CB_COLOR0_FRAG,4,2        ## @R600_CB_COLOR0_FRAG
	.comm	_R600_CB_COLOR0_MASK,4,2        ## @R600_CB_COLOR0_MASK
	.no_dead_strip	_set_render_target
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_render_target
_set_render_target:                     ; @set_render_target
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x22, x4
	mov	x21, x3
	mov	x20, x2
	mov	x19, x1
	mov	x23, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG
	mov	x0, x21
	mov	w1, #8
	bl	_ALIGN
	mov	x21, x0
	ldr	w8, [x23]
Lloh2:
	adrp	x9, _RADEON_FAMILY_MASK@GOTPAGE
Lloh3:
	ldr	x9, [x9, _RADEON_FAMILY_MASK@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	and	w8, w9, w8
Lloh5:
	adrp	x9, _CHIP_R600@GOTPAGE
Lloh6:
	ldr	x9, [x9, _CHIP_R600@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
Lloh8:
	adrp	x10, _CHIP_RV770@GOTPAGE
Lloh9:
	ldr	x10, [x10, _CHIP_RV770@GOTPAGEOFF]
Lloh10:
	ldr	w10, [x10]
	cmp	w8, w9
	ccmp	w8, w10, #0, gt
Lloh11:
	adrp	x24, _R600_IT_SET_CONTEXT_REG@GOTPAGE
Lloh12:
	ldr	x24, [x24, _R600_IT_SET_CONTEXT_REG@GOTPAGEOFF]
Lloh13:
	adrp	x23, _R600_SET_CONTEXT_REG_OFFSET@GOTPAGE
Lloh14:
	ldr	x23, [x23, _R600_SET_CONTEXT_REG_OFFSET@GOTPAGEOFF]
	b.lt	LBB0_2
; %bb.1:
	mov	w0, #21
	bl	_BEGIN_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh15:
	adrp	x8, _R600_CB_COLOR0_BASE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _R600_CB_COLOR0_BASE@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	asr	w0, w22, #8
	b	LBB0_3
LBB0_2:
	mov	w0, #23
	bl	_BEGIN_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh18:
	adrp	x8, _R600_CB_COLOR0_BASE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _R600_CB_COLOR0_BASE@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	asr	w0, w22, #8
	bl	_OUT_RING
Lloh21:
	adrp	x8, _R600_IT_SURFACE_BASE_UPDATE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _R600_IT_SURFACE_BASE_UPDATE@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	mov	w1, #0
	bl	_CP_PACKET3
	bl	_OUT_RING
	mov	w0, #2
LBB0_3:
	bl	_OUT_RING
	mov	w8, #8
	cmp	w21, #8
	csel	w8, w21, w8, gt
	mul	w8, w8, w20
	add	w9, w8, #63
	cmp	w8, #0
	csel	w8, w9, w8, lt
	lsl	w8, w8, #4
	and	w21, w8, #0xfffffc00
	add	w8, w20, #7
	cmp	w20, #0
	csel	w8, w8, w20, lt
	asr	w8, w8, #3
	sub	w20, w8, #1
	lsl	w8, w19, #2
	orr	w19, w8, #0x8000000
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh24:
	adrp	x8, _R600_CB_COLOR0_SIZE@GOTPAGE
Lloh25:
	ldr	x8, [x8, _R600_CB_COLOR0_SIZE@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	sub	w8, w21, #1024
	orr	w0, w8, w20
	bl	_OUT_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh27:
	adrp	x8, _R600_CB_COLOR0_VIEW@GOTPAGE
Lloh28:
	ldr	x8, [x8, _R600_CB_COLOR0_VIEW@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	mov	w0, #0
	bl	_OUT_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh30:
	adrp	x8, _R600_CB_COLOR0_INFO@GOTPAGE
Lloh31:
	ldr	x8, [x8, _R600_CB_COLOR0_INFO@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	mov	x0, x19
	bl	_OUT_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh33:
	adrp	x8, _R600_CB_COLOR0_TILE@GOTPAGE
Lloh34:
	ldr	x8, [x8, _R600_CB_COLOR0_TILE@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	mov	w0, #0
	bl	_OUT_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh36:
	adrp	x8, _R600_CB_COLOR0_FRAG@GOTPAGE
Lloh37:
	ldr	x8, [x8, _R600_CB_COLOR0_FRAG@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	mov	w0, #0
	bl	_OUT_RING
	ldr	w0, [x24]
	mov	w1, #1
	bl	_CP_PACKET3
	bl	_OUT_RING
Lloh39:
	adrp	x8, _R600_CB_COLOR0_MASK@GOTPAGE
Lloh40:
	ldr	x8, [x8, _R600_CB_COLOR0_MASK@GOTPAGEOFF]
Lloh41:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w0, w8, #2
	bl	_OUT_RING
	mov	w0, #0
	bl	_OUT_RING
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_ADVANCE_RING
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_RING_LOCALS,4,2                ; @RING_LOCALS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"\n"

	.comm	_RADEON_FAMILY_MASK,4,2         ; @RADEON_FAMILY_MASK
	.comm	_CHIP_R600,4,2                  ; @CHIP_R600
	.comm	_CHIP_RV770,4,2                 ; @CHIP_RV770
	.comm	_R600_IT_SET_CONTEXT_REG,4,2    ; @R600_IT_SET_CONTEXT_REG
	.comm	_R600_CB_COLOR0_BASE,4,2        ; @R600_CB_COLOR0_BASE
	.comm	_R600_SET_CONTEXT_REG_OFFSET,4,2 ; @R600_SET_CONTEXT_REG_OFFSET
	.comm	_R600_IT_SURFACE_BASE_UPDATE,4,2 ; @R600_IT_SURFACE_BASE_UPDATE
	.comm	_R600_CB_COLOR0_SIZE,4,2        ; @R600_CB_COLOR0_SIZE
	.comm	_R600_CB_COLOR0_VIEW,4,2        ; @R600_CB_COLOR0_VIEW
	.comm	_R600_CB_COLOR0_INFO,4,2        ; @R600_CB_COLOR0_INFO
	.comm	_R600_CB_COLOR0_TILE,4,2        ; @R600_CB_COLOR0_TILE
	.comm	_R600_CB_COLOR0_FRAG,4,2        ; @R600_CB_COLOR0_FRAG
	.comm	_R600_CB_COLOR0_MASK,4,2        ; @R600_CB_COLOR0_MASK
	.no_dead_strip	_set_render_target
.subsections_via_symbols
