	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_make_vdp_palette               ## -- Begin function make_vdp_palette
	.p2align	4, 0x90
_make_vdp_palette:                      ## @make_vdp_palette
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	.cfi_offset %rbx, -24
	xorl	%eax, %eax
	leaq	l___const.make_vdp_palette.lut(%rip), %r8
	movq	_vdp_palette@GOTPCREL(%rip), %r9
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	%eax, %esi
	shrl	$6, %esi
	andl	$7, %esi
	movl	%eax, %edi
	shrl	$3, %edi
	andl	$7, %edi
	movl	%eax, %r10d
	andl	$7, %r10d
	movl	%eax, %ecx
	shrl	$9, %ecx
	movq	%rcx, %rdx
	shlq	$6, %rdx
	addq	%r8, %rdx
	movq	(%rdx,%rsi,8), %r11
	movq	(%r9), %rsi
	movq	(%rsi,%rcx,8), %rsi
	movl	%eax, %ebx
	andl	$511, %ebx                      ## imm = 0x1FF
	shlq	$3, %rbx
	leaq	(%rbx,%rbx,2), %rbx
	movq	%r11, 16(%rsi,%rbx)
	movq	(%rdx,%rdi,8), %rsi
	movq	(%r9), %rdi
	movq	(%rdi,%rcx,8), %rdi
	movq	%rsi, 8(%rdi,%rbx)
	movq	(%rdx,%r10,8), %rdx
	movq	(%r9), %rsi
	movq	(%rsi,%rcx,8), %rcx
	movq	%rdx, (%rcx,%rbx)
	incl	%eax
	cmpl	$1536, %eax                     ## imm = 0x600
	jne	LBB0_1
## %bb.2:
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__const
	.p2align	4                               ## @__const.make_vdp_palette.lut
l___const.make_vdp_palette.lut:
	.quad	0
	.quad	4
	.quad	8
	.quad	12
	.quad	16
	.quad	20
	.quad	24
	.quad	28
	.quad	0
	.quad	8
	.quad	16
	.quad	24
	.quad	32
	.quad	40
	.quad	48
	.quad	56
	.quad	32
	.quad	36
	.quad	40
	.quad	44
	.quad	48
	.quad	52
	.quad	56
	.quad	60

	.comm	_vdp_palette,8,3                ## @vdp_palette
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_make_vdp_palette               ; -- Begin function make_vdp_palette
	.p2align	2
_make_vdp_palette:                      ; @make_vdp_palette
	.cfi_startproc
; %bb.0:
	mov	w8, #0
Lloh0:
	adrp	x9, _vdp_palette@GOTPAGE
Lloh1:
	ldr	x9, [x9, _vdp_palette@GOTPAGEOFF]
	mov	w10, #24
Lloh2:
	adrp	x11, l___const.make_vdp_palette.lut@PAGE
Lloh3:
	add	x11, x11, l___const.make_vdp_palette.lut@PAGEOFF
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ubfx	w12, w8, #6, #3
	lsr	w13, w8, #9
	add	x14, x11, x13, lsl #6
	ldr	x15, [x9]
	lsl	x13, x13, #3
	ldr	x12, [x14, w12, uxtw #3]
	ldr	x15, [x15, x13]
	and	w16, w8, #0x1ff
	umaddl	x15, w16, w10, x15
	str	x12, [x15, #16]
	ubfx	w12, w8, #3, #3
	ldr	x12, [x14, w12, uxtw #3]
	ldr	x15, [x9]
	ldr	x15, [x15, x13]
	and	w17, w8, #0x7
	umaddl	x15, w16, w10, x15
	str	x12, [x15, #8]
	ldr	x12, [x14, w17, uxtw #3]
	ldr	x14, [x9]
	umull	x15, w16, w10
	ldr	x13, [x14, x13]
	str	x12, [x13, x15]
	add	w8, w8, #1
	cmp	w8, #1536
	b.ne	LBB0_1
; %bb.2:
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__const
	.p2align	3                               ; @__const.make_vdp_palette.lut
l___const.make_vdp_palette.lut:
	.quad	0
	.quad	4
	.quad	8
	.quad	12
	.quad	16
	.quad	20
	.quad	24
	.quad	28
	.quad	0
	.quad	8
	.quad	16
	.quad	24
	.quad	32
	.quad	40
	.quad	48
	.quad	56
	.quad	32
	.quad	36
	.quad	40
	.quad	44
	.quad	48
	.quad	52
	.quad	56
	.quad	60

	.comm	_vdp_palette,8,3                ; @vdp_palette
.subsections_via_symbols
