	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vga_str_to_iostate
_vga_str_to_iostate:                    ## @vga_str_to_iostate
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	movq	%rdi, %rbx
	leaq	L_.str(%rip), %rsi
	movl	$4, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	movl	$6, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_5
## %bb.3:
	leaq	L_.str.2(%rip), %rsi
	movq	%rbx, %rdi
	movl	$2, %edx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	leaq	L_.str.3(%rip), %rsi
	movq	%rbx, %rdi
	movl	$3, %edx
	callq	_strncmp
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	jne	LBB0_7
LBB0_5:
	movq	_VGA_RSRC_LEGACY_IO@GOTPCREL(%rip), %rcx
	movq	_VGA_RSRC_LEGACY_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	(%rcx), %eax
	jmp	LBB0_6
LBB0_1:
	movq	_VGA_RSRC_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_6:
	movl	%eax, (%r14)
	movl	$1, %eax
LBB0_7:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"none"

	.comm	_VGA_RSRC_NONE,4,2              ## @VGA_RSRC_NONE
L_.str.1:                               ## @.str.1
	.asciz	"io+mem"

L_.str.2:                               ## @.str.2
	.asciz	"io"

L_.str.3:                               ## @.str.3
	.asciz	"mem"

	.comm	_VGA_RSRC_LEGACY_IO,4,2         ## @VGA_RSRC_LEGACY_IO
	.comm	_VGA_RSRC_LEGACY_MEM,4,2        ## @VGA_RSRC_LEGACY_MEM
	.no_dead_strip	_vga_str_to_iostate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vga_str_to_iostate
_vga_str_to_iostate:                    ; @vga_str_to_iostate
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x2
	mov	x20, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w2, #4
	bl	_strncmp
	cbz	x0, LBB0_6
; %bb.1:
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	w2, #6
	bl	_strncmp
	cbz	x0, LBB0_5
; %bb.2:
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	mov	w2, #2
	bl	_strncmp
	cbz	x0, LBB0_5
; %bb.3:
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	mov	w2, #3
	bl	_strncmp
	cbz	x0, LBB0_5
; %bb.4:
	mov	w0, #0
	b	LBB0_8
LBB0_5:
Lloh8:
	adrp	x8, _VGA_RSRC_LEGACY_IO@GOTPAGE
Lloh9:
	ldr	x8, [x8, _VGA_RSRC_LEGACY_IO@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
Lloh11:
	adrp	x9, _VGA_RSRC_LEGACY_MEM@GOTPAGE
Lloh12:
	ldr	x9, [x9, _VGA_RSRC_LEGACY_MEM@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	orr	w8, w9, w8
	b	LBB0_7
LBB0_6:
Lloh14:
	adrp	x8, _VGA_RSRC_NONE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _VGA_RSRC_NONE@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
LBB0_7:
	str	w8, [x19]
	mov	w0, #1
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"none"

	.comm	_VGA_RSRC_NONE,4,2              ; @VGA_RSRC_NONE
l_.str.1:                               ; @.str.1
	.asciz	"io+mem"

l_.str.2:                               ; @.str.2
	.asciz	"io"

l_.str.3:                               ; @.str.3
	.asciz	"mem"

	.comm	_VGA_RSRC_LEGACY_IO,4,2         ; @VGA_RSRC_LEGACY_IO
	.comm	_VGA_RSRC_LEGACY_MEM,4,2        ; @VGA_RSRC_LEGACY_MEM
	.no_dead_strip	_vga_str_to_iostate
.subsections_via_symbols
