	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pas_midi_out
_pas_midi_out:                          ## @pas_midi_out
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	movq	_pas_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock_irqsave
	movq	_qlen@GOTPCREL(%rip), %r12
	cmpl	$0, (%r12)
	je	LBB0_4
## %bb.1:
	movq	_qhead@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rax
	movq	_tmp_queue@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r14), %rcx
	movzbl	(%rcx,%rax), %edi
	callq	_dump_to_midi
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	(%rbx), %rax
	incq	%rax
	decl	(%r12)
	movq	%rax, (%rbx)
	jne	LBB0_2
LBB0_4:
	movq	_pas_lock@GOTPCREL(%rip), %rdi
	callq	_spin_unlock_irqrestore
	movl	(%r12), %ecx
	testl	%ecx, %ecx
	je	LBB0_5
LBB0_7:
	xorl	%eax, %eax
	cmpl	$255, %ecx
	jg	LBB0_9
## %bb.8:
	movq	_pas_lock@GOTPCREL(%rip), %r14
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movq	_tmp_queue@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_qtail@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	movb	%r15b, (%rax,%rdx)
	incl	(%r12)
	incq	(%rcx)
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	movl	$1, %eax
	jmp	LBB0_9
LBB0_5:
	movzbl	%r15b, %edi
	callq	_dump_to_midi
	movq	%rax, %rcx
	movl	$1, %eax
	testq	%rcx, %rcx
	je	LBB0_6
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	(%r12), %ecx
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_pas_lock,4,2                   ## @pas_lock
	.comm	_qlen,4,2                       ## @qlen
	.comm	_tmp_queue,8,3                  ## @tmp_queue
	.comm	_qhead,8,3                      ## @qhead
	.comm	_qtail,8,3                      ## @qtail
	.no_dead_strip	_pas_midi_out
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pas_midi_out
_pas_midi_out:                          ; @pas_midi_out
	.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	x19, x1
Lloh0:
	adrp	x0, _pas_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _pas_lock@GOTPAGEOFF]
	bl	_spin_lock_irqsave
Lloh2:
	adrp	x21, _qlen@GOTPAGE
Lloh3:
	ldr	x21, [x21, _qlen@GOTPAGEOFF]
	ldr	w8, [x21]
Lloh4:
	adrp	x22, _tmp_queue@GOTPAGE
Lloh5:
	ldr	x22, [x22, _tmp_queue@GOTPAGEOFF]
	cbz	w8, LBB0_4
; %bb.1:
Lloh6:
	adrp	x20, _qhead@GOTPAGE
Lloh7:
	ldr	x20, [x20, _qhead@GOTPAGEOFF]
	ldr	x8, [x20]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x22]
	ldrb	w0, [x9, x8]
	bl	_dump_to_midi
	cbz	x0, LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w9, [x21]
	ldr	x8, [x20]
	add	x8, x8, #1
	str	x8, [x20]
	subs	w9, w9, #1
	str	w9, [x21]
	b.ne	LBB0_2
LBB0_4:
Lloh8:
	adrp	x0, _pas_lock@GOTPAGE
Lloh9:
	ldr	x0, [x0, _pas_lock@GOTPAGEOFF]
	bl	_spin_unlock_irqrestore
	ldr	w8, [x21]
	cbz	w8, LBB0_7
; %bb.5:
	cmp	w8, #255
	b.le	LBB0_9
LBB0_6:
	mov	w0, #0
	b	LBB0_11
LBB0_7:
	mov	x0, x19
	bl	_dump_to_midi
	cbnz	x0, LBB0_10
; %bb.8:
	ldr	w8, [x21]
	cmp	w8, #255
	b.gt	LBB0_6
LBB0_9:
Lloh10:
	adrp	x20, _pas_lock@GOTPAGE
Lloh11:
	ldr	x20, [x20, _pas_lock@GOTPAGEOFF]
	mov	x0, x20
	bl	_spin_lock_irqsave
	ldr	x8, [x22]
Lloh12:
	adrp	x9, _qtail@GOTPAGE
Lloh13:
	ldr	x9, [x9, _qtail@GOTPAGEOFF]
	ldr	x10, [x9]
	strb	w19, [x8, x10]
	ldr	w8, [x21]
	add	w8, w8, #1
	str	w8, [x21]
	ldr	x8, [x9]
	add	x8, x8, #1
	str	x8, [x9]
	mov	x0, x20
	bl	_spin_unlock_irqrestore
LBB0_10:
	mov	w0, #1
LBB0_11:
	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 AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_pas_lock,4,2                   ; @pas_lock
	.comm	_qlen,4,2                       ; @qlen
	.comm	_tmp_queue,8,3                  ; @tmp_queue
	.comm	_qhead,8,3                      ; @qhead
	.comm	_qtail,8,3                      ; @qtail
	.no_dead_strip	_pas_midi_out
.subsections_via_symbols
