	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_DSoundEnumerate                ## -- Begin function DSoundEnumerate
	.p2align	4, 0x90
_DSoundEnumerate:                       ## @DSoundEnumerate
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r13
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r12
	movq	_RootInfo@GOTPCREL(%rip), %r14
	cmpq	$0, (%r14)
	jne	LBB0_2
## %bb.1:
	movq	_RootInfo@GOTPCREL(%rip), %rdi
	callq	_EnumAudioDeviceInterfaces
LBB0_2:
	movq	%r12, %rax
	orq	-56(%rbp), %rax                 ## 8-byte Folded Reload
	jne	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	callq	_DPRINT
	movq	_DSERR_INVALIDPARAM@GOTPCREL(%rip), %rbx
	jmp	LBB0_18
LBB0_4:
	movq	_DS_OK@GOTPCREL(%rip), %rbx
	cmpq	$0, (%r14)
	je	LBB0_18
## %bb.5:
	testq	%r13, %r13
	jne	LBB0_6
## %bb.7:
	movq	_IDS_PRIMARY_RECORD_DEVICE@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_6:
	movq	_IDS_PRIMARY_PLAYBACK_DEVICE@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %ecx
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%rsp)
	leaq	l_.str.1(%rip), %r9
	movq	%r12, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	callq	_DoDSoundCallback
	testq	%rax, %rax
	je	LBB0_18
## %bb.9:
	movq	(%r14), %r14
	movq	_GUID_NULL@GOTPCREL(%rip), %rbx
	movq	%r12, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_10 Depth=1
	xorl	%ecx, %ecx
	leaq	l_.str.1(%rip), %r9
	callq	_DoDSoundCallback
	testq	%rax, %rax
	je	LBB0_17
LBB0_16:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	8(%r14), %r14
	testq	%r14, %r14
	je	LBB0_17
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	16(%r14), %rdi
	testq	%r13, %r13
	je	LBB0_13
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	addq	$4, %rdi
	movq	%rbx, %rsi
	callq	_IsEqualGUID
	testl	%eax, %eax
	jne	LBB0_16
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	%r13, %r15
	leaq	-80(%rbp), %r13
	movq	%r13, %rdi
	movl	$8, %esi
	callq	_RtlZeroMemory
	movq	(%r14), %rax
	movq	8(%rax), %rax
	xorl	%edi, %edi
	movq	_ULONG_MAX@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	setne	%dil
	callq	_ASSERT
	movq	(%r14), %rax
	movl	8(%rax), %edi
	movq	%r13, %rsi
	movq	%r15, %r13
	movl	$8, %edx
	callq	_waveOutGetDevCapsW
	movq	-80(%rbp), %r8
	movq	_MAXPNAMELEN@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	movl	$0, -4(%r8,%rax,4)
	movq	16(%r14), %rdx
	addq	$4, %rdx
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%rsp)
	movq	%r12, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	%rbx, %rsi
	callq	_IsEqualGUID
	testl	%eax, %eax
	jne	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	%rbx, %r15
	leaq	-72(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$8, %esi
	callq	_RtlZeroMemory
	movq	(%r14), %rax
	movq	8(%rax), %rax
	xorl	%edi, %edi
	movq	_ULONG_MAX@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	setne	%dil
	callq	_ASSERT
	movq	(%r14), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	movq	%r15, %rbx
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	movl	$8, %edx
	callq	_waveInGetDevCapsW
	movq	-72(%rbp), %r8
	movq	_MAXPNAMELEN@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	movl	$0, -4(%r8,%rax,4)
	movq	16(%r14), %rdx
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%rsp)
	movq	%r12, %rdi
	movq	%r15, %rsi
	jmp	LBB0_15
LBB0_17:
	movq	_DS_OK@GOTPCREL(%rip), %rbx
LBB0_18:
	movl	(%rbx), %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RootInfo,8,3                   ## @RootInfo
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No callback\n"

	.comm	_DSERR_INVALIDPARAM,4,2         ## @DSERR_INVALIDPARAM
	.comm	_IDS_PRIMARY_PLAYBACK_DEVICE,4,2 ## @IDS_PRIMARY_PLAYBACK_DEVICE
	.comm	_IDS_PRIMARY_RECORD_DEVICE,4,2  ## @IDS_PRIMARY_RECORD_DEVICE
	.section	__TEXT,__const
	.p2align	2                               ## @.str.1
l_.str.1:
	.space	4

	.comm	_DS_OK,4,2                      ## @DS_OK
	.comm	_GUID_NULL,4,2                  ## @GUID_NULL
	.comm	_ULONG_MAX,8,3                  ## @ULONG_MAX
	.comm	_MAXPNAMELEN,4,2                ## @MAXPNAMELEN
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_DSoundEnumerate                ; -- Begin function DSoundEnumerate
	.p2align	2
_DSoundEnumerate:                       ; @DSoundEnumerate
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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, x3
	mov	x20, x2
	mov	x21, x1
	mov	x22, x0
Lloh0:
	adrp	x23, _RootInfo@GOTPAGE
Lloh1:
	ldr	x23, [x23, _RootInfo@GOTPAGEOFF]
	ldr	x8, [x23]
	cbz	x8, LBB0_3
; %bb.1:
	orr	x8, x22, x21
	cbnz	x8, LBB0_4
LBB0_2:
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DPRINT
Lloh4:
	adrp	x25, _DSERR_INVALIDPARAM@GOTPAGE
