	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ClipOrCenterRectToMonitor      ## -- Begin function ClipOrCenterRectToMonitor
	.p2align	4, 0x90
_ClipOrCenterRectToMonitor:             ## @ClipOrCenterRectToMonitor
	.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
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movl	(%rdi), %r14d
	movl	8(%rdi), %eax
	subl	4(%rdi), %r14d
	subl	12(%rdi), %eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	_MONITOR_DEFAULTTONEAREST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_MonitorFromRect
	movl	$36, -88(%rbp)
	leaq	-88(%rbp), %rsi
	movl	%eax, %edi
	callq	_GetMonitorInfo
	movq	_MONITOR_WORKAREA@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_2
## %bb.1:
	movl	-68(%rbp), %r12d
	movl	-64(%rbp), %edi
	movl	-60(%rbp), %edx
	leaq	-56(%rbp), %rax
	jmp	LBB0_3
LBB0_2:
	movl	-84(%rbp), %r12d
	movl	-80(%rbp), %edi
	movl	-76(%rbp), %edx
	leaq	-72(%rbp), %rax
LBB0_3:
	movl	(%rax), %r13d
	movq	_MONITOR_CENTER@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_5
## %bb.4:
	subl	%r14d, %edi
	subl	%r12d, %edi
	movl	%edi, %ecx
	shrl	$31, %ecx
	addl	%edi, %ecx
	sarl	%ecx
	addl	%r12d, %ecx
	movl	%ecx, 4(%rbx)
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	subl	%edx, %r13d
	subl	%r15d, %r13d
	movl	%r13d, %eax
	shrl	$31, %eax
	addl	%r13d, %eax
	sarl	%eax
	addl	%edx, %eax
	movl	%eax, 12(%rbx)
	jmp	LBB0_6
LBB0_5:
	subl	%r14d, %edi
	movl	4(%rbx), %esi
	movq	%rdx, -96(%rbp)                 ## 8-byte Spill
	callq	_min
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_max
	movl	%eax, 4(%rbx)
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	subl	%r15d, %r13d
	movl	12(%rbx), %esi
	movl	%r13d, %edi
	callq	_min
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
                                        ## kill: def $edi killed $edi killed $rdi
	movl	%eax, %esi
	callq	_max
	movl	%eax, 12(%rbx)
	movl	4(%rbx), %ecx
LBB0_6:
	addl	%r14d, %ecx
	movl	%ecx, (%rbx)
	addl	%r15d, %eax
	movl	%eax, 8(%rbx)
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MONITOR_DEFAULTTONEAREST,4,2   ## @MONITOR_DEFAULTTONEAREST
	.comm	_MONITOR_WORKAREA,4,2           ## @MONITOR_WORKAREA
	.comm	_MONITOR_CENTER,4,2             ## @MONITOR_CENTER
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ClipOrCenterRectToMonitor      ; -- Begin function ClipOrCenterRectToMonitor
	.p2align	2
_ClipOrCenterRectToMonitor:             ; @ClipOrCenterRectToMonitor
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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, x1
	mov	x19, x0
	ldp	w23, w24, [x0]
	ldp	w25, w26, [x0, #8]
Lloh0:
	adrp	x8, _MONITOR_DEFAULTTONEAREST@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MONITOR_DEFAULTTONEAREST@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_MonitorFromRect
	mov	w8, #36
	str	w8, [sp, #8]
	add	x21, sp, #8
	add	x1, sp, #8
	bl	_GetMonitorInfo
Lloh3:
	adrp	x8, _MONITOR_WORKAREA@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MONITOR_WORKAREA@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_2
; %bb.1:
	ldp	w22, w8, [sp, #28]
	add	x9, x21, #32
	ldr	w21, [sp, #36]
	b	LBB0_3
LBB0_2:
	ldp	w22, w8, [sp, #12]
	add	x9, x21, #16
	ldr	w21, [sp, #20]
LBB0_3:
	sub	w24, w23, w24
	sub	w23, w25, w26
	ldr	w25, [x9]
Lloh6:
	adrp	x9, _MONITOR_CENTER@GOTPAGE
Lloh7:
	ldr	x9, [x9, _MONITOR_CENTER@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	tst	w9, w20
	b.eq	LBB0_5
; %bb.4:
	add	w9, w24, w22
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	add	w8, w22, w8, asr #1
	str	w8, [x19, #4]
	add	w9, w21, w23
	sub	w9, w25, w9
	cmp	w9, #0
	cinc	w9, w9, lt
	add	w0, w21, w9, asr #1
	str	w0, [x19, #12]
	b	LBB0_6
LBB0_5:
	sub	w0, w8, w24
	ldr	w1, [x19, #4]
	bl	_min
	mov	x1, x0
	mov	x0, x22
	bl	_max
	str	w0, [x19, #4]
	sub	w0, w25, w23
	ldr	w1, [x19, #12]
	bl	_min
	mov	x1, x0
	mov	x0, x21
	bl	_max
	str	w0, [x19, #12]
	ldr	w8, [x19, #4]
LBB0_6:
	add	w8, w8, w24
	str	w8, [x19]
	add	w8, w0, w23
	str	w8, [x19, #8]
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_MONITOR_DEFAULTTONEAREST,4,2   ; @MONITOR_DEFAULTTONEAREST
	.comm	_MONITOR_WORKAREA,4,2           ; @MONITOR_WORKAREA
	.comm	_MONITOR_CENTER,4,2             ; @MONITOR_CENTER
.subsections_via_symbols
