	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ide_identify
_ide_identify:                          ## @ide_identify
	.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
	movq	%rdi, %r14
	movq	48(%rdi), %r12
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$512, %edx                      ## imm = 0x200
	callq	_memset
	movq	_GCBI_FIXED_DRIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_LE16
	movl	(%r14), %edx
	movq	%r12, %rdi
	movl	$1, %esi
	callq	_LE16
	movl	4(%r14), %edx
	movq	%r12, %rdi
	movl	$3, %esi
	callq	_LE16
	movl	8(%r14), %edx
	movq	%r12, %rdi
	movl	$6, %esi
	callq	_LE16
	leaq	80(%r12), %rdi
	movq	16(%r14), %rsi
	movl	$20, %edx
	callq	_padstr
	movq	%r12, %rdi
	movl	$22, %esi
	movl	$4, %edx
	callq	_LE16
	leaq	184(%r12), %rdi
	movq	_PACKAGE_VERSION@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movl	$8, %edx
	callq	_padstr
	leaq	216(%r12), %r15
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movl	$40, %edx
	callq	_padstr
	movq	_MAX_MULT_SECTORS@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	cmpl	$2, %edx
	jl	LBB0_2
## %bb.1:
	orl	$32768, %edx                    ## imm = 0x8000
	movq	%r12, %rdi
	movl	$47, %esi
	callq	_LE16
LBB0_2:
	movq	%r12, %rdi
	movl	$48, %esi
	xorl	%edx, %edx
	callq	_LE16
	movq	_CAP_LBA_SUPPORTED@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	movq	%r12, %rdi
	movl	$49, %esi
	callq	_LE16
	movq	%r12, %rdi
	movl	$51, %esi
	movl	$512, %edx                      ## imm = 0x200
	callq	_LE16
	movq	%r12, %rdi
	movl	$53, %esi
	movl	$1, %edx
	callq	_LE16
	movl	(%r14), %edx
	movq	%r12, %rdi
	movl	$54, %esi
	callq	_LE16
	movl	4(%r14), %edx
	movq	%r12, %rdi
	movl	$55, %esi
	callq	_LE16
	movl	8(%r14), %edx
	movq	%r12, %rdi
	movl	$56, %esi
	callq	_LE16
	movl	4(%r14), %ebx
	imull	(%r14), %ebx
	imull	8(%r14), %ebx
	movq	%r12, %rdi
	movl	$57, %esi
	movl	%ebx, %edx
	callq	_LE16
	shrl	$16, %ebx
	movq	%r12, %rdi
	movl	$58, %esi
	movl	%ebx, %edx
	callq	_LE16
	movl	24(%r14), %edx
	testl	%edx, %edx
	je	LBB0_4
## %bb.3:
	orl	$256, %edx                      ## imm = 0x100
	movq	%r12, %rdi
	movl	$59, %esi
	callq	_LE16
LBB0_4:
	movl	28(%r14), %edx
	movq	%r12, %rdi
	movl	$60, %esi
	callq	_LE16
	movswl	30(%r14), %edx
	movq	%r12, %rdi
	movl	$61, %esi
	callq	_LE16
	cmpq	$0, 40(%r14)
	je	LBB0_6
## %bb.5:
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$33930, %edx                    ## imm = 0x848A
	callq	_LE16
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movl	$40, %edx
	callq	_padstr
	movl	(%r13), %edx
	movq	%r12, %rdi
	movl	$49, %esi
	callq	_LE16
	movq	%r12, %rdi
	movl	$51, %esi
	movl	$2, %edx
	callq	_LE16
	movq	%r12, %rdi
	movl	$52, %esi
	movl	$1, %edx
	callq	_LE16
LBB0_6:
	cmpq	$0, 32(%r14)
	je	LBB0_7
