	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sdt_load_devmem                ## -- Begin function sdt_load_devmem
	.p2align	4, 0x90
_sdt_load_devmem:                       ## @sdt_load_devmem
	.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
	xorl	%eax, %eax
	callq	_acpi_find_rsd_ptr
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	callq	_errx
LBB0_2:
	movq	_tflag@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_4
## %bb.3:
	movq	%rbx, %rdi
	callq	_acpi_print_rsd_ptr
LBB0_4:
	cmpl	$1, (%rbx)
	jg	LBB0_6
## %bb.5:
	movl	8(%rbx), %edi
	callq	_acpi_map_sdt
	movq	%rax, %rbx
	movl	4(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	$4, %edx
	callq	_memcmp
	leaq	L_.str.2(%rip), %r14
	testq	%rax, %rax
	jne	LBB0_9
	jmp	LBB0_8
LBB0_6:
	movl	4(%rbx), %edi
	callq	_acpi_map_sdt
	movq	%rax, %rbx
	movl	4(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	movl	$4, %edx
	callq	_memcmp
	leaq	L_.str.4(%rip), %r14
	testq	%rax, %rax
	jne	LBB0_9
LBB0_8:
	movl	(%rbx), %esi
	movq	%rbx, %rdi
	callq	_acpi_checksum
	testq	%rax, %rax
	je	LBB0_10
LBB0_9:
	movl	$1, %edi
	movq	%r14, %rsi
	callq	_errx
LBB0_10:
	movq	_addr_size@GOTPCREL(%rip), %rax
	movl	$4, (%rax)
	movq	%rbx, %rax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Can't find ACPI information"

	.comm	_tflag,8,3                      ## @tflag
L_.str.1:                               ## @.str.1
	.asciz	"RSDT"

L_.str.2:                               ## @.str.2
	.asciz	"RSDT is corrupted"

	.comm	_addr_size,4,2                  ## @addr_size
L_.str.3:                               ## @.str.3
	.asciz	"XSDT"

L_.str.4:                               ## @.str.4
	.asciz	"XSDT is corrupted"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sdt_load_devmem                ; -- Begin function sdt_load_devmem
	.p2align	2
_sdt_load_devmem:                       ; @sdt_load_devmem
	.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
	bl	_acpi_find_rsd_ptr
	mov	x19, x0
	cbnz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_errx
LBB0_2:
Lloh2:
	adrp	x8, _tflag@GOTPAGE
Lloh3:
	ldr	x8, [x8, _tflag@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	cbz	x8, LBB0_4
; %bb.3:
	mov	x0, x19
	bl	_acpi_print_rsd_ptr
LBB0_4:
	ldr	w8, [x19]
	cmp	w8, #1
	b.gt	LBB0_8
; %bb.5:
	ldr	w0, [x19, #8]
	bl	_acpi_map_sdt
	mov	x19, x0
	ldr	w0, [x0, #4]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w2, #4
	bl	_memcmp
	cbnz	x0, LBB0_7
; %bb.6:
	ldr	w1, [x19]
	mov	x0, x19
	bl	_acpi_checksum
	cbz	x0, LBB0_12
LBB0_7:
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_11
LBB0_8:
	ldr	w0, [x19, #4]
	bl	_acpi_map_sdt
	mov	x19, x0
	ldr	w0, [x0, #4]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w2, #4
	bl	_memcmp
	cbnz	x0, LBB0_10
; %bb.9:
	ldr	w1, [x19]
	mov	x0, x19
	bl	_acpi_checksum
	cbz	x0, LBB0_12
LBB0_10:
Lloh11:
	adrp	x1, l_.str.4@PAGE
Lloh12:
	add	x1, x1, l_.str.4@PAGEOFF
LBB0_11:
	mov	w0, #1
	bl	_errx
LBB0_12:
Lloh13:
	adrp	x8, _addr_size@GOTPAGE
Lloh14:
	ldr	x8, [x8, _addr_size@GOTPAGEOFF]
	mov	w9, #4
Lloh15:
	str	w9, [x8]
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotStr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Can't find ACPI information"

	.comm	_tflag,8,3                      ; @tflag
l_.str.1:                               ; @.str.1
	.asciz	"RSDT"

l_.str.2:                               ; @.str.2
	.asciz	"RSDT is corrupted"

	.comm	_addr_size,4,2                  ; @addr_size
l_.str.3:                               ; @.str.3
	.asciz	"XSDT"

l_.str.4:                               ; @.str.4
	.asciz	"XSDT is corrupted"

.subsections_via_symbols
