	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wl18xx_top_reg_read            ## -- Begin function wl18xx_top_reg_read
	.p2align	4, 0x90
_wl18xx_top_reg_read:                   ## @wl18xx_top_reg_read
	.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
	movq	%rdx, %r14
	movl	%esi, %ebx
	movq	%rdi, %r15
	movl	$0, -28(%rbp)
	movl	%esi, %eax
	shrl	$31, %eax
	addl	%esi, %eax
	andl	$-2, %eax
	movl	%esi, %edi
	subl	%eax, %edi
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_10
LBB0_2:
	testb	$3, %bl
	je	LBB0_3
## %bb.6:
	addl	$-2, %ebx
	leaq	-28(%rbp), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_wlcore_read32
	testq	%r14, %r14
	je	LBB0_10
## %bb.7:
	testl	%eax, %eax
	js	LBB0_10
## %bb.8:
	movzwl	-26(%rbp), %ecx
	jmp	LBB0_9
LBB0_3:
	leaq	-28(%rbp), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_wlcore_read32
	testq	%r14, %r14
	je	LBB0_10
## %bb.4:
	testl	%eax, %eax
	js	LBB0_10
## %bb.5:
	movzwl	-28(%rbp), %ecx
LBB0_9:
	movl	%ecx, (%r14)
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wl18xx_top_reg_read            ; -- Begin function wl18xx_top_reg_read
	.p2align	2
_wl18xx_top_reg_read:                   ; @wl18xx_top_reg_read
	.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
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
	str	wzr, [sp, #12]
	and	w8, w1, #0x1
	cmp	w1, #0
	cneg	w0, w8, lt
	bl	_WARN_ON
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_10
LBB0_2:
	tst	w21, #0x3
	b.eq	LBB0_6
; %bb.3:
	sub	w1, w21, #2
	add	x2, sp, #12
	mov	x0, x20
	bl	_wlcore_read32
	cbz	x19, LBB0_10
; %bb.4:
	tbnz	w0, #31, LBB0_10
; %bb.5:
	ldrh	w8, [sp, #14]
	b	LBB0_9
LBB0_6:
	add	x2, sp, #12
	mov	x0, x20
	mov	x1, x21
	bl	_wlcore_read32
	cbz	x19, LBB0_10
; %bb.7:
	tbnz	w0, #31, LBB0_10
; %bb.8:
	ldrh	w8, [sp, #12]
LBB0_9:
	str	w8, [x19]
LBB0_10:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
.subsections_via_symbols