## %bb.8:
	movq	_GCBI_HAS_PACKET_FEAT_SET@GOTPCREL(%rip), %rax
	movq	_GCBI_CDROM_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movq	_GCBI_HAS_REMOVABLE_MEDIA@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	_GCBI_50US_TILL_DRQ@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	_GCBI_12BYTE_PACKETS@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_LE16
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	movl	$40, %edx
	callq	_padstr
	movl	(%r13), %edx
	movq	%r12, %rdi
	movl	$49, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_LE16                           ## TAILCALL
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GCBI_FIXED_DRIVE,4,2           ## @GCBI_FIXED_DRIVE
	.comm	_PACKAGE_VERSION,8,3            ## @PACKAGE_VERSION
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ATARI800 HARDDISK"

	.comm	_MAX_MULT_SECTORS,4,2           ## @MAX_MULT_SECTORS
	.comm	_CAP_LBA_SUPPORTED,4,2          ## @CAP_LBA_SUPPORTED
L_.str.1:                               ## @.str.1
	.asciz	"ATARI800 MICRODRIVE"

	.comm	_GCBI_HAS_PACKET_FEAT_SET,4,2   ## @GCBI_HAS_PACKET_FEAT_SET
	.comm	_GCBI_CDROM_DEVICE,4,2          ## @GCBI_CDROM_DEVICE
	.comm	_GCBI_HAS_REMOVABLE_MEDIA,4,2   ## @GCBI_HAS_REMOVABLE_MEDIA
	.comm	_GCBI_50US_TILL_DRQ,4,2         ## @GCBI_50US_TILL_DRQ
	.comm	_GCBI_12BYTE_PACKETS,4,2        ## @GCBI_12BYTE_PACKETS
