	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nv50_mem_timing_calc
_nv50_mem_timing_calc:                  ## @nv50_mem_timing_calc
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -48(%rbp)                  ## 8-byte Spill
	movq	%r8, %r13
	movl	%ecx, -60(%rbp)                 ## 4-byte Spill
	movq	%rdx, %r12
	movq	%rdi, %r14
	callq	_nouveau_dev
	movq	%rax, %rdi
	callq	_nouveau_fb
	movq	%rax, %r15
	movq	%r14, %rdi
	callq	_nouveau_drm
	movq	%rax, %rbx
	leaq	-56(%rbp), %rdx
	movq	%r14, %rdi
	movl	$80, %esi
	callq	_bit_table
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_18
LBB0_2:
	movq	%rbx, %r14
	movq	%r13, -80(%rbp)                 ## 8-byte Spill
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	movl	-60(%rbp), %edi                 ## 4-byte Reload
	movl	$22, %esi
	callq	_min
                                        ## kill: def $eax killed $eax def $rax
	xorl	%r15d, %r15d
	addl	$-19, %eax
	cmpl	$3, %eax
	movq	%rbx, -88(%rbp)                 ## 8-byte Spill
	ja	LBB0_3
## %bb.4:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rdx
	addq	%rcx, %rdx
	xorl	%eax, %eax
	xorl	%r13d, %r13d
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movq	%r12, %rbx
	jmpq	*%rdx
LBB0_5:
	movl	(%rbx), %r15d
LBB0_6:
	movl	%r15d, %eax
	movl	4(%rbx), %r15d
LBB0_7:
	movl	8(%rbx), %ecx
	testl	%ecx, %ecx
	jle	LBB0_9
## %bb.8:
	movl	%ecx, (%rsi)
LBB0_9:
	movl	%eax, %r13d
LBB0_10:
	movl	12(%rbx), %edi
	jmp	LBB0_11
LBB0_3:
	xorl	%r15d, %r15d
	movl	$1, %edi
	xorl	%r13d, %r13d
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movq	%r12, %rbx
LBB0_11:
	movl	16(%rbx), %eax
	movl	20(%rbx), %ecx
	shll	$24, %eax
	shll	$16, %ecx
	orl	%eax, %ecx
	movl	24(%rbx), %eax
	shll	$8, %eax
	orl	%ecx, %eax
	orl	28(%rbx), %eax
	movq	8(%rsi), %rcx
	movl	%eax, (%rcx)
	movl	(%rsi), %r14d
	addl	32(%r12), %r14d
	shll	$24, %r14d
	addl	$16777216, %r14d                ## imm = 0x1000000
	movl	$1, %esi
	callq	_max
	shll	$16, %eax
	orl	%r14d, %eax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rcx), %ecx
	addl	36(%r12), %ecx
	shll	$8, %ecx
	addl	$256, %ecx                      ## imm = 0x100
	orl	%eax, %ecx
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %rax
	movl	%ecx, 4(%rax)
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rcx), %ecx
	shll	$24, %ecx
	addl	$-16777216, %ecx                ## imm = 0xFF000000
	movl	40(%r12), %edx
	movl	44(%r12), %esi
	shll	$16, %edx
	shll	$8, %esi
	orl	%edx, %esi
	orl	%ecx, %esi
	orl	48(%r12), %esi
	movl	%esi, 8(%rax)
	movl	52(%r12), %ecx
	movl	%ecx, %edx
	shll	$8, %edx
	orl	%ecx, %edx
	movl	%edx, 16(%rax)
	movl	24(%r12), %ebx
	movl	44(%r12), %esi
	shll	$24, %ebx
	movl	48(%r12), %edi
	callq	_max
	movq	-48(%rbp), %r11                 ## 8-byte Reload
	shll	$16, %eax
	orl	%ebx, %eax
	orl	16(%r12), %eax
	movq	8(%r11), %rsi
	movl	%eax, 20(%rsi)
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	8(%rcx), %rdx
	movl	$-256, %r9d
	andl	32(%rdx), %r9d
	movl	%r9d, 32(%rsi)
	cmpl	$1, -56(%rbp)
	movl	56(%r12), %r8d
	jne	LBB0_16
