	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function migrate_config
_migrate_config:                        ## @migrate_config
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	leaq	-40(%rbp), %rdi
	callq	_pipe
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	-48(%rbp), %rdi
	callq	_pipe
	testq	%rax, %rax
	je	LBB0_7
LBB0_2:
	leaq	L_.str(%rip), %rdi
LBB0_3:
	callq	_warn
LBB0_4:
	xorl	%r14d, %r14d
LBB0_5:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_28
## %bb.6:
	movq	%r14, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	xorl	%eax, %eax
	callq	_fork
	testl	%eax, %eax
	je	LBB0_10
## %bb.8:
	cmpl	$-1, %eax
	jne	LBB0_11
## %bb.9:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_3
LBB0_10:
	movl	-36(%rbp), %edi
	callq	_close
	movl	-40(%rbp), %edi
	xorl	%esi, %esi
	callq	_dup2
	movl	-48(%rbp), %edi
	callq	_close
	movl	-44(%rbp), %edi
	movl	$1, %esi
	callq	_dup2
	leaq	L_.str.2(%rip), %rdi
	leaq	_migrate_config.argv(%rip), %rsi
	callq	_exec_i3_utility
LBB0_11:
	movl	-40(%rbp), %edi
	callq	_close
	movl	-36(%rbp), %edi
	movq	%rbx, %rsi
	movl	%r14d, %edx
	callq	_writeall
	cmpl	$-1, %eax
	je	LBB0_22
## %bb.12:
	movl	-36(%rbp), %edi
	callq	_close
	movl	-44(%rbp), %edi
	callq	_close
	movl	$65535, %r15d                   ## imm = 0xFFFF
	movl	$65535, %edi                    ## imm = 0xFFFF
	movl	$1, %esi
	callq	_scalloc
	movq	%rax, %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	cmpl	%r15d, %ebx
	jne	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	addl	$65535, %r15d                   ## imm = 0xFFFF
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_srealloc
	movq	%rax, %r14
LBB0_15:                                ##   in Loop: Header=BB0_13 Depth=1
	movl	-48(%rbp), %edi
	movslq	%ebx, %rsi
	addq	%r14, %rsi
	movl	%r15d, %edx
	subl	%ebx, %edx
	callq	_read
	cmpl	$-1, %eax
	je	LBB0_23
## %bb.16:                              ##   in Loop: Header=BB0_13 Depth=1
	addl	%eax, %ebx
	testl	%eax, %eax
	jg	LBB0_13
## %bb.17:
	leaq	-52(%rbp), %rdi
	callq	_wait
	movl	-52(%rbp), %edi
	callq	_WIFEXITED
	testl	%eax, %eax
	je	LBB0_24
## %bb.18:
	movl	-52(%rbp), %edi
	callq	_WEXITSTATUS
	testl	%eax, %eax
	je	LBB0_5
## %bb.19:
	movl	%eax, %ebx
	movq	_stderr@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	leaq	L_.str.6(%rip), %rsi
	callq	_fprintf
	cmpl	$2, %ebx
	je	LBB0_25
## %bb.20:
	cmpl	$1, %ebx
	jne	LBB0_27
## %bb.21:
	movl	(%r15), %edi
	leaq	L_.str.8(%rip), %rsi
	callq	_fprintf
	leaq	L_.str.9(%rip), %rsi
	jmp	LBB0_26
LBB0_22:
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_3
LBB0_23:
	leaq	L_.str.4(%rip), %rdi
	callq	_warn
	jmp	LBB0_27
LBB0_24:
	leaq	L_.str.5(%rip), %rsi
	jmp	LBB0_26
LBB0_25:
	leaq	L_.str.7(%rip), %rsi
LBB0_26:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_fprintf
LBB0_27:
	movq	%r14, %rdi
	callq	_FREE
	jmp	LBB0_4
LBB0_28:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"migrate_config: Could not create pipes"

L_.str.1:                               ## @.str.1
	.asciz	"Could not fork()"

.zerofill __DATA,__bss,_migrate_config.argv,16,4 ## @migrate_config.argv
L_.str.2:                               ## @.str.2
	.asciz	"i3-migrate-config-to-v4"

L_.str.3:                               ## @.str.3
	.asciz	"Could not write to pipe"

L_.str.4:                               ## @.str.4
	.asciz	"Cannot read from pipe"

	.comm	_stderr,4,2                     ## @stderr
L_.str.5:                               ## @.str.5
	.asciz	"Child did not terminate normally, using old config file (will lead to broken behaviour)\n"

L_.str.6:                               ## @.str.6
	.asciz	"Migration process exit code was != 0\n"

L_.str.7:                               ## @.str.7
	.asciz	"could not start the migration script\n"

L_.str.8:                               ## @.str.8
	.asciz	"This already was a v4 config. Please add the following line to your config file:\n"

