	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mingw_rename                   ## -- Begin function mingw_rename
	.p2align	4, 0x90
_mingw_rename:                          ## @mingw_rename
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r13
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MAX_PATH@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	shlq	$2, %rbx
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r12
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r14
	movq	%r12, %rdi
	movq	%r15, %rsi
	callq	_xutftowcs_path
	testq	%rax, %rax
	js	LBB0_24
## %bb.1:
	movq	%r14, %rdi
	movq	%r13, %rsi
	callq	_xutftowcs_path
	testq	%rax, %rax
	js	LBB0_24
## %bb.2:
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	__wrename
	xorl	%ebx, %ebx
	testl	%eax, %eax
	je	LBB0_25
## %bb.3:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_EEXIST@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_24
## %bb.4:
	movq	_MOVEFILE_REPLACE_EXISTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_MoveFileExW
	testq	%rax, %rax
	jne	LBB0_25
## %bb.5:
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_8
LBB0_6:                                 ##   in Loop: Header=BB0_8 Depth=1
	movq	_delay@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movl	(%rax,%rbx,4), %edi
	callq	_Sleep
	incq	%rbx
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_8 Depth=1
	movq	_MOVEFILE_REPLACE_EXISTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_MoveFileExW
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_25
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_GetLastError
	movq	%rax, %r13
	movq	_ERROR_ACCESS_DENIED@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r13
	jne	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movq	%r14, %rdi
	callq	_GetFileAttributesW
	movq	%rax, %rbx
	movq	_INVALID_FILE_ATTRIBUTES@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rbx
	jne	LBB0_14
LBB0_10:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	_delay@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_ARRAY_SIZE
	movslq	%eax, %rcx
	movq	_ERROR_ACCESS_DENIED@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	%rcx, -56(%rbp)                 ## 8-byte Folded Reload
	jge	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_8 Depth=1
	cmpq	%rax, %r13
	je	LBB0_6
LBB0_12:                                ##   in Loop: Header=BB0_8 Depth=1
	cmpq	%rax, %r13
	jne	LBB0_22
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	leaq	L_.str(%rip), %rdi
	movq	%r15, %rsi
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	callq	_ask_yes_no_if_possible
	testq	%rax, %rax
	jne	LBB0_7
	jmp	LBB0_22
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	_FILE_ATTRIBUTE_DIRECTORY@GOTPCREL(%rip), %rax
	testq	%rbx, (%rax)
	je	LBB0_18
## %bb.15:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	%r12, %rdi
	callq	_GetFileAttributesW
	movq	_INVALID_FILE_ATTRIBUTES@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_28
## %bb.16:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	_FILE_ATTRIBUTE_DIRECTORY@GOTPCREL(%rip), %rcx
	testq	%rax, (%rcx)
	je	LBB0_28
## %bb.17:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	%r14, %rdi
	callq	__wrmdir
	testl	%eax, %eax
	je	LBB0_7
	jmp	LBB0_24
LBB0_18:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	_FILE_ATTRIBUTE_READONLY@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testq	%rbx, %rax
	je	LBB0_10
## %bb.19:                              ##   in Loop: Header=BB0_8 Depth=1
	notq	%rax
	movq	%rbx, %rsi
	andq	%rax, %rsi
	movq	%r14, %rdi
	callq	_SetFileAttributesW
	testl	%eax, %eax
	je	LBB0_10
## %bb.20:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	_MOVEFILE_REPLACE_EXISTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_MoveFileExW
	testq	%rax, %rax
	jne	LBB0_29
## %bb.21:                              ##   in Loop: Header=BB0_8 Depth=1
	xorl	%eax, %eax
	callq	_GetLastError
	movq	%rax, %r13
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_SetFileAttributesW
	jmp	LBB0_10
LBB0_22:
	movq	_EACCES@GOTPCREL(%rip), %rax
LBB0_23:
	movq	(%rax), %rax
	movq	_errno@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
LBB0_24:
	movl	$-1, %ebx
LBB0_25:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_30
## %bb.26:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_28:
	movq	_EISDIR@GOTPCREL(%rip), %rax
	jmp	LBB0_23
LBB0_29:
	xorl	%ebx, %ebx
	jmp	LBB0_25
