	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal4,4byte_literals
	.p2align	2                               ## -- Begin function play_notes
LCPI0_0:
	.long	0x42c80000                      ## float 100
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_play_notes
	.p2align	4, 0x90
_play_notes:                            ## @play_notes
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	_audio_initialized@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jne	LBB0_2
## %bb.1:
	xorl	%eax, %eax
	callq	_audio_init
LBB0_2:
	movq	_audio_config@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_6
## %bb.3:
	movq	_playing_note@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_5
## %bb.4:
	xorl	%eax, %eax
	callq	_stop_all_notes
LBB0_5:
	movq	_playing_notes@GOTPCREL(%rip), %rax
	movl	$1, (%rax)
	movq	_notes_pointer@GOTPCREL(%rip), %rax
	movq	%rbx, (%rax)
	movq	_notes_count@GOTPCREL(%rip), %rax
	movl	%r15d, (%rax)
	movq	_notes_repeat@GOTPCREL(%rip), %rax
	movl	%r14d, (%rax)
	movq	_place@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	_current_note@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	(%rbx), %rax
	movq	(%rax), %rax
	movl	(%rax), %ecx
	movq	_note_frequency@GOTPCREL(%rip), %rdx
	movl	%ecx, (%rdx)
	movl	4(%rax), %eax
	leal	3(%rax), %ecx
	testl	%eax, %eax
	cmovnsl	%eax, %ecx
	sarl	$2, %ecx
	cvtsi2ss	%ecx, %xmm0
	movq	_note_tempo@GOTPCREL(%rip), %rax
	cvtsi2ssq	(%rax), %xmm1
	divss	LCPI0_0(%rip), %xmm1
	mulss	%xmm0, %xmm1
	cvttss2si	%xmm1, %eax
	movq	_note_length@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	_note_position@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_audio_initialized,4,2          ## @audio_initialized
	.comm	_audio_config,8,3               ## @audio_config
	.comm	_playing_note,8,3               ## @playing_note
	.comm	_playing_notes,4,2              ## @playing_notes
	.comm	_notes_pointer,8,3              ## @notes_pointer
	.comm	_notes_count,4,2                ## @notes_count
	.comm	_notes_repeat,4,2               ## @notes_repeat
	.comm	_place,8,3                      ## @place
	.comm	_current_note,8,3               ## @current_note
	.comm	_note_frequency,4,2             ## @note_frequency
	.comm	_note_tempo,8,3                 ## @note_tempo
	.comm	_note_length,4,2                ## @note_length
	.comm	_note_position,8,3              ## @note_position
	.comm	_DISABLE_AUDIO_COUNTER_1_ISR,4,2 ## @DISABLE_AUDIO_COUNTER_1_ISR
	.comm	_DISABLE_AUDIO_COUNTER_3_ISR,4,2 ## @DISABLE_AUDIO_COUNTER_3_ISR
	.comm	_ENABLE_AUDIO_COUNTER_1_ISR,4,2 ## @ENABLE_AUDIO_COUNTER_1_ISR
	.comm	_ENABLE_AUDIO_COUNTER_1_OUTPUT,4,2 ## @ENABLE_AUDIO_COUNTER_1_OUTPUT
	.comm	_ENABLE_AUDIO_COUNTER_3_ISR,4,2 ## @ENABLE_AUDIO_COUNTER_3_ISR
	.comm	_ENABLE_AUDIO_COUNTER_3_OUTPUT,4,2 ## @ENABLE_AUDIO_COUNTER_3_OUTPUT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_play_notes                     ; -- Begin function play_notes
	.p2align	2
