	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bitmap_to_string               ## -- Begin function bitmap_to_string
	.p2align	4, 0x90
_bitmap_to_string:                      ## @bitmap_to_string
	.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	%rdx, %r12
	movq	%rsi, %r15
	movq	%rdi, %r14
	callq	_bitmap_nbytes
	movl	$-1, %ecx
	cmpq	%r12, %rax
	ja	LBB0_12
## %bb.1:
	movl	(%r14), %edx
	cmpl	4(%r14), %edx
	jge	LBB0_12
## %bb.2:
	cmpq	%r12, %rax
	cmovbq	%rax, %r12
	xorl	%ecx, %ecx
	incl	%edx
	je	LBB0_12
## %bb.3:
	movslq	%edx, %r8
	movq	_BITMAP_BYTES@GOTPCREL(%rip), %r9
	movq	(%r9), %rsi
	leaq	(%r15,%rax,8), %r10
	addq	$-8, %r10
	xorl	%r11d, %r11d
	xorl	%r15d, %r15d
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_4 Depth=1
	negq	%rdx
	movq	%rdx, %r11
LBB0_10:                                ##   in Loop: Header=BB0_4 Depth=1
	incq	%r15
	cmpq	%r8, %r15
	je	LBB0_11
LBB0_4:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_7 Depth 2
	testq	%rsi, %rsi
	je	LBB0_10
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpq	%r12, %r11
	jae	LBB0_10
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	8(%r14), %rax
	movq	%r11, %rdx
	negq	%rdx
	movl	$1, %ebx
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_7:                                 ##   Parent Loop BB0_4 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	(%rax,%r15,8), %rsi
	shrq	%cl, %rsi
	movzbl	%sil, %esi
	movq	%rsi, (%r10,%rdx,8)
	movq	(%r9), %rsi
	decq	%rdx
	cmpq	%rsi, %rbx
	jae	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=2
	leaq	(%r11,%rbx), %rdi
	incq	%rbx
	addq	$8, %rcx
	cmpq	%r12, %rdi
	jb	LBB0_7
	jmp	LBB0_9
LBB0_11:
	xorl	%ecx, %ecx
LBB0_12:
	movl	%ecx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BITMAP_BYTES,8,3               ## @BITMAP_BYTES
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bitmap_to_string               ; -- Begin function bitmap_to_string
	.p2align	2
_bitmap_to_string:                      ; @bitmap_to_string
	.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	x21, x2
	mov	x20, x1
	mov	x19, x0
	bl	_bitmap_nbytes
	cmp	x0, x21
	b.hi	LBB0_4
; %bb.1:
	ldp	w9, w8, [x19]
	cmp	w9, w8
	b.ge	LBB0_4
; %bb.2:
	cmp	x0, x21
	csel	x8, x0, x21, lo
	adds	w11, w9, #1
	b.lo	LBB0_6
LBB0_3:
	mov	w0, #0
	b	LBB0_5
LBB0_4:
	mov	w0, #-1
LBB0_5:
	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
LBB0_6:
	mov	x9, #0
	mov	x10, #0
	sxtw	x11, w11
Lloh0:
	adrp	x12, _BITMAP_BYTES@GOTPAGE
Lloh1:
	ldr	x12, [x12, _BITMAP_BYTES@GOTPAGEOFF]
	ldr	x14, [x12]
	add	x13, x20, x0, lsl #3
	sub	x13, x13, #8
	b	LBB0_8
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	add	x10, x10, #1
	cmp	x10, x11
	b.eq	LBB0_3
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_11 Depth 2
	cbz	x14, LBB0_7
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	cmp	x9, x8
	b.hs	LBB0_7
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x16, #0
	mov	x15, #0
	ldr	x17, [x19, #8]
	sub	x0, x13, x9, lsl #3
LBB0_11:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x14, [x17, x10, lsl #3]
	lsr	x14, x14, x16
	and	x14, x14, #0xff
	add	x1, x9, x15
	str	x14, [x0], #-8
	add	x1, x1, #1
	add	x15, x15, #1
	ldr	x14, [x12]
	add	x16, x16, #8
	cmp	x15, x14
	ccmp	x1, x8, #2, lo
	b.lo	LBB0_11
; %bb.12:                               ;   in Loop: Header=BB0_8 Depth=1
	add	x9, x9, x15
	b	LBB0_7
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_BITMAP_BYTES,8,3               ; @BITMAP_BYTES
.subsections_via_symbols
