	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function write_partition
_write_partition:                       ## @write_partition
	.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
	movl	$4120, %eax                     ## imm = 0x1018
	callq	____chkstk_darwin
	subq	%rax, %rsp
	popq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, -4152(%rbp)               ## 8-byte Spill
	movq	%rdx, %r12
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	addq	8(%rdx), %rsi
	movq	_SEEK_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_fseek
	movl	(%r12), %ebx
	cmpq	$4096, %rbx                     ## imm = 0x1000
	jae	LBB0_1
## %bb.15:
	xorl	%eax, %eax
LBB0_7:
	subq	%rax, %rbx
	jbe	LBB0_13
## %bb.8:
	leaq	-4144(%rbp), %rdi
	movq	%rbx, %rsi
	movl	$1, %edx
	movq	%r15, %rcx
	callq	_fread
	cmpl	$1, %eax
	je	LBB0_10
## %bb.9:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movl	$1, %edi
	callq	_error
LBB0_10:
	leaq	-4144(%rbp), %rdi
	movq	%rbx, %rsi
	movl	$1, %edx
	movq	-4152(%rbp), %rcx               ## 8-byte Reload
	callq	_fwrite
	cmpl	$1, %eax
	jne	LBB0_11
LBB0_13:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_16
## %bb.14:
	addq	$4120, %rsp                     ## imm = 0x1018
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	xorl	%r14d, %r14d
	leaq	-4144(%rbp), %r13
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movslq	(%r12), %rbx
	leaq	4096(%r14), %rax
	addq	$8192, %r14                     ## imm = 0x2000
	cmpq	%rbx, %r14
	movq	%rax, %r14
	ja	LBB0_7
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	$4096, %esi                     ## imm = 0x1000
	movq	%r13, %rdi
	movl	$1, %edx
	movq	%r15, %rcx
	callq	_fread
	cmpl	$1, %eax
	je	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edi
	leaq	L_.str(%rip), %rdx
	callq	_error
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	$4096, %esi                     ## imm = 0x1000
	movq	%r13, %rdi
	movl	$1, %edx
	movq	-4152(%rbp), %rcx               ## 8-byte Reload
	callq	_fwrite
	cmpl	$1, %eax
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edi
	leaq	L_.str.1(%rip), %rdx
	callq	_error
	jmp	LBB0_6
LBB0_11:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_16
## %bb.12:
	leaq	L_.str.1(%rip), %rdx
	movl	$1, %edi
	addq	$4120, %rsp                     ## imm = 0x1018
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_error                          ## TAILCALL
LBB0_16:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
	.comm	_errno,4,2                      ## @errno
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Can not read partition from input_file"

L_.str.1:                               ## @.str.1
	.asciz	"Can not write partition to output_file"

	.no_dead_strip	_write_partition
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function write_partition
_write_partition:                       ; @write_partition
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	w9, #4112
Lloh0:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh1:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	sub	sp, sp, #1, lsl #12             ; =4096
	sub	sp, sp, #16
	mov	x19, x3
	mov	x21, x2
	mov	x20, x0
Lloh2:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh3:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
	ldr	x8, [x2, #8]
	add	x1, x8, x1
Lloh5:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh6:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	bl	_fseek
	ldr	w8, [x21]
	cmp	w8, #1, lsl #12                 ; =4096
	b.hs	LBB0_8
; %bb.1:
	mov	x9, #0
LBB0_2:
	subs	x21, x8, x9
	b.ls	LBB0_6
; %bb.3:
	add	x0, sp, #8
	mov	x1, x21
	mov	w2, #1
	mov	x3, x20
	bl	_fread
	cmp	w0, #1
	b.eq	LBB0_5
; %bb.4:
Lloh8:
	adrp	x8, _errno@GOTPAGE
Lloh9:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
Lloh11:
	adrp	x2, l_.str@PAGE
Lloh12:
	add	x2, x2, l_.str@PAGEOFF
	mov	w0, #1
	bl	_error
LBB0_5:
	add	x0, sp, #8
	mov	x1, x21
	mov	w2, #1
	mov	x3, x19
	bl	_fwrite
	cmp	w0, #1
	b.ne	LBB0_14
LBB0_6:
	ldur	x8, [x29, #-72]
Lloh13:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh14:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_16
; %bb.7:
	add	sp, sp, #1, lsl #12             ; =4096
	add	sp, sp, #16
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_8:
	mov	x24, #0
Lloh16:
	adrp	x25, _errno@GOTPAGE
Lloh17:
	ldr	x25, [x25, _errno@GOTPAGEOFF]
Lloh18:
	adrp	x22, l_.str.1@PAGE
Lloh19:
	add	x22, x22, l_.str.1@PAGEOFF
Lloh20:
	adrp	x23, l_.str@PAGE
Lloh21:
	add	x23, x23, l_.str@PAGEOFF
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=1
	ldrsw	x8, [x21]
	add	x9, x24, #1, lsl #12            ; =4096
	add	x10, x24, #2, lsl #12           ; =8192
	mov	x24, x9
	cmp	x10, x8
	b.hi	LBB0_2
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	add	x0, sp, #8
	mov	w1, #4096
	mov	w2, #1
	mov	x3, x20
	bl	_fread
	cmp	w0, #1
	b.eq	LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	ldr	w1, [x25]
	mov	w0, #1
	mov	x2, x23
	bl	_error
LBB0_12:                                ;   in Loop: Header=BB0_10 Depth=1
	add	x0, sp, #8
	mov	w1, #4096
	mov	w2, #1
	mov	x3, x19
	bl	_fwrite
	cmp	w0, #1
	b.eq	LBB0_9
; %bb.13:                               ;   in Loop: Header=BB0_10 Depth=1
	ldr	w1, [x25]
	mov	w0, #1
	mov	x2, x22
	bl	_error
	b	LBB0_9
LBB0_14:
Lloh22:
	adrp	x8, _errno@GOTPAGE
Lloh23:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
	ldur	x8, [x29, #-72]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_16
; %bb.15:
Lloh28:
	adrp	x2, l_.str.1@PAGE
Lloh29:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	w0, #1
	add	sp, sp, #1, lsl #12             ; =4096
	add	sp, sp, #16
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_error
LBB0_16:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
	.comm	_errno,4,2                      ; @errno
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Can not read partition from input_file"

l_.str.1:                               ; @.str.1
	.asciz	"Can not write partition to output_file"

	.no_dead_strip	_write_partition
.subsections_via_symbols