_play_notes:                            ; @play_notes
	.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
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _audio_initialized@GOTPAGE
Lloh1:
	ldr	x8, [x8, _audio_initialized@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cbnz	w8, LBB0_2
; %bb.1:
	bl	_audio_init
LBB0_2:
Lloh3:
	adrp	x8, _audio_config@GOTPAGE
Lloh4:
	ldr	x8, [x8, _audio_config@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cbz	x8, LBB0_6
; %bb.3:
Lloh6:
	adrp	x8, _playing_note@GOTPAGE
Lloh7:
	ldr	x8, [x8, _playing_note@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	cbz	x8, LBB0_5
; %bb.4:
	bl	_stop_all_notes
LBB0_5:
Lloh9:
	adrp	x8, _playing_notes@GOTPAGE
Lloh10:
	ldr	x8, [x8, _playing_notes@GOTPAGEOFF]
	mov	w9, #1
Lloh11:
	str	w9, [x8]
Lloh12:
	adrp	x8, _notes_pointer@GOTPAGE
Lloh13:
	ldr	x8, [x8, _notes_pointer@GOTPAGEOFF]
Lloh14:
	str	x19, [x8]
Lloh15:
	adrp	x8, _notes_count@GOTPAGE
Lloh16:
	ldr	x8, [x8, _notes_count@GOTPAGEOFF]
Lloh17:
	str	w21, [x8]
Lloh18:
	adrp	x8, _notes_repeat@GOTPAGE
Lloh19:
	ldr	x8, [x8, _notes_repeat@GOTPAGEOFF]
Lloh20:
	str	w20, [x8]
Lloh21:
	adrp	x8, _place@GOTPAGE
Lloh22:
	ldr	x8, [x8, _place@GOTPAGEOFF]
Lloh23:
	str	xzr, [x8]
Lloh24:
	adrp	x8, _current_note@GOTPAGE
Lloh25:
	ldr	x8, [x8, _current_note@GOTPAGEOFF]
Lloh26:
	str	xzr, [x8]
	ldr	x8, [x19]
	ldr	x8, [x8]
Lloh27:
	adrp	x9, _note_frequency@GOTPAGE
Lloh28:
	ldr	x9, [x9, _note_frequency@GOTPAGEOFF]
	ldp	w10, w8, [x8]
	add	w11, w8, #3
	cmp	w8, #0
	csel	w8, w11, w8, lt
	asr	w8, w8, #2
	scvtf	s0, w8
Lloh29:
	str	w10, [x9]
Lloh30:
	adrp	x8, _note_tempo@GOTPAGE
Lloh31:
	ldr	x8, [x8, _note_tempo@GOTPAGEOFF]
Lloh32:
	ldr	x8, [x8]
	scvtf	s1, x8
	mov	w8, #1120403456
	fmov	s2, w8
	fdiv	s1, s1, s2
	fmul	s0, s1, s0
	fcvtzs	w8, s0
Lloh33:
	adrp	x9, _note_length@GOTPAGE
Lloh34:
	ldr	x9, [x9, _note_length@GOTPAGEOFF]
Lloh35:
	str	w8, [x9]
Lloh36:
	adrp	x8, _note_position@GOTPAGE
Lloh37:
	ldr	x8, [x8, _note_position@GOTPAGEOFF]
Lloh38:
	str	xzr, [x8]
LBB0_6:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotStr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotStr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotStr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotStr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotStr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotStr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotStr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotStr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotStr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_audio_initialized,4,2          ; @audio_initialized
	.comm	_audio_config,8,3               ; @audio_config
	.comm	_playing_note,8,3               ; @playing_note
	.comm	_playing_notes,4,2              ; @playing_notes
	.comm	_notes_pointer,8,3              ; @notes_pointer
	.comm	_notes_count,4,2                ; @notes_count
	.comm	_notes_repeat,4,2               ; @notes_repeat
	.comm	_place,8,3                      ; @place
	.comm	_current_note,8,3               ; @current_note
	.comm	_note_frequency,4,2             ; @note_frequency
	.comm	_note_tempo,8,3                 ; @note_tempo
	.comm	_note_length,4,2                ; @note_length
	.comm	_note_position,8,3              ; @note_position
	.comm	_DISABLE_AUDIO_COUNTER_1_ISR,4,2 ; @DISABLE_AUDIO_COUNTER_1_ISR
	.comm	_DISABLE_AUDIO_COUNTER_3_ISR,4,2 ; @DISABLE_AUDIO_COUNTER_3_ISR
	.comm	_ENABLE_AUDIO_COUNTER_1_ISR,4,2 ; @ENABLE_AUDIO_COUNTER_1_ISR
	.comm	_ENABLE_AUDIO_COUNTER_1_OUTPUT,4,2 ; @ENABLE_AUDIO_COUNTER_1_OUTPUT
	.comm	_ENABLE_AUDIO_COUNTER_3_ISR,4,2 ; @ENABLE_AUDIO_COUNTER_3_ISR
	.comm	_ENABLE_AUDIO_COUNTER_3_OUTPUT,4,2 ; @ENABLE_AUDIO_COUNTER_3_OUTPUT
.subsections_via_symbols
