	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function check_for_audio_disc
_check_for_audio_disc:                  ## @check_for_audio_disc
	.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
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	_CD_OPEN@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_cdinfo
	movq	_CDO_CHECK_TYPE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	je	LBB0_19
## %bb.1:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_15
## %bb.2:
	movq	_CDSL_CURRENT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	%r14, %rdi
	callq	*%rax
	movl	%eax, %ebx
	movl	(%r12), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_cdinfo
	movq	_CDS_TRAY_OPEN@GOTPCREL(%rip), %r13
	cmpl	(%r13), %ebx
	jne	LBB0_15
## %bb.3:
	movl	(%r12), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_cdinfo
	movq	_CDC_CLOSE_TRAY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_CDROM_CAN
	testq	%rax, %rax
	je	LBB0_8
## %bb.4:
	movq	_CDO_AUTO_CLOSE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	je	LBB0_8
## %bb.5:
	movl	(%r12), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_cdinfo
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	*8(%r15)
	testl	%eax, %eax
	je	LBB0_9
## %bb.6:
	movl	(%r12), %edi
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_7
LBB0_8:
	movl	(%r12), %edi
	leaq	L_.str.5(%rip), %rsi
LBB0_7:
	xorl	%eax, %eax
	callq	_cdinfo
	movq	_ENOMEDIUM@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_9:
	movq	_CDSL_CURRENT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	*(%r15)
	movq	_CDS_NO_DISC@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_11
## %bb.10:
	cmpl	(%r13), %eax
	je	LBB0_11
## %bb.12:
	movq	_CDS_DISC_OK@GOTPCREL(%rip), %rcx
	movl	(%r12), %edi
	cmpl	(%rcx), %eax
	jne	LBB0_13
## %bb.14:
	leaq	L_.str.8(%rip), %rsi
	xorl	%eax, %eax
	callq	_cdinfo
LBB0_15:
	leaq	-56(%rbp), %rsi
	movq	%r14, %rdi
	callq	_cdrom_count_tracks
	movl	-56(%rbp), %ebx
	testl	%ebx, %ebx
	jne	LBB0_19
## %bb.16:
	cmpq	$0, -48(%rbp)
	movl	$0, %ebx
	jne	LBB0_19
## %bb.17:
	movq	_EMEDIUMTYPE@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
LBB0_18:
	subl	(%rax), %ebx
LBB0_19:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movl	(%r12), %edi
	leaq	L_.str.6(%rip), %rsi
	xorl	%ebx, %ebx
	jmp	LBB0_7
