	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ScreenNextResolution           ## -- Begin function ScreenNextResolution
	.p2align	4, 0x90
_ScreenNextResolution:                  ## @ScreenNextResolution
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	(%rdi), %r12
	cmpq	8(%rdi), %r12
	jae	LBB0_1
## %bb.4:
	movq	40(%rbx), %rax
	jmp	LBB0_5
LBB0_1:
	leaq	8(%rbx), %r15
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	16(%rbx), %rdx
	incq	%rdx
	movq	%rdx, 16(%rbx)
	movl	32(%rbx), %edi
	cmpq	24(%rbx), %rdx
	jae	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%esi, %esi
	movq	%r15, %rcx
	callq	_XRRRates
	movq	%rax, 40(%rbx)
	movq	$0, (%rbx)
	cmpq	$0, 8(%rbx)
	je	LBB0_2
LBB0_5:
	movq	16(%rbx), %rcx
	movq	%rcx, (%r14)
	movq	48(%rbx), %rdx
	movl	4(%rdx,%rcx,8), %esi
	movl	%esi, 24(%r14)
	movl	(%rdx,%rcx,8), %ecx
	movl	%ecx, 20(%r14)
	movl	(%rax,%r12,4), %eax
	movl	%eax, 16(%r14)
	movq	$0, 8(%r14)
	incq	%r12
	movq	%r12, (%rbx)
	xorl	%eax, %eax
	jmp	LBB0_7
LBB0_6:
	callq	_XCloseDisplay
	movq	%rbx, %rdi
	callq	_free
	movl	$1, %eax
LBB0_7:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ScreenNextResolution           ; -- Begin function ScreenNextResolution
	.p2align	2
_ScreenNextResolution:                  ; @ScreenNextResolution
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x1
	mov	x19, x0
	mov	x21, x0
	ldr	x8, [x21, #8]!
	ldr	x9, [x0]
	cmp	x9, x8
	b.hs	LBB0_2
; %bb.1:
	ldr	x0, [x19, #40]
	b	LBB0_5
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x8, x9, [x19, #16]
	add	x2, x8, #1
	str	x2, [x19, #16]
	ldr	w0, [x19, #32]
	cmp	x2, x9
	b.hs	LBB0_6
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w1, #0
	mov	x3, x21
	bl	_XRRRates
	str	x0, [x19, #40]
	str	xzr, [x19]
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_2
; %bb.4:
	mov	x9, #0
LBB0_5:
	mov	w8, #0
	ldr	x10, [x19, #16]
	ldr	x11, [x19, #48]
	ldr	d0, [x11, x10, lsl #3]
	stur	d0, [x20, #20]
	ldr	w11, [x0, x9, lsl #2]
	str	w11, [x20, #16]
	stp	x10, xzr, [x20]
	add	x9, x9, #1
	str	x9, [x19]
	b	LBB0_7
LBB0_6:
	bl	_XCloseDisplay
	mov	x0, x19
	bl	_free
	mov	w8, #1
LBB0_7:
	mov	x0, x8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
