	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rename_temporary_snapshot      ## -- Begin function rename_temporary_snapshot
	.p2align	4, 0x90
_rename_temporary_snapshot:             ## @rename_temporary_snapshot
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_strlen
	movl	%eax, %ebx
	xorl	%r15d, %r15d
	cmpl	$4, %eax
	jl	LBB0_3
## %bb.1:
	movl	%ebx, %eax
	leaq	(%r14,%rax), %rdi
	addq	$-4, %rdi
	leaq	L_.str(%rip), %rsi
	callq	_strcmp
	testl	%eax, %eax
	jne	LBB0_3
## %bb.2:
	xorl	%r15d, %r15d
	cmpl	$257, %ebx                      ## imm = 0x101
	setb	%r15b
LBB0_3:
	movl	%r15d, %edi
	callq	_assert
	movslq	%ebx, %rbx
	leaq	-4(%rbx), %rdx
	leaq	_rename_temporary_snapshot.tmpbuff(%rip), %r15
	movq	%r15, %rdi
	movq	%r14, %rsi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_memcpy
	movb	$0, -4(%rbx,%r15)
	movq	_verbosity@GOTPCREL(%rip), %rax
	cmpl	$2, (%rax)
	jl	LBB0_5
## %bb.4:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	leaq	_rename_temporary_snapshot.tmpbuff(%rip), %rcx
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_fprintf
LBB0_5:
	leaq	_rename_temporary_snapshot.tmpbuff(%rip), %rdi
	xorl	%esi, %esi
	callq	_access
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	leaq	_rename_temporary_snapshot.tmpbuff(%rip), %rsi
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_rename                         ## TAILCALL
LBB0_6:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	leaq	_rename_temporary_snapshot.tmpbuff(%rip), %rdx
	xorl	%eax, %eax
	callq	_fprintf
	movl	$-1, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	".tmp"

.zerofill __DATA,__bss,_rename_temporary_snapshot.tmpbuff,256,4 ## @rename_temporary_snapshot.tmpbuff
	.comm	_verbosity,4,2                  ## @verbosity
	.comm	_stderr,4,2                     ## @stderr
L_.str.1:                               ## @.str.1
	.asciz	"renaming temporary snapshot %s to %s\n"

L_.str.2:                               ## @.str.2
	.asciz	"fatal: snapshot %s already exists\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rename_temporary_snapshot      ; -- Begin function rename_temporary_snapshot
	.p2align	2
_rename_temporary_snapshot:             ; @rename_temporary_snapshot
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
	bl	_strlen
	mov	x20, x0
	cmp	w0, #4
	b.lt	LBB0_2
; %bb.1:
	add	x8, x19, w20, uxtw
	sub	x0, x8, #4
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_strcmp
	cmp	w20, #257
	cset	w8, lo
	cmp	w0, #0
	csel	w0, wzr, w8, ne
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	bl	_assert
	sxtw	x8, w20
	sub	x21, x8, #4
Lloh2:
	adrp	x20, _rename_temporary_snapshot.tmpbuff@PAGE
Lloh3:
	add	x20, x20, _rename_temporary_snapshot.tmpbuff@PAGEOFF
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_memcpy
	strb	wzr, [x20, x21]
Lloh4:
	adrp	x8, _verbosity@GOTPAGE
Lloh5:
	ldr	x8, [x8, _verbosity@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	cmp	w8, #2
	b.lt	LBB0_5
; %bb.4:
Lloh7:
	adrp	x8, _stderr@GOTPAGE
Lloh8:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	str	x20, [sp]
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x19
	bl	_fprintf
LBB0_5:
Lloh12:
	adrp	x0, _rename_temporary_snapshot.tmpbuff@PAGE
Lloh13:
	add	x0, x0, _rename_temporary_snapshot.tmpbuff@PAGEOFF
	mov	w1, #0
	bl	_access
	cbz	w0, LBB0_7
; %bb.6:
Lloh14:
	adrp	x1, _rename_temporary_snapshot.tmpbuff@PAGE
Lloh15:
	add	x1, x1, _rename_temporary_snapshot.tmpbuff@PAGEOFF
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_rename
LBB0_7:
Lloh16:
	adrp	x8, _stderr@GOTPAGE
Lloh17:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh18:
	ldr	w0, [x8]
Lloh19:
	adrp	x1, l_.str.2@PAGE
Lloh20:
	add	x1, x1, l_.str.2@PAGEOFF
Lloh21:
	adrp	x2, _rename_temporary_snapshot.tmpbuff@PAGE
Lloh22:
	add	x2, x2, _rename_temporary_snapshot.tmpbuff@PAGEOFF
	bl	_fprintf
	mov	w0, #-1
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	".tmp"

.zerofill __DATA,__bss,_rename_temporary_snapshot.tmpbuff,256,0 ; @rename_temporary_snapshot.tmpbuff
	.comm	_verbosity,4,2                  ; @verbosity
	.comm	_stderr,4,2                     ; @stderr
l_.str.1:                               ; @.str.1
	.asciz	"renaming temporary snapshot %s to %s\n"

l_.str.2:                               ; @.str.2
	.asciz	"fatal: snapshot %s already exists\n"

.subsections_via_symbols
