	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fgets_timed
_fgets_timed:                           ## @fgets_timed
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%eax, %eax
	testq	%rdi, %rdi
	je	LBB0_31
## %bb.1:
	movl	%ecx, %r14d
	movl	%edx, %r15d
	movl	%esi, %ebx
	movl	%edx, %ecx
	orl	%esi, %ecx
	js	LBB0_31
## %bb.2:
	movq	%rdi, %r12
	movb	$0, (%rdi)
	testl	%ebx, %ebx
	je	LBB0_30
## %bb.3:
	xorl	%edi, %edi
	callq	_clocktime
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	cmpb	$10, (%r12)
	je	LBB0_29
## %bb.4:
	cmpl	$2, %ebx
	jl	LBB0_29
## %bb.5:
	decl	%ebx
	movq	%r15, -48(%rbp)                 ## 8-byte Spill
	leal	1(%r15), %eax
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	xorl	%eax, %eax
	movq	%r12, %r15
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
LBB0_6:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_9 Depth 2
	leaq	(%r12,%rax), %rcx
	incq	%rcx
	incq	%rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_9 Depth=2
	movq	_XLOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_plog
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_EINTR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_26
LBB0_8:                                 ##   in Loop: Header=BB0_9 Depth=2
	cmpb	$10, (%r15)
	movq	%r13, %rcx
	je	LBB0_24
LBB0_9:                                 ##   Parent Loop BB0_6 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%rcx, %r13
	movb	$0, (%rcx)
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
                                        ## kill: def $edi killed $edi killed $rdi
	movq	%r15, %rsi
	movl	$1, %edx
	callq	_read
	testl	%eax, %eax
	je	LBB0_23
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=2
	cmpl	$1, %eax
	je	LBB0_19
## %bb.11:                              ##   in Loop: Header=BB0_9 Depth=2
	testl	%eax, %eax
	jns	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_9 Depth=2
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_EAGAIN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_9 Depth=2
	movq	_EINTR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_27
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_9 Depth=2
	movq	$0, -96(%rbp)
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	callq	_clocktime
	testl	%r14d, %r14d
	jle	LBB0_17
## %bb.15:                              ##   in Loop: Header=BB0_9 Depth=2
	subl	-60(%rbp), %eax                 ## 4-byte Folded Reload
	cmpl	%r14d, %eax
	jge	LBB0_22
## %bb.16:                              ##   in Loop: Header=BB0_9 Depth=2
	movl	%r14d, %ebx
	subl	%eax, %ebx
