	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pms_i2c_stat
_pms_i2c_stat:                          ## @pms_i2c_stat
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %r15d
	movq	_io_port@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movl	$40, %edi
	callq	_outb
	xorl	%ebx, %ebx
	movq	_data_port@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	callq	_inb
	testb	$1, %al
	jne	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	incl	%ebx
	cmpl	$257, %ebx                      ## imm = 0x101
	jne	LBB0_1
## %bb.3:
	movl	$257, %ebx                      ## imm = 0x101
LBB0_4:
	addl	$-256, %ebx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	callq	_inb
	testb	$1, %al
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	leal	1(%rbx), %eax
	testl	%ebx, %ebx
	movl	%eax, %ebx
	jne	LBB0_5
LBB0_7:
	movl	(%r14), %esi
	movl	%r15d, %edi
	callq	_outb
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	callq	_inb
	testb	$1, %al
	jne	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	incl	%ebx
	cmpl	$257, %ebx                      ## imm = 0x101
	jne	LBB0_8
## %bb.10:
	movl	$257, %ebx                      ## imm = 0x101
LBB0_11:
	addl	$-256, %ebx
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	callq	_inb
	testb	$1, %al
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	leal	1(%rbx), %eax
	testl	%ebx, %ebx
	movl	%eax, %ebx
	jne	LBB0_12
LBB0_14:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.15:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.16:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.17:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.18:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.19:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.20:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.21:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.22:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.23:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.24:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.25:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.26:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.27:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.28:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.29:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.30:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.31:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.32:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.33:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.34:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.35:
	testl	%eax, %eax
	jne	LBB0_38
## %bb.36:
	movl	(%r12), %edi
	callq	_inb
	xorl	%ecx, %ecx
	testb	$1, %al
	movl	$10, %edx
	cmovnel	%ecx, %edx
	testb	$2, %al
	movl	$1, %eax
	cmovel	%edx, %eax
	cmpl	$10, %eax
	je	LBB0_39
## %bb.37:
	testl	%eax, %eax
	jne	LBB0_38
LBB0_39:
	movl	(%r14), %esi
	movl	$41, %edi
	callq	_outb
	movl	(%r12), %edi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_inb                            ## TAILCALL
LBB0_38:
	movl	$-1, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_io_port,4,2                    ## @io_port
	.comm	_data_port,4,2                  ## @data_port
	.no_dead_strip	_pms_i2c_stat
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pms_i2c_stat
_pms_i2c_stat:                          ; @pms_i2c_stat
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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, x0
Lloh0:
	adrp	x20, _io_port@GOTPAGE
Lloh1:
	ldr	x20, [x20, _io_port@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	w0, #40
	bl	_outb
	mov	w22, #0
Lloh2:
	adrp	x21, _data_port@GOTPAGE
Lloh3:
	ldr	x21, [x21, _data_port@GOTPAGEOFF]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x21]
	bl	_inb
	tbnz	w0, #0, LBB0_3
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	add	w22, w22, #1
	cmp	w22, #257
	b.ne	LBB0_1
LBB0_3:
	sub	w8, w22, #256
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x22, x8
	ldr	w0, [x21]
	bl	_inb
	tbz	w0, #0, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	w8, w22, #1
	cbnz	w22, LBB0_4
LBB0_6:
	ldr	w1, [x20]
	mov	x0, x19
	bl	_outb
	mov	w19, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x21]
	bl	_inb
	tbnz	w0, #0, LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	add	w19, w19, #1
	cmp	w19, #257
	b.ne	LBB0_7
LBB0_9:
	sub	w8, w19, #256
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	mov	x19, x8
	ldr	w0, [x21]
	bl	_inb
	tbz	w0, #0, LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	add	w8, w19, #1
	cbnz	w19, LBB0_10
LBB0_12:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.13:
	cbnz	w8, LBB0_37
; %bb.14:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.15:
	cbnz	w8, LBB0_37
; %bb.16:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.17:
	cbnz	w8, LBB0_37
; %bb.18:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.19:
	cbnz	w8, LBB0_37
; %bb.20:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.21:
	cbnz	w8, LBB0_37
; %bb.22:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.23:
	cbnz	w8, LBB0_37
; %bb.24:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.25:
	cbnz	w8, LBB0_37
; %bb.26:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.27:
	cbnz	w8, LBB0_37
; %bb.28:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.29:
	cbnz	w8, LBB0_37
; %bb.30:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.31:
	cbnz	w8, LBB0_37
; %bb.32:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.33:
	cbnz	w8, LBB0_37
; %bb.34:
	ldr	w0, [x21]
	bl	_inb
	tst	w0, #0x1
	mov	w8, #10
	csel	w8, w8, wzr, eq
	tst	w0, #0x2
	csinc	w8, w8, wzr, eq
	cmp	w8, #10
	b.eq	LBB0_36
; %bb.35:
	cbnz	w8, LBB0_37
LBB0_36:
	ldr	w1, [x20]
	mov	w0, #41
	bl	_outb
	ldr	w0, [x21]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_inb
LBB0_37:
	mov	w0, #-1
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_io_port,4,2                    ; @io_port
	.comm	_data_port,4,2                  ; @data_port
	.no_dead_strip	_pms_i2c_stat
.subsections_via_symbols
