	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ffs_create_image
_ffs_create_image:                      ## @ffs_create_image
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_O_RDWR@GOTPCREL(%rip), %rax
	movq	_O_CREAT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	movq	%rsi, %r15
	movq	%rdi, %r14
	xorl	%edi, %edi
	testq	%r14, %r14
	setne	%dil
	callq	_assert
	xorl	%edi, %edi
	testq	%r15, %r15
	setne	%dil
	callq	_assert
	xorl	%eax, %eax
	cmpq	$0, (%r15)
	jne	LBB0_2
## %bb.1:
	movq	_O_TRUNC@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_2:
	orl	%eax, %ebx
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	$438, %edx                      ## imm = 0x1B6
	callq	_open
	movl	%eax, 8(%r15)
	cmpl	$-1, %eax
	je	LBB0_3
## %bb.4:
	movq	16(%r15), %r12
	cmpq	$0, 40(%r15)
	je	LBB0_8
## %bb.5:
	movl	%eax, %edi
	movq	%r12, %rsi
	callq	_ftruncate
	cmpl	$-1, %eax
	je	LBB0_6
## %bb.7:
	xorl	%r13d, %r13d
	cmpq	$0, 40(%r15)
	movl	$0, %ebx
	jne	LBB0_11
	jmp	LBB0_8
LBB0_3:
	leaq	L_.str(%rip), %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_warn
	movl	$-1, %eax
	jmp	LBB0_31
LBB0_6:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_warn
	movq	$0, 40(%r15)
LBB0_8:
	movq	_debug@GOTPCREL(%rip), %rax
	movq	_DEBUG_FS_CREATE_IMAGE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%rax)
	je	LBB0_10
## %bb.9:
	leaq	L_.str.2(%rip), %rdi
	movq	%r14, %rsi
	movq	%r12, %rdx
	movl	$8192, %ecx                     ## imm = 0x2000
	xorl	%eax, %eax
	callq	_printf
LBB0_10:
	movl	$1, %edi
	movl	$8192, %esi                     ## imm = 0x2000
	callq	_ecalloc
	movq	%rax, %r13
	movq	%r12, %rbx
LBB0_11:
	movq	(%r15), %rsi
	testq	%rsi, %rsi
	je	LBB0_15
## %bb.12:
	movl	8(%r15), %edi
	movq	_SEEK_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_lseek
	cmpl	$-1, %eax
	je	LBB0_13
LBB0_15:
	testq	%rbx, %rbx
	jle	LBB0_19
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movl	8(%r15), %r12d
	movl	$8192, %edi                     ## imm = 0x2000
	movq	%rbx, %rsi
	callq	_MIN
	movl	%r12d, %edi
	movq	%r13, %rsi
	movl	%eax, %edx
	callq	_write
	cmpl	$-1, %eax
	je	LBB0_17
## %bb.18:                              ##   in Loop: Header=BB0_16 Depth=1
	cltq
	subq	%rax, %rbx
	jg	LBB0_16
LBB0_19:
	testq	%r13, %r13
	je	LBB0_21
## %bb.20:
	movq	%r13, %rdi
	callq	_free
LBB0_21:
	movq	_debug@GOTPCREL(%rip), %r12
	movq	_DEBUG_FS_CREATE_IMAGE@GOTPCREL(%rip), %r13
	movl	(%r13), %eax
	testl	%eax, (%r12)
	je	LBB0_23
## %bb.22:
	leaq	L_.str.5(%rip), %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_printf
LBB0_23:
	movq	_stampst@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_24
## %bb.25:
	movq	_start_time@GOTPCREL(%rip), %rax
	jmp	LBB0_26
LBB0_13:
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	callq	_warn
	jmp	LBB0_14
LBB0_17:
	leaq	L_.str.4(%rip), %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_warn
LBB0_14:
	movq	%r13, %rdi
	callq	_free
	movl	$-1, %eax
	jmp	LBB0_31
LBB0_24:
	addq	$8, %rax
LBB0_26:
	movq	(%rax), %rbx
	movq	%rbx, %rdi
	callq	_srandom
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	callq	_ffs_mkfs
	movq	%rax, %rbx
	movq	%rax, 32(%r15)
	movl	(%r13), %eax
	testl	%eax, (%r12)
	je	LBB0_28
## %bb.27:
	movq	32(%rbx), %rax
	movq	%rax, -48(%rbp)
	leaq	-48(%rbp), %rdi
	callq	_ctime
	leaq	L_.str.6(%rip), %rdi
	movq	%rbx, %rsi
	movq	%rax, %rdx
	xorl	%eax, %eax
	callq	_printf
	movq	24(%rbx), %rsi
	movq	16(%rbx), %rdx
	movq	(%rbx), %rcx
	movq	8(%rbx), %r8
	leaq	L_.str.7(%rip), %rdi
	xorl	%eax, %eax
	callq	_printf