LBB0_17:                                ##   in Loop: Header=BB0_9 Depth=2
	movl	%ebx, -104(%rbp)
	leaq	-84(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_FD_ZERO
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
                                        ## kill: def $edi killed $edi killed $rdi
	movq	%rbx, %rsi
	callq	_FD_SET
	movl	-64(%rbp), %edi                 ## 4-byte Reload
	movq	%rbx, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	leaq	-104(%rbp), %r8
	callq	_select
	movl	%eax, %r12d
	testl	%eax, %eax
	js	LBB0_7
## %bb.18:                              ##   in Loop: Header=BB0_9 Depth=2
	jne	LBB0_8
	jmp	LBB0_22
LBB0_19:                                ##   in Loop: Header=BB0_6 Depth=1
	cmpb	$0, (%r15)
	je	LBB0_23
## %bb.20:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	%r13, %r15
	cmpb	$10, (%r13)
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	je	LBB0_30
## %bb.21:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	cmpq	%rbx, %rax
	jb	LBB0_6
	jmp	LBB0_30
LBB0_22:
	movq	_XLOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%r12d, %r12d
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_plog
	jmp	LBB0_28
LBB0_23:
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	jmp	LBB0_28
LBB0_24:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	testl	%r12d, %r12d
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	jg	LBB0_31
## %bb.25:
	xorl	%r12d, %r12d
	jmp	LBB0_29
LBB0_26:
	xorl	%r12d, %r12d
	jmp	LBB0_28
LBB0_27:
	movq	_XLOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	callq	_plog
LBB0_28:
	movq	-48(%rbp), %r15                 ## 8-byte Reload
LBB0_29:
	movl	%r15d, %edi
	callq	_close
LBB0_30:
	movq	%r12, %rax
LBB0_31:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_errno,8,3                      ## @errno
	.comm	_EAGAIN,8,3                     ## @EAGAIN
	.comm	_EINTR,8,3                      ## @EINTR
	.comm	_XLOG_WARNING,4,2               ## @XLOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fgets_timed read error: %m"

L_.str.1:                               ## @.str.1
	.asciz	"executable map read timed out (> %d secs)"

L_.str.2:                               ## @.str.2
	.asciz	"fgets_timed select error: %m"

	.no_dead_strip	_fgets_timed
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fgets_timed
_fgets_timed:                           ; @fgets_timed
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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
	mov	x20, x0
	mov	x0, #0
	cbz	x20, LBB0_31
; %bb.1:
	mov	x19, x2
	mov	x23, x1
	orr	w8, w2, w1
	tbnz	w8, #31, LBB0_31
; %bb.2:
	strb	wzr, [x20]
	cbz	w23, LBB0_30
; %bb.3:
	mov	x21, x3
	mov	x0, #0
	bl	_clocktime
	ldrb	w8, [x20]
	cmp	w8, #10
	b.eq	LBB0_29
; %bb.4:
	cmp	w23, #2
	b.lt	LBB0_29
; %bb.5:
	mov	x22, x0
	mov	x27, #0
	sub	w8, w23, #1
	str	x8, [sp, #16]                   ; 8-byte Folded Spill
Lloh0:
	adrp	x24, _EINTR@GOTPAGE
Lloh1:
	ldr	x24, [x24, _EINTR@GOTPAGEOFF]
	add	w23, w19, #1
	mov	x28, x20
LBB0_6:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	mov	x25, x28
	add	x27, x27, #1
	add	x28, x20, x27
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=2
Lloh2:
	adrp	x8, _XLOG_WARNING@GOTPAGE
Lloh3:
	ldr	x8, [x8, _XLOG_WARNING@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
Lloh5:
	adrp	x1, l_.str.2@PAGE
Lloh6:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_plog
Lloh7:
	adrp	x8, _errno@GOTPAGE
Lloh8:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	ldr	x9, [x24]
	cmp	x8, x9
	b.ne	LBB0_28
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=2
	ldrb	w8, [x25]
	cmp	w8, #10
	b.eq	LBB0_22
LBB0_9:                                 ;   Parent Loop BB0_6 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	strb	wzr, [x28]
	mov	x0, x19
	mov	x1, x25
	mov	w2, #1
	bl	_read
	cbz	w0, LBB0_29
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=2
	cmp	w0, #1
	b.eq	LBB0_19
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=2
	tbz	w0, #31, LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=2
Lloh10:
	adrp	x8, _errno@GOTPAGE
Lloh11:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
Lloh13:
	adrp	x9, _EAGAIN@GOTPAGE
Lloh14:
	ldr	x9, [x9, _EAGAIN@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	ldr	x10, [x24]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_26
LBB0_13:                                ;   in Loop: Header=BB0_9 Depth=2
	str	xzr, [sp, #32]
	mov	x0, #0
	bl	_clocktime
	cmp	w21, #1
	b.lt	LBB0_16
; %bb.14:                               ;   in Loop: Header=BB0_9 Depth=2
	sub	w8, w0, w22
	cmp	w8, w21
	b.ge	LBB0_23
; %bb.15:                               ;   in Loop: Header=BB0_9 Depth=2
	sub	w8, w21, w8
	b	LBB0_17
LBB0_16:                                ;   in Loop: Header=BB0_9 Depth=2
	mov	w8, #0
LBB0_17:                                ;   in Loop: Header=BB0_9 Depth=2
	str	w8, [sp, #24]
	add	x0, sp, #44
	bl	_FD_ZERO
	add	x1, sp, #44
	mov	x0, x19
	bl	_FD_SET
	add	x1, sp, #44
	add	x4, sp, #24
	mov	x0, x23
	mov	x2, #0
	mov	x3, #0
	bl	_select
	mov	x26, x0
	tbnz	w0, #31, LBB0_7
; %bb.18:                               ;   in Loop: Header=BB0_9 Depth=2
	cbnz	w26, LBB0_8
	b	LBB0_24
LBB0_19:                                ;   in Loop: Header=BB0_6 Depth=1
	ldrb	w8, [x25]
	cbz	w8, LBB0_29
; %bb.20:                               ;   in Loop: Header=BB0_6 Depth=1
	ldrb	w8, [x28]
	cmp	w8, #10
	b.eq	LBB0_30
; %bb.21:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	cmp	x27, x8
	b.lo	LBB0_6
	b	LBB0_30
LBB0_22:
	mov	x0, x20
	cmp	w26, #0
	b.gt	LBB0_31
	b	LBB0_28
LBB0_23:
Lloh16:
	adrp	x8, _XLOG_WARNING@GOTPAGE
Lloh17:
	ldr	x8, [x8, _XLOG_WARNING@GOTPAGEOFF]
Lloh18:
	ldr	w0, [x8]
	b	LBB0_25
LBB0_24:
Lloh19:
	adrp	x8, _XLOG_WARNING@GOTPAGE
Lloh20:
	ldr	x8, [x8, _XLOG_WARNING@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
                                        ; kill: def $w21 killed $w21 killed $x21 def $x21
LBB0_25:
	str	x21, [sp]
Lloh22:
	adrp	x1, l_.str.1@PAGE
Lloh23:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_27
LBB0_26:
Lloh24:
	adrp	x8, _XLOG_WARNING@GOTPAGE
Lloh25:
	ldr	x8, [x8, _XLOG_WARNING@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
Lloh27:
	adrp	x1, l_.str@PAGE
Lloh28:
	add	x1, x1, l_.str@PAGEOFF
LBB0_27:
	bl	_plog
LBB0_28:
	mov	x20, #0
LBB0_29:
	mov	x0, x19
	bl	_close
LBB0_30:
	mov	x0, x20
LBB0_31:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_errno,8,3                      ; @errno
	.comm	_EAGAIN,8,3                     ; @EAGAIN
	.comm	_EINTR,8,3                      ; @EINTR
	.comm	_XLOG_WARNING,4,2               ; @XLOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fgets_timed read error: %m"

l_.str.1:                               ; @.str.1
	.asciz	"executable map read timed out (> %d secs)"

l_.str.2:                               ; @.str.2
	.asciz	"fgets_timed select error: %m"

	.no_dead_strip	_fgets_timed
.subsections_via_symbols
