	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function parse_psr
_parse_psr:                             ## @parse_psr
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r12
	movslq	(%rdi), %rbx
	movq	_BDB_PSR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_find_section
	testq	%rax, %rax
	je	LBB0_23
## %bb.1:
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	8(%rax), %r13
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	leaq	(%rbx,%rbx,2), %r14
	movl	20(%r13,%r14,8), %eax
	movl	%eax, 28(%r12)
	movl	16(%r13,%r14,8), %eax
	movl	%eax, 24(%r12)
	movl	(%r13,%r14,8), %eax
	cmpl	$15, %eax
	movl	$15, %ecx
	cmovll	%eax, %ecx
	xorl	%eax, %eax
	testl	%ecx, %ecx
	cmovgl	%ecx, %eax
	movl	%eax, 4(%r12)
	movl	4(%r13,%r14,8), %esi
	cmpq	$3, %rsi
	ja	LBB0_8
## %bb.2:
	leaq	LJTI0_0(%rip), %rax
	movslq	(%rax,%rsi,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_3:
	movq	_PSR_0_LINES_TO_WAIT@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_23:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DRM_DEBUG_KMS                  ## TAILCALL
LBB0_8:
	leaq	L_.str.1(%rip), %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%eax, %eax
	callq	_DRM_DEBUG_KMS
	cmpl	$205, (%r15)
	jge	LBB0_10
	jmp	LBB0_18
LBB0_5:
	movq	_PSR_1_LINE_TO_WAIT@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_6:
	movq	_PSR_4_LINES_TO_WAIT@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_7:
	movq	_PSR_8_LINES_TO_WAIT@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %eax
	movl	%eax, 20(%r12)
	cmpl	$205, (%r15)
	jl	LBB0_18
LBB0_10:
	movq	%r12, %rdi
	callq	_IS_GEN9_BC
	testq	%rax, %rax
	jne	LBB0_13
## %bb.11:
	movq	%r12, %rdi
	callq	_IS_GEMINILAKE
	testq	%rax, %rax
	jne	LBB0_13
## %bb.12:
	movq	%r12, %rdi
	callq	_INTEL_GEN
	cmpl	$10, %eax
	jl	LBB0_18
LBB0_13:
	movslq	8(%r13,%r14,8), %rsi
	leaq	l_switch.table.parse_psr.4(%rip), %rbx
	cmpq	$4, %rsi
	jae	LBB0_14
## %bb.15:
	movl	(%rbx,%rsi,4), %eax
	jmp	LBB0_16
LBB0_18:
	imull	$100, 8(%r13,%r14,8), %eax
	movl	%eax, 8(%r12)
	imull	$100, 12(%r13,%r14,8), %eax
	jmp	LBB0_20
LBB0_14:
	leaq	L_.str.2(%rip), %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%eax, %eax
	callq	_DRM_DEBUG_KMS
	movl	$2500, %eax                     ## imm = 0x9C4
LBB0_16:
	movl	%eax, 8(%r12)
	movslq	12(%r13,%r14,8), %rsi
	cmpq	$4, %rsi
	jae	LBB0_17
## %bb.19:
	movl	(%rbx,%rsi,4), %eax
	jmp	LBB0_20
LBB0_17:
	leaq	L_.str.3(%rip), %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%eax, %eax
	callq	_DRM_DEBUG_KMS
	movl	$2500, %eax                     ## imm = 0x9C4
LBB0_20:
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, 12(%r12)
	cmpl	$226, (%r15)
	jl	LBB0_22
## %bb.21:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %eax
	addl	%ecx, %ecx
                                        ## kill: def $cl killed $cl killed $rcx
	sarl	%cl, %eax
	andl	$3, %eax
	leaq	L_switch.table.parse_psr.5(%rip), %rcx
	movl	(%rcx,%rax,4), %eax
LBB0_22:
	movl	%eax, 16(%r12)
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
LJTI0_0:
	.long	L0_0_set_3
	.long	L0_0_set_5
	.long	L0_0_set_6
	.long	L0_0_set_7
	.end_data_region
                                        ## -- End function
	.comm	_BDB_PSR,4,2                    ## @BDB_PSR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No PSR BDB found.\n"

	.comm	_PSR_0_LINES_TO_WAIT,4,2        ## @PSR_0_LINES_TO_WAIT
	.comm	_PSR_1_LINE_TO_WAIT,4,2         ## @PSR_1_LINE_TO_WAIT
	.comm	_PSR_4_LINES_TO_WAIT,4,2        ## @PSR_4_LINES_TO_WAIT
	.comm	_PSR_8_LINES_TO_WAIT,4,2        ## @PSR_8_LINES_TO_WAIT
L_.str.1:                               ## @.str.1
	.asciz	"VBT has unknown PSR lines to wait %u\n"

L_.str.2:                               ## @.str.2
	.asciz	"VBT tp1 wakeup time value %d is outside range[0-3], defaulting to max value 2500us\n"

L_.str.3:                               ## @.str.3
	.asciz	"VBT tp2_tp3 wakeup time value %d is outside range[0-3], defaulting to max value 2500us\n"

	.no_dead_strip	_parse_psr
	.section	__TEXT,__const
	.p2align	2                               ## @switch.table.parse_psr.4
l_switch.table.parse_psr.4:
	.long	500                             ## 0x1f4
	.long	100                             ## 0x64
	.long	2500                            ## 0x9c4
	.long	0                               ## 0x0

	.section	__TEXT,__literal16,16byte_literals
	.p2align	2                               ## @switch.table.parse_psr.5
L_switch.table.parse_psr.5:
	.long	500                             ## 0x1f4
	.long	100                             ## 0x64
	.long	2500                            ## 0x9c4
	.long	50                              ## 0x32

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function parse_psr
_parse_psr:                             ; @parse_psr
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x20, x1
	mov	x19, x0
	ldrsw	x22, [x0]
Lloh0:
	adrp	x8, _BDB_PSR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BDB_PSR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_find_section
	cbz	x0, LBB0_4
; %bb.1:
	mov	x21, x0
	ldr	x23, [x0, #8]
	mov	w8, #24
	madd	x8, x22, x8, x23
	ldr	d0, [x8, #16]
	str	d0, [x19, #24]
	mov	w9, #15
	ldp	w10, w8, [x8]
	cmp	w10, #15
	csel	w9, w10, w9, lt
	cmp	w9, #0
	csel	w9, w9, wzr, gt
	str	w9, [x19, #4]
	cmp	w8, #3
	b.hi	LBB0_5
; %bb.2:
Lloh3:
	adrp	x9, lJTI0_0@PAGE
Lloh4:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_3
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_3:
Lloh5:
	adrp	x8, _PSR_0_LINES_TO_WAIT@GOTPAGE
Lloh6:
	ldr	x8, [x8, _PSR_0_LINES_TO_WAIT@GOTPAGEOFF]
	b	LBB0_9
LBB0_4:
Lloh7:
	adrp	x0, l_.str@PAGE
Lloh8:
	add	x0, x0, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	b	_DRM_DEBUG_KMS
LBB0_5:
                                        ; kill: def $w8 killed $w8 killed $x8 def $x8
	str	x8, [sp]
Lloh9:
	adrp	x0, l_.str.1@PAGE
Lloh10:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_DEBUG_KMS
	b	LBB0_10
LBB0_6:
Lloh11:
	adrp	x8, _PSR_1_LINE_TO_WAIT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _PSR_1_LINE_TO_WAIT@GOTPAGEOFF]
	b	LBB0_9
LBB0_7:
Lloh13:
	adrp	x8, _PSR_4_LINES_TO_WAIT@GOTPAGE
Lloh14:
	ldr	x8, [x8, _PSR_4_LINES_TO_WAIT@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh15:
	adrp	x8, _PSR_8_LINES_TO_WAIT@GOTPAGE
Lloh16:
	ldr	x8, [x8, _PSR_8_LINES_TO_WAIT@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	str	w8, [x19, #20]
LBB0_10:
	ldr	w8, [x20]
	cmp	w8, #205
	b.lt	LBB0_16
; %bb.11:
	mov	x0, x19
	bl	_IS_GEN9_BC
	cbnz	x0, LBB0_14
; %bb.12:
	mov	x0, x19
	bl	_IS_GEMINILAKE
	cbnz	x0, LBB0_14
; %bb.13:
	mov	x0, x19
	bl	_INTEL_GEN
	cmp	w0, #10
	b.lt	LBB0_16
LBB0_14:
	mov	w8, #24
	madd	x8, x22, x8, x23
	ldrsw	x8, [x8, #8]
Lloh17:
	adrp	x24, l_switch.table.parse_psr.4@PAGE
Lloh18:
	add	x24, x24, l_switch.table.parse_psr.4@PAGEOFF
	cmp	w8, #4
	b.hs	LBB0_17
; %bb.15:
	ldr	w8, [x24, x8, lsl #2]
	b	LBB0_18
LBB0_16:
	mov	w8, #24
	madd	x8, x22, x8, x23
	mov	w9, #100
	ldp	w10, w8, [x8, #8]
	mul	w10, w10, w9
	str	w10, [x19, #8]
	mul	w8, w8, w9
	b	LBB0_21
LBB0_17:
	str	x8, [sp]
Lloh19:
	adrp	x0, l_.str.2@PAGE
Lloh20:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DRM_DEBUG_KMS
	mov	w8, #2500
LBB0_18:
	str	w8, [x19, #8]
	mov	w8, #24
	madd	x8, x22, x8, x23
	ldrsw	x8, [x8, #12]
	cmp	w8, #4
	b.hs	LBB0_20
; %bb.19:
	ldr	w8, [x24, x8, lsl #2]
	b	LBB0_21
LBB0_20:
	str	x8, [sp]
Lloh21:
	adrp	x0, l_.str.3@PAGE
Lloh22:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_DRM_DEBUG_KMS
	mov	w8, #2500
LBB0_21:
	str	w8, [x19, #12]
	ldr	w9, [x20]
	cmp	w9, #226
	b.lt	LBB0_23
; %bb.22:
	ldr	w8, [x21]
	lsl	w9, w22, #1
	asr	w8, w8, w9
	and	w8, w8, #0x3
Lloh23:
	adrp	x9, l_switch.table.parse_psr.5@PAGE
Lloh24:
	add	x9, x9, l_switch.table.parse_psr.5@PAGEOFF
	ldr	w8, [x9, w8, uxtw #2]
LBB0_23:
	str	w8, [x19, #16]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_3)>>2
	.byte	(LBB0_6-LBB0_3)>>2
	.byte	(LBB0_7-LBB0_3)>>2
	.byte	(LBB0_8-LBB0_3)>>2
                                        ; -- End function
	.comm	_BDB_PSR,4,2                    ; @BDB_PSR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No PSR BDB found.\n"

	.comm	_PSR_0_LINES_TO_WAIT,4,2        ; @PSR_0_LINES_TO_WAIT
	.comm	_PSR_1_LINE_TO_WAIT,4,2         ; @PSR_1_LINE_TO_WAIT
	.comm	_PSR_4_LINES_TO_WAIT,4,2        ; @PSR_4_LINES_TO_WAIT
	.comm	_PSR_8_LINES_TO_WAIT,4,2        ; @PSR_8_LINES_TO_WAIT
l_.str.1:                               ; @.str.1
	.asciz	"VBT has unknown PSR lines to wait %u\n"

l_.str.2:                               ; @.str.2
	.asciz	"VBT tp1 wakeup time value %d is outside range[0-3], defaulting to max value 2500us\n"

l_.str.3:                               ; @.str.3
	.asciz	"VBT tp2_tp3 wakeup time value %d is outside range[0-3], defaulting to max value 2500us\n"

	.no_dead_strip	_parse_psr
	.section	__TEXT,__const
	.p2align	2                               ; @switch.table.parse_psr.4
l_switch.table.parse_psr.4:
	.long	500                             ; 0x1f4
	.long	100                             ; 0x64
	.long	2500                            ; 0x9c4
	.long	0                               ; 0x0

	.section	__TEXT,__literal16,16byte_literals
	.p2align	2                               ; @switch.table.parse_psr.5
l_switch.table.parse_psr.5:
	.long	500                             ; 0x1f4
	.long	100                             ; 0x64
	.long	2500                            ; 0x9c4
	.long	50                              ; 0x32

.subsections_via_symbols