LBB0_28:
	movq	_UFS_ROOTINO@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	addq	(%rbx), %rdx
	movq	24(%r15), %rcx
	cmpq	%rcx, %rdx
	jge	LBB0_30
## %bb.29:
	leaq	L_.str.8(%rip), %rdi
	movq	%r14, %rsi
	callq	_warnx
	movl	$-1, %eax
	jmp	LBB0_31
LBB0_30:
	movl	8(%r15), %eax
LBB0_31:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_O_RDWR,4,2                     ## @O_RDWR
	.comm	_O_CREAT,4,2                    ## @O_CREAT
	.comm	_O_TRUNC,4,2                    ## @O_TRUNC
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Can't open `%s' for writing"

L_.str.1:                               ## @.str.1
	.asciz	"sparse option disabled."

	.comm	_debug,4,2                      ## @debug
	.comm	_DEBUG_FS_CREATE_IMAGE,4,2      ## @DEBUG_FS_CREATE_IMAGE
L_.str.2:                               ## @.str.2
	.asciz	"zero-ing image `%s', %lld sectors, using %d byte chunks\n"

	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
L_.str.3:                               ## @.str.3
	.asciz	"can't seek"

L_.str.4:                               ## @.str.4
	.asciz	"zeroing image, %lld bytes to go"

L_.str.5:                               ## @.str.5
	.asciz	"calling mkfs(\"%s\", ...)\n"

	.comm	_stampst,16,3                   ## @stampst
	.comm	_start_time,8,3                 ## @start_time
L_.str.6:                               ## @.str.6
	.asciz	"mkfs returned %p; fs_time %s"

L_.str.7:                               ## @.str.7
	.asciz	"fs totals: nbfree %lld, nffree %lld, nifree %lld, ndir %lld\n"

	.comm	_UFS_ROOTINO,8,3                ## @UFS_ROOTINO
