	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_msdos_makefs                   ## -- Begin function msdos_makefs
	.p2align	4, 0x90
_msdos_makefs:                          ## @msdos_makefs
	.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	%rcx, %r13
	movq	%rdx, %r15
	movq	%rsi, %r12
	movq	%rdi, %r14
	movq	32(%rcx), %rbx
	xorl	%edi, %edi
	testq	%r14, %r14
	setne	%dil
	callq	_assert
	xorl	%edi, %edi
	testq	%r12, %r12
	setne	%dil
	callq	_assert
	xorl	%edi, %edi
	testq	%r15, %r15
	setne	%dil
	callq	_assert
	xorl	%edi, %edi
	testq	%r13, %r13
	setne	%dil
	callq	_assert
	movq	8(%r13), %rsi
	movq	%rsi, (%r13)
	movl	12(%rbx), %edi
	addq	16(%r13), %rsi
	callq	_MAX
	movl	%eax, 12(%rbx)
	movq	16(%r13), %rax
	testq	%rax, %rax
	jle	LBB0_2
## %bb.1:
	movq	%rax, (%rbx)
LBB0_2:
	movl	8(%rbx), %ecx
	movl	24(%r13), %edx
	testl	%ecx, %ecx
	je	LBB0_3
## %bb.6:
	cmpl	$-1, %edx
	je	LBB0_7
## %bb.8:
	cmpl	%ecx, %edx
	je	LBB0_10
## %bb.9:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_err
	jmp	LBB0_10
LBB0_3:
	cmpl	$-1, %edx
	jne	LBB0_5
## %bb.4:
	movl	$512, 24(%r13)                  ## imm = 0x200
	movl	$512, %edx                      ## imm = 0x200
LBB0_5:
	movl	%edx, 8(%rbx)
	jmp	LBB0_10
LBB0_7:
	movl	%ecx, 24(%r13)
LBB0_10:
	leaq	L_.str.1(%rip), %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_printf
	callq	_TIMER_START
	movq	%r14, %rdi
	xorl	%esi, %esi
	movq	%rbx, %rdx
	callq	_mkfs_msdos
	cmpl	$-1, %eax
	je	LBB0_25