LBB0_13:
	leaq	L_.str.7(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_cdinfo
	movq	_EIO@GOTPCREL(%rip), %rax
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
	.comm	_CD_OPEN,4,2                    ## @CD_OPEN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"entering check_for_audio_disc\n"

	.comm	_CDO_CHECK_TYPE,4,2             ## @CDO_CHECK_TYPE
	.comm	_CDSL_CURRENT,4,2               ## @CDSL_CURRENT
L_.str.1:                               ## @.str.1
	.asciz	"drive_status=%d\n"

	.comm	_CDS_TRAY_OPEN,4,2              ## @CDS_TRAY_OPEN
L_.str.2:                               ## @.str.2
	.asciz	"the tray is open...\n"

	.comm	_CDC_CLOSE_TRAY,4,2             ## @CDC_CLOSE_TRAY
	.comm	_CDO_AUTO_CLOSE,4,2             ## @CDO_AUTO_CLOSE
L_.str.3:                               ## @.str.3
	.asciz	"trying to close the tray.\n"

L_.str.4:                               ## @.str.4
	.asciz	"bummer. tried to close tray but failed.\n"

	.comm	_ENOMEDIUM,4,2                  ## @ENOMEDIUM
L_.str.5:                               ## @.str.5
	.asciz	"bummer. this driver can't close the tray.\n"

	.comm	_CDS_NO_DISC,4,2                ## @CDS_NO_DISC
L_.str.6:                               ## @.str.6
	.asciz	"bummer. the tray is still not closed.\n"

	.comm	_CDS_DISC_OK,4,2                ## @CDS_DISC_OK
L_.str.7:                               ## @.str.7
	.asciz	"bummer. disc isn't ready.\n"

	.comm	_EIO,4,2                        ## @EIO
L_.str.8:                               ## @.str.8
	.asciz	"the tray is now closed.\n"

	.comm	_EMEDIUMTYPE,4,2                ## @EMEDIUMTYPE
	.no_dead_strip	_check_for_audio_disc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function check_for_audio_disc
_check_for_audio_disc:                  ; @check_for_audio_disc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x22, _CD_OPEN@GOTPAGE
Lloh1:
	ldr	x22, [x22, _CD_OPEN@GOTPAGEOFF]
	ldr	w0, [x22]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_cdinfo
	ldr	w8, [x19]
Lloh4:
	adrp	x9, _CDO_CHECK_TYPE@GOTPAGE
Lloh5:
	ldr	x9, [x9, _CDO_CHECK_TYPE@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_15
; %bb.1:
	ldr	x8, [x20]
	cbz	x8, LBB0_13
; %bb.2:
Lloh7:
	adrp	x23, _CDSL_CURRENT@GOTPAGE
Lloh8:
	ldr	x23, [x23, _CDSL_CURRENT@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x19
	blr	x8
	mov	x21, x0
	ldr	w0, [x22]
	str	x21, [sp]
Lloh9:
	adrp	x1, l_.str.1@PAGE
Lloh10:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_cdinfo
Lloh11:
	adrp	x24, _CDS_TRAY_OPEN@GOTPAGE
Lloh12:
	ldr	x24, [x24, _CDS_TRAY_OPEN@GOTPAGEOFF]
	ldr	w8, [x24]
	cmp	w21, w8
	b.ne	LBB0_13
; %bb.3:
	ldr	w0, [x22]
Lloh13:
	adrp	x1, l_.str.2@PAGE
Lloh14:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_cdinfo
Lloh15:
	adrp	x8, _CDC_CLOSE_TRAY@GOTPAGE
Lloh16:
	ldr	x8, [x8, _CDC_CLOSE_TRAY@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	bl	_CDROM_CAN
	cbz	x0, LBB0_7
; %bb.4:
	ldr	w8, [x19]
Lloh18:
	adrp	x9, _CDO_AUTO_CLOSE@GOTPAGE
Lloh19:
	ldr	x9, [x9, _CDO_AUTO_CLOSE@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.5:
	ldr	w0, [x22]
Lloh21:
	adrp	x1, l_.str.3@PAGE
Lloh22:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_cdinfo
	ldr	x8, [x20, #8]
	mov	x0, x19
	mov	w1, #0
	blr	x8
	cbz	w0, LBB0_9
; %bb.6:
	ldr	w0, [x22]
Lloh23:
	adrp	x1, l_.str.4@PAGE
Lloh24:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_8
LBB0_7:
	ldr	w0, [x22]
Lloh25:
	adrp	x1, l_.str.5@PAGE
Lloh26:
	add	x1, x1, l_.str.5@PAGEOFF
LBB0_8:
	bl	_cdinfo
Lloh27:
	adrp	x8, _ENOMEDIUM@GOTPAGE
Lloh28:
	ldr	x8, [x8, _ENOMEDIUM@GOTPAGEOFF]
	b	LBB0_17
LBB0_9:
	ldr	x8, [x20]
	ldr	w1, [x23]
	mov	x0, x19
	blr	x8
Lloh29:
	adrp	x8, _CDS_NO_DISC@GOTPAGE
Lloh30:
	ldr	x8, [x8, _CDS_NO_DISC@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
	cmp	w0, w8
	b.eq	LBB0_19
; %bb.10:
	ldr	w8, [x24]
	cmp	w0, w8
	b.eq	LBB0_19
; %bb.11:
Lloh32:
	adrp	x8, _CDS_DISC_OK@GOTPAGE
Lloh33:
	ldr	x8, [x8, _CDS_DISC_OK@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x8]
	ldr	w8, [x22]
	cmp	w0, w9
	b.ne	LBB0_20
; %bb.12:
Lloh35:
	adrp	x1, l_.str.8@PAGE
Lloh36:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	x0, x8
	bl	_cdinfo
LBB0_13:
	add	x1, sp, #16
	mov	x0, x19
	bl	_cdrom_count_tracks
	ldr	w0, [sp, #16]
	cbnz	w0, LBB0_18
; %bb.14:
	ldr	x8, [sp, #24]
	cbz	x8, LBB0_16
LBB0_15:
	mov	w0, #0
	b	LBB0_18
LBB0_16:
Lloh37:
	adrp	x8, _EMEDIUMTYPE@GOTPAGE
Lloh38:
	ldr	x8, [x8, _EMEDIUMTYPE@GOTPAGEOFF]
LBB0_17:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_18:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_19:
	ldr	w0, [x22]
Lloh39:
	adrp	x1, l_.str.6@PAGE
Lloh40:
	add	x1, x1, l_.str.6@PAGEOFF
	b	LBB0_8
LBB0_20:
Lloh41:
	adrp	x1, l_.str.7@PAGE
Lloh42:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x0, x8
	bl	_cdinfo
Lloh43:
	adrp	x8, _EIO@GOTPAGE
Lloh44:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_17
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpLdrGot	Lloh43, Lloh44
	.loh AdrpAdd	Lloh41, Lloh42
	.cfi_endproc
                                        ; -- End function
	.comm	_CD_OPEN,4,2                    ; @CD_OPEN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"entering check_for_audio_disc\n"

	.comm	_CDO_CHECK_TYPE,4,2             ; @CDO_CHECK_TYPE
	.comm	_CDSL_CURRENT,4,2               ; @CDSL_CURRENT
l_.str.1:                               ; @.str.1
	.asciz	"drive_status=%d\n"

	.comm	_CDS_TRAY_OPEN,4,2              ; @CDS_TRAY_OPEN
l_.str.2:                               ; @.str.2
	.asciz	"the tray is open...\n"

	.comm	_CDC_CLOSE_TRAY,4,2             ; @CDC_CLOSE_TRAY
	.comm	_CDO_AUTO_CLOSE,4,2             ; @CDO_AUTO_CLOSE
l_.str.3:                               ; @.str.3
	.asciz	"trying to close the tray.\n"

l_.str.4:                               ; @.str.4
	.asciz	"bummer. tried to close tray but failed.\n"

	.comm	_ENOMEDIUM,4,2                  ; @ENOMEDIUM
l_.str.5:                               ; @.str.5
	.asciz	"bummer. this driver can't close the tray.\n"

	.comm	_CDS_NO_DISC,4,2                ; @CDS_NO_DISC
l_.str.6:                               ; @.str.6
	.asciz	"bummer. the tray is still not closed.\n"

	.comm	_CDS_DISC_OK,4,2                ; @CDS_DISC_OK
l_.str.7:                               ; @.str.7
	.asciz	"bummer. disc isn't ready.\n"

	.comm	_EIO,4,2                        ; @EIO
l_.str.8:                               ; @.str.8
	.asciz	"the tray is now closed.\n"

	.comm	_EMEDIUMTYPE,4,2                ; @EMEDIUMTYPE
	.no_dead_strip	_check_for_audio_disc
.subsections_via_symbols