## %bb.12:
	subl	(%r11), %r8d
	addl	$3, %r8d
	orl	4(%rsi), %r8d
	movl	%r8d, 4(%rsi)
	movl	56(%r12), %ecx
	movl	%ecx, %ebx
	shll	$24, %ebx
	addl	$335544320, %ebx                ## imm = 0x14000000
	decl	%ecx
	movl	%ecx, %r10d
	shll	$8, %r10d
	orl	%ecx, %r10d
	orl	%ebx, %r10d
	orl	$1441792, %r10d                 ## imm = 0x160000
	movl	%r10d, 12(%rsi)
	movzwl	18(%rdx), %ecx
	shll	$16, %ecx
	orl	%ecx, 16(%rsi)
	movl	(%r11), %ebx
	movl	%ebx, %ecx
	movl	56(%r12), %edx
	subl	%ebx, %edx
	shll	$16, %ebx
	movl	$3342336, %edi                  ## imm = 0x330000
	subl	%ebx, %edi
	shll	$8, %ecx
	orl	%edi, %ecx
	addl	$46, %edx
	orl	%ecx, %edx
	movl	%edx, 24(%rsi)
	movl	56(%r12), %ecx
	shll	$16, %ecx
	addl	$-65536, %ecx                   ## imm = 0xFFFF0000
	orl	$67109378, %ecx                 ## imm = 0x4000202
	movl	%ecx, 28(%rsi)
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	movq	(%rcx), %rdi
	movq	_NV_MEM_TYPE_DDR2@GOTPCREL(%rip), %rbx
	movl	56(%r12), %ecx
	shll	$8, %ecx
	cmpq	(%rbx), %rdi
	jne	LBB0_14
## %bb.13:
	addl	$768, %ecx                      ## imm = 0x300
	orl	%eax, %ecx
	movl	%ecx, 20(%rsi)
	movl	(%r11), %eax
	shll	$8, %eax
	addl	$-512, %eax                     ## imm = 0xFE00
	orl	%edx, %eax
	movl	%eax, 24(%rsi)
	movl	56(%r12), %eax
	addl	$-4, %eax
	jmp	LBB0_15
LBB0_16:
	subl	(%r11), %r8d
	addl	$5, %r8d
	orl	4(%rsi), %r8d
	movl	%r8d, 4(%rsi)
	movl	56(%r12), %r10d
	movl	%r10d, %ecx
	shll	$24, %ecx
	movzbl	14(%rdx), %edi
	shll	$16, %edi
	addl	%edi, %ecx
	addl	$805306368, %ecx                ## imm = 0x30000000
	movl	%r10d, %edi
	shll	$8, %edi
	addl	$2816, %edi                     ## imm = 0xB00
	decl	%r10d
	orl	%edi, %r10d
	orl	%ecx, %r10d
	movl	%r10d, 12(%rsi)
	shll	$24, %r15d
	shll	$16, %r13d
	orl	%r15d, %r13d
	orl	%r13d, 16(%rsi)
	movl	(%r11), %ecx
	shll	$8, %ecx
	addl	$1536, %ecx                     ## imm = 0x600
	orl	%eax, %ecx
	movl	%ecx, 20(%rsi)
	movl	56(%r12), %eax
	movl	%eax, %ecx
	shll	$16, %ecx
	addl	$5898240, %ecx                  ## imm = 0x5A0000
	movl	(%r11), %ebx
	movl	%ebx, %edi
	subl	%eax, %edi
	shll	$8, %edi
	addl	$1536, %edi                     ## imm = 0x600
	subl	%ebx, %eax
	addl	$80, %eax
	orl	%ecx, %eax
	orl	%edi, %eax
	movl	%eax, 24(%rsi)
	movl	28(%rdx), %eax
	movl	%eax, %ecx
	shrl	$24, %ecx
	andl	$-16777216, %eax                ## imm = 0xFF000000
	addl	56(%r12), %ecx
	shll	$16, %ecx
	addl	$-393216, %ecx                  ## imm = 0xFFFA0000
	orl	%eax, %ecx
	orl	$514, %ecx                      ## imm = 0x202
	movl	%ecx, 28(%rsi)
	jmp	LBB0_17
LBB0_14:
	addl	$512, %ecx                      ## imm = 0x200
	orl	%eax, %ecx
	movl	%ecx, 20(%rsi)
	movl	(%r11), %eax
	shll	$8, %eax
	orl	%edx, %eax
	movl	%eax, 24(%rsi)
	movl	56(%r12), %eax
	addl	$-2, %eax
LBB0_15:
	orl	%r9d, %eax
	movl	%eax, 32(%rsi)
