	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function getbits
_getbits:                               ## @getbits
	.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
	movb	(%rdi), %al
	movl	$-2, %r14d
	testb	%al, %al
	je	LBB0_8
## %bb.1:
	movq	%rdi, %r13
	movq	_digits@GOTPCREL(%rip), %rcx
	movq	(%rcx), %r15
	testl	%esi, %esi
	movl	$32, %ecx
	movl	$128, %r12d
	cmovel	%ecx, %r12d
	incq	%r13
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movsbl	%al, %esi
	movq	%r15, %rdi
	callq	_strchr
	testq	%rax, %rax
	je	LBB0_8
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	subq	%r15, %rax
	shlq	$33, %rbx
	leaq	(%rbx,%rbx,4), %rbx
	sarq	$32, %rbx
	addq	%rax, %rbx
	testl	%ebx, %ebx
	je	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	%ebx, %r12d
	jl	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movzbl	(%r13), %eax
	incq	%r13
	testb	%al, %al
	jne	LBB0_2
## %bb.7:
	movl	%ebx, %r14d
	jmp	LBB0_8
LBB0_4:
	xorl	%eax, %eax
	cmpb	$0, (%r13)
	sete	%al
	leal	(%rax,%rax), %r14d
	addl	$-2, %r14d
LBB0_8:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_digits,8,3                     ## @digits
	.no_dead_strip	_getbits
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function getbits
_getbits:                               ; @getbits
	.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
	ldrb	w8, [x0]
	cbz	w8, LBB0_6
; %bb.1:
	mov	x19, #0
Lloh0:
	adrp	x9, _digits@GOTPAGE
Lloh1:
	ldr	x9, [x9, _digits@GOTPAGEOFF]
Lloh2:
	ldr	x20, [x9]
	mov	w9, #128
	mov	w10, #32
	cmp	w1, #0
	csel	w22, w10, w9, eq
	add	x21, x0, #1
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	sxtb	w1, w8
	mov	x0, x20
	bl	_strchr
	cbz	x0, LBB0_6
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	sub	x8, x0, x20
	add	w9, w19, w19, lsl #2
	lsl	x9, x9, #33
	add	x19, x8, x9, asr #32
	cbz	w19, LBB0_8
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	cmp	w22, w19
	b.lt	LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	ldrb	w8, [x21], #1
	cbnz	w8, LBB0_2
	b	LBB0_7
LBB0_6:
	mov	w19, #-2
LBB0_7:
	mov	x0, x19
	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_8:
	ldrb	w8, [x21]
	mov	w9, #-2
	cmp	w8, #0
	csel	w19, wzr, w9, eq
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_digits,8,3                     ; @digits
	.no_dead_strip	_getbits
.subsections_via_symbols
