	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bin2str                        ## -- Begin function bin2str
	.p2align	4, 0x90
_bin2str:                               ## @bin2str
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, %r13
	movq	%rdi, %r12
	leaq	L_.str(%rip), %rsi
	movl	$2, %edx
	callq	_strncasecmp
	testq	%rax, %rax
	je	LBB0_1
## %bb.5:
	leaq	L_.str.2(%rip), %rsi
	movq	%r12, %rdi
	movl	$2, %edx
	callq	_strncasecmp
	xorl	%ebx, %ebx
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	xorl	%r14d, %r14d
	jmp	LBB0_22
LBB0_1:
	leal	(%r15,%r15), %edi
	addl	$3, %edi
	callq	_malloc
	movq	%rax, %r14
	movq	%rax, %rdi
	movq	%r12, %rsi
	callq	_strcpy
	movsbl	1(%r12), %edx
	leaq	L_.str.1(%rip), %rsi
	leaq	-45(%rbp), %rdi
	callq	_sprintf
	leaq	2(%r14), %rbx
	testl	%r15d, %r15d
	jle	LBB0_4
## %bb.2:
	incl	%r15d
	leaq	-45(%rbp), %r12
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movsbl	(%r13), %edx
	incq	%r13
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_sprintf
	addq	$2, %rbx
	decl	%r15d
	cmpl	$1, %r15d
	ja	LBB0_3
LBB0_4:
	movb	$0, (%rbx)
	jmp	LBB0_22
LBB0_7:
	leal	8(,%r15,4), %eax
	cltq
	imulq	$1431655766, %rax, %rax         ## imm = 0x55555556
	movq	%rax, %rcx
	shrq	$32, %rcx
	shrq	$63, %rax
	leal	(%rcx,%rax), %edi
	addl	$3, %edi
	callq	_malloc
	movq	%rax, %r14
	movq	%rax, %rdi
	movq	%r12, %rsi
	callq	_strcpy
	leaq	2(%r14), %rax
	testl	%r15d, %r15d
	jle	LBB0_16
## %bb.8:
	xorl	%ebx, %ebx
	movl	$2863311531, %r8d               ## imm = 0xAAAAAAAB
	movq	_base64@GOTPCREL(%rip), %r9
	movl	%r15d, %esi
	xorl	%ecx, %ecx
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_9 Depth=1
	movzbl	(%r13), %edx
	shrl	$6, %edx
	addl	%edx, %ebx
	movq	(%r9), %rdx
	movslq	%ebx, %rdi
	movzbl	(%rdx,%rdi,8), %edx
	movb	%dl, (%rax)
	movq	(%r9), %rdx
	movzbl	(%r13), %edi
	andl	$63, %edi
	movzbl	(%rdx,%rdi,8), %edx
	movb	%dl, 1(%rax)
	addq	$2, %rax
LBB0_15:                                ##   in Loop: Header=BB0_9 Depth=1
	incq	%r13
	incl	%ecx
	decl	%esi
	je	LBB0_16
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ecx, %edi
	imulq	%r8, %rdi
	shrq	$33, %rdi
	leal	(%rdi,%rdi,2), %edx
	movl	%ecx, %edi
	subl	%edx, %edi
	cmpl	$2, %edi
	je	LBB0_14
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	cmpl	$1, %edi
	je	LBB0_13
## %bb.11:                              ##   in Loop: Header=BB0_9 Depth=1
	testl	%edi, %edi
	jne	LBB0_15
## %bb.12:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	(%r9), %rdx
	movzbl	(%r13), %edi
	andl	$252, %edi
	movzbl	(%rdx,%rdi,2), %edx
	movb	%dl, (%rax)
	incq	%rax
	movzbl	(%r13), %ebx
	shll	$4, %ebx
	andl	$48, %ebx
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_9 Depth=1
	movzbl	(%r13), %edx
	shrl	$4, %edx
	addl	%edx, %ebx
	movq	(%r9), %rdx
	movslq	%ebx, %rdi
	movzbl	(%rdx,%rdi,8), %edx
	movb	%dl, (%rax)
	incq	%rax
	movzbl	(%r13), %ebx
	shll	$2, %ebx
	andl	$60, %ebx
	jmp	LBB0_15
LBB0_16:
	movslq	%r15d, %rcx
	imulq	$1431655766, %rcx, %rcx         ## imm = 0x55555556
	movq	%rcx, %rdx
	shrq	$63, %rdx
	shrq	$32, %rcx
	addl	%edx, %ecx
	leal	(%rcx,%rcx,2), %ecx
	subl	%ecx, %r15d
	cmpl	$2, %r15d
	je	LBB0_19
## %bb.17:
	cmpl	$1, %r15d
	jne	LBB0_21
## %bb.18:
	movq	_base64@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movslq	%ebx, %rdx
	movb	(%rcx,%rdx,8), %cl
	movb	%cl, (%rax)
	leaq	2(%rax), %rcx
	movb	$61, 1(%rax)
	movl	$3, %edx
	jmp	LBB0_20
LBB0_19:
	movq	_base64@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movslq	%ebx, %rdx
	movb	(%rcx,%rdx,8), %dl
	leaq	1(%rax), %rcx
	movb	%dl, (%rax)
	movl	$2, %edx
LBB0_20:
	addq	%rdx, %rax
	movb	$61, (%rcx)
LBB0_21:
	movb	$0, (%rax)
LBB0_22:
	movq	%r14, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"0x"

L_.str.1:                               ## @.str.1
	.asciz	"%%02%c"