LBB0_17:
	movl	16(%r11), %edx
	movl	(%rsi), %ecx
	movl	8(%rsi), %r9d
	movl	%r10d, (%rsp)
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	-88(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	xorl	%eax, %eax
	movq	%r11, %r15
	callq	_NV_DEBUG
	movq	8(%r15), %rax
	movl	16(%rax), %edx
	movl	20(%rax), %ecx
	movl	24(%rax), %r8d
	movl	28(%rax), %r9d
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_NV_DEBUG
	movq	8(%r15), %rax
	movl	32(%rax), %edx
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_NV_DEBUG
LBB0_18:
	movl	%ebx, %eax
	addq	$56, %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_10, LBB0_10-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
LJTI0_0:
	.long	L0_0_set_10
	.long	L0_0_set_7
	.long	L0_0_set_6
	.long	L0_0_set_5
	.end_data_region
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_NV_MEM_TYPE_DDR2,8,3           ## @NV_MEM_TYPE_DDR2
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Entry %d: 220: %08x %08x %08x %08x\n"

L_.str.1:                               ## @.str.1
	.asciz	"         230: %08x %08x %08x %08x\n"

L_.str.2:                               ## @.str.2
	.asciz	"         240: %08x\n"

	.no_dead_strip	_nv50_mem_timing_calc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nv50_mem_timing_calc
_nv50_mem_timing_calc:                  ; @nv50_mem_timing_calc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x5
	mov	x23, x4
	mov	x24, x3
	mov	x21, x2
	mov	x25, x0
	bl	_nouveau_dev
	bl	_nouveau_fb
	mov	x22, x0
	mov	x0, x25
	bl	_nouveau_drm
	mov	x20, x0
	add	x2, sp, #40
	mov	x0, x25
	mov	w1, #80
	bl	_bit_table
	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_17
LBB0_2:
	mov	x0, x24
	mov	w1, #22
	bl	_min
	mov	w24, #0
	sub	w8, w0, #19
	cmp	w8, #3
	b.hi	LBB0_9
; %bb.3:
Lloh3:
	adrp	x9, lJTI0_0@PAGE
Lloh4:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_4
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	mov	x25, x24
	br	x10
LBB0_4:
	ldr	w24, [x21]
LBB0_5:
	mov	x25, x24
	ldr	w24, [x21, #4]
LBB0_6:
	ldr	w8, [x21, #8]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.7:
	str	w8, [x19]
LBB0_8:
	ldr	w0, [x21, #12]
	b	LBB0_10
LBB0_9:
	mov	w0, #1
	mov	x25, x24
LBB0_10:
	ldp	w8, w9, [x21, #16]
	lsl	w9, w9, #16
	orr	w8, w9, w8, lsl #24
	ldp	w9, w10, [x21, #24]
	orr	w8, w8, w9, lsl #8
	orr	w8, w8, w10
	ldr	x9, [x19, #8]
	str	w8, [x9]
	ldr	w8, [x21, #32]
	ldr	w9, [x19]
	add	w8, w9, w8
	mov	w9, #16777216
	add	w26, w9, w8, lsl #24
	mov	w1, #1
	bl	_max
	orr	w8, w26, w0, lsl #16
	ldr	w9, [x21, #36]
	ldr	w10, [x19]
	add	w9, w10, w9
	lsl	w9, w9, #8
	add	w9, w9, #256
	orr	w8, w8, w9
	ldr	x9, [x19, #8]
	str	w8, [x9, #4]
	ldr	w8, [x19]
	mov	w10, #-16777216
	add	w8, w10, w8, lsl #24
	ldp	w10, w11, [x21, #40]
	orr	w8, w8, w10, lsl #16
	orr	w8, w8, w11, lsl #8
	ldr	w10, [x21, #48]
	orr	w8, w8, w10
	str	w8, [x9, #8]
	ldr	w8, [x21, #52]
	orr	w8, w8, w8, lsl #8
	str	w8, [x9, #16]
	ldr	w26, [x21, #24]
	ldp	w1, w0, [x21, #44]
	bl	_max
	lsl	w8, w0, #16
	orr	w8, w8, w26, lsl #24
	ldr	w9, [x21, #16]
	orr	w11, w8, w9
	ldr	x8, [x19, #8]
	str	w11, [x8, #20]
	ldr	x12, [x23, #8]
	ldr	w9, [x12, #32]
	and	w13, w9, #0xffffff00
	str	w13, [x8, #32]
	ldr	w10, [sp, #40]
	ldr	w9, [x21, #56]
	cmp	w10, #1
	b.ne	LBB0_13
; %bb.11:
	ldr	w10, [x19]
	sub	w9, w9, w10
	add	w9, w9, #3
	ldr	w10, [x8, #4]
	orr	w9, w10, w9
	str	w9, [x8, #4]
	ldr	w10, [x21, #56]
	mov	w14, #335544320
	add	w14, w14, w10, lsl #24
	sub	w10, w10, #1
	orr	w10, w10, w10, lsl #8
	orr	w10, w10, w14
	mov	w14, #1441792
	orr	w10, w10, w14
	str	w10, [x8, #12]
	ldrh	w12, [x12, #18]
	ldr	w14, [x8, #16]
	orr	w12, w14, w12, lsl #16
	str	w12, [x8, #16]
	ldr	w12, [x19]
	mov	w14, #3342336
	sub	w14, w14, w12, lsl #16
	orr	w14, w14, w12, lsl #8
	ldr	w15, [x21, #56]
	sub	w12, w15, w12
	add	w12, w12, #46
	orr	w12, w14, w12
	str	w12, [x8, #24]
	ldr	w14, [x21, #56]
	lsl	w14, w14, #16
	sub	w14, w14, #16, lsl #12          ; =65536
	mov	w15, #514
	movk	w15, #1024, lsl #16
	orr	w14, w14, w15
	str	w14, [x8, #28]
	ldr	x15, [x22]
Lloh5:
	adrp	x14, _NV_MEM_TYPE_DDR2@GOTPAGE
Lloh6:
	ldr	x14, [x14, _NV_MEM_TYPE_DDR2@GOTPAGEOFF]
Lloh7:
	ldr	x16, [x14]
	ldr	w14, [x21, #56]
	lsl	w14, w14, #8
	cmp	x15, x16
	b.ne	LBB0_14
; %bb.12:
	add	w14, w14, #768
	orr	w11, w14, w11
	str	w11, [x8, #20]
	ldr	w11, [x19]
	lsl	w11, w11, #8
	sub	w11, w11, #512
	orr	w11, w11, w12
	str	w11, [x8, #24]
	ldr	w11, [x21, #56]
	sub	w11, w11, #4
	b	LBB0_15
LBB0_13:
	ldr	w10, [x19]
	sub	w9, w9, w10
	add	w9, w9, #5
	ldr	w10, [x8, #4]
	orr	w9, w10, w9
	str	w9, [x8, #4]
	ldr	w10, [x21, #56]
	ldrb	w13, [x12, #14]
	lsl	w13, w13, #16
	bfi	w13, w10, #24, #8
	lsl	w14, w10, #8
	add	w14, w14, #2816
	sub	w10, w10, #1
	orr	w10, w14, w10
	mov	w14, #805306368
	add	w13, w13, w14
	orr	w10, w10, w13
	lsl	w13, w25, #16
	orr	w13, w13, w24, lsl #24
	ldr	w14, [x8, #16]
	orr	w13, w13, w14
	stp	w10, w13, [x8, #12]
	ldr	w13, [x19]
	lsl	w13, w13, #8
	add	w13, w13, #1536
	orr	w11, w13, w11
	str	w11, [x8, #20]
	ldr	w11, [x21, #56]
	lsl	w13, w11, #16
	add	w13, w13, #1440, lsl #12        ; =5898240
	ldr	w14, [x19]
	sub	w15, w14, w11
	lsl	w15, w15, #8
	add	w15, w15, #1536
	sub	w11, w11, w14
	add	w11, w11, #80
	orr	w11, w11, w13
	orr	w11, w11, w15
	str	w11, [x8, #24]
	ldr	w11, [x12, #28]
	and	w12, w11, #0xff000000
	ldr	w13, [x21, #56]
	add	w11, w13, w11, lsr #24
	lsl	w11, w11, #16
	sub	w11, w11, #96, lsl #12          ; =393216
	orr	w11, w12, w11
	mov	w12, #514
	orr	w11, w11, w12
	str	w11, [x8, #28]
	b	LBB0_16
LBB0_14:
	add	w14, w14, #512
	orr	w11, w14, w11
	str	w11, [x8, #20]
	ldr	w11, [x19]
	orr	w11, w12, w11, lsl #8
	str	w11, [x8, #24]
	ldr	w11, [x21, #56]
	sub	w11, w11, #2
LBB0_15:
	orr	w11, w11, w13
	str	w11, [x8, #32]
LBB0_16:
	ldr	w2, [x19, #16]
	ldr	w11, [x8]
	ldr	w8, [x8, #8]
	stp	x8, x10, [sp, #16]
	stp	x11, x9, [sp]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_NV_DEBUG
	ldr	x8, [x19, #8]
	ldp	w2, w9, [x8, #16]
	ldp	w10, w8, [x8, #24]
	stp	x10, x8, [sp, #8]
	str	x9, [sp]
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_NV_DEBUG
	ldr	x8, [x19, #8]
	ldr	w2, [x8, #32]
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_NV_DEBUG
	mov	w0, #0
LBB0_17:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_8-LBB0_4)>>2
	.byte	(LBB0_6-LBB0_4)>>2
	.byte	(LBB0_5-LBB0_4)>>2
	.byte	(LBB0_4-LBB0_4)>>2
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_NV_MEM_TYPE_DDR2,8,3           ; @NV_MEM_TYPE_DDR2
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Entry %d: 220: %08x %08x %08x %08x\n"

l_.str.1:                               ; @.str.1
	.asciz	"         230: %08x %08x %08x %08x\n"

l_.str.2:                               ; @.str.2
	.asciz	"         240: %08x\n"

	.no_dead_strip	_nv50_mem_timing_calc
.subsections_via_symbols
