	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pg_reg_getcolor                ## -- Begin function pg_reg_getcolor
	.p2align	4, 0x90
_pg_reg_getcolor:                       ## @pg_reg_getcolor
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	_MAX_SIMPLE_CHR@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpq	%rsi, (%rax)
	setl	%dil
	callq	_assert
	movl	(%r14), %eax
	testl	%eax, %eax
	jle	LBB0_7
## %bb.1:
	movq	16(%r14), %rcx
	xorl	%edx, %edx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%esi, %eax
	cmpl	%edx, %eax
	jle	LBB0_7
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	%eax, %edi
	subl	%edx, %edi
	movl	%edi, %esi
	shrl	$31, %esi
	addl	%edi, %esi
	sarl	%esi
	addl	%edx, %esi
	movslq	%esi, %rdi
	leaq	(%rdi,%rdi,2), %rdi
	cmpq	%rbx, (%rcx,%rdi,8)
	jg	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpq	%rbx, 8(%rcx,%rdi,8)
	jge	LBB0_11
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	incl	%esi
	movl	%esi, %edx
	cmpl	%edx, %eax
	jg	LBB0_2
LBB0_7:
	xorl	%r15d, %r15d
	cmpl	$2, 4(%r14)
	jl	LBB0_10
LBB0_9:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_cclass_column_index
	imull	4(%r14), %r15d
	addl	%eax, %r15d
LBB0_10:
	movq	8(%r14), %rax
	movslq	%r15d, %rcx
	movl	(%rax,%rcx,4), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movl	16(%rcx,%rdi,8), %r15d
	cmpl	$2, 4(%r14)
	jge	LBB0_9
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_SIMPLE_CHR,8,3             ## @MAX_SIMPLE_CHR
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pg_reg_getcolor                ; -- Begin function pg_reg_getcolor
	.p2align	2
_pg_reg_getcolor:                       ; @pg_reg_getcolor
	.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
Lloh0:
	adrp	x8, _MAX_SIMPLE_CHR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAX_SIMPLE_CHR@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x8, x1
	cset	w0, lt
	bl	_assert
	ldr	w9, [x19]
	cmp	w9, #1
	b.lt	LBB0_6
; %bb.1:
	mov	w11, #0
	ldr	x8, [x19, #16]
	mov	w10, #24
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x9, x12
	cmp	w12, w11
	b.le	LBB0_6
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	sub	w12, w9, w11
	cmp	w12, #0
	cinc	w12, w12, lt
	add	w12, w11, w12, asr #1
	smull	x13, w12, w10
	ldr	x13, [x8, x13]
	cmp	x13, x20
	b.gt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	sxtw	x11, w12
	madd	x13, x11, x10, x8
	ldr	x13, [x13, #8]
	cmp	x13, x20
	b.ge	LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	add	w11, w12, #1
	mov	x12, x9
	b	LBB0_2
LBB0_6:
	mov	w21, #0
	b	LBB0_8
LBB0_7:
	mov	w9, #24
	madd	x8, x11, x9, x8
	ldr	w21, [x8, #16]
LBB0_8:
	ldr	w8, [x19, #4]
	cmp	w8, #1
	b.le	LBB0_10
; %bb.9:
	mov	x0, x19
	mov	x1, x20
	bl	_cclass_column_index
	ldr	w8, [x19, #4]
	madd	w21, w8, w21, w0
LBB0_10:
	ldr	x8, [x19, #8]
	ldr	w0, [x8, w21, sxtw #2]
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_SIMPLE_CHR,8,3             ; @MAX_SIMPLE_CHR
.subsections_via_symbols
