	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_init_cow_file                  ## -- Begin function init_cow_file
	.p2align	4, 0x90
_init_cow_file:                         ## @init_cow_file
	.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
	movq	%r9, %r14
	movl	%r8d, %r12d
	movl	%ecx, %r13d
	movl	%edi, %r15d
	movb	$0, -41(%rbp)
	leaq	-56(%rbp), %r9
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rdi
	movl	%r15d, %esi
	callq	_write_cow_header
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_1
LBB0_7:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	24(%rbp), %rbx
	movl	$4, %edi
	movl	%r12d, %esi
	callq	_ROUND_UP
	movl	%eax, (%r14)
	movq	_COW_VERSION@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	movq	-56(%rbp), %rsi
	movq	%rbx, (%rsp)
	movl	%r13d, %edx
	movl	%r12d, %ecx
	movl	%eax, %r8d
	movq	16(%rbp), %r9
	callq	_cow_sizes
	movslq	(%rbx), %rax
	movq	-56(%rbp), %rcx
	leaq	(%rax,%rcx), %rsi
	decq	%rsi
	movl	%r15d, %edi
	callq	_cow_seek_file
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	leaq	-41(%rbp), %rsi
	movl	%r15d, %edi
	movl	$1, %edx
	callq	_cow_write_file
	xorl	%ebx, %ebx
	cmpl	$1, %eax
	je	LBB0_7
## %bb.4:
	movl	%eax, %r14d
	movl	%eax, %edx
	negl	%edx
	leaq	L_.str.1(%rip), %rdi
	xorl	%ebx, %ebx
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_cow_printf
	testl	%r14d, %r14d
	js	LBB0_5
## %bb.6:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_7
LBB0_2:
	movl	%eax, %ebx
	movl	%eax, %esi
	negl	%esi
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_cow_printf
	jmp	LBB0_7
LBB0_5:
	movl	%r14d, %ebx
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_COW_VERSION,4,2                ## @COW_VERSION
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cow bitmap lseek failed : err = %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"Write of bitmap to new COW file '%s' failed, err = %d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_init_cow_file                  ; -- Begin function init_cow_file
	.p2align	2
_init_cow_file:                         ; @init_cow_file
	.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	x21, x7
	mov	x23, x6
	mov	x26, x5
	mov	x24, x4
	mov	x25, x3
	mov	x19, x1
	mov	x20, x0
	strb	wzr, [sp, #23]
	add	x5, sp, #24
	mov	x0, x1
	mov	x1, x20
	bl	_write_cow_header
	mov	x22, x0
	cbz	w0, LBB0_2
LBB0_1:
	mov	x0, x22
	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
LBB0_2:
	mov	w0, #4
	mov	x1, x24
	bl	_ROUND_UP
	mov	x4, x0
	str	w0, [x26]
Lloh0:
	adrp	x8, _COW_VERSION@GOTPAGE
Lloh1:
	ldr	x8, [x8, _COW_VERSION@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	ldr	x1, [sp, #24]
	mov	x2, x25
	mov	x3, x24
	mov	x5, x23
	mov	x6, x21
	bl	_cow_sizes
	ldrsw	x8, [x21]
	ldr	x9, [sp, #24]
	add	x8, x8, x9
	sub	x1, x8, #1
	mov	x0, x20
	bl	_cow_seek_file
	tbnz	w0, #31, LBB0_5
; %bb.3:
	add	x1, sp, #23
	mov	x0, x20
	mov	w2, #1
	bl	_cow_write_file
	cmp	w0, #1
	b.ne	LBB0_6
; %bb.4:
	mov	w22, #0
	b	LBB0_1
LBB0_5:
	mov	x22, x0
	neg	w8, w0
	str	x8, [sp]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_cow_printf
	b	LBB0_1
LBB0_6:
	mov	x22, x0
	neg	w8, w0
	stp	x19, x8, [sp]
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_cow_printf
	tbnz	w22, #31, LBB0_1
; %bb.7:
Lloh7:
	adrp	x8, _EINVAL@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_COW_VERSION,4,2                ; @COW_VERSION
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cow bitmap lseek failed : err = %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"Write of bitmap to new COW file '%s' failed, err = %d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
.subsections_via_symbols
