	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function r600_calculate_u_and_p
_r600_calculate_u_and_p:                ## @r600_calculate_u_and_p
	.cfi_startproc
## %bb.0:
	movq	%rcx, %r9
	movl	%edx, %ecx
	imull	%esi, %edi
	movslq	%edi, %rax
	imulq	$1374389535, %rax, %rax         ## imm = 0x51EB851F
	movq	%rax, %rdx
	shrq	$63, %rdx
	sarq	$37, %rax
	addl	%edx, %eax
	movl	%eax, %esi
                                        ## kill: def $cl killed $cl killed $ecx
	sarl	%cl, %esi
	testl	%esi, %esi
	je	LBB0_1
## %bb.2:
	movl	$1, %edx
	movl	%esi, %ecx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	sarl	%ecx
	incl	%edx
	cmpl	$1, %esi
	movl	%ecx, %esi
	ja	LBB0_3
## %bb.4:
	movl	%edx, %ecx
	shrl	$31, %ecx
	addl	%edx, %ecx
	sarl	%ecx
	jmp	LBB0_5
LBB0_1:
	xorl	%ecx, %ecx
LBB0_5:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	%ecx, (%r8)
	addl	%ecx, %ecx
	movl	$1, %esi
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %esi
                                        ## kill: def $eax killed $eax killed $rax
	cltd
	idivl	%esi
	movl	%eax, (%r9)
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_r600_calculate_u_and_p
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function r600_calculate_u_and_p
_r600_calculate_u_and_p:                ; @r600_calculate_u_and_p
	.cfi_startproc
; %bb.0:
	mul	w8, w1, w0
	mov	w9, #34079
	movk	w9, #20971, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #37
	add	w8, w8, w9
	asr	w9, w8, w2
	cbz	w9, LBB0_4
; %bb.1:
	mov	w10, #1
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	asr	w11, w9, #1
	add	w10, w10, #1
	cmp	w9, #1
	mov	x9, x11
	b.hi	LBB0_2
; %bb.3:
	cmp	w10, #0
	cinc	w9, w10, lt
	asr	w9, w9, #1
LBB0_4:
	str	w9, [x4]
	lsl	w9, w9, #1
	mov	w10, #1
	lsl	w9, w10, w9
	sdiv	w8, w8, w9
	str	w8, [x3]
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_r600_calculate_u_and_p
.subsections_via_symbols
