	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snapshot_map
_snapshot_map:                          ## @snapshot_map
	.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	%rsi, %r12
	movq	(%rdi), %r14
	movq	_DM_MAPIO_REMAPPED@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r15d
	movq	%rsi, %rdi
	callq	_init_tracked_chunk
	movq	_REQ_PREFLUSH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r12)
	je	LBB0_2
## %bb.1:
	movq	48(%r14), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_bio_set_dev
	movl	(%rbx), %r15d
	jmp	LBB0_39
LBB0_2:
	movq	24(%r14), %rdi
	movl	4(%r12), %esi
	callq	_sector_to_chunk
	movl	%eax, %r13d
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_dm_exception_table_lock_init
	cmpq	$0, 16(%r14)
	je	LBB0_37
## %bb.3:
	movq	%r12, %rdi
	callq	_bio_data_dir
	movq	_WRITE@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %rax
	jne	LBB0_5
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_wait_for_in_progress
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_4
LBB0_5:
	leaq	4(%r14), %rdi
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_down_read
	leaq	-48(%rbp), %rdi
	callq	_dm_exception_table_lock
	cmpq	$0, 16(%r14)
	je	LBB0_8
## %bb.6:
	movl	(%r14), %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_11
## %bb.7:
	movq	%r12, %rdi
	callq	_bio_data_dir
	cmpq	(%rbx), %rax
	jne	LBB0_11
LBB0_8:
	movq	_DM_MAPIO_KILL@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %r15d
LBB0_10:
	leaq	-48(%rbp), %rdi
	callq	_dm_exception_table_unlock
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_up_read
	jmp	LBB0_39
LBB0_11:
	movq	%r12, %rdi
	callq	_bio_op
	movq	_REQ_OP_DISCARD@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_15
## %bb.12:
	cmpq	$0, 40(%r14)
	je	LBB0_15
## %bb.13:
	movq	%r12, %rdi
	callq	_dm_bio_get_target_bio_nr
	testq	%rax, %rax
	je	LBB0_15
LBB0_14:
	movq	8(%r14), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_bio_set_dev
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%r13d, %edx
	callq	_track_chunk
	jmp	LBB0_10
LBB0_15:
	leaq	32(%r14), %rbx
	movq	%rbx, %rdi
	movl	%r13d, %esi
	callq	_dm_lookup_exception
	testq	%rax, %rax
	je	LBB0_19
## %bb.16:
	movq	%r14, %rdi
	movq	%rax, %rbx
	movq	%rax, %rsi
	movq	%r12, %rdx
	movl	%r13d, %ecx
	callq	_remap_exception
	movq	%r12, %rdi
	callq	_bio_op
	xorl	%edi, %edi
	movq	_REQ_OP_DISCARD@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_10
## %bb.17:
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_io_overlaps_chunk
	testq	%rax, %rax
	je	LBB0_10
## %bb.18:
	leaq	-48(%rbp), %rdi
	callq	_dm_exception_table_unlock
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_up_read
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%r12, %rdx
	movl	%r13d, %ecx
	callq	_zero_exception
	movq	_DM_MAPIO_SUBMITTED@GOTPCREL(%rip), %rax
	jmp	LBB0_38
LBB0_19:
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	callq	_bio_op
	xorl	%edi, %edi
	movq	_REQ_OP_DISCARD@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	movq	%r12, %rdi
	callq	_bio_endio
	movq	_DM_MAPIO_SUBMITTED@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_21:
	movq	%r12, %rdi
	callq	_bio_data_dir
	movq	_WRITE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_14
## %bb.22:
	movq	%r14, %rdi
	movl	%r13d, %esi
	callq	___lookup_pending_exception
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_26
LBB0_23:
	leaq	8(%rbx), %rsi
	movq	%r14, %rdi
	movq	%r12, %rdx
	movl	%r13d, %ecx
	callq	_remap_exception
	movq	_DM_MAPIO_SUBMITTED@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	cmpl	$0, (%rbx)
	je	LBB0_28
LBB0_24:
	leaq	4(%rbx), %rdi
	movq	%r12, %rsi
	callq	_bio_list_add
	cmpl	$0, (%rbx)
	jne	LBB0_10
