	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_amdgpu_ib_get                  ## -- Begin function amdgpu_ib_get
	.p2align	4, 0x90
_amdgpu_ib_get:                         ## @amdgpu_ib_get
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%r14d, %r14d
	testl	%edx, %edx
	je	LBB0_5
## %bb.1:
	movq	%rcx, %r12
	movq	%rsi, %r15
	movq	%rdi, %r13
	addq	$4, %rdi
	movq	%rcx, %rsi
	movl	$256, %ecx                      ## imm = 0x100
	callq	_amdgpu_sa_bo_new
	testl	%eax, %eax
	je	LBB0_3
## %bb.2:
	movl	%eax, %ebx
	movl	(%r13), %edi
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edx
	callq	_dev_err
	movl	%ebx, %r14d
	jmp	LBB0_5
LBB0_3:
	movl	(%r12), %edi
	callq	_amdgpu_sa_bo_cpu_addr
	movl	%eax, 8(%r12)
	testq	%r15, %r15
	jne	LBB0_5
## %bb.4:
	movl	(%r12), %edi
	callq	_amdgpu_sa_bo_gpu_addr
	movl	%eax, 4(%r12)
LBB0_5:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to get a new IB (%d)\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_amdgpu_ib_get                  ; -- Begin function amdgpu_ib_get
	.p2align	2
_amdgpu_ib_get:                         ; @amdgpu_ib_get
	.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
	cbz	w2, LBB0_4
; %bb.1:
	mov	x19, x3
	mov	x21, x1
	mov	x22, x0
	add	x0, x0, #4
	mov	x1, x3
	mov	w3, #256
	bl	_amdgpu_sa_bo_new
	cbz	w0, LBB0_3
; %bb.2:
	mov	x20, x0
	ldr	w0, [x22]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	b	LBB0_5
LBB0_3:
	ldr	w0, [x19]
	bl	_amdgpu_sa_bo_cpu_addr
	str	w0, [x19, #8]
	cbz	x21, LBB0_6
LBB0_4:
	mov	w20, #0
LBB0_5:
	mov	x0, x20
	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
LBB0_6:
	ldr	w0, [x19]
	bl	_amdgpu_sa_bo_gpu_addr
	mov	w20, #0
	str	w0, [x19, #4]
	b	LBB0_5
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to get a new IB (%d)\n"

.subsections_via_symbols
