	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sis_idle                       ## -- Begin function sis_idle
	.p2align	4, 0x90
_sis_idle:                              ## @sis_idle
	.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
	movq	(%rdi), %r15
	cmpl	$0, (%r15)
	jne	LBB0_16
## %bb.1:
	cmpq	$0, 16(%r15)
	jne	LBB0_4
## %bb.2:
	callq	_sis_reg_init
	movq	%rax, 16(%r15)
	testq	%rax, %rax
	je	LBB0_3
LBB0_4:
	movq	8(%r15), %rax
	movq	_SIS_CHIP_315@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_16
## %bb.5:
	movq	_jiffies@GOTPCREL(%rip), %r12
	movslq	(%r12), %rax
	movq	_DRM_HZ@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rcx
	leaq	(%rcx,%rcx,2), %r14
	addq	%rax, %r14
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	$34252, %edi                    ## imm = 0x85CC
	callq	_SIS_READ
	movl	%eax, %ebx
	movl	(%r12), %edi
	movq	%r14, %rsi
	callq	_time_after_eq
	testq	%rax, %rax
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	testl	%ebx, %ebx
	jns	LBB0_6
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movl	$34252, %edi                    ## imm = 0x85CC
	callq	_SIS_READ
	movl	%eax, %ebx
	movl	(%r12), %edi
	movq	%r14, %rsi
	callq	_time_after_eq
	testq	%rax, %rax
	jne	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	testl	%ebx, %ebx
	jns	LBB0_8
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movl	$34252, %edi                    ## imm = 0x85CC
	callq	_SIS_READ
	movl	%eax, %ebx
	movl	(%r12), %edi
	movq	%r14, %rsi
	callq	_time_after_eq
	testq	%rax, %rax
	jne	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	testl	%ebx, %ebx
	jns	LBB0_10
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	$34252, %edi                    ## imm = 0x85CC
	callq	_SIS_READ
	movl	%eax, %ebx
	movl	(%r12), %edi
	movq	%r14, %rsi
	callq	_time_after_eq
	testq	%rax, %rax
	jne	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	testl	%ebx, %ebx
	jns	LBB0_12
LBB0_14:
	movl	(%r12), %edi
	movq	%r14, %rsi
	callq	_time_after_eq
	testq	%rax, %rax
	je	LBB0_16
## %bb.15:
	leaq	L_.str.1(%rip), %rdi
	callq	_DRM_ERROR
	movl	$1, (%r15)
	jmp	LBB0_16
LBB0_3:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_ERROR
LBB0_16:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Could not find register map.\n"

	.comm	_SIS_CHIP_315,8,3               ## @SIS_CHIP_315
	.comm	_jiffies,4,2                    ## @jiffies
	.comm	_DRM_HZ,4,2                     ## @DRM_HZ
L_.str.1:                               ## @.str.1
	.asciz	"Graphics engine idle timeout. Disabling idle check\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sis_idle                       ; -- Begin function sis_idle
	.p2align	2
_sis_idle:                              ; @sis_idle
	.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
	ldr	x21, [x0]
	ldr	w8, [x21]
	cbnz	w8, LBB0_16
; %bb.1:
	ldr	x8, [x21, #16]
	cbnz	x8, LBB0_3
; %bb.2:
	bl	_sis_reg_init
	str	x0, [x21, #16]
	cbz	x0, LBB0_15
LBB0_3:
	ldr	x8, [x21, #8]
Lloh0:
	adrp	x9, _SIS_CHIP_315@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SIS_CHIP_315@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_16
; %bb.4:
Lloh3:
	adrp	x22, _jiffies@GOTPAGE
Lloh4:
	ldr	x22, [x22, _jiffies@GOTPAGEOFF]
	ldrsw	x8, [x22]
Lloh5:
	adrp	x9, _DRM_HZ@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DRM_HZ@GOTPAGEOFF]
Lloh7:
	ldrsw	x9, [x9]
	add	x9, x9, x9, lsl #1
	add	x19, x9, x8
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	w0, #34252
	bl	_SIS_READ
	mov	x20, x0
	ldr	w0, [x22]
	mov	x1, x19
	bl	_time_after_eq
	cbnz	x0, LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	tbz	w20, #31, LBB0_5
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	mov	w0, #34252
	bl	_SIS_READ
	mov	x20, x0
	ldr	w0, [x22]
	mov	x1, x19
	bl	_time_after_eq
	cbnz	x0, LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	tbz	w20, #31, LBB0_7
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	mov	w0, #34252
	bl	_SIS_READ
	mov	x20, x0
	ldr	w0, [x22]
	mov	x1, x19
	bl	_time_after_eq
	cbnz	x0, LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	tbz	w20, #31, LBB0_9
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	mov	w0, #34252
	bl	_SIS_READ
	mov	x20, x0
	ldr	w0, [x22]
	mov	x1, x19
	bl	_time_after_eq
	cbnz	x0, LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	tbz	w20, #31, LBB0_11
LBB0_13:
	ldr	w0, [x22]
	mov	x1, x19
	bl	_time_after_eq
	cbz	x0, LBB0_16
; %bb.14:
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_ERROR
	mov	w8, #1
	str	w8, [x21]
	b	LBB0_16
LBB0_15:
Lloh10:
	adrp	x0, l_.str@PAGE
Lloh11:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
LBB0_16:
	mov	w0, #0
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Could not find register map.\n"

	.comm	_SIS_CHIP_315,8,3               ; @SIS_CHIP_315
	.comm	_jiffies,4,2                    ; @jiffies
	.comm	_DRM_HZ,4,2                     ; @DRM_HZ
l_.str.1:                               ; @.str.1
	.asciz	"Graphics engine idle timeout. Disabling idle check\n"

.subsections_via_symbols