L_.str.9:                               ## @.str.9
	.asciz	"# i3 config file (v4)\n"

	.no_dead_strip	_migrate_config
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function migrate_config
_migrate_config:                        ; @migrate_config
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	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]
	str	x8, [sp, #24]
	add	x0, sp, #16
	bl	_pipe
	cbnz	x0, LBB0_2
; %bb.1:
	add	x0, sp, #8
	bl	_pipe
	cbz	x0, LBB0_7
LBB0_2:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
LBB0_3:
	bl	_warn
LBB0_4:
	mov	x19, #0
LBB0_5:
	ldr	x8, [sp, #24]
Lloh5:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh6:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_28
; %bb.6:
	mov	x0, x19
	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
	add	sp, sp, #80
	ret
LBB0_7:
	bl	_fork
	cbz	w0, LBB0_10
; %bb.8:
	cmn	w0, #1
	b.ne	LBB0_11
; %bb.9:
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_3
LBB0_10:
	ldr	w0, [sp, #20]
	bl	_close
	ldr	w0, [sp, #16]
	mov	w1, #0
	bl	_dup2
	ldr	w0, [sp, #8]
	bl	_close
	ldr	w0, [sp, #12]
	mov	w1, #1
	bl	_dup2
Lloh10:
	adrp	x0, l_.str.2@PAGE
Lloh11:
	add	x0, x0, l_.str.2@PAGEOFF
Lloh12:
	adrp	x1, _migrate_config.argv@PAGE
Lloh13:
	add	x1, x1, _migrate_config.argv@PAGEOFF
	bl	_exec_i3_utility
LBB0_11:
	ldr	w0, [sp, #16]
	bl	_close
	ldr	w0, [sp, #20]
	mov	x1, x20
	mov	x2, x19
	bl	_writeall
	cmn	w0, #1
	b.eq	LBB0_22
; %bb.12:
	ldr	w0, [sp, #20]
	bl	_close
	ldr	w0, [sp, #12]
	bl	_close
	mov	w21, #65535
	mov	w0, #65535
	mov	w1, #1
	bl	_scalloc
	mov	x19, x0
	mov	w22, #0
	mov	w20, #65535
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	cmp	w22, w20
	b.ne	LBB0_15
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	add	w20, w20, w21
	mov	x0, x19
	mov	x1, x20
	bl	_srealloc
	mov	x19, x0
LBB0_15:                                ;   in Loop: Header=BB0_13 Depth=1
	ldr	w0, [sp, #8]
	add	x1, x19, w22, sxtw
	sub	w2, w20, w22
	bl	_read
	cmn	w0, #1
	b.eq	LBB0_23
; %bb.16:                               ;   in Loop: Header=BB0_13 Depth=1
	add	w22, w0, w22
	cmp	w0, #0
	b.gt	LBB0_13
; %bb.17:
	add	x0, sp, #4
	bl	_wait
	ldr	w0, [sp, #4]
	bl	_WIFEXITED
Lloh14:
	adrp	x21, _stderr@GOTPAGE
Lloh15:
	ldr	x21, [x21, _stderr@GOTPAGEOFF]
	cbz	w0, LBB0_24
; %bb.18:
	ldr	w0, [sp, #4]
	bl	_WEXITSTATUS
	cbz	w0, LBB0_5
; %bb.19:
	mov	x20, x0
	ldr	w0, [x21]
Lloh16:
	adrp	x1, l_.str.6@PAGE
Lloh17:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_fprintf
	cmp	w20, #2
	b.eq	LBB0_25
; %bb.20:
	cmp	w20, #1
	b.ne	LBB0_27
; %bb.21:
	ldr	w0, [x21]
Lloh18:
	adrp	x1, l_.str.8@PAGE
Lloh19:
	add	x1, x1, l_.str.8@PAGEOFF
	bl	_fprintf
Lloh20:
	adrp	x1, l_.str.9@PAGE
Lloh21:
	add	x1, x1, l_.str.9@PAGEOFF
	b	LBB0_26
LBB0_22:
Lloh22:
	adrp	x0, l_.str.3@PAGE
Lloh23:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_3
LBB0_23:
Lloh24:
	adrp	x0, l_.str.4@PAGE
Lloh25:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_warn
	b	LBB0_27
LBB0_24:
Lloh26:
	adrp	x1, l_.str.5@PAGE
Lloh27:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_26
LBB0_25:
Lloh28:
	adrp	x1, l_.str.7@PAGE
Lloh29:
	add	x1, x1, l_.str.7@PAGEOFF
LBB0_26:
	ldr	w0, [x21]
	bl	_fprintf
LBB0_27:
	mov	x0, x19
	bl	_FREE
	b	LBB0_4
LBB0_28:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"migrate_config: Could not create pipes"

l_.str.1:                               ; @.str.1
	.asciz	"Could not fork()"

.zerofill __DATA,__bss,_migrate_config.argv,16,3 ; @migrate_config.argv
l_.str.2:                               ; @.str.2
	.asciz	"i3-migrate-config-to-v4"

l_.str.3:                               ; @.str.3
	.asciz	"Could not write to pipe"

l_.str.4:                               ; @.str.4
	.asciz	"Cannot read from pipe"

	.comm	_stderr,4,2                     ; @stderr
l_.str.5:                               ; @.str.5
	.asciz	"Child did not terminate normally, using old config file (will lead to broken behaviour)\n"

l_.str.6:                               ; @.str.6
	.asciz	"Migration process exit code was != 0\n"

l_.str.7:                               ; @.str.7
	.asciz	"could not start the migration script\n"

l_.str.8:                               ; @.str.8
	.asciz	"This already was a v4 config. Please add the following line to your config file:\n"

l_.str.9:                               ; @.str.9
	.asciz	"# i3 config file (v4)\n"

	.no_dead_strip	_migrate_config
.subsections_via_symbols