Lloh5:
	ldr	x25, [x25, _DSERR_INVALIDPARAM@GOTPAGEOFF]
	b	LBB0_15
LBB0_3:
Lloh6:
	adrp	x0, _RootInfo@GOTPAGE
Lloh7:
	ldr	x0, [x0, _RootInfo@GOTPAGEOFF]
	bl	_EnumAudioDeviceInterfaces
	orr	x8, x22, x21
	cbz	x8, LBB0_2
LBB0_4:
	ldr	x8, [x23]
	cbz	x8, LBB0_14
; %bb.5:
Lloh8:
	adrp	x8, _IDS_PRIMARY_RECORD_DEVICE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _IDS_PRIMARY_RECORD_DEVICE@GOTPAGEOFF]
Lloh10:
	adrp	x9, _IDS_PRIMARY_PLAYBACK_DEVICE@GOTPAGE
Lloh11:
	ldr	x9, [x9, _IDS_PRIMARY_PLAYBACK_DEVICE@GOTPAGEOFF]
	cmp	x19, #0
	csel	x8, x8, x9, eq
	ldr	w3, [x8]
Lloh12:
	adrp	x5, l_.str.1@PAGE
Lloh13:
	add	x5, x5, l_.str.1@PAGEOFF
	mov	x0, x22
	mov	x1, x21
	mov	x2, #0
	mov	x4, #0
	mov	x6, x20
	bl	_DoDSoundCallback
	cbz	x0, LBB0_14
; %bb.6:
	ldr	x26, [x23]
Lloh14:
	adrp	x23, _GUID_NULL@GOTPAGE
Lloh15:
	ldr	x23, [x23, _GUID_NULL@GOTPAGEOFF]
Lloh16:
	adrp	x27, _ULONG_MAX@GOTPAGE
Lloh17:
	ldr	x27, [x27, _ULONG_MAX@GOTPAGEOFF]
Lloh18:
	adrp	x28, _MAXPNAMELEN@GOTPAGE
Lloh19:
	ldr	x28, [x28, _MAXPNAMELEN@GOTPAGEOFF]
Lloh20:
	adrp	x24, l_.str.1@PAGE
Lloh21:
	add	x24, x24, l_.str.1@PAGEOFF
Lloh22:
	adrp	x25, _DS_OK@GOTPAGE
Lloh23:
	ldr	x25, [x25, _DS_OK@GOTPAGEOFF]
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x22
	mov	x1, x21
	mov	w3, #0
	mov	x5, x24
	mov	x6, x20
	bl	_DoDSoundCallback
	cbz	x0, LBB0_15
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	ldr	x26, [x26, #8]
	cbz	x26, LBB0_15
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x26, #16]
	cbz	x19, LBB0_12
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x0, x0, #4
	mov	x1, x23
	bl	_IsEqualGUID
	cbnz	w0, LBB0_8
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x0, sp, #8
	mov	w1, #8
	bl	_RtlZeroMemory
	ldr	x8, [x26]
	ldr	x8, [x8, #8]
	ldr	x9, [x27]
	cmp	x8, x9
	cset	w0, ne
	bl	_ASSERT
	ldr	x8, [x26]
	ldr	w0, [x8, #8]
	add	x1, sp, #8
	mov	w2, #8
	bl	_waveOutGetDevCapsW
	ldr	x4, [sp, #8]
	ldrsw	x8, [x28]
	add	x8, x4, x8, lsl #2
	stur	wzr, [x8, #-4]
	ldr	x8, [x26, #16]
	add	x2, x8, #4
	b	LBB0_7
LBB0_12:                                ;   in Loop: Header=BB0_9 Depth=1
	mov	x1, x23
	bl	_IsEqualGUID
	cbnz	w0, LBB0_8
; %bb.13:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, sp
	mov	w1, #8
	bl	_RtlZeroMemory
	ldr	x8, [x26]
	ldr	x8, [x8, #8]
	ldr	x9, [x27]
	cmp	x8, x9
	cset	w0, ne
	bl	_ASSERT
	ldr	x8, [x26]
	ldr	w0, [x8]
	mov	x1, sp
	mov	w2, #8
	bl	_waveInGetDevCapsW
	ldr	x4, [sp]
	ldrsw	x8, [x28]
	add	x8, x4, x8, lsl #2
	stur	wzr, [x8, #-4]
	ldr	x2, [x26, #16]
	b	LBB0_7
LBB0_14:
Lloh24:
	adrp	x25, _DS_OK@GOTPAGE
Lloh25:
	ldr	x25, [x25, _DS_OK@GOTPAGEOFF]
LBB0_15:
	ldr	w0, [x25]
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_RootInfo,8,3                   ; @RootInfo
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No callback\n"

	.comm	_DSERR_INVALIDPARAM,4,2         ; @DSERR_INVALIDPARAM
	.comm	_IDS_PRIMARY_PLAYBACK_DEVICE,4,2 ; @IDS_PRIMARY_PLAYBACK_DEVICE
	.comm	_IDS_PRIMARY_RECORD_DEVICE,4,2  ; @IDS_PRIMARY_RECORD_DEVICE
	.section	__TEXT,__const
	.p2align	2                               ; @.str.1
l_.str.1:
	.space	4

	.comm	_DS_OK,4,2                      ; @DS_OK
	.comm	_GUID_NULL,4,2                  ; @GUID_NULL
	.comm	_ULONG_MAX,8,3                  ; @ULONG_MAX
	.comm	_MAXPNAMELEN,4,2                ; @MAXPNAMELEN
.subsections_via_symbols
