	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function getreg
_getreg:                                ## @getreg
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_15
## %bb.1:
	movq	%rdi, %r14
	movb	(%rdi), %al
	testb	%al, %al
	je	LBB0_15
## %bb.2:
	movq	_regs@GOTPCREL(%rip), %r15
	movq	(%r15), %rcx
	movq	(%rcx), %rsi
	testq	%rsi, %rsi
	je	LBB0_7
## %bb.3:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_strcmp
	testl	%eax, %eax
	je	LBB0_14
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	(%r15), %rax
	movq	8(%rax,%rbx,8), %rsi
	incq	%rbx
	testq	%rsi, %rsi
	jne	LBB0_4
## %bb.6:
	movb	(%r14), %al
LBB0_7:
	cmpb	$45, %al
	jne	LBB0_9
## %bb.8:
	leaq	1(%r14), %rsi
	xorl	%edi, %edi
	callq	_r_num_get
	movq	%rax, %rbx
	negl	%ebx
	testl	%ebx, %ebx
	jne	LBB0_14
	jmp	LBB0_11
LBB0_15:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_eprintf
LBB0_13:
	movl	$-1, %ebx
LBB0_14:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	xorl	%edi, %edi
	movq	%r14, %rsi
	callq	_r_num_get
	movq	%rax, %rbx
	testl	%ebx, %ebx
	jne	LBB0_14
LBB0_11:
	xorl	%ebx, %ebx
	cmpb	$48, (%r14)
	je	LBB0_14
## %bb.12:
	leaq	L_.str.1(%rip), %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	xorl	%eax, %eax
	callq	_eprintf
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Missing argument\n"

	.comm	_regs,8,3                       ## @regs
L_.str.1:                               ## @.str.1
	.asciz	"Invalid reg name (%s) at pos %d\n"

	.no_dead_strip	_getreg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function getreg
_getreg:                                ; @getreg
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	cbz	x0, LBB0_9
; %bb.1:
	mov	x19, x0
	ldrb	w8, [x0]
	cbz	w8, LBB0_9
; %bb.2:
Lloh0:
	adrp	x20, _regs@GOTPAGE
Lloh1:
	ldr	x20, [x20, _regs@GOTPAGEOFF]
	ldr	x9, [x20]
	ldr	x1, [x9]
	cbz	x1, LBB0_7
; %bb.3:
	mov	x21, #0
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_strcmp
	cbz	w0, LBB0_15
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x20]
	add	x8, x8, x21, lsl #3
	add	x21, x21, #1
	ldr	x1, [x8, #8]
	cbnz	x1, LBB0_4
; %bb.6:
	ldrb	w8, [x19]
LBB0_7:
	cmp	w8, #45
	b.ne	LBB0_12
; %bb.8:
	add	x1, x19, #1
	mov	x0, #0
	bl	_r_num_get
	neg	w0, w0
	cbnz	w0, LBB0_11
	b	LBB0_13
LBB0_9:
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
LBB0_10:
	bl	_eprintf
	mov	w0, #-1
LBB0_11:
                                        ; kill: def $w0 killed $w0 killed $x0
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_12:
	mov	x0, #0
	mov	x1, x19
	bl	_r_num_get
	cbnz	w0, LBB0_11
LBB0_13:
	ldrb	w8, [x19]
	cmp	w8, #48
	b.ne	LBB0_16
; %bb.14:
	mov	w0, #0
	b	LBB0_11
LBB0_15:
	mov	x0, x21
	b	LBB0_11
LBB0_16:
	stp	x19, xzr, [sp]
Lloh4:
	adrp	x0, l_.str.1@PAGE
Lloh5:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_10
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Missing argument\n"

	.comm	_regs,8,3                       ; @regs
l_.str.1:                               ; @.str.1
	.asciz	"Invalid reg name (%s) at pos %d\n"

	.no_dead_strip	_getreg
.subsections_via_symbols
