	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_scissors
_set_scissors:                          ## @set_scissors
	.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, %r14d
	movl	%edx, %r13d
	movq	_RADEON_RING_TYPE_GFX_INDEX@GOTPCREL(%rip), %r8
	testl	%ecx, %ecx
	movl	$1, %edx
	cmovel	%edx, %esi
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movq	(%rdi), %rdx
	movq	_CHIP_CAYMAN@GOTPCREL(%rip), %rsi
	movl	%ecx, %ebx
	xorl	$1, %ebx
	movl	%r14d, %eax
	xorl	$1, %eax
	orl	%ebx, %eax
	movl	$2, %eax
	movl	%ecx, %r12d
	cmovel	%eax, %r12d
	cmpq	(%rsi), %rdx
	movq	(%r8), %rbx
	cmovll	%ecx, %r12d
	shlq	$2, %rbx
	addq	8(%rdi), %rbx
	movq	_PACKET3_SET_CONTEXT_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$2, %esi
	callq	_PACKET3
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_PA_SC_SCREEN_SCISSOR_TL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_PACKET3_SET_CONTEXT_REG_START@GOTPCREL(%rip), %rax
	subl	(%rax), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	shll	$16, %r13d
	testl	%r14d, %r14d
	movl	$65536, %r15d                   ## imm = 0x10000
	cmovnel	%r13d, %r15d
	orl	-44(%rbp), %r15d                ## 4-byte Folded Reload
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_radeon_ring_write
	shll	$16, %r14d
	orl	%r12d, %r14d
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_radeon_ring_write
	movq	_PACKET3_SET_CONTEXT_REG@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movl	$2, %esi
	callq	_PACKET3
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_PA_SC_GENERIC_SCISSOR_TL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_PACKET3_SET_CONTEXT_REG_START@GOTPCREL(%rip), %r13
	subl	(%r13), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	orl	$-2147483648, %r15d             ## imm = 0x80000000
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_radeon_ring_write
	movl	(%r12), %edi
	movl	$2, %esi
	callq	_PACKET3
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_PA_SC_WINDOW_SCISSOR_TL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	subl	(%r13), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	movl	%r14d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_radeon_ring_write              ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_RADEON_RING_TYPE_GFX_INDEX,8,3 ## @RADEON_RING_TYPE_GFX_INDEX
	.comm	_CHIP_CAYMAN,8,3                ## @CHIP_CAYMAN
	.comm	_PACKET3_SET_CONTEXT_REG,4,2    ## @PACKET3_SET_CONTEXT_REG
	.comm	_PA_SC_SCREEN_SCISSOR_TL,4,2    ## @PA_SC_SCREEN_SCISSOR_TL
	.comm	_PACKET3_SET_CONTEXT_REG_START,4,2 ## @PACKET3_SET_CONTEXT_REG_START
	.comm	_PA_SC_GENERIC_SCISSOR_TL,4,2   ## @PA_SC_GENERIC_SCISSOR_TL
	.comm	_PA_SC_WINDOW_SCISSOR_TL,4,2    ## @PA_SC_WINDOW_SCISSOR_TL
	.no_dead_strip	_set_scissors
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_scissors
_set_scissors:                          ; @set_scissors
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x4
	mov	x21, x2
	cmp	w3, #0
Lloh0:
	adrp	x8, _RADEON_RING_TYPE_GFX_INDEX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RADEON_RING_TYPE_GFX_INDEX@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	csinc	w24, w1, wzr, ne
Lloh3:
	adrp	x9, _CHIP_CAYMAN@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CHIP_CAYMAN@GOTPAGEOFF]
	ldp	x11, x10, [x0]
Lloh5:
	ldr	x9, [x9]
	cmp	w4, #1
	ccmp	w3, #1, #0, eq
	mov	w12, #2
	csel	w12, w12, w3, eq
	cmp	x11, x9
	csel	w25, w3, w12, lt
	add	x19, x10, x8, lsl #2
Lloh6:
	adrp	x22, _PACKET3_SET_CONTEXT_REG@GOTPAGE
Lloh7:
	ldr	x22, [x22, _PACKET3_SET_CONTEXT_REG@GOTPAGEOFF]
	ldr	w0, [x22]
	mov	w1, #2
	bl	_PACKET3
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh8:
	adrp	x8, _PA_SC_SCREEN_SCISSOR_TL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _PA_SC_SCREEN_SCISSOR_TL@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
Lloh11:
	adrp	x23, _PACKET3_SET_CONTEXT_REG_START@GOTPAGE
Lloh12:
	ldr	x23, [x23, _PACKET3_SET_CONTEXT_REG_START@GOTPAGEOFF]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	lsl	w8, w21, #16
	mov	w9, #65536
	cmp	w20, #0
	csel	w8, w9, w8, eq
	orr	w21, w8, w24
	mov	x0, x19
	mov	x1, x21
	bl	_radeon_ring_write
	orr	w20, w25, w20, lsl #16
	mov	x0, x19
	mov	x1, x20
	bl	_radeon_ring_write
	ldr	w0, [x22]
	mov	w1, #2
	bl	_PACKET3
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh13:
	adrp	x8, _PA_SC_GENERIC_SCISSOR_TL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _PA_SC_GENERIC_SCISSOR_TL@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	orr	w21, w21, #0x80000000
	mov	x0, x19
	mov	x1, x21
	bl	_radeon_ring_write
	mov	x0, x19
	mov	x1, x20
	bl	_radeon_ring_write
	ldr	w0, [x22]
	mov	w1, #2
	bl	_PACKET3
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh16:
	adrp	x8, _PA_SC_WINDOW_SCISSOR_TL@GOTPAGE
Lloh17:
	ldr	x8, [x8, _PA_SC_WINDOW_SCISSOR_TL@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	ldr	w9, [x23]
	sub	w8, w8, w9
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	x0, x19
	mov	x1, x21
	bl	_radeon_ring_write
	mov	x0, x19
	mov	x1, x20
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_radeon_ring_write
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_RADEON_RING_TYPE_GFX_INDEX,8,3 ; @RADEON_RING_TYPE_GFX_INDEX
	.comm	_CHIP_CAYMAN,8,3                ; @CHIP_CAYMAN
	.comm	_PACKET3_SET_CONTEXT_REG,4,2    ; @PACKET3_SET_CONTEXT_REG
	.comm	_PA_SC_SCREEN_SCISSOR_TL,4,2    ; @PA_SC_SCREEN_SCISSOR_TL
	.comm	_PACKET3_SET_CONTEXT_REG_START,4,2 ; @PACKET3_SET_CONTEXT_REG_START
	.comm	_PA_SC_GENERIC_SCISSOR_TL,4,2   ; @PA_SC_GENERIC_SCISSOR_TL
	.comm	_PA_SC_WINDOW_SCISSOR_TL,4,2    ; @PA_SC_WINDOW_SCISSOR_TL
	.no_dead_strip	_set_scissors
.subsections_via_symbols