L_.str.8:                               ## @.str.8
	.asciz	"Image file `%s' has %lld free inodes; %lld are required."

	.no_dead_strip	_ffs_create_image
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ffs_create_image
_ffs_create_image:                      ; @ffs_create_image
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _O_RDWR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _O_RDWR@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _O_CREAT@GOTPAGE
Lloh4:
	ldr	x9, [x9, _O_CREAT@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w21, w9, w8
	cmp	x0, #0
	cset	w0, ne
	bl	_assert
	cmp	x20, #0
	cset	w0, ne
	bl	_assert
	ldr	x8, [x20]
Lloh6:
	adrp	x9, _O_TRUNC@GOTPAGE
Lloh7:
	ldr	x9, [x9, _O_TRUNC@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	x8, #0
	csel	w8, w9, wzr, eq
	orr	w1, w21, w8
	mov	x0, x19
	mov	w2, #438
	bl	_open
	str	w0, [x20, #8]
	cmn	w0, #1
	b.eq	LBB0_5
; %bb.1:
	ldr	x21, [x20, #16]
	ldr	x8, [x20, #40]
Lloh9:
	adrp	x24, _debug@GOTPAGE
Lloh10:
	ldr	x24, [x24, _debug@GOTPAGEOFF]
Lloh11:
	adrp	x25, _DEBUG_FS_CREATE_IMAGE@GOTPAGE
Lloh12:
	ldr	x25, [x25, _DEBUG_FS_CREATE_IMAGE@GOTPAGEOFF]
	cbz	x8, LBB0_7
; %bb.2:
	mov	x1, x21
	bl	_ftruncate
	cmn	w0, #1
	b.eq	LBB0_6
; %bb.3:
	ldr	x8, [x20, #40]
	cbz	x8, LBB0_7
; %bb.4:
	mov	x22, #0
	mov	x21, #0
	ldr	x1, [x20]
	cbnz	x1, LBB0_10
	b	LBB0_11
LBB0_5:
	str	x19, [sp]
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	bl	_warn
	mov	w0, #-1
	b	LBB0_26
LBB0_6:
Lloh15:
	adrp	x0, l_.str.1@PAGE
Lloh16:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_warn
	str	xzr, [x20, #40]
LBB0_7:
	ldr	w8, [x24]
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.8:
	mov	w8, #8192
	stp	x21, x8, [sp, #8]
	str	x19, [sp]
Lloh17:
	adrp	x0, l_.str.2@PAGE
Lloh18:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_printf
LBB0_9:
	mov	w0, #1
	mov	w1, #8192
	bl	_ecalloc
	mov	x22, x0
	ldr	x1, [x20]
	cbz	x1, LBB0_11
LBB0_10:
	ldr	w0, [x20, #8]
Lloh19:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh20:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh21:
	ldr	w2, [x8]
	bl	_lseek
	cmn	w0, #1
	b.eq	LBB0_22
LBB0_11:
	cmp	x21, #1
	b.lt	LBB0_14
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	w23, [x20, #8]
	mov	w0, #8192
	mov	x1, x21
	bl	_MIN
	mov	x2, x0
	mov	x0, x23
	mov	x1, x22
	bl	_write
	cmn	w0, #1
	b.eq	LBB0_23
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=1
	sub	x21, x21, w0, sxtw
	cmp	x21, #0
	b.gt	LBB0_12
LBB0_14:
	cbz	x22, LBB0_16
; %bb.15:
	mov	x0, x22
	bl	_free
LBB0_16:
	ldr	w8, [x24]
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_18
; %bb.17:
	str	x19, [sp]
Lloh22:
	adrp	x0, l_.str.5@PAGE
Lloh23:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_printf
LBB0_18:
Lloh24:
	adrp	x8, _stampst@GOTPAGE
Lloh25:
	ldr	x8, [x8, _stampst@GOTPAGEOFF]
	ldr	x9, [x8], #8
Lloh26:
	adrp	x10, _start_time@GOTPAGE
Lloh27:
	ldr	x10, [x10, _start_time@GOTPAGEOFF]
	cmp	x9, #0
	csel	x8, x10, x8, eq
	ldr	x21, [x8]
	mov	x0, x21
	bl	_srandom
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_ffs_mkfs
	mov	x21, x0
	str	x0, [x20, #32]
	ldr	w8, [x24]
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_20
; %bb.19:
	ldr	x8, [x21, #32]
	str	x8, [sp, #40]
	add	x0, sp, #40
	bl	_ctime
	stp	x21, x0, [sp]
Lloh28:
	adrp	x0, l_.str.6@PAGE
Lloh29:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_printf
	ldp	x9, x8, [x21, #16]
	ldp	x10, x11, [x21]
	stp	x10, x11, [sp, #16]
	stp	x8, x9, [sp]
Lloh30:
	adrp	x0, l_.str.7@PAGE
Lloh31:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_printf
LBB0_20:
	ldr	x8, [x21]
Lloh32:
	adrp	x9, _UFS_ROOTINO@GOTPAGE
Lloh33:
	ldr	x9, [x9, _UFS_ROOTINO@GOTPAGEOFF]
Lloh34:
	ldr	x9, [x9]
	ldr	x3, [x20, #24]
	add	x2, x9, x8
	cmp	x2, x3
	b.ge	LBB0_25
; %bb.21:
Lloh35:
	adrp	x0, l_.str.8@PAGE
Lloh36:
	add	x0, x0, l_.str.8@PAGEOFF
	mov	x1, x19
	bl	_warnx
	mov	w0, #-1
	b	LBB0_26
LBB0_22:
Lloh37:
	adrp	x0, l_.str.3@PAGE
Lloh38:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_24
LBB0_23:
	str	x21, [sp]
Lloh39:
	adrp	x0, l_.str.4@PAGE
Lloh40:
	add	x0, x0, l_.str.4@PAGEOFF
LBB0_24:
	bl	_warn
	mov	x0, x22
	bl	_free
	mov	w0, #-1
	b	LBB0_26
LBB0_25:
	ldr	w0, [x20, #8]
LBB0_26:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.cfi_endproc
                                        ; -- End function
	.comm	_O_RDWR,4,2                     ; @O_RDWR
	.comm	_O_CREAT,4,2                    ; @O_CREAT
	.comm	_O_TRUNC,4,2                    ; @O_TRUNC
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Can't open `%s' for writing"

l_.str.1:                               ; @.str.1
	.asciz	"sparse option disabled."

	.comm	_debug,4,2                      ; @debug
	.comm	_DEBUG_FS_CREATE_IMAGE,4,2      ; @DEBUG_FS_CREATE_IMAGE
l_.str.2:                               ; @.str.2
	.asciz	"zero-ing image `%s', %lld sectors, using %d byte chunks\n"

	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
l_.str.3:                               ; @.str.3
	.asciz	"can't seek"

l_.str.4:                               ; @.str.4
	.asciz	"zeroing image, %lld bytes to go"

l_.str.5:                               ; @.str.5
	.asciz	"calling mkfs(\"%s\", ...)\n"

	.comm	_stampst,16,3                   ; @stampst
	.comm	_start_time,8,3                 ; @start_time
l_.str.6:                               ; @.str.6
	.asciz	"mkfs returned %p; fs_time %s"

l_.str.7:                               ; @.str.7
	.asciz	"fs totals: nbfree %lld, nffree %lld, nifree %lld, ndir %lld\n"

	.comm	_UFS_ROOTINO,8,3                ; @UFS_ROOTINO
l_.str.8:                               ; @.str.8
	.asciz	"Image file `%s' has %lld free inodes; %lld are required."

	.no_dead_strip	_ffs_create_image
.subsections_via_symbols
