	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pcc_cmd
_pcc_cmd:                               ## @pcc_cmd
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_doorbell@GOTPCREL(%rip), %rbx
	leaq	-36(%rbp), %rdi
	movq	%rbx, %rsi
	callq	_acpi_read
	movq	_doorbell_preserve@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	andl	-36(%rbp), %edi
	movq	_doorbell_write@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_acpi_write
	movq	_POLL_LOOPS@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_4
## %bb.1:
	xorl	%ebx, %ebx
	movq	_pcch_hdr@GOTPCREL(%rip), %r15
	movq	_CMD_COMPLETE@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rdi
	callq	_ioread16
	testl	%eax, (%r12)
	jne	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_3 Depth=1
	incl	%ebx
	cmpl	(%r14), %ebx
	jl	LBB0_3
LBB0_4:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_doorbell,4,2                   ## @doorbell
	.comm	_doorbell_preserve,4,2          ## @doorbell_preserve
	.comm	_doorbell_write,4,2             ## @doorbell_write
	.comm	_POLL_LOOPS,4,2                 ## @POLL_LOOPS
	.comm	_pcch_hdr,8,3                   ## @pcch_hdr
	.comm	_CMD_COMPLETE,4,2               ## @CMD_COMPLETE
	.no_dead_strip	_pcc_cmd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pcc_cmd
_pcc_cmd:                               ; @pcc_cmd
	.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
Lloh0:
	adrp	x19, _doorbell@GOTPAGE
Lloh1:
	ldr	x19, [x19, _doorbell@GOTPAGEOFF]
	add	x0, sp, #12
	mov	x1, x19
	bl	_acpi_read
	ldr	w8, [sp, #12]
Lloh2:
	adrp	x9, _doorbell_preserve@GOTPAGE
Lloh3:
	ldr	x9, [x9, _doorbell_preserve@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	and	w8, w9, w8
Lloh5:
	adrp	x9, _doorbell_write@GOTPAGE
Lloh6:
	ldr	x9, [x9, _doorbell_write@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w0, w8, w9
	mov	x1, x19
	bl	_acpi_write
Lloh8:
	adrp	x19, _POLL_LOOPS@GOTPAGE
Lloh9:
	ldr	x19, [x19, _POLL_LOOPS@GOTPAGEOFF]
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_4
; %bb.1:
	mov	w20, #0
Lloh10:
	adrp	x21, _pcch_hdr@GOTPAGE
Lloh11:
	ldr	x21, [x21, _pcch_hdr@GOTPAGEOFF]
Lloh12:
	adrp	x22, _CMD_COMPLETE@GOTPAGE
Lloh13:
	ldr	x22, [x22, _CMD_COMPLETE@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x21]
	bl	_ioread16
	ldr	w8, [x22]
	tst	w8, w0
	b.ne	LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	w20, w20, #1
	ldr	w8, [x19]
	cmp	w20, w8
	b.lt	LBB0_2
LBB0_4:
	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 AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_doorbell,4,2                   ; @doorbell
	.comm	_doorbell_preserve,4,2          ; @doorbell_preserve
	.comm	_doorbell_write,4,2             ; @doorbell_write
	.comm	_POLL_LOOPS,4,2                 ; @POLL_LOOPS
	.comm	_pcch_hdr,8,3                   ; @pcch_hdr
	.comm	_CMD_COMPLETE,4,2               ; @CMD_COMPLETE
	.no_dead_strip	_pcc_cmd
.subsections_via_symbols