## %bb.11:
	leaq	L_.str.2(%rip), %rsi
	callq	_TIMER_RESULTS
	movq	_O_RDWR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_open
	movl	%eax, 28(%r13)
	movq	%r13, -56(%rbp)
	leaq	-56(%rbp), %rdi
	callq	_msdosfs_mount
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_13
## %bb.12:
	leaq	L_.str.3(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_err
LBB0_13:
	leaq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_msdosfs_root
	testq	%rax, %rax
	je	LBB0_15
## %bb.14:
	leaq	L_.str.4(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_err
LBB0_15:
	movq	_debug@GOTPCREL(%rip), %rcx
	movq	_DEBUG_FS_MAKEFS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rcx)
	je	LBB0_17
## %bb.16:
	leaq	L_.str.5(%rip), %rdi
	movq	%r14, %rsi
	movq	%r12, %rdx
	movq	%r15, %rcx
	xorl	%eax, %eax
	callq	_printf
LBB0_17:
	leaq	L_.str.6(%rip), %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_printf
	callq	_TIMER_START
	leaq	-48(%rbp), %rdi
	callq	_VTODE
	movq	%r12, %rdi
	movl	%eax, %esi
	movq	%r15, %rdx
	movq	%r15, %rcx
	movq	%r13, %r8
	callq	_msdos_populate_dir
	cmpl	$-1, %eax
	jne	LBB0_19
## %bb.18:
	leaq	L_.str.7(%rip), %rsi
	movl	$1, %edi
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_errx
LBB0_19:
	leaq	L_.str.8(%rip), %rsi
	callq	_TIMER_RESULTS
	movq	%rbx, %rdi
	callq	_msdosfs_fsiflush
	testq	%rax, %rax
	movq	_DEBUG_FS_MAKEFS@GOTPCREL(%rip), %r15
	je	LBB0_21
## %bb.20:
	leaq	L_.str.9(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_errx
LBB0_21:
	movl	(%r15), %eax
	movq	_debug@GOTPCREL(%rip), %rbx
	testl	%eax, (%rbx)
	je	LBB0_24
## %bb.22:
	movl	$10, %edi
	callq	_putchar
	movl	(%r15), %eax
	testl	%eax, (%rbx)
	je	LBB0_24
## %bb.23:
	xorl	%eax, %eax
	callq	_bcleanup
LBB0_24:
	leaq	L_.str.10(%rip), %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_printf
LBB0_25:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"inconsistent sectorsize -S %u!= -o bytes_per_sector %u"

L_.str.1:                               ## @.str.1
	.asciz	"Creating `%s'\n"

L_.str.2:                               ## @.str.2
	.asciz	"mkfs_msdos"

	.comm	_O_RDWR,4,2                     ## @O_RDWR
L_.str.3:                               ## @.str.3
	.asciz	"msdosfs_mount"

L_.str.4:                               ## @.str.4
	.asciz	"msdosfs_root"

	.comm	_debug,4,2                      ## @debug
	.comm	_DEBUG_FS_MAKEFS,4,2            ## @DEBUG_FS_MAKEFS
L_.str.5:                               ## @.str.5
	.asciz	"msdos_makefs: image %s directory %s root %p\n"

L_.str.6:                               ## @.str.6
	.asciz	"Populating `%s'\n"

L_.str.7:                               ## @.str.7
	.asciz	"Image file `%s' not created."

L_.str.8:                               ## @.str.8
	.asciz	"msdos_populate_dir"

L_.str.9:                               ## @.str.9
	.asciz	"Unable to update FSInfo block."

L_.str.10:                              ## @.str.10
	.asciz	"Image `%s' complete\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_msdos_makefs                   ; -- Begin function msdos_makefs
	.p2align	2
_msdos_makefs:                          ; @msdos_makefs
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	ldr	x23, [x3, #32]
	cmp	x0, #0
	cset	w0, ne
	bl	_assert
	cmp	x22, #0
	cset	w0, ne
	bl	_assert
	cmp	x21, #0
	cset	w0, ne
	bl	_assert
	cmp	x20, #0
	cset	w0, ne
	bl	_assert
	ldp	x8, x9, [x20, #8]
	str	x8, [x20]
	ldr	w0, [x23, #12]
	add	x1, x9, x8
	bl	_MAX
	str	w0, [x23, #12]
	ldr	x8, [x20, #16]
	cmp	x8, #1
	b.lt	LBB0_2
; %bb.1:
	str	x8, [x23]
LBB0_2:
	ldr	w9, [x23, #8]
	ldr	w8, [x20, #24]
	cmn	w8, #1
	cbz	w9, LBB0_6
; %bb.3:
	b.eq	LBB0_9
; %bb.4:
	cmp	w8, w9
	b.eq	LBB0_10
; %bb.5:
	stp	x8, x9, [sp]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_err
	b	LBB0_10
LBB0_6:
	b.ne	LBB0_8
; %bb.7:
	mov	w8, #512
	str	w8, [x20, #24]
LBB0_8:
	str	w8, [x23, #8]
	b	LBB0_10
LBB0_9:
	str	w9, [x20, #24]
LBB0_10:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x19
	bl	_printf
	mov	x0, #0
	bl	_TIMER_START
	mov	x0, x19
	mov	x1, #0
	mov	x2, x23
	bl	_mkfs_msdos
	cmn	w0, #1
	b.eq	LBB0_25
; %bb.11:
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, #0
	bl	_TIMER_RESULTS
Lloh6:
	adrp	x8, _O_RDWR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _O_RDWR@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_open
	str	w0, [x20, #28]
	str	x20, [sp, #24]
	add	x0, sp, #24
	bl	_msdosfs_mount
	mov	x23, x0
	cbnz	x0, LBB0_13
; %bb.12:
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_13:
	add	x1, sp, #16
	mov	x0, x23
	bl	_msdosfs_root
	cbz	x0, LBB0_15
; %bb.14:
Lloh11:
	adrp	x1, l_.str.4@PAGE
Lloh12:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_15:
Lloh13:
	adrp	x24, _debug@GOTPAGE
Lloh14:
	ldr	x24, [x24, _debug@GOTPAGEOFF]
	ldr	w8, [x24]
Lloh15:
	adrp	x25, _DEBUG_FS_MAKEFS@GOTPAGE
Lloh16:
	ldr	x25, [x25, _DEBUG_FS_MAKEFS@GOTPAGEOFF]
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_17
; %bb.16:
	stp	x22, x21, [sp]
Lloh17:
	adrp	x0, l_.str.5@PAGE
Lloh18:
	add	x0, x0, l_.str.5@PAGEOFF
	mov	x1, x19
	bl	_printf
LBB0_17:
Lloh19:
	adrp	x0, l_.str.6@PAGE
Lloh20:
	add	x0, x0, l_.str.6@PAGEOFF
	mov	x1, x19
	bl	_printf
	mov	x0, #0
	bl	_TIMER_START
	add	x0, sp, #16
	bl	_VTODE
	mov	x1, x0
	mov	x0, x22
	mov	x2, x21
	mov	x3, x21
	mov	x4, x20
	bl	_msdos_populate_dir
	cmn	w0, #1
	b.ne	LBB0_19
; %bb.18:
	str	x19, [sp]
Lloh21:
	adrp	x1, l_.str.7@PAGE
Lloh22:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	w0, #1
	bl	_errx
LBB0_19:
Lloh23:
	adrp	x1, l_.str.8@PAGE
Lloh24:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	x0, #0
	bl	_TIMER_RESULTS
	mov	x0, x23
	bl	_msdosfs_fsiflush
	cbz	x0, LBB0_21
; %bb.20:
Lloh25:
	adrp	x1, l_.str.9@PAGE
Lloh26:
	add	x1, x1, l_.str.9@PAGEOFF
	mov	w0, #1
	bl	_errx
LBB0_21:
	ldr	w8, [x24]
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_24
; %bb.22:
	mov	w0, #10
	bl	_putchar
	ldr	w8, [x24]
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_24
; %bb.23:
	bl	_bcleanup
LBB0_24:
Lloh27:
	adrp	x0, l_.str.10@PAGE
Lloh28:
	add	x0, x0, l_.str.10@PAGEOFF
	mov	x1, x19
	bl	_printf
LBB0_25:
	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
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"inconsistent sectorsize -S %u!= -o bytes_per_sector %u"

l_.str.1:                               ; @.str.1
	.asciz	"Creating `%s'\n"

l_.str.2:                               ; @.str.2
	.asciz	"mkfs_msdos"

	.comm	_O_RDWR,4,2                     ; @O_RDWR
l_.str.3:                               ; @.str.3
	.asciz	"msdosfs_mount"

l_.str.4:                               ; @.str.4
	.asciz	"msdosfs_root"

	.comm	_debug,4,2                      ; @debug
	.comm	_DEBUG_FS_MAKEFS,4,2            ; @DEBUG_FS_MAKEFS
l_.str.5:                               ; @.str.5
	.asciz	"msdos_makefs: image %s directory %s root %p\n"

l_.str.6:                               ; @.str.6
	.asciz	"Populating `%s'\n"

l_.str.7:                               ; @.str.7
	.asciz	"Image file `%s' not created."

l_.str.8:                               ; @.str.8
	.asciz	"msdos_populate_dir"

l_.str.9:                               ; @.str.9
	.asciz	"Unable to update FSInfo block."

l_.str.10:                              ; @.str.10
	.asciz	"Image `%s' complete\n"

.subsections_via_symbols