L_.str.2:                               ## @.str.2
	.asciz	"ATARI800 DVD-ROM"

	.no_dead_strip	_ide_identify
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ide_identify
_ide_identify:                          ; @ide_identify
	.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	x20, x0
	ldr	x19, [x0, #48]
	mov	x0, x19
	mov	w1, #0
	mov	w2, #512
	bl	_memset
Lloh0:
	adrp	x8, _GCBI_FIXED_DRIVE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GCBI_FIXED_DRIVE@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #0
	bl	_LE16
	ldr	w2, [x20]
	mov	x0, x19
	mov	w1, #1
	bl	_LE16
	ldr	w2, [x20, #4]
	mov	x0, x19
	mov	w1, #3
	bl	_LE16
	ldr	w2, [x20, #8]
	mov	x0, x19
	mov	w1, #6
	bl	_LE16
	add	x0, x19, #80
	ldr	x1, [x20, #16]
	mov	w2, #20
	bl	_padstr
	mov	x0, x19
	mov	w1, #22
	mov	w2, #4
	bl	_LE16
	add	x0, x19, #184
Lloh3:
	adrp	x8, _PACKAGE_VERSION@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PACKAGE_VERSION@GOTPAGEOFF]
Lloh5:
	ldr	x1, [x8]
	mov	w2, #8
	bl	_padstr
	add	x21, x19, #216
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	mov	w2, #40
	bl	_padstr
Lloh8:
	adrp	x8, _MAX_MULT_SECTORS@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MAX_MULT_SECTORS@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	cmp	w8, #2
	b.lt	LBB0_2
; %bb.1:
	orr	w2, w8, #0x8000
	mov	x0, x19
	mov	w1, #47
	bl	_LE16
LBB0_2:
	mov	x0, x19
	mov	w1, #48
	mov	w2, #0
	bl	_LE16
Lloh11:
	adrp	x23, _CAP_LBA_SUPPORTED@GOTPAGE
Lloh12:
	ldr	x23, [x23, _CAP_LBA_SUPPORTED@GOTPAGEOFF]
	ldr	w2, [x23]
	mov	x0, x19
	mov	w1, #49
	bl	_LE16
	mov	x0, x19
	mov	w1, #51
	mov	w2, #512
	bl	_LE16
	mov	x0, x19
	mov	w1, #53
	mov	w2, #1
	bl	_LE16
	ldr	w2, [x20]
	mov	x0, x19
	mov	w1, #54
	bl	_LE16
	ldr	w2, [x20, #4]
	mov	x0, x19
	mov	w1, #55
	bl	_LE16
	ldr	w2, [x20, #8]
	mov	x0, x19
	mov	w1, #56
	bl	_LE16
	ldp	w8, w9, [x20]
	mul	w8, w9, w8
	ldr	w9, [x20, #8]
	mul	w22, w8, w9
	mov	x0, x19
	mov	w1, #57
	mov	x2, x22
	bl	_LE16
	lsr	w2, w22, #16
	mov	x0, x19
	mov	w1, #58
	bl	_LE16
	ldr	w8, [x20, #24]
	cbz	w8, LBB0_4
; %bb.3:
	orr	w2, w8, #0x100
	mov	x0, x19
	mov	w1, #59
	bl	_LE16
LBB0_4:
	ldr	w2, [x20, #28]
	mov	x0, x19
	mov	w1, #60
	bl	_LE16
	ldrsh	w2, [x20, #30]
	mov	x0, x19
	mov	w1, #61
	bl	_LE16
	ldr	x8, [x20, #40]
	cbz	x8, LBB0_6
; %bb.5:
	mov	x0, x19
	mov	w1, #0
	mov	w2, #33930
	bl	_LE16
Lloh13:
	adrp	x1, l_.str.1@PAGE
Lloh14:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	mov	w2, #40
	bl	_padstr
	ldr	w2, [x23]
	mov	x0, x19
	mov	w1, #49
	bl	_LE16
	mov	x0, x19
	mov	w1, #51
	mov	w2, #2
	bl	_LE16
	mov	x0, x19
	mov	w1, #52
	mov	w2, #1
	bl	_LE16
LBB0_6:
	ldr	x8, [x20, #32]
	cbz	x8, LBB0_8
; %bb.7:
Lloh15:
	adrp	x8, _GCBI_HAS_PACKET_FEAT_SET@GOTPAGE
Lloh16:
	ldr	x8, [x8, _GCBI_HAS_PACKET_FEAT_SET@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
Lloh18:
	adrp	x9, _GCBI_CDROM_DEVICE@GOTPAGE
Lloh19:
	ldr	x9, [x9, _GCBI_CDROM_DEVICE@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh21:
	adrp	x9, _GCBI_HAS_REMOVABLE_MEDIA@GOTPAGE
Lloh22:
	ldr	x9, [x9, _GCBI_HAS_REMOVABLE_MEDIA@GOTPAGEOFF]
Lloh23:
	ldr	w9, [x9]
	orr	w8, w8, w9
Lloh24:
	adrp	x9, _GCBI_50US_TILL_DRQ@GOTPAGE
Lloh25:
	ldr	x9, [x9, _GCBI_50US_TILL_DRQ@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	orr	w8, w8, w9
Lloh27:
	adrp	x9, _GCBI_12BYTE_PACKETS@GOTPAGE
Lloh28:
	ldr	x9, [x9, _GCBI_12BYTE_PACKETS@GOTPAGEOFF]
Lloh29:
	ldr	w9, [x9]
	orr	w2, w8, w9
	mov	x0, x19
	mov	w1, #0
	bl	_LE16
Lloh30:
	adrp	x1, l_.str.2@PAGE
Lloh31:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x21
	mov	w2, #40
	bl	_padstr
	ldr	w2, [x23]
	mov	x0, x19
	mov	w1, #49
	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
	b	_LE16
LBB0_8:
	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
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_GCBI_FIXED_DRIVE,4,2           ; @GCBI_FIXED_DRIVE
	.comm	_PACKAGE_VERSION,8,3            ; @PACKAGE_VERSION
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ATARI800 HARDDISK"

	.comm	_MAX_MULT_SECTORS,4,2           ; @MAX_MULT_SECTORS
	.comm	_CAP_LBA_SUPPORTED,4,2          ; @CAP_LBA_SUPPORTED
l_.str.1:                               ; @.str.1
	.asciz	"ATARI800 MICRODRIVE"

	.comm	_GCBI_HAS_PACKET_FEAT_SET,4,2   ; @GCBI_HAS_PACKET_FEAT_SET
	.comm	_GCBI_CDROM_DEVICE,4,2          ; @GCBI_CDROM_DEVICE
	.comm	_GCBI_HAS_REMOVABLE_MEDIA,4,2   ; @GCBI_HAS_REMOVABLE_MEDIA
	.comm	_GCBI_50US_TILL_DRQ,4,2         ; @GCBI_50US_TILL_DRQ
	.comm	_GCBI_12BYTE_PACKETS,4,2        ; @GCBI_12BYTE_PACKETS
l_.str.2:                               ; @.str.2
	.asciz	"ATARI800 DVD-ROM"

	.no_dead_strip	_ide_identify
.subsections_via_symbols
