	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function check_atom_bios
_check_atom_bios:                       ## @check_atom_bios
	.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
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.1:
	movq	%rsi, %r14
	cmpq	$72, %rsi
	jbe	LBB0_2
## %bb.4:
	movq	%rdi, %rbx
	callq	_AMD_IS_VALID_VBIOS
	testl	%eax, %eax
	je	LBB0_5
## %bb.6:
	movl	292(%rbx), %eax
	shll	$8, %eax
	orl	288(%rbx), %eax
	je	LBB0_7
## %bb.8:
	cltq
	addq	$4, %rax
	cmpq	%r14, %rax
	jbe	LBB0_10
## %bb.9:
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_3
LBB0_2:
	leaq	L_.str(%rip), %rdi
LBB0_3:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_DRM_INFO
	jmp	LBB0_13
LBB0_5:
	movl	(%rbx), %esi
	movl	4(%rbx), %edx
	leaq	L_.str.1(%rip), %rdi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_DRM_INFO
	jmp	LBB0_13
LBB0_7:
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_3
LBB0_10:
	leaq	(%rbx,%rax,4), %rbx
	leaq	L_.str.4(%rip), %rsi
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_memcmp
	testl	%eax, %eax
	je	LBB0_12
## %bb.11:
	leaq	L_.str.5(%rip), %rsi
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_memcmp
	xorl	%ebx, %ebx
	testl	%eax, %eax
	jne	LBB0_13
LBB0_12:
	leaq	L_.str.6(%rip), %rdi
	callq	_DRM_DEBUG
	movl	$1, %ebx
LBB0_13:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"vbios mem is null or mem size is wrong\n"

L_.str.1:                               ## @.str.1
	.asciz	"BIOS signature incorrect %x %x\n"

L_.str.2:                               ## @.str.2
	.asciz	"Can't locate bios header\n"

L_.str.3:                               ## @.str.3
	.asciz	"BIOS header is broken\n"

L_.str.4:                               ## @.str.4
	.asciz	"ATOM"

L_.str.5:                               ## @.str.5
	.asciz	"MOTA"

L_.str.6:                               ## @.str.6
	.asciz	"ATOMBIOS detected\n"

	.no_dead_strip	_check_atom_bios
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function check_atom_bios
_check_atom_bios:                       ; @check_atom_bios
	.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
	cbz	x0, LBB0_6
; %bb.1:
	mov	x20, x1
	cmp	x1, #72
	b.ls	LBB0_6
; %bb.2:
	mov	x19, x0
	bl	_AMD_IS_VALID_VBIOS
	cbz	w0, LBB0_7
; %bb.3:
	ldr	w8, [x19, #288]
	ldr	w9, [x19, #292]
	orr	w8, w8, w9, lsl #8
	cbz	w8, LBB0_8
; %bb.4:
	sxtw	x8, w8
	add	x8, x8, #4
	cmp	x8, x20
	b.ls	LBB0_12
; %bb.5:
Lloh0:
	adrp	x0, l_.str.3@PAGE
Lloh1:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_9
LBB0_6:
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_9
LBB0_7:
	ldp	w8, w9, [x19]
	stp	x8, x9, [sp]
Lloh4:
	adrp	x0, l_.str.1@PAGE
Lloh5:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_9
LBB0_8:
Lloh6:
	adrp	x0, l_.str.2@PAGE
Lloh7:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_9:
	bl	_DRM_INFO
LBB0_10:
	mov	w0, #0
LBB0_11:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_12:
	add	x19, x19, x8, lsl #2
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x19
	mov	w2, #4
	bl	_memcmp
	cbz	w0, LBB0_14
; %bb.13:
Lloh10:
	adrp	x1, l_.str.5@PAGE
Lloh11:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x19
	mov	w2, #4
	bl	_memcmp
	cbnz	w0, LBB0_10
LBB0_14:
Lloh12:
	adrp	x0, l_.str.6@PAGE
Lloh13:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_DRM_DEBUG
	mov	w0, #1
	b	LBB0_11
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"vbios mem is null or mem size is wrong\n"

l_.str.1:                               ; @.str.1
	.asciz	"BIOS signature incorrect %x %x\n"

l_.str.2:                               ; @.str.2
	.asciz	"Can't locate bios header\n"

l_.str.3:                               ; @.str.3
	.asciz	"BIOS header is broken\n"

l_.str.4:                               ; @.str.4
	.asciz	"ATOM"

l_.str.5:                               ; @.str.5
	.asciz	"MOTA"

l_.str.6:                               ; @.str.6
	.asciz	"ATOMBIOS detected\n"

	.no_dead_strip	_check_atom_bios
.subsections_via_symbols
