	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gets_fromFile                  ## -- Begin function gets_fromFile
	.p2align	4, 0x90
_gets_fromFile:                         ## @gets_fromFile
	.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	$1032, %rsp                     ## imm = 0x408
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	_gets_fromFile.buffer(%rip), %rdi
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.2:
	callq	_resetPQExpBuffer
	jmp	LBB0_3
LBB0_1:
	xorl	%eax, %eax
	callq	_createPQExpBuffer
	movq	%rax, _gets_fromFile.buffer(%rip)
LBB0_3:
	movq	_sigint_interrupt_enabled@GOTPCREL(%rip), %r15
	movl	$1, (%r15)
	leaq	-1056(%rbp), %rdi
	movl	$1024, %esi                     ## imm = 0x400
	movq	%r14, %rdx
	callq	_fgets
	movl	$0, (%r15)
	testq	%rax, %rax
	je	LBB0_8
## %bb.4:
	leaq	-1056(%rbp), %rbx
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	movl	$1, (%r15)
	movq	%rbx, %rdi
	movl	$1024, %esi                     ## imm = 0x400
	movq	%r14, %rdx
	callq	_fgets
	movl	$0, (%r15)
	testq	%rax, %rax
	je	LBB0_8
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	_gets_fromFile.buffer(%rip), %rdi
	movq	%rbx, %rsi
	callq	_appendPQExpBufferStr
	movq	_gets_fromFile.buffer(%rip), %rdi
	callq	_PQExpBufferBroken
	testq	%rax, %rax
	jne	LBB0_6
## %bb.11:                              ##   in Loop: Header=BB0_5 Depth=1
	movq	_gets_fromFile.buffer(%rip), %rax
	movl	(%rax), %ecx
	testl	%ecx, %ecx
	jle	LBB0_7
## %bb.12:                              ##   in Loop: Header=BB0_5 Depth=1
	movq	8(%rax), %rdx
	decl	%ecx
	cmpb	$10, (%rdx,%rcx)
	jne	LBB0_7
## %bb.13:
	movl	%ecx, %ecx
	movb	$0, (%rdx,%rcx)
	jmp	LBB0_14
LBB0_8:
	movq	%r14, %rdi
	callq	_ferror
	testq	%rax, %rax
	je	LBB0_15
## %bb.9:
	leaq	L_.str(%rip), %rdi
	callq	_pg_log_error
	jmp	LBB0_16
LBB0_6:
	leaq	L_.str.1(%rip), %rdi
	callq	_pg_log_error
	jmp	LBB0_16
LBB0_15:
	movq	_gets_fromFile.buffer(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_16
LBB0_14:
	movq	8(%rax), %rdi
	callq	_pg_strdup
	jmp	LBB0_17
LBB0_16:
	xorl	%eax, %eax
LBB0_17:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-32(%rbp), %rcx
	jne	LBB0_19
## %bb.18:
	addq	$1032, %rsp                     ## imm = 0x408
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_gets_fromFile.buffer,8,3 ## @gets_fromFile.buffer
	.comm	_sigint_interrupt_enabled,4,2   ## @sigint_interrupt_enabled
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"could not read from input file: %m"

L_.str.1:                               ## @.str.1
	.asciz	"out of memory"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gets_fromFile                  ; -- Begin function gets_fromFile
	.p2align	2
_gets_fromFile:                         ; @gets_fromFile
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -56
	.cfi_offset w28, -64
	sub	sp, sp, #1040
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	adrp	x20, _gets_fromFile.buffer@PAGE
	ldr	x0, [x20, _gets_fromFile.buffer@PAGEOFF]
	cbz	x0, LBB0_2
; %bb.1:
	bl	_resetPQExpBuffer
	b	LBB0_3
LBB0_2:
	bl	_createPQExpBuffer
	str	x0, [x20, _gets_fromFile.buffer@PAGEOFF]
LBB0_3:
Lloh3:
	adrp	x21, _sigint_interrupt_enabled@GOTPAGE
Lloh4:
	ldr	x21, [x21, _sigint_interrupt_enabled@GOTPAGEOFF]
	mov	w22, #1
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	str	w22, [x21]
	add	x0, sp, #8
	mov	w1, #1024
	mov	x2, x19
	bl	_fgets
	str	wzr, [x21]
	cbz	x0, LBB0_9
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x0, [x20, _gets_fromFile.buffer@PAGEOFF]
	add	x1, sp, #8
	bl	_appendPQExpBufferStr
	ldr	x0, [x20, _gets_fromFile.buffer@PAGEOFF]
	bl	_PQExpBufferBroken
	cbnz	x0, LBB0_11
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x20, _gets_fromFile.buffer@PAGEOFF]
	ldr	w9, [x8]
	subs	w9, w9, #1
	b.lt	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x10, [x8, #8]
	ldrb	w11, [x10, w9, uxtw]
	cmp	w11, #10
	b.ne	LBB0_4
; %bb.8:
	strb	wzr, [x10, w9, uxtw]
	b	LBB0_13
LBB0_9:
	mov	x0, x19
	bl	_ferror
	cbz	x0, LBB0_12
; %bb.10:
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pg_log_error
	b	LBB0_14
LBB0_11:
Lloh7:
	adrp	x0, l_.str.1@PAGE
Lloh8:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pg_log_error
	b	LBB0_14
LBB0_12:
	ldr	x8, [x20, _gets_fromFile.buffer@PAGEOFF]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_14
LBB0_13:
	ldr	x0, [x8, #8]
	bl	_pg_strdup
	b	LBB0_15
LBB0_14:
	mov	x0, #0
LBB0_15:
	ldur	x8, [x29, #-56]
Lloh9:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh10:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_17
; %bb.16:
	add	sp, sp, #1040
	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
	ldp	x28, x27, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_17:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_gets_fromFile.buffer,8,3 ; @gets_fromFile.buffer
	.comm	_sigint_interrupt_enabled,4,2   ; @sigint_interrupt_enabled
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"could not read from input file: %m"

l_.str.1:                               ; @.str.1
	.asciz	"out of memory"

.subsections_via_symbols
