	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function reverse_color16
_reverse_color16:                       ## @reverse_color16
	.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
	movq	(%rdx), %rax
	movl	$255, 12(%rax)
	cmpl	$0, (%rdi)
	jle	LBB0_9
## %bb.1:
	movq	8(%rdi), %rax
	movq	(%rax), %r8
	movq	8(%rsi), %r9
	movq	8(%rdx), %r10
	xorl	%eax, %eax
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%ebx, 8(%rcx)
	incq	%rax
	movslq	(%rdi), %rcx
	cmpq	%rcx, %rax
	jge	LBB0_9
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	(%r8,%rax,4), %ecx
	movl	$1, %esi
	shll	%cl, %esi
	leal	-1(%rsi), %r11d
	shrl	%esi
	movq	(%r9,%rax,8), %rdx
	movl	$0, %ebx
	cmpl	%esi, (%rdx)
	ja	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r11d, %ebx
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	(%r10,%rax,8), %rcx
	movl	%ebx, (%rcx)
	movl	$0, %ebx
	cmpl	%esi, 4(%rdx)
	ja	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r11d, %ebx
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%ebx, 4(%rcx)
	movl	$0, %ebx
	cmpl	%esi, 8(%rdx)
	ja	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r11d, %ebx
	jmp	LBB0_8
LBB0_9:
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_reverse_color16
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function reverse_color16
_reverse_color16:                       ; @reverse_color16
	.cfi_startproc
; %bb.0:
	ldr	x8, [x2]
	mov	w9, #255
	str	w9, [x8, #12]
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.1:
	mov	x8, #0
	ldr	x9, [x0, #8]
	ldr	x9, [x9]
	ldr	x10, [x1, #8]
	ldr	x11, [x2, #8]
	mov	w12, #1
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w13, [x9, x8, lsl #2]
	lsl	w13, w12, w13
	sub	w14, w13, #1
	lsl	x15, x8, #3
	ldr	x16, [x10, x15]
	lsr	w13, w13, #1
	ldr	w17, [x16]
	cmp	w17, w13
	csel	w17, wzr, w14, hi
	ldr	x15, [x11, x15]
	str	w17, [x15]
	ldr	w17, [x16, #4]
	cmp	w17, w13
	csel	w17, wzr, w14, hi
	str	w17, [x15, #4]
	ldr	w16, [x16, #8]
	cmp	w16, w13
	csel	w13, wzr, w14, hi
	str	w13, [x15, #8]
	add	x8, x8, #1
	ldrsw	x13, [x0]
	cmp	x8, x13
	b.lt	LBB0_2
LBB0_3:
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_reverse_color16
.subsections_via_symbols
