	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_usbmidi_emagic_output
_snd_usbmidi_emagic_output:             ## @snd_usbmidi_emagic_output
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	(%rdi), %ebx
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	movl	4(%rdi), %edx
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	movq	(%rsi), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movl	$16, %r14d
	jmp	LBB0_1
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_1 Depth=1
	leaq	(%r15,%r13), %rax
	addq	$8, %rax
	movq	$0, (%rax)
	movl	-52(%rbp), %edx                 ## 4-byte Reload
LBB0_13:                                ##   in Loop: Header=BB0_1 Depth=1
	incl	%ebx
	decl	%r14d
	je	LBB0_14
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %r12d
	andl	$15, %r12d
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %r15
	movq	%r12, %r13
	shlq	$4, %r13
	cmpq	$0, 8(%r15,%r13)
	je	LBB0_13
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	%edx, -52(%rbp)                 ## 4-byte Spill
	movl	(%r15,%r13), %edi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movl	$1, %edx
	callq	_snd_rawmidi_transmit_peek
	cmpl	$1, %eax
	jne	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	cmpl	(%rax), %r12d
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	testl	%edx, %edx
	jg	LBB0_9
	jmp	LBB0_17
LBB0_6:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	cmpl	$2, %edx
	jl	LBB0_14
## %bb.7:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movl	%r12d, (%rax)
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	$245, (%rcx)
	leal	1(%rbx), %eax
	andl	$15, %eax
	movl	%eax, 4(%rcx)
	addq	$8, %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	addl	$-2, %edx
	testl	%edx, %edx
	jle	LBB0_17
LBB0_9:                                 ##   in Loop: Header=BB0_1 Depth=1
	addq	%r13, %r15
	movl	(%r15), %edi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movl	%edx, %r15d
	callq	_snd_rawmidi_transmit
	testl	%eax, %eax
	jle	LBB0_10
## %bb.11:                              ##   in Loop: Header=BB0_1 Depth=1
	subl	%eax, %r15d
	movl	%r15d, %edx
	jle	LBB0_17
## %bb.12:                              ##   in Loop: Header=BB0_1 Depth=1
	movl	%eax, %eax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%rcx,%rax,4), %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_13
LBB0_10:                                ##   in Loop: Header=BB0_1 Depth=1
	movl	%r15d, %edx
	jmp	LBB0_13
LBB0_14:
	testl	%edx, %edx
	jle	LBB0_17
## %bb.15:
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	cmpl	4(%rax), %edx
	jge	LBB0_17
## %bb.16:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	$255, (%rax)
	decl	%edx
LBB0_17:
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movl	4(%rax), %eax
	subl	%edx, %eax
	movl	%eax, 8(%rcx)
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_snd_usbmidi_emagic_output
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_usbmidi_emagic_output
_snd_usbmidi_emagic_output:             ; @snd_usbmidi_emagic_output
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x1
	mov	x20, x0
	mov	w23, #0
	ldr	x22, [x1]
	ldp	w24, w21, [x0]
	mov	w25, #245
	b	LBB0_3
LBB0_1:                                 ;   in Loop: Header=BB0_3 Depth=1
	str	xzr, [x28]
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w23, w23, #1
	cmp	w23, #16
	b.eq	LBB0_12
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	w8, w24, w23
	and	w27, w8, #0xf
	ldr	x8, [x20, #8]
	add	x28, x8, w27, uxtw #4
	ldr	x9, [x28, #8]!
	cbz	x9, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x26, x8, x27, lsl #4
	ldr	w0, [x26]
	mov	x1, x22
	mov	w2, #1
	bl	_snd_rawmidi_transmit_peek
	cmp	w0, #1
	b.ne	LBB0_1
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x20]
	cmp	w27, w8
	b.eq	LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	cmp	w21, #1
	b.le	LBB0_12
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	str	w27, [x20]
	add	w8, w24, w23
	add	w8, w8, #1
	and	w8, w8, #0xf
	stp	w25, w8, [x22], #8
	sub	w21, w21, #2
LBB0_8:                                 ;   in Loop: Header=BB0_3 Depth=1
	cmp	w21, #1
	b.lt	LBB0_15
; %bb.9:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x26]
	mov	x1, x22
	mov	x2, x21
	bl	_snd_rawmidi_transmit
	cmp	w0, #1
	b.lt	LBB0_2
; %bb.10:                               ;   in Loop: Header=BB0_3 Depth=1
	sub	w21, w21, w0
	cmp	w21, #1
	b.lt	LBB0_15
; %bb.11:                               ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x22, w0, uxtw #2
	b	LBB0_2
LBB0_12:
	subs	w8, w21, #1
	b.lt	LBB0_15
; %bb.13:
	ldr	w9, [x20, #4]
	cmp	w21, w9
	b.ge	LBB0_15
; %bb.14:
	mov	w9, #255
	str	w9, [x22]
	mov	x21, x8
LBB0_15:
	ldr	w8, [x20, #4]
	sub	w8, w8, w21
	str	w8, [x19, #8]
	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
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_snd_usbmidi_emagic_output
.subsections_via_symbols