L_.str.2:                               ## @.str.2
	.asciz	"0b"

	.comm	_base64,8,3                     ## @base64
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bin2str                        ; -- Begin function bin2str
	.p2align	2
_bin2str:                               ; @bin2str
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x2
	mov	x20, x1
	mov	x22, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w2, #2
	bl	_strncasecmp
	cbz	x0, LBB0_3
; %bb.1:
Lloh2:
	adrp	x1, l_.str.2@PAGE
Lloh3:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x22
	mov	w2, #2
	bl	_strncasecmp
	cbz	x0, LBB0_7
; %bb.2:
	mov	x19, #0
	b	LBB0_23
LBB0_3:
	lsl	w8, w21, #1
	add	w0, w8, #3
	bl	_malloc
	mov	x19, x0
	mov	x1, x22
	bl	_strcpy
	ldrsb	w2, [x22, #1]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x0, sp, #11
	bl	_sprintf
	add	x22, x19, #2
	cmp	w21, #1
	b.lt	LBB0_6
; %bb.4:
	add	w21, w21, #1
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldrsb	w2, [x20], #1
	add	x1, sp, #11
	mov	x0, x22
	bl	_sprintf
	add	x22, x22, #2
	sub	w21, w21, #1
	cmp	w21, #1
	b.hi	LBB0_5
LBB0_6:
	strb	wzr, [x22]
	b	LBB0_23
LBB0_7:
	lsl	w8, w21, #2
	add	w8, w8, #8
	mov	w23, #21846
	movk	w23, #21845, lsl #16
	smull	x8, w8, w23
	lsr	x9, x8, #63
	lsr	x8, x8, #32
	add	w8, w8, w9
	add	w0, w8, #3
	bl	_malloc
	mov	x19, x0
	mov	x1, x22
	bl	_strcpy
	add	x8, x19, #2
	cmp	w21, #1
	b.lt	LBB0_16
; %bb.8:
	mov	w9, #0
	mov	w10, #0
	mov	w11, #43691
	movk	w11, #43690, lsl #16
Lloh6:
	adrp	x12, _base64@GOTPAGE
Lloh7:
	ldr	x12, [x12, _base64@GOTPAGEOFF]
	mov	x13, x21
	b	LBB0_11
LBB0_9:                                 ;   in Loop: Header=BB0_11 Depth=1
	ldrb	w14, [x20]
	add	w9, w9, w14, lsr #6
	ldr	x14, [x12]
	ldr	x14, [x14, w9, sxtw #3]
	strb	w14, [x8]
	ldr	x14, [x12]
	ldrb	w15, [x20]
	and	x15, x15, #0x3f
	ldr	x14, [x14, x15, lsl #3]
	strb	w14, [x8, #1]
	add	x8, x8, #2
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x20, x20, #1
	add	w10, w10, #1
	subs	w13, w13, #1
	b.eq	LBB0_17
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	umull	x14, w10, w11
	lsr	x14, x14, #33
	add	w14, w14, w14, lsl #1
	sub	w14, w10, w14
	cmp	w14, #2
	b.eq	LBB0_9
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	cmp	w14, #1
	b.eq	LBB0_15
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	cbnz	w14, LBB0_10
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	x9, [x12]
	ldrb	w14, [x20]
	lsl	w14, w14, #1
	and	x14, x14, #0x1f8
	ldr	x9, [x9, x14]
	strb	w9, [x8], #1
	ldrb	w9, [x20]
	ubfiz	w9, w9, #4, #2
	b	LBB0_10
LBB0_15:                                ;   in Loop: Header=BB0_11 Depth=1
	ldrb	w14, [x20]
	add	w9, w9, w14, lsr #4
	ldr	x14, [x12]
	ldr	x9, [x14, w9, sxtw #3]
	strb	w9, [x8], #1
	ldrb	w9, [x20]
	ubfiz	w9, w9, #2, #4
	b	LBB0_10
LBB0_16:
	mov	w9, #0
LBB0_17:
	smull	x10, w21, w23
	lsr	x11, x10, #63
	lsr	x10, x10, #32
	add	w10, w10, w11
	add	w10, w10, w10, lsl #1
	sub	w10, w21, w10
	cmp	w10, #2
	b.eq	LBB0_20
; %bb.18:
	cmp	w10, #1
	b.ne	LBB0_22
; %bb.19:
Lloh8:
	adrp	x10, _base64@GOTPAGE
Lloh9:
	ldr	x10, [x10, _base64@GOTPAGEOFF]
Lloh10:
	ldr	x10, [x10]
	ldr	x9, [x10, w9, sxtw #3]
	strb	w9, [x8]
	add	x9, x8, #2
	mov	w10, #61
	strb	w10, [x8, #1]
	mov	w10, #3
	b	LBB0_21
LBB0_20:
Lloh11:
	adrp	x10, _base64@GOTPAGE
Lloh12:
	ldr	x10, [x10, _base64@GOTPAGEOFF]
Lloh13:
	ldr	x10, [x10]
	ldr	x10, [x10, w9, sxtw #3]
	mov	x9, x8
	strb	w10, [x9], #1
	mov	w10, #2
LBB0_21:
	add	x8, x8, x10
	mov	w10, #61
	strb	w10, [x9]
LBB0_22:
	strb	wzr, [x8]
LBB0_23:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"0x"

l_.str.1:                               ; @.str.1
	.asciz	"%%02%c"

l_.str.2:                               ; @.str.2
	.asciz	"0b"

	.comm	_base64,8,3                     ; @base64
.subsections_via_symbols
