	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_device_check_arguments
_amdgpu_device_check_arguments:         ## @amdgpu_device_check_arguments
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	_amdgpu_sched_jobs@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	cmpl	$3, %edx
	jg	LBB0_2
## %bb.1:
	movl	4(%r14), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_warn
	movl	$4, %eax
	jmp	LBB0_4
LBB0_2:
	movl	%edx, %edi
	callq	_is_power_of_2
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:
	movl	4(%r14), %edi
	movl	(%rbx), %edx
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_warn
	movl	(%rbx), %edi
	callq	_roundup_pow_of_two
LBB0_4:
	movl	%eax, (%rbx)
LBB0_5:
	movq	_amdgpu_gart_size@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	cmpl	$-1, %edx
	je	LBB0_8
## %bb.6:
	cmpl	$31, %edx
	jg	LBB0_8
## %bb.7:
	movl	4(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_warn
	movl	$-1, (%rbx)
LBB0_8:
	movq	_amdgpu_gtt_size@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	cmpl	$-1, %edx
	je	LBB0_11
## %bb.9:
	cmpl	$31, %edx
	jg	LBB0_11
## %bb.10:
	movl	4(%r14), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_warn
	movl	$-1, (%rbx)
LBB0_11:
	movq	_amdgpu_vm_fragment_size@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	leal	-4(%rax), %ecx
	cmpl	$6, %ecx
	jae	LBB0_12
LBB0_14:
	movq	%r14, %rdi
	callq	_amdgpu_device_check_smu_prv_buffer_size
	movq	%r14, %rdi
	callq	_amdgpu_device_check_vm_size
	movq	%r14, %rdi
	callq	_amdgpu_device_check_block_size
	movq	%r14, %rdi
	callq	_amdgpu_device_get_job_timeout_settings
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_16
## %bb.15:
	movl	4(%r14), %edi
	leaq	L_.str.5(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_17
LBB0_16:
	movq	_amdgpu_fw_load_type@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_amdgpu_ucode_get_load_type
	movl	%eax, (%r14)
LBB0_17:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_12:
	cmpl	$-1, %eax
	je	LBB0_14
## %bb.13:
	movl	4(%r14), %edi
	leaq	L_.str.4(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_warn
	movl	$-1, (%rbx)
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_amdgpu_sched_jobs,4,2          ## @amdgpu_sched_jobs
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sched jobs (%d) must be at least 4\n"

L_.str.1:                               ## @.str.1
	.asciz	"sched jobs (%d) must be a power of 2\n"

	.comm	_amdgpu_gart_size,4,2           ## @amdgpu_gart_size
L_.str.2:                               ## @.str.2
	.asciz	"gart size (%d) too small\n"

	.comm	_amdgpu_gtt_size,4,2            ## @amdgpu_gtt_size
L_.str.3:                               ## @.str.3
	.asciz	"gtt size (%d) too small\n"

	.comm	_amdgpu_vm_fragment_size,4,2    ## @amdgpu_vm_fragment_size
L_.str.4:                               ## @.str.4
	.asciz	"valid range is between 4 and 9\n"

L_.str.5:                               ## @.str.5
	.asciz	"invalid lockup_timeout parameter syntax\n"

	.comm	_amdgpu_fw_load_type,4,2        ## @amdgpu_fw_load_type
	.no_dead_strip	_amdgpu_device_check_arguments
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_device_check_arguments
_amdgpu_device_check_arguments:         ; @amdgpu_device_check_arguments
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x20, _amdgpu_sched_jobs@GOTPAGE
Lloh1:
	ldr	x20, [x20, _amdgpu_sched_jobs@GOTPAGEOFF]
	ldr	w0, [x20]
	cmp	w0, #3
	b.gt	LBB0_2
; %bb.1:
	ldr	w8, [x19, #4]
	str	x0, [sp]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x8
	bl	_dev_warn
	mov	w0, #4
	b	LBB0_4
LBB0_2:
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_is_power_of_2
	cbnz	w0, LBB0_5
; %bb.3:
	ldr	w0, [x19, #4]
	ldr	w8, [x20]
	str	x8, [sp]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_warn
	ldr	w0, [x20]
	bl	_roundup_pow_of_two
LBB0_4:
	str	w0, [x20]
LBB0_5:
Lloh6:
	adrp	x20, _amdgpu_gart_size@GOTPAGE
Lloh7:
	ldr	x20, [x20, _amdgpu_gart_size@GOTPAGEOFF]
	ldr	w8, [x20]
	cmn	w8, #1
	ccmp	w8, #31, #0, ne
	b.gt	LBB0_7
; %bb.6:
	ldr	w0, [x19, #4]
	str	x8, [sp]
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_warn
	mov	w8, #-1
	str	w8, [x20]
LBB0_7:
Lloh10:
	adrp	x20, _amdgpu_gtt_size@GOTPAGE
Lloh11:
	ldr	x20, [x20, _amdgpu_gtt_size@GOTPAGEOFF]
	ldr	w8, [x20]
	cmn	w8, #1
	ccmp	w8, #31, #0, ne
	b.gt	LBB0_9
; %bb.8:
	ldr	w0, [x19, #4]
	str	x8, [sp]
Lloh12:
	adrp	x1, l_.str.3@PAGE
Lloh13:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_warn
	mov	w8, #-1
	str	w8, [x20]
LBB0_9:
Lloh14:
	adrp	x20, _amdgpu_vm_fragment_size@GOTPAGE
Lloh15:
	ldr	x20, [x20, _amdgpu_vm_fragment_size@GOTPAGEOFF]
	ldr	w8, [x20]
	sub	w9, w8, #4
	cmp	w9, #6
	ccmn	w8, #1, #4, hs
	b.ne	LBB0_14
LBB0_10:
	mov	x0, x19
	bl	_amdgpu_device_check_smu_prv_buffer_size
	mov	x0, x19
	bl	_amdgpu_device_check_vm_size
	mov	x0, x19
	bl	_amdgpu_device_check_block_size
	mov	x0, x19
	bl	_amdgpu_device_get_job_timeout_settings
	mov	x20, x0
	cbz	w0, LBB0_12
; %bb.11:
	ldr	w0, [x19, #4]
Lloh16:
	adrp	x1, l_.str.5@PAGE
Lloh17:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_dev_err
	b	LBB0_13
LBB0_12:
Lloh18:
	adrp	x8, _amdgpu_fw_load_type@GOTPAGE
Lloh19:
	ldr	x8, [x8, _amdgpu_fw_load_type@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_amdgpu_ucode_get_load_type
	str	w0, [x19]
LBB0_13:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_14:
	ldr	w0, [x19, #4]
Lloh21:
	adrp	x1, l_.str.4@PAGE
Lloh22:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_dev_warn
	mov	w8, #-1
	str	w8, [x20]
	b	LBB0_10
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_amdgpu_sched_jobs,4,2          ; @amdgpu_sched_jobs
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sched jobs (%d) must be at least 4\n"

l_.str.1:                               ; @.str.1
	.asciz	"sched jobs (%d) must be a power of 2\n"

	.comm	_amdgpu_gart_size,4,2           ; @amdgpu_gart_size
l_.str.2:                               ; @.str.2
	.asciz	"gart size (%d) too small\n"

	.comm	_amdgpu_gtt_size,4,2            ; @amdgpu_gtt_size
l_.str.3:                               ; @.str.3
	.asciz	"gtt size (%d) too small\n"

	.comm	_amdgpu_vm_fragment_size,4,2    ; @amdgpu_vm_fragment_size
l_.str.4:                               ; @.str.4
	.asciz	"valid range is between 4 and 9\n"

l_.str.5:                               ; @.str.5
	.asciz	"invalid lockup_timeout parameter syntax\n"

	.comm	_amdgpu_fw_load_type,4,2        ; @amdgpu_fw_load_type
	.no_dead_strip	_amdgpu_device_check_arguments
.subsections_via_symbols
