	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_drm_fb_cma_get_gem_addr        ## -- Begin function drm_fb_cma_get_gem_addr
	.p2align	4, 0x90
_drm_fb_cma_get_gem_addr:               ## @drm_fb_cma_get_gem_addr
	.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
	movl	%edx, %ebx
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	8(%rdi), %rdi
	movl	%edx, %esi
	callq	_drm_format_info_block_width
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	8(%r13), %rdi
	movl	%ebx, %esi
	callq	_drm_format_info_block_height
	movl	%eax, %r12d
	movq	8(%r13), %rax
	movq	(%rax), %rax
	movl	%ebx, %r14d
	movslq	(%rax,%r14,4), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	%r13, %rdi
	movl	%ebx, %esi
	callq	_drm_fb_cma_get_gem_obj
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	16(%r13), %rcx
	movq	(%rcx,%r14,8), %rcx
	addq	(%rax), %rcx
	testl	%ebx, %ebx
	je	LBB0_3
## %bb.4:
	movq	8(%r13), %rax
	movl	8(%rax), %esi
	movl	12(%rax), %edi
	jmp	LBB0_5
LBB0_1:
	xorl	%ecx, %ecx
	jmp	LBB0_6
LBB0_3:
	movl	$1, %edi
	movl	$1, %esi
LBB0_5:
	movswl	2(%r15), %eax
	cltd
	idivl	%esi
	movl	%eax, %esi
	movswl	6(%r15), %eax
	cltd
	idivl	%edi
	movl	%eax, %edi
	cltd
	idivl	%r12d
	subl	%edx, %edi
	movl	%esi, %eax
	cltd
	idivl	-44(%rbp)                       ## 4-byte Folded Reload
	movq	(%r13), %rdx
	movslq	(%rdx,%r14,4), %rdx
	movslq	%edi, %rsi
	imulq	%rdx, %rsi
	cltq
	imulq	-56(%rbp), %rax                 ## 8-byte Folded Reload
	addq	%rax, %rcx
	addq	%rsi, %rcx
LBB0_6:
	movq	%rcx, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_drm_fb_cma_get_gem_addr        ; -- Begin function drm_fb_cma_get_gem_addr
	.p2align	2
_drm_fb_cma_get_gem_addr:               ; @drm_fb_cma_get_gem_addr
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x23, x2
	mov	x21, x1
	mov	x19, x0
	ldr	x0, [x0, #8]
	mov	x1, x2
	bl	_drm_format_info_block_width
	mov	x20, x0
	ldr	x0, [x19, #8]
	mov	x1, x23
	bl	_drm_format_info_block_height
	mov	x22, x0
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldrsw	x24, [x8, w23, uxtw #2]
	mov	x0, x19
	mov	x1, x23
	bl	_drm_fb_cma_get_gem_obj
	cbz	x0, LBB0_5
; %bb.1:
	mov	w8, w23
	ldr	x9, [x0]
	ldr	x10, [x19, #16]
	ldr	x10, [x10, x8, lsl #3]
	add	x9, x10, x9
	cbz	w23, LBB0_3
; %bb.2:
	ldr	x10, [x19, #8]
	ldp	w11, w10, [x10, #8]
	b	LBB0_4
LBB0_3:
	mov	w10, #1
	mov	w11, #1
LBB0_4:
	ldrsh	w12, [x21, #2]
	sdiv	w11, w12, w11
	ldrsh	w12, [x21, #6]
	sdiv	w10, w12, w10
	sdiv	w10, w10, w22
	ldr	x12, [x19]
	ldrsw	x8, [x12, x8, lsl #2]
	mul	w10, w10, w22
	sxtw	x10, w10
	sdiv	w11, w11, w20
	sxtw	x11, w11
	madd	x9, x11, x24, x9
	madd	x0, x8, x10, x9
LBB0_5:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