LBB0_30:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_PATH,4,2                   ## @MAX_PATH
	.comm	_errno,8,3                      ## @errno
	.comm	_EEXIST,8,3                     ## @EEXIST
	.comm	_MOVEFILE_REPLACE_EXISTING,4,2  ## @MOVEFILE_REPLACE_EXISTING
	.comm	_ERROR_ACCESS_DENIED,8,3        ## @ERROR_ACCESS_DENIED
	.comm	_INVALID_FILE_ATTRIBUTES,8,3    ## @INVALID_FILE_ATTRIBUTES
	.comm	_FILE_ATTRIBUTE_DIRECTORY,8,3   ## @FILE_ATTRIBUTE_DIRECTORY
	.comm	_EISDIR,8,3                     ## @EISDIR
	.comm	_FILE_ATTRIBUTE_READONLY,8,3    ## @FILE_ATTRIBUTE_READONLY
	.comm	_delay,8,3                      ## @delay
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Rename from '%s' to '%s' failed. Should I try again?"

	.comm	_EACCES,8,3                     ## @EACCES
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mingw_rename                   ; -- Begin function mingw_rename
	.p2align	2
_mingw_rename:                          ; @mingw_rename
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	sub	sp, sp, #16
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MAX_PATH@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_PATH@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x8, x8, #2
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x10, x8, #15
	and	x12, x10, #0x7fffffff0
	sub	x21, x9, x12
	mov	sp, x21
	mov	x9, x8
Lloh8:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh9:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	sub	x22, x8, x12
	mov	sp, x22
	mov	x0, x21
	mov	x1, x20
	bl	_xutftowcs_path
	tbnz	x0, #63, LBB0_24
; %bb.1:
	mov	x0, x22
	mov	x1, x19
	bl	_xutftowcs_path
	tbnz	x0, #63, LBB0_24
; %bb.2:
	mov	x0, x21
	mov	x1, x22
	bl	__wrename
	cbz	w0, LBB0_25
; %bb.3:
Lloh10:
	adrp	x8, _errno@GOTPAGE
Lloh11:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
Lloh13:
	adrp	x9, _EEXIST@GOTPAGE