## %bb.25:
	movl	$1, (%rbx)
	leaq	-48(%rbp), %rdi
	callq	_dm_exception_table_unlock
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_up_read
	movq	%rbx, %rdi
	callq	_start_copy
	jmp	LBB0_39
LBB0_26:
	leaq	-48(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_dm_exception_table_unlock
	movq	%r14, %rdi
	callq	_alloc_pending_exception
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_dm_exception_table_lock
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movl	%r13d, %esi
	callq	_dm_lookup_exception
	testq	%rax, %rax
	je	LBB0_30
## %bb.27:
	movq	%rax, %rbx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_free_pending_exception
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%r12, %rdx
	movl	%r13d, %ecx
	callq	_remap_exception
	jmp	LBB0_10
LBB0_28:
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_io_overlaps_chunk
	testq	%rax, %rax
	je	LBB0_24
## %bb.29:
	movl	$1, (%rbx)
	leaq	-48(%rbp), %rdi
	callq	_dm_exception_table_unlock
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_up_read
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_start_full_bio
	jmp	LBB0_39
LBB0_30:
	movq	%r14, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movl	%r13d, %edx
	callq	___find_pending_exception
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_23
## %bb.31:
	leaq	-48(%rbp), %rdi
	callq	_dm_exception_table_unlock
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_up_read
	movq	%rbx, %rdi
	callq	_down_write
	movq	24(%r14), %rax
	cmpq	$0, (%rax)
	je	LBB0_35
## %bb.32:
	cmpq	$0, 16(%r14)
	je	LBB0_36
## %bb.33:
	cmpl	$0, (%r14)
	jne	LBB0_36
## %bb.34:
	movl	$1, (%r14)
	leaq	L_.str(%rip), %rdi
	callq	_DMERR
	jmp	LBB0_36
LBB0_35:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%esi, %esi
	subl	(%rax), %esi
	movq	%r14, %rdi
	callq	___invalidate_snapshot
LBB0_36:
	movq	%rbx, %rdi
	callq	_up_write
LBB0_37:
	movq	_DM_MAPIO_KILL@GOTPCREL(%rip), %rax
LBB0_38:
	movl	(%rax), %r15d
LBB0_39:
	movl	%r15d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DM_MAPIO_REMAPPED,4,2          ## @DM_MAPIO_REMAPPED
	.comm	_REQ_PREFLUSH,4,2               ## @REQ_PREFLUSH
	.comm	_DM_MAPIO_KILL,4,2              ## @DM_MAPIO_KILL
	.comm	_WRITE,8,3                      ## @WRITE
	.comm	_REQ_OP_DISCARD,8,3             ## @REQ_OP_DISCARD
	.comm	_DM_MAPIO_SUBMITTED,4,2         ## @DM_MAPIO_SUBMITTED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Snapshot overflowed: Unable to allocate exception."

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_snapshot_map
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snapshot_map
_snapshot_map:                          ; @snapshot_map
	.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	x21, x1
	ldr	x22, [x0]
Lloh0:
	adrp	x20, _DM_MAPIO_REMAPPED@GOTPAGE
Lloh1:
	ldr	x20, [x20, _DM_MAPIO_REMAPPED@GOTPAGEOFF]
	ldr	w19, [x20]
	mov	x0, x1
	bl	_init_tracked_chunk
	ldr	w8, [x21]
Lloh2:
	adrp	x9, _REQ_PREFLUSH@GOTPAGE
Lloh3:
	ldr	x9, [x9, _REQ_PREFLUSH@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x22, #48]
	ldr	w1, [x8]
	mov	x0, x21
	bl	_bio_set_dev
	ldr	w19, [x20]
	b	LBB0_39
LBB0_2:
	ldr	x0, [x22, #24]
	ldr	w1, [x21, #4]
	bl	_sector_to_chunk
	mov	x23, x0
	add	x2, sp, #8
	mov	x0, x22
	mov	x1, x23
	bl	_dm_exception_table_lock_init
	ldr	x8, [x22, #16]
	cbz	x8, LBB0_37
; %bb.3:
	mov	x0, x21
	bl	_bio_data_dir
Lloh5:
	adrp	x26, _WRITE@GOTPAGE
Lloh6:
	ldr	x26, [x26, _WRITE@GOTPAGEOFF]
	ldr	x8, [x26]
	cmp	x0, x8
	b.ne	LBB0_5
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	mov	w1, #0
	bl	_wait_for_in_progress
	cmp	w0, #0
	cset	w0, eq
	bl	_unlikely
	cbnz	x0, LBB0_4
LBB0_5:
	add	x20, x22, #4
	mov	x0, x20
	bl	_down_read
	add	x0, sp, #8
	bl	_dm_exception_table_lock
	ldr	x8, [x22, #16]
	cbz	x8, LBB0_8
; %bb.6:
	ldr	w0, [x22]
	bl	_unlikely
	cbz	x0, LBB0_11
; %bb.7:
	mov	x0, x21
	bl	_bio_data_dir
	ldr	x8, [x26]
	cmp	x0, x8
	b.ne	LBB0_11
LBB0_8:
Lloh7:
	adrp	x8, _DM_MAPIO_KILL@GOTPAGE
Lloh8:
	ldr	x8, [x8, _DM_MAPIO_KILL@GOTPAGEOFF]
LBB0_9:
	ldr	w19, [x8]
LBB0_10:
	add	x0, sp, #8
	bl	_dm_exception_table_unlock
	mov	x0, x20
	bl	_up_read
	b	LBB0_39
LBB0_11:
	mov	x0, x21
	bl	_bio_op
Lloh9:
	adrp	x27, _REQ_OP_DISCARD@GOTPAGE
Lloh10:
	ldr	x27, [x27, _REQ_OP_DISCARD@GOTPAGEOFF]
	ldr	x8, [x27]
	cmp	x0, x8
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_15
; %bb.12:
	ldr	x8, [x22, #40]
	cbz	x8, LBB0_15
; %bb.13:
	mov	x0, x21
	bl	_dm_bio_get_target_bio_nr
	cbz	x0, LBB0_15
LBB0_14:
	ldr	x8, [x22, #8]
	ldr	w1, [x8]
	mov	x0, x21
	bl	_bio_set_dev
	mov	x0, x22
	mov	x1, x21
	mov	x2, x23
	bl	_track_chunk
	b	LBB0_10
LBB0_15:
	add	x25, x22, #32
	mov	x0, x25
	mov	x1, x23
	bl	_dm_lookup_exception
	cbz	x0, LBB0_19
; %bb.16:
	mov	x24, x0
	mov	x0, x22
	mov	x1, x24
	mov	x2, x21
	mov	x3, x23
	bl	_remap_exception
	mov	x0, x21
	bl	_bio_op
	ldr	x8, [x27]
	cmp	x0, x8
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_10
; %bb.17:
	mov	x0, x22
	mov	x1, x21
	bl	_io_overlaps_chunk
	cbz	x0, LBB0_10
; %bb.18:
	add	x0, sp, #8
	bl	_dm_exception_table_unlock
	mov	x0, x20
	bl	_up_read
	mov	x0, x22
	mov	x1, x24
	mov	x2, x21
	mov	x3, x23
	bl	_zero_exception
Lloh11:
	adrp	x8, _DM_MAPIO_SUBMITTED@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DM_MAPIO_SUBMITTED@GOTPAGEOFF]
	b	LBB0_38
LBB0_19:
	mov	x0, x21
	bl	_bio_op
	ldr	x8, [x27]
	cmp	x0, x8
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_21
; %bb.20:
	mov	x0, x21
	bl	_bio_endio
Lloh13:
	adrp	x8, _DM_MAPIO_SUBMITTED@GOTPAGE
Lloh14:
	ldr	x8, [x8, _DM_MAPIO_SUBMITTED@GOTPAGEOFF]
	b	LBB0_9
LBB0_21:
	mov	x0, x21
	bl	_bio_data_dir
	ldr	x8, [x26]
	cmp	x0, x8
	b.ne	LBB0_14
; %bb.22:
	mov	x0, x22
	mov	x1, x23
	bl	___lookup_pending_exception
	mov	x24, x0
	cbz	x0, LBB0_26
LBB0_23:
	add	x1, x24, #8
	mov	x0, x22
	mov	x2, x21
	mov	x3, x23
	bl	_remap_exception
Lloh15:
	adrp	x8, _DM_MAPIO_SUBMITTED@GOTPAGE
Lloh16:
	ldr	x8, [x8, _DM_MAPIO_SUBMITTED@GOTPAGEOFF]
Lloh17:
	ldr	w19, [x8]
	ldr	w8, [x24]
	cbz	w8, LBB0_28
LBB0_24:
	add	x0, x24, #4
	mov	x1, x21
	bl	_bio_list_add
	ldr	w8, [x24]
	cbnz	w8, LBB0_10
; %bb.25:
	mov	w8, #1
	str	w8, [x24]
	add	x0, sp, #8
	bl	_dm_exception_table_unlock
	mov	x0, x20
	bl	_up_read
	mov	x0, x24
	bl	_start_copy
	b	LBB0_39
LBB0_26:
	add	x0, sp, #8
	bl	_dm_exception_table_unlock
	mov	x0, x22
	bl	_alloc_pending_exception
	mov	x24, x0
	add	x0, sp, #8
	bl	_dm_exception_table_lock
	mov	x0, x25
	mov	x1, x23
	bl	_dm_lookup_exception
	cbz	x0, LBB0_30
; %bb.27:
	mov	x25, x0
	mov	x0, x24
	bl	_free_pending_exception
	mov	x0, x22
	mov	x1, x25
	mov	x2, x21
	mov	x3, x23
	bl	_remap_exception
	b	LBB0_10
LBB0_28:
	mov	x0, x22
	mov	x1, x21
	bl	_io_overlaps_chunk
	cbz	x0, LBB0_24
; %bb.29:
	mov	w8, #1
	str	w8, [x24]
	add	x0, sp, #8
	bl	_dm_exception_table_unlock
	mov	x0, x20
	bl	_up_read
	mov	x0, x24
	mov	x1, x21
	bl	_start_full_bio
	b	LBB0_39
LBB0_30:
	mov	x0, x22
	mov	x1, x24
	mov	x2, x23
	bl	___find_pending_exception
	mov	x24, x0
	cbnz	x0, LBB0_23
; %bb.31:
	add	x0, sp, #8
	bl	_dm_exception_table_unlock
	mov	x0, x20
	bl	_up_read
	mov	x0, x20
	bl	_down_write
	ldr	x8, [x22, #24]
	ldr	x8, [x8]
	cbz	x8, LBB0_35
; %bb.32:
	ldr	x8, [x22, #16]
	cbz	x8, LBB0_36
; %bb.33:
	ldr	w8, [x22]
	cbnz	w8, LBB0_36
; %bb.34:
	mov	w8, #1
	str	w8, [x22]
Lloh18:
	adrp	x0, l_.str@PAGE
Lloh19:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DMERR
	b	LBB0_36
LBB0_35:
Lloh20:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	neg	w1, w8
	mov	x0, x22
	bl	___invalidate_snapshot
LBB0_36:
	mov	x0, x20
	bl	_up_write
LBB0_37:
Lloh23:
	adrp	x8, _DM_MAPIO_KILL@GOTPAGE
Lloh24:
	ldr	x8, [x8, _DM_MAPIO_KILL@GOTPAGEOFF]
LBB0_38:
	ldr	w19, [x8]
LBB0_39:
	mov	x0, x19
	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 AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_DM_MAPIO_REMAPPED,4,2          ; @DM_MAPIO_REMAPPED
	.comm	_REQ_PREFLUSH,4,2               ; @REQ_PREFLUSH
	.comm	_DM_MAPIO_KILL,4,2              ; @DM_MAPIO_KILL
	.comm	_WRITE,8,3                      ; @WRITE
	.comm	_REQ_OP_DISCARD,8,3             ; @REQ_OP_DISCARD
	.comm	_DM_MAPIO_SUBMITTED,4,2         ; @DM_MAPIO_SUBMITTED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Snapshot overflowed: Unable to allocate exception."

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_snapshot_map
.subsections_via_symbols
