	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_config_file_write              ## -- Begin function config_file_write
	.p2align	4, 0x90
_config_file_write:                     ## @config_file_write
	.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
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movq	%rsi, %rbx
	movq	%rdi, %r13
	movq	%rsi, %rdi
	callq	_string_is_empty
	testl	%eax, %eax
	je	LBB0_1
## %bb.7:
	movq	_stdout@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%r13, %rdi
	movl	%r14d, %edx
	callq	_config_file_dump
	movl	$1, %r15d
LBB0_8:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_fopen_utf8
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	movq	%rax, %r12
	movl	$1, %r15d
	movl	$1, %edi
	movl	$16384, %esi                    ## imm = 0x4000
	callq	_calloc
	movq	%rax, %rbx
	movq	__IOFBF@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movl	$16384, %ecx                    ## imm = 0x4000
	callq	_setvbuf
	movq	%r13, %rdi
	movq	%r12, %rsi
	movl	%r14d, %edx
	callq	_config_file_dump
	movq	_stdout@GOTPCREL(%rip), %rax
	cmpq	%r12, (%rax)
	je	LBB0_5
## %bb.4:
	movq	%r12, %rdi
	callq	_fclose
LBB0_5:
	testq	%rbx, %rbx
	je	LBB0_8
## %bb.6:
	movq	%rbx, %rdi
	callq	_free
	jmp	LBB0_8
LBB0_2:
	xorl	%r15d, %r15d
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"wb"

	.comm	__IOFBF,4,2                     ## @_IOFBF
	.comm	_stdout,8,3                     ## @stdout
	.comm	_O_CREAT,4,2                    ## @O_CREAT
	.comm	_O_RDWR,4,2                     ## @O_RDWR
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_config_file_write              ; -- Begin function config_file_write
	.p2align	2
_config_file_write:                     ; @config_file_write
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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, x2
	mov	x21, x1
	mov	x20, x0
	mov	x0, x1
	bl	_string_is_empty
	cbz	w0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _stdout@GOTPAGE
Lloh1:
	ldr	x8, [x8, _stdout@GOTPAGEOFF]
Lloh2:
	ldr	x1, [x8]
	mov	x0, x20
	mov	x2, x19
	bl	_config_file_dump
	b	LBB0_7
LBB0_2:
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	bl	_fopen_utf8
	cbz	x0, LBB0_8
; %bb.3:
	mov	x21, x0
	mov	w0, #1
	mov	w1, #16384
	bl	_calloc
	mov	x22, x0
Lloh5:
	adrp	x8, __IOFBF@GOTPAGE
Lloh6:
	ldr	x8, [x8, __IOFBF@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x21
	mov	x1, x22
	mov	w3, #16384
	bl	_setvbuf
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	bl	_config_file_dump
Lloh8:
	adrp	x8, _stdout@GOTPAGE
Lloh9:
	ldr	x8, [x8, _stdout@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	cmp	x8, x21
	b.eq	LBB0_5
; %bb.4:
	mov	x0, x21
	bl	_fclose
LBB0_5:
	cbz	x22, LBB0_7
; %bb.6:
	mov	x0, x22
	bl	_free
LBB0_7:
	mov	w0, #1
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"wb"

	.comm	__IOFBF,4,2                     ; @_IOFBF
	.comm	_stdout,8,3                     ; @stdout
	.comm	_O_CREAT,4,2                    ; @O_CREAT
	.comm	_O_RDWR,4,2                     ; @O_RDWR
.subsections_via_symbols