Lloh14:
	ldr	x9, [x9, _EEXIST@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_24
; %bb.4:
Lloh16:
	adrp	x27, _MOVEFILE_REPLACE_EXISTING@GOTPAGE
Lloh17:
	ldr	x27, [x27, _MOVEFILE_REPLACE_EXISTING@GOTPAGEOFF]
	ldr	w2, [x27]
	mov	x0, x21
	mov	x1, x22
	bl	_MoveFileExW
	cbz	x0, LBB0_6
LBB0_5:
	mov	w0, #0
	b	LBB0_25
LBB0_6:
	mov	x28, #0
Lloh18:
	adrp	x26, _ERROR_ACCESS_DENIED@GOTPAGE
Lloh19:
	ldr	x26, [x26, _ERROR_ACCESS_DENIED@GOTPAGEOFF]
Lloh20:
	adrp	x23, _delay@GOTPAGE
Lloh21:
	ldr	x23, [x23, _delay@GOTPAGEOFF]
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	ldr	x8, [x23]
	ldr	w0, [x8, x28, lsl #2]
	bl	_Sleep
	add	x28, x28, #1
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	ldr	w2, [x27]
	mov	x0, x21
	mov	x1, x22
	bl	_MoveFileExW
	mov	x8, x0
	mov	w0, #0
	cbnz	x8, LBB0_25
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	bl	_GetLastError
	mov	x24, x0
	ldr	x8, [x26]
	cmp	x0, x8
	b.ne	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x22
	bl	_GetFileAttributesW
Lloh22:
	adrp	x8, _INVALID_FILE_ATTRIBUTES@GOTPAGE
Lloh23:
	ldr	x8, [x8, _INVALID_FILE_ATTRIBUTES@GOTPAGEOFF]
Lloh24:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_14
LBB0_11:                                ;   in Loop: Header=BB0_9 Depth=1
	ldr	x0, [x23]
	bl	_ARRAY_SIZE
	ldr	x8, [x26]
	cmp	x28, w0, sxtw
	ccmp	x24, x8, #0, lt
	b.eq	LBB0_7
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=1
	cmp	x24, x8
	b.ne	LBB0_22
; %bb.13:                               ;   in Loop: Header=BB0_9 Depth=1
Lloh25:
	adrp	x0, l_.str@PAGE
Lloh26:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x20
	mov	x2, x19
	bl	_ask_yes_no_if_possible
	cbnz	x0, LBB0_8
	b	LBB0_22
LBB0_14:                                ;   in Loop: Header=BB0_9 Depth=1
	mov	x25, x0
Lloh27:
	adrp	x8, _FILE_ATTRIBUTE_DIRECTORY@GOTPAGE
Lloh28:
	ldr	x8, [x8, _FILE_ATTRIBUTE_DIRECTORY@GOTPAGEOFF]
Lloh29:
	ldr	x8, [x8]
	tst	x8, x0
	b.eq	LBB0_18
; %bb.15:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x21
	bl	_GetFileAttributesW
Lloh30:
	adrp	x8, _INVALID_FILE_ATTRIBUTES@GOTPAGE
Lloh31:
	ldr	x8, [x8, _INVALID_FILE_ATTRIBUTES@GOTPAGEOFF]
Lloh32:
	ldr	x8, [x8]
	cmp	x0, x8
	b.eq	LBB0_27
; %bb.16:                               ;   in Loop: Header=BB0_9 Depth=1
Lloh33:
	adrp	x8, _FILE_ATTRIBUTE_DIRECTORY@GOTPAGE
Lloh34:
	ldr	x8, [x8, _FILE_ATTRIBUTE_DIRECTORY@GOTPAGEOFF]
Lloh35:
	ldr	x8, [x8]
	tst	x8, x0
	b.eq	LBB0_27
; %bb.17:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x22
	bl	__wrmdir
	cbz	w0, LBB0_8
	b	LBB0_24
LBB0_18:                                ;   in Loop: Header=BB0_9 Depth=1
Lloh36:
	adrp	x8, _FILE_ATTRIBUTE_READONLY@GOTPAGE
Lloh37:
	ldr	x8, [x8, _FILE_ATTRIBUTE_READONLY@GOTPAGEOFF]
Lloh38:
	ldr	x8, [x8]
	tst	x8, x25
	b.eq	LBB0_11
; %bb.19:                               ;   in Loop: Header=BB0_9 Depth=1
	bic	x1, x25, x8
	mov	x0, x22
	bl	_SetFileAttributesW
	cbz	w0, LBB0_11
; %bb.20:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w2, [x27]
	mov	x0, x21
	mov	x1, x22
	bl	_MoveFileExW
	cbnz	x0, LBB0_5
; %bb.21:                               ;   in Loop: Header=BB0_9 Depth=1
	bl	_GetLastError
	mov	x24, x0
	mov	x0, x22
	mov	x1, x25
	bl	_SetFileAttributesW
	b	LBB0_11
LBB0_22:
Lloh39:
	adrp	x8, _EACCES@GOTPAGE
Lloh40:
	ldr	x8, [x8, _EACCES@GOTPAGEOFF]
LBB0_23:
	ldr	x8, [x8]
Lloh41:
	adrp	x9, _errno@GOTPAGE
Lloh42:
	ldr	x9, [x9, _errno@GOTPAGEOFF]
Lloh43:
	str	x8, [x9]
LBB0_24:
	mov	w0, #-1
LBB0_25:
	ldur	x8, [x29, #-88]
Lloh44:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh45:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh46:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_28
; %bb.26:
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_27:
Lloh47:
	adrp	x8, _EISDIR@GOTPAGE
Lloh48:
	ldr	x8, [x8, _EISDIR@GOTPAGEOFF]
	b	LBB0_23
LBB0_28:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotStr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGot	Lloh47, Lloh48
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_PATH,4,2                   ; @MAX_PATH
	.comm	_errno,8,3                      ; @errno
	.comm	_EEXIST,8,3                     ; @EEXIST
	.comm	_MOVEFILE_REPLACE_EXISTING,4,2  ; @MOVEFILE_REPLACE_EXISTING
	.comm	_ERROR_ACCESS_DENIED,8,3        ; @ERROR_ACCESS_DENIED
	.comm	_INVALID_FILE_ATTRIBUTES,8,3    ; @INVALID_FILE_ATTRIBUTES
	.comm	_FILE_ATTRIBUTE_DIRECTORY,8,3   ; @FILE_ATTRIBUTE_DIRECTORY
	.comm	_EISDIR,8,3                     ; @EISDIR
	.comm	_FILE_ATTRIBUTE_READONLY,8,3    ; @FILE_ATTRIBUTE_READONLY
	.comm	_delay,8,3                      ; @delay
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Rename from '%s' to '%s' failed. Should I try again?"

	.comm	_EACCES,8,3                     ; @EACCES
.subsections_via_symbols
