	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function threadRun
_threadRun:                             ## @threadRun
	.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	$88, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	40(%rdi), %r15
	movl	(%rdi), %edi
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_alloc_socket_set
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movl	28(%r13), %edi
	callq	_INSTR_TIME_GET_MICROSEC
	movq	%rax, -128(%rbp)                ## 8-byte Spill
	movl	%eax, -120(%rbp)
	movq	_progress@GOTPCREL(%rip), %rax
	imull	$1000000, (%rax), %eax          ## imm = 0xF4240
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	callq	_INSTR_TIME_SET_CURRENT
	callq	_INSTR_TIME_GET_MICROSEC
	movq	%rax, 32(%r13)
	movl	24(%r13), %edi
	callq	_INSTR_TIME_SET_ZERO
	xorl	%edi, %edi
	callq	_time
	leaq	-76(%rbp), %rdi
	movl	%eax, %esi
	callq	_initStats
	movl	-76(%rbp), %eax
	movl	%eax, -116(%rbp)
	movq	_use_log@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_6
## %bb.1:
	movq	%r15, %r12
	movq	%rsp, %r14
	movq	_MAXPGPATH@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r15
	movq	_logfile_prefix@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	leaq	L_.str(%rip), %rcx
	cmovneq	%rax, %rcx
	movq	8(%r13), %r9
	movq	_main_pid@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	testq	%r9, %r9
	je	LBB0_3
## %bb.2:
	leaq	L_.str.2(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_snprintf
	jmp	LBB0_4
LBB0_3:
	leaq	L_.str.1(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_snprintf
LBB0_4:
	leaq	L_.str.3(%rip), %rsi
	movq	%r15, %rdi
	callq	_fopen
	movq	%rax, 16(%r13)
	testq	%rax, %rax
	je	LBB0_14
## %bb.5:
	movq	%r14, %rsp
	movq	%r12, %r15
LBB0_6:
	movq	_is_connect@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jne	LBB0_11
## %bb.7:
	cmpl	$0, -64(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_11
## %bb.8:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	leaq	(,%rax,8), %rax
	leaq	(%rax,%rax,2), %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_doConnect
	movq	%rax, 16(%r15,%rbx)
	testq	%rax, %rax
	je	LBB0_72
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	addq	$24, %rbx
	cmpq	%rbx, %r14
	jne	LBB0_9
LBB0_11:
	movl	24(%r13), %edi
	callq	_INSTR_TIME_SET_CURRENT
	movl	24(%r13), %edi
	movl	28(%r13), %esi
	callq	_INSTR_TIME_SUBTRACT
	cmpl	$0, -64(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_72
## %bb.12:
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	leaq	-1(%r8), %rcx
	movl	%r8d, %eax
	andl	$3, %eax
	cmpq	$3, %rcx
	jae	LBB0_15
## %bb.13:
	xorl	%ecx, %ecx
	jmp	LBB0_17
LBB0_14:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_strerror
	leaq	L_.str.4(%rip), %rsi
	movl	%ebx, %edi
	movq	%r15, %rdx
	movq	%rax, %rcx
	xorl	%eax, %eax
	callq	_fprintf
	movq	%r14, %rsp
	movq	%r12, %r15
	jmp	LBB0_72
LBB0_15:
	movl	%r8d, %edx
	andl	$-4, %edx
	xorl	%ecx, %ecx
	movq	_CSTATE_CHOOSE_SCRIPT@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movq	(%rsi), %rbx
	movq	%rbx, (%rdi)
	movq	(%rsi), %rbx
	movq	%rbx, 24(%rdi)
	movq	(%rsi), %rbx
	movq	%rbx, 48(%rdi)
	movq	(%rsi), %rbx
	movq	%rbx, 72(%rdi)
	addq	$4, %rcx
	addq	$96, %rdi
	cmpq	%rcx, %rdx
	jne	LBB0_16
LBB0_17:
	testq	%rax, %rax
	movl	-52(%rbp), %ebx                 ## 4-byte Reload
	je	LBB0_20
## %bb.18:
	leaq	(%rcx,%rcx,2), %rcx
	leaq	(%r15,%rcx,8), %rcx
	shlq	$3, %rax
	leaq	(%rax,%rax,2), %rax
	xorl	%edx, %edx
	movq	_CSTATE_CHOOSE_SCRIPT@GOTPCREL(%rip), %rsi
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	(%rsi), %rdi
	movq	%rdi, (%rcx,%rdx)
	addq	$24, %rdx
	cmpq	%rdx, %rax
	jne	LBB0_19
LBB0_20:
	addl	-128(%rbp), %ebx                ## 4-byte Folded Reload
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
	leaq	8(%r15), %r12
	movq	_PG_INT64_MAX@GOTPCREL(%rip), %rbx
	movl	%r8d, %eax
	movl	%r8d, -92(%rbp)                 ## 4-byte Spill
	movq	%r13, -112(%rbp)                ## 8-byte Spill
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	movq	%r12, -104(%rbp)                ## 8-byte Spill
	jmp	LBB0_21
LBB0_47:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	_EINTR@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdi
	movq	-112(%rbp), %r13                ## 8-byte Reload
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	movq	-104(%rbp), %r12                ## 8-byte Reload
	movq	_PG_INT64_MAX@GOTPCREL(%rip), %rbx
	jne	LBB0_78
LBB0_60:                                ##   in Loop: Header=BB0_21 Depth=1
	cmpl	$0, -92(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_72
LBB0_21:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_25 Depth 2
                                        ##     Child Loop BB0_53 Depth 2
                                        ##     Child Loop BB0_64 Depth 2
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_clear_socket_set
	movl	(%rbx), %r13d
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movq	%r12, %rbx
	xorl	%r12d, %r12d
	xorl	%r15d, %r15d
	movq	_CSTATE_SLEEP@GOTPCREL(%rip), %rsi
	jmp	LBB0_25
	.p2align	4, 0x90
LBB0_22:                                ##   in Loop: Header=BB0_25 Depth=2
	testl	%r15d, %r15d
	je	LBB0_32
LBB0_23:                                ##   in Loop: Header=BB0_25 Depth=2
	leaq	4(%rbx), %rdx
	cmpq	%rcx, %rax
	cmoveq	%rbx, %rdx
	movl	(%rdx), %eax
	subl	%r15d, %eax
	cmpl	%eax, %r13d
	cmovgel	%eax, %r13d
LBB0_24:                                ##   in Loop: Header=BB0_25 Depth=2
	addq	$24, %rbx
	decq	%r14
	je	LBB0_33
LBB0_25:                                ##   Parent Loop BB0_21 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	-8(%rbx), %rax
	movq	(%rsi), %rcx
	cmpq	%rcx, %rax
	je	LBB0_22
## %bb.26:                              ##   in Loop: Header=BB0_25 Depth=2
	movq	_CSTATE_THROTTLE@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_22
## %bb.27:                              ##   in Loop: Header=BB0_25 Depth=2
	movq	_CSTATE_WAIT_RESULT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_30
## %bb.28:                              ##   in Loop: Header=BB0_25 Depth=2
	movq	8(%rbx), %rdi
	callq	_PQsocket
	testl	%eax, %eax
	js	LBB0_70
## %bb.29:                              ##   in Loop: Header=BB0_25 Depth=2
	movq	%r12, %rdx
	incl	%r12d
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_add_socket_to_set
                                        ## kill: def $r12d killed $r12d def $r12
	movq	_CSTATE_SLEEP@GOTPCREL(%rip), %rsi
	jmp	LBB0_24
	.p2align	4, 0x90
LBB0_30:                                ##   in Loop: Header=BB0_25 Depth=2
	movq	_CSTATE_ABORTED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_24
## %bb.31:                              ##   in Loop: Header=BB0_25 Depth=2
	movq	_CSTATE_FINISHED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_24
	jmp	LBB0_48
LBB0_32:                                ##   in Loop: Header=BB0_25 Depth=2
	callq	_INSTR_TIME_SET_CURRENT
	callq	_INSTR_TIME_GET_MICROSEC
	movq	_CSTATE_SLEEP@GOTPCREL(%rip), %rsi
	movq	%rax, %r15
	movq	-8(%rbx), %rax
	movq	(%rsi), %rcx
	jmp	LBB0_23
	.p2align	4, 0x90
LBB0_33:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	_progress@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_41
## %bb.34:                              ##   in Loop: Header=BB0_21 Depth=1
	testl	%r13d, %r13d
	jle	LBB0_41
## %bb.35:                              ##   in Loop: Header=BB0_21 Depth=1
	movq	-112(%rbp), %rax                ## 8-byte Reload
	cmpq	$0, 8(%rax)
	jne	LBB0_43
## %bb.36:                              ##   in Loop: Header=BB0_21 Depth=1
	testl	%r15d, %r15d
	jne	LBB0_38
## %bb.37:                              ##   in Loop: Header=BB0_21 Depth=1
	callq	_INSTR_TIME_SET_CURRENT
	callq	_INSTR_TIME_GET_MICROSEC
	movq	%rax, %r15
LBB0_38:                                ##   in Loop: Header=BB0_21 Depth=1
	movl	-52(%rbp), %eax                 ## 4-byte Reload
	subl	%r15d, %eax
	jle	LBB0_48
## %bb.39:                              ##   in Loop: Header=BB0_21 Depth=1
	cmpl	%r13d, %eax
	jl	LBB0_42
	jmp	LBB0_43
	.p2align	4, 0x90
LBB0_41:                                ##   in Loop: Header=BB0_21 Depth=1
	movl	%r13d, %eax
LBB0_42:                                ##   in Loop: Header=BB0_21 Depth=1
	movl	%eax, %r13d
	testl	%eax, %eax
	jle	LBB0_48
LBB0_43:                                ##   in Loop: Header=BB0_21 Depth=1
	xorl	%esi, %esi
	movq	_PG_INT64_MAX@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	je	LBB0_46
## %bb.44:                              ##   in Loop: Header=BB0_21 Depth=1
	testl	%r12d, %r12d
	jle	LBB0_68
## %bb.45:                              ##   in Loop: Header=BB0_21 Depth=1
	movl	%r13d, %esi
LBB0_46:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_wait_on_socket_set
	testl	%eax, %eax
	jns	LBB0_49
	jmp	LBB0_47
	.p2align	4, 0x90
LBB0_48:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_clear_socket_set
	movq	-64(%rbp), %r14                 ## 8-byte Reload
LBB0_49:                                ##   in Loop: Header=BB0_21 Depth=1
	xorl	%r15d, %r15d
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	-112(%rbp), %r13                ## 8-byte Reload
	jmp	LBB0_53
	.p2align	4, 0x90
LBB0_50:                                ##   in Loop: Header=BB0_53 Depth=2
	movq	%r13, %rdi
	movq	%rbx, %rsi
	leaq	-76(%rbp), %rdx
	callq	_advanceConnectionState
	movq	(%rbx), %rax
	movq	_CSTATE_FINISHED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	sete	%cl
	movq	_CSTATE_ABORTED@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	sete	%al
	orb	%cl, %al
	movzbl	%al, %eax
	subl	%eax, -92(%rbp)                 ## 4-byte Folded Spill
LBB0_51:                                ##   in Loop: Header=BB0_53 Depth=2
	movl	%r12d, %r15d
LBB0_52:                                ##   in Loop: Header=BB0_53 Depth=2
	addq	$24, %rbx
	decq	%r14
	je	LBB0_58
LBB0_53:                                ##   Parent Loop BB0_21 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	(%rbx), %rax
	movq	_CSTATE_WAIT_RESULT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_56
## %bb.54:                              ##   in Loop: Header=BB0_53 Depth=2
	movq	16(%rbx), %rdi
	callq	_PQsocket
	testl	%eax, %eax
	js	LBB0_69
## %bb.55:                              ##   in Loop: Header=BB0_53 Depth=2
	leal	1(%r15), %r12d
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, %esi
	movl	%r15d, %edx
	callq	_socket_has_input
	testl	%eax, %eax
	jne	LBB0_50
	jmp	LBB0_51
	.p2align	4, 0x90
LBB0_56:                                ##   in Loop: Header=BB0_53 Depth=2
	movq	_CSTATE_FINISHED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_52
## %bb.57:                              ##   in Loop: Header=BB0_53 Depth=2
	movl	%r15d, %r12d
	movq	_CSTATE_ABORTED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_50
	jmp	LBB0_52
	.p2align	4, 0x90
LBB0_58:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	_progress@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	movq	-104(%rbp), %r12                ## 8-byte Reload
	je	LBB0_61
## %bb.59:                              ##   in Loop: Header=BB0_21 Depth=1
	cmpq	$0, 8(%r13)
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	movq	_PG_INT64_MAX@GOTPCREL(%rip), %rbx
	jne	LBB0_60
## %bb.62:                              ##   in Loop: Header=BB0_21 Depth=1
	callq	_INSTR_TIME_SET_CURRENT
	callq	_INSTR_TIME_GET_MICROSEC
	movq	%rax, %r14
	movl	-52(%rbp), %ebx                 ## 4-byte Reload
	cmpl	%r14d, %ebx
	jg	LBB0_66
## %bb.63:                              ##   in Loop: Header=BB0_21 Depth=1
	movq	%r13, %rdi
	movq	-128(%rbp), %rsi                ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	movl	%r14d, %edx
	leaq	-116(%rbp), %rcx
	leaq	-120(%rbp), %r8
	callq	_printProgressReport
	movq	_progress@GOTPCREL(%rip), %rax
	imull	$1000000, (%rax), %eax          ## imm = 0xF4240
	.p2align	4, 0x90
LBB0_64:                                ##   Parent Loop BB0_21 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	addl	%eax, %ebx
	cmpl	%r14d, %ebx
	jle	LBB0_64
## %bb.65:                              ##   in Loop: Header=BB0_21 Depth=1
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
LBB0_66:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	-104(%rbp), %r12                ## 8-byte Reload
	jmp	LBB0_67
LBB0_61:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	-72(%rbp), %r15                 ## 8-byte Reload
LBB0_67:                                ##   in Loop: Header=BB0_21 Depth=1
	movq	_PG_INT64_MAX@GOTPCREL(%rip), %rbx
	cmpl	$0, -92(%rbp)                   ## 4-byte Folded Reload
	jg	LBB0_21
	jmp	LBB0_72
LBB0_68:                                ##   in Loop: Header=BB0_21 Depth=1
	movl	%r13d, %edi
	callq	_pg_usleep
	jmp	LBB0_49
LBB0_69:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	16(%rbx), %rdi
	callq	_PQerrorMessage
	leaq	L_.str.5(%rip), %rsi
	movl	%r15d, %edi
	movq	%rax, %rdx
	xorl	%eax, %eax
	callq	_fprintf
	jmp	LBB0_71
LBB0_70:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	8(%rbx), %rdi
	callq	_PQerrorMessage
	leaq	L_.str.5(%rip), %rsi
	movl	%r14d, %edi
	movq	%rax, %rdx
	xorl	%eax, %eax
	callq	_fprintf
	movq	-112(%rbp), %r13                ## 8-byte Reload
LBB0_71:
	movq	-72(%rbp), %r15                 ## 8-byte Reload
LBB0_72:
	callq	_INSTR_TIME_SET_CURRENT
	movq	%r15, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_disconnect_all
	callq	_INSTR_TIME_SET_CURRENT
	movl	24(%r13), %edi
	callq	_INSTR_TIME_ACCUM_DIFF
	movq	16(%r13), %rdi
	testq	%rdi, %rdi
	je	LBB0_76
## %bb.73:
	movq	_agg_interval@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jle	LBB0_75
## %bb.74:
	leaq	-76(%rbp), %rdx
	movq	%r13, %rdi
	movq	%r15, %rsi
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_doLog
	movq	16(%r13), %rdi
LBB0_75:
	callq	_fclose
	movq	$0, 16(%r13)
LBB0_76:
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_free_socket_set
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_79
## %bb.77:
	xorl	%eax, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_78:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_SOCKET_WAIT_METHOD@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	callq	_strerror
	leaq	L_.str.6(%rip), %rsi
	movl	%ebx, %edi
	movq	%r15, %rdx
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	movq	%rax, %rcx
	xorl	%eax, %eax
	callq	_fprintf
	jmp	LBB0_72
LBB0_79:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_progress,8,3                   ## @progress
	.comm	_use_log,8,3                    ## @use_log
	.comm	_MAXPGPATH,4,2                  ## @MAXPGPATH
	.comm	_logfile_prefix,8,3             ## @logfile_prefix
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pgbench_log"

L_.str.1:                               ## @.str.1
	.asciz	"%s.%d"

	.comm	_main_pid,4,2                   ## @main_pid
L_.str.2:                               ## @.str.2
	.asciz	"%s.%d.%d"

L_.str.3:                               ## @.str.3
	.asciz	"w"

	.comm	_stderr,4,2                     ## @stderr
L_.str.4:                               ## @.str.4
	.asciz	"could not open logfile \"%s\": %s\n"

	.comm	_errno,8,3                      ## @errno
	.comm	_is_connect,4,2                 ## @is_connect
	.comm	_CSTATE_CHOOSE_SCRIPT,8,3       ## @CSTATE_CHOOSE_SCRIPT
	.comm	_PG_INT64_MAX,4,2               ## @PG_INT64_MAX
	.comm	_CSTATE_SLEEP,8,3               ## @CSTATE_SLEEP
	.comm	_CSTATE_THROTTLE,8,3            ## @CSTATE_THROTTLE
	.comm	_CSTATE_WAIT_RESULT,8,3         ## @CSTATE_WAIT_RESULT
L_.str.5:                               ## @.str.5
	.asciz	"invalid socket: %s"

	.comm	_CSTATE_ABORTED,8,3             ## @CSTATE_ABORTED
	.comm	_CSTATE_FINISHED,8,3            ## @CSTATE_FINISHED
	.comm	_EINTR,8,3                      ## @EINTR
L_.str.6:                               ## @.str.6
	.asciz	"%s() failed: %s\n"

	.comm	_SOCKET_WAIT_METHOD,8,3         ## @SOCKET_WAIT_METHOD
	.comm	_agg_interval,8,3               ## @agg_interval
	.no_dead_strip	_threadRun
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function threadRun
_threadRun:                             ; @threadRun
	.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, #64
	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, #-88]
	ldr	x27, [x0, #40]
	ldr	w0, [x0]
	stur	x0, [x29, #-112]                ; 8-byte Folded Spill
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_alloc_socket_set
	mov	x26, x0
	ldr	w0, [x19, #28]
	bl	_INSTR_TIME_GET_MICROSEC
	stur	x0, [x29, #-120]                ; 8-byte Folded Spill
	stur	w0, [x29, #-92]
Lloh3:
	adrp	x8, _progress@GOTPAGE
Lloh4:
	ldr	x8, [x8, _progress@GOTPAGEOFF]
Lloh5:
	ldr	w20, [x8]
	bl	_INSTR_TIME_SET_CURRENT
	bl	_INSTR_TIME_GET_MICROSEC
	str	x0, [x19, #32]
	ldr	w0, [x19, #24]
	bl	_INSTR_TIME_SET_ZERO
	mov	x0, #0
	bl	_time
	mov	x1, x0
	sub	x0, x29, #100
	bl	_initStats
	ldur	w8, [x29, #-100]
	stur	w8, [x29, #-96]
Lloh6:
	adrp	x8, _use_log@GOTPAGE
Lloh7:
	ldr	x8, [x8, _use_log@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	cbz	x8, LBB0_6
; %bb.1:
	mov	x21, sp
Lloh9:
	adrp	x8, _MAXPGPATH@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MAXPGPATH@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x9, x1
Lloh12:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh13:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x1, #15
	and	x9, x9, #0x1fffffff0
	sub	x24, x8, x9
	mov	sp, x24
Lloh14:
	adrp	x8, _logfile_prefix@GOTPAGE
Lloh15:
	ldr	x8, [x8, _logfile_prefix@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
Lloh17:
	adrp	x9, l_.str@PAGE
Lloh18:
	add	x9, x9, l_.str@PAGEOFF
	cmp	x8, #0
	csel	x3, x9, x8, eq
	ldr	x8, [x19, #8]
Lloh19:
	adrp	x9, _main_pid@GOTPAGE
Lloh20:
	ldr	x9, [x9, _main_pid@GOTPAGEOFF]
Lloh21:
	ldr	w4, [x9]
	cbz	x8, LBB0_3
; %bb.2:
Lloh22:
	adrp	x2, l_.str.2@PAGE
Lloh23:
	add	x2, x2, l_.str.2@PAGEOFF
	str	x8, [sp, #-16]!
	mov	x0, x24
                                        ; kill: def $w1 killed $w1 killed $x1
	bl	_snprintf
	add	sp, sp, #16
	b	LBB0_4
LBB0_3:
Lloh24:
	adrp	x2, l_.str.1@PAGE
Lloh25:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x24
                                        ; kill: def $w1 killed $w1 killed $x1
	bl	_snprintf
LBB0_4:
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x24
	bl	_fopen
	str	x0, [x19, #16]
	cbz	x0, LBB0_14
; %bb.5:
	mov	sp, x21
LBB0_6:
Lloh28:
	adrp	x8, _is_connect@GOTPAGE
Lloh29:
	ldr	x8, [x8, _is_connect@GOTPAGEOFF]
Lloh30:
	ldr	w8, [x8]
	cmp	w8, #0
	ldur	x8, [x29, #-112]                ; 8-byte Folded Reload
	ccmp	w8, #1, #8, eq
	b.lt	LBB0_10
; %bb.7:
	add	x21, x27, #16
	ldur	x22, [x29, #-112]               ; 8-byte Folded Reload
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	bl	_doConnect
	str	x0, [x21]
	cbz	x0, LBB0_63
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	add	x21, x21, #24
	subs	x22, x22, #1
	b.ne	LBB0_8
LBB0_10:
	ldr	w0, [x19, #24]
	bl	_INSTR_TIME_SET_CURRENT
	ldp	w0, w1, [x19, #24]
	bl	_INSTR_TIME_SUBTRACT
	ldur	x8, [x29, #-112]                ; 8-byte Folded Reload
	cmp	w8, #1
	b.lt	LBB0_63
; %bb.11:
	mov	w9, #16960
	movk	w9, #15, lsl #16
	ldur	x8, [x29, #-120]                ; 8-byte Folded Reload
	madd	w8, w20, w9, w8
	stur	w8, [x29, #-140]                ; 4-byte Folded Spill
Lloh31:
	adrp	x8, _CSTATE_CHOOSE_SCRIPT@GOTPAGE
Lloh32:
	ldr	x8, [x8, _CSTATE_CHOOSE_SCRIPT@GOTPAGEOFF]
	ldur	x9, [x29, #-112]                ; 8-byte Folded Reload
	mov	x10, x27
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x8]
	str	x11, [x10], #24
	subs	x9, x9, #1
	b.ne	LBB0_12
; %bb.13:
	add	x22, x27, #8
Lloh33:
	adrp	x23, _PG_INT64_MAX@GOTPAGE
Lloh34:
	ldr	x23, [x23, _PG_INT64_MAX@GOTPAGEOFF]
Lloh35:
	adrp	x25, _CSTATE_SLEEP@GOTPAGE
Lloh36:
	ldr	x25, [x25, _CSTATE_SLEEP@GOTPAGEOFF]
Lloh37:
	adrp	x21, _CSTATE_WAIT_RESULT@GOTPAGE
Lloh38:
	ldr	x21, [x21, _CSTATE_WAIT_RESULT@GOTPAGEOFF]
	ldur	x8, [x29, #-112]                ; 8-byte Folded Reload
	mov	x28, x8
	stp	x22, x27, [x29, #-136]          ; 16-byte Folded Spill
	b	LBB0_17
LBB0_14:
Lloh39:
	adrp	x8, _stderr@GOTPAGE
Lloh40:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh41:
	ldr	w23, [x8]
Lloh42:
	adrp	x8, _errno@GOTPAGE
Lloh43:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh44:
	ldr	x0, [x8]
	bl	_strerror
	str	x0, [sp, #-16]!
Lloh45:
	adrp	x1, l_.str.4@PAGE
Lloh46:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x23
	mov	x2, x24
	bl	_fprintf
	add	sp, sp, #16
	mov	sp, x21
	b	LBB0_63
LBB0_15:                                ;   in Loop: Header=BB0_17 Depth=1
	ldur	x22, [x29, #-136]               ; 8-byte Folded Reload
Lloh47:
	adrp	x23, _PG_INT64_MAX@GOTPAGE
Lloh48:
	ldr	x23, [x23, _PG_INT64_MAX@GOTPAGEOFF]
Lloh49:
	adrp	x25, _CSTATE_SLEEP@GOTPAGE
Lloh50:
	ldr	x25, [x25, _CSTATE_SLEEP@GOTPAGEOFF]
LBB0_16:                                ;   in Loop: Header=BB0_17 Depth=1
	cmp	w28, #0
	b.le	LBB0_63
LBB0_17:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_21 Depth 2
                                        ;     Child Loop BB0_46 Depth 2
                                        ;     Child Loop BB0_55 Depth 2
                                        ;     Child Loop BB0_58 Depth 2
	mov	x27, x26
	mov	x0, x26
	bl	_clear_socket_set
	mov	w20, #0
	mov	w26, #0
	ldr	w24, [x23]
	ldur	x23, [x29, #-112]               ; 8-byte Folded Reload
Lloh51:
	adrp	x11, _CSTATE_THROTTLE@GOTPAGE
Lloh52:
	ldr	x11, [x11, _CSTATE_THROTTLE@GOTPAGEOFF]
	b	LBB0_21
LBB0_18:                                ;   in Loop: Header=BB0_21 Depth=2
	cbz	w26, LBB0_26
LBB0_19:                                ;   in Loop: Header=BB0_21 Depth=2
	add	x10, x22, #4
	cmp	x8, x9
	csel	x8, x22, x10, eq
	ldr	w8, [x8]
	sub	w8, w8, w26
	cmp	w24, w8
	csel	w24, w24, w8, lt
LBB0_20:                                ;   in Loop: Header=BB0_21 Depth=2
	add	x22, x22, #24
	subs	x23, x23, #1
	b.eq	LBB0_27
LBB0_21:                                ;   Parent Loop BB0_17 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldur	x8, [x22, #-8]
	ldr	x9, [x25]
	ldr	x10, [x11]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.eq	LBB0_18
; %bb.22:                               ;   in Loop: Header=BB0_21 Depth=2
	ldr	x9, [x21]
	cmp	x8, x9
	b.ne	LBB0_25
; %bb.23:                               ;   in Loop: Header=BB0_21 Depth=2
	ldr	x0, [x22, #8]
	bl	_PQsocket
	tbnz	w0, #31, LBB0_62
; %bb.24:                               ;   in Loop: Header=BB0_21 Depth=2
	mov	x1, x0
	add	w25, w20, #1
	mov	x0, x27
	mov	x2, x20
	bl	_add_socket_to_set
	mov	x20, x25
Lloh53:
	adrp	x25, _CSTATE_SLEEP@GOTPAGE
Lloh54:
	ldr	x25, [x25, _CSTATE_SLEEP@GOTPAGEOFF]
Lloh55:
	adrp	x11, _CSTATE_THROTTLE@GOTPAGE
Lloh56:
	ldr	x11, [x11, _CSTATE_THROTTLE@GOTPAGEOFF]
	b	LBB0_20
LBB0_25:                                ;   in Loop: Header=BB0_21 Depth=2
Lloh57:
	adrp	x9, _CSTATE_ABORTED@GOTPAGE
Lloh58:
	ldr	x9, [x9, _CSTATE_ABORTED@GOTPAGEOFF]
Lloh59:
	ldr	x9, [x9]
Lloh60:
	adrp	x10, _CSTATE_FINISHED@GOTPAGE
Lloh61:
	ldr	x10, [x10, _CSTATE_FINISHED@GOTPAGEOFF]
Lloh62:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.eq	LBB0_20
	b	LBB0_40
LBB0_26:                                ;   in Loop: Header=BB0_21 Depth=2
	bl	_INSTR_TIME_SET_CURRENT
	bl	_INSTR_TIME_GET_MICROSEC
	mov	x26, x0
Lloh63:
	adrp	x11, _CSTATE_THROTTLE@GOTPAGE
Lloh64:
	ldr	x11, [x11, _CSTATE_THROTTLE@GOTPAGEOFF]
	ldur	x8, [x22, #-8]
	ldr	x9, [x25]
	b	LBB0_19
LBB0_27:                                ;   in Loop: Header=BB0_17 Depth=1
Lloh65:
	adrp	x8, _progress@GOTPAGE
Lloh66:
	ldr	x8, [x8, _progress@GOTPAGEOFF]
Lloh67:
	ldr	x8, [x8]
	cmp	x8, #0
	ccmp	w24, #1, #8, ne
	b.ge	LBB0_30
; %bb.28:                               ;   in Loop: Header=BB0_17 Depth=1
	mov	x8, x24
LBB0_29:                                ;   in Loop: Header=BB0_17 Depth=1
	mov	x24, x8
	cmp	w8, #1
	b.ge	LBB0_31
	b	LBB0_40
LBB0_30:                                ;   in Loop: Header=BB0_17 Depth=1
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_36
LBB0_31:                                ;   in Loop: Header=BB0_17 Depth=1
Lloh68:
	adrp	x8, _PG_INT64_MAX@GOTPAGE
Lloh69:
	ldr	x8, [x8, _PG_INT64_MAX@GOTPAGEOFF]
Lloh70:
	ldr	w8, [x8]
	cmp	w24, w8
	b.ne	LBB0_33
; %bb.32:                               ;   in Loop: Header=BB0_17 Depth=1
	mov	w24, #0
	mov	x26, x27
	b	LBB0_34
LBB0_33:                                ;   in Loop: Header=BB0_17 Depth=1
	cmp	w20, #0
	mov	x26, x27
	b.le	LBB0_60
LBB0_34:                                ;   in Loop: Header=BB0_17 Depth=1
	ldur	x27, [x29, #-128]               ; 8-byte Folded Reload
Lloh71:
	adrp	x20, _CSTATE_FINISHED@GOTPAGE
Lloh72:
	ldr	x20, [x20, _CSTATE_FINISHED@GOTPAGEOFF]
	mov	x0, x26
	mov	x1, x24
	bl	_wait_on_socket_set
	tbz	w0, #31, LBB0_42
; %bb.35:                               ;   in Loop: Header=BB0_17 Depth=1
Lloh73:
	adrp	x8, _errno@GOTPAGE
Lloh74:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh75:
	ldr	x0, [x8]
Lloh76:
	adrp	x8, _EINTR@GOTPAGE
Lloh77:
	ldr	x8, [x8, _EINTR@GOTPAGEOFF]
Lloh78:
	ldr	x8, [x8]
	cmp	x0, x8
	ldur	x22, [x29, #-136]               ; 8-byte Folded Reload
Lloh79:
	adrp	x23, _PG_INT64_MAX@GOTPAGE
Lloh80:
	ldr	x23, [x23, _PG_INT64_MAX@GOTPAGEOFF]
	b.eq	LBB0_16
	b	LBB0_69
LBB0_36:                                ;   in Loop: Header=BB0_17 Depth=1
	cbnz	w26, LBB0_38
; %bb.37:                               ;   in Loop: Header=BB0_17 Depth=1
	bl	_INSTR_TIME_SET_CURRENT
	bl	_INSTR_TIME_GET_MICROSEC
	mov	x26, x0
LBB0_38:                                ;   in Loop: Header=BB0_17 Depth=1
	ldur	w8, [x29, #-140]                ; 4-byte Folded Reload
	subs	w8, w8, w26
	b.le	LBB0_40
; %bb.39:                               ;   in Loop: Header=BB0_17 Depth=1
	cmp	w8, w24
	b.lt	LBB0_29
	b	LBB0_31
LBB0_40:                                ;   in Loop: Header=BB0_17 Depth=1
	mov	x26, x27
	mov	x0, x27
	bl	_clear_socket_set
LBB0_41:                                ;   in Loop: Header=BB0_17 Depth=1
	ldur	x27, [x29, #-128]               ; 8-byte Folded Reload
Lloh81:
	adrp	x20, _CSTATE_FINISHED@GOTPAGE
Lloh82:
	ldr	x20, [x20, _CSTATE_FINISHED@GOTPAGEOFF]
LBB0_42:                                ;   in Loop: Header=BB0_17 Depth=1
	mov	w25, #0
	ldur	x22, [x29, #-112]               ; 8-byte Folded Reload
	mov	x24, x27
	b	LBB0_46
LBB0_43:                                ;   in Loop: Header=BB0_46 Depth=2
	sub	x2, x29, #100
	mov	x0, x19
	mov	x1, x24
	bl	_advanceConnectionState
	ldr	x8, [x24]
	ldr	x9, [x20]
	cmp	x8, x9
Lloh83:
	adrp	x9, _CSTATE_ABORTED@GOTPAGE
Lloh84:
	ldr	x9, [x9, _CSTATE_ABORTED@GOTPAGEOFF]
Lloh85:
	ldr	x9, [x9]
	ccmp	x8, x9, #4, ne
	cset	w8, eq
	sub	w28, w28, w8
LBB0_44:                                ;   in Loop: Header=BB0_46 Depth=2
	mov	x25, x23
LBB0_45:                                ;   in Loop: Header=BB0_46 Depth=2
	add	x24, x24, #24
	subs	x22, x22, #1
	b.eq	LBB0_50
LBB0_46:                                ;   Parent Loop BB0_17 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x24]
	ldr	x9, [x21]
	cmp	x8, x9
	b.ne	LBB0_49
; %bb.47:                               ;   in Loop: Header=BB0_46 Depth=2
	ldr	x0, [x24, #16]
	bl	_PQsocket
	tbnz	w0, #31, LBB0_61
; %bb.48:                               ;   in Loop: Header=BB0_46 Depth=2
	mov	x1, x0
	add	w23, w25, #1
	mov	x0, x26
	mov	x2, x25
	bl	_socket_has_input
	cbnz	w0, LBB0_43
	b	LBB0_44
LBB0_49:                                ;   in Loop: Header=BB0_46 Depth=2
	ldr	x9, [x20]
Lloh86:
	adrp	x10, _CSTATE_ABORTED@GOTPAGE
Lloh87:
	ldr	x10, [x10, _CSTATE_ABORTED@GOTPAGEOFF]
Lloh88:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	mov	x23, x25
	b.ne	LBB0_43
	b	LBB0_45
LBB0_50:                                ;   in Loop: Header=BB0_17 Depth=1
Lloh89:
	adrp	x8, _progress@GOTPAGE
Lloh90:
	ldr	x8, [x8, _progress@GOTPAGEOFF]
Lloh91:
	ldr	x8, [x8]
	cbz	x8, LBB0_15
; %bb.51:                               ;   in Loop: Header=BB0_17 Depth=1
	ldr	x8, [x19, #8]
	ldur	x22, [x29, #-136]               ; 8-byte Folded Reload
Lloh92:
	adrp	x23, _PG_INT64_MAX@GOTPAGE
Lloh93:
	ldr	x23, [x23, _PG_INT64_MAX@GOTPAGEOFF]
Lloh94:
	adrp	x25, _CSTATE_SLEEP@GOTPAGE
Lloh95:
	ldr	x25, [x25, _CSTATE_SLEEP@GOTPAGEOFF]
	cbnz	x8, LBB0_16
; %bb.52:                               ;   in Loop: Header=BB0_17 Depth=1
	bl	_INSTR_TIME_SET_CURRENT
	bl	_INSTR_TIME_GET_MICROSEC
	mov	x24, x0
	ldur	w20, [x29, #-140]               ; 4-byte Folded Reload
	cmp	w20, w24
	b.gt	LBB0_16
; %bb.53:                               ;   in Loop: Header=BB0_17 Depth=1
	sub	x3, x29, #96
	sub	x4, x29, #92
	mov	x0, x19
	ldur	x1, [x29, #-120]                ; 8-byte Folded Reload
                                        ; kill: def $w1 killed $w1 killed $x1
	mov	x2, x24
	bl	_printProgressReport
Lloh96:
	adrp	x8, _progress@GOTPAGE
Lloh97:
	ldr	x8, [x8, _progress@GOTPAGEOFF]
Lloh98:
	ldr	w8, [x8]
	mov	w9, #16960
	movk	w9, #15, lsl #16
	mul	w8, w8, w9
	add	w9, w24, #1
	add	w10, w20, w8
	cmp	w10, w9
	csinc	w9, w10, w24, gt
	sub	w9, w9, w20
	cmp	w9, w8
	cset	w10, ne
	mov	w11, #1
	cinc	w11, w11, ne
	sub	w9, w9, w10
	sub	w9, w9, w8
	cmp	w8, #1
	csinc	w10, w8, wzr, hi
	udiv	w9, w9, w10
	add	w9, w11, w9
	cmp	w9, #4
	b.lo	LBB0_57
; %bb.54:                               ;   in Loop: Header=BB0_17 Depth=1
	mov	w11, #0
	and	w10, w9, #0xfffffffc
	madd	w20, w10, w8, w20
	stur	w20, [x29, #-140]               ; 4-byte Folded Spill
LBB0_55:                                ;   Parent Loop BB0_17 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	w11, w11, #4
	cmp	w11, w10
	b.ne	LBB0_55
; %bb.56:                               ;   in Loop: Header=BB0_17 Depth=1
	cmp	w9, w10
	b.eq	LBB0_16
LBB0_57:                                ;   in Loop: Header=BB0_17 Depth=1
	ldur	w9, [x29, #-140]                ; 4-byte Folded Reload
LBB0_58:                                ;   Parent Loop BB0_17 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	w9, w9, w8
	cmp	w9, w24
	b.le	LBB0_58
; %bb.59:                               ;   in Loop: Header=BB0_17 Depth=1
	stur	w9, [x29, #-140]                ; 4-byte Folded Spill
	b	LBB0_16
LBB0_60:                                ;   in Loop: Header=BB0_17 Depth=1
	mov	x0, x24
	bl	_pg_usleep
	b	LBB0_41
LBB0_61:
Lloh99:
	adrp	x8, _stderr@GOTPAGE
Lloh100:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh101:
	ldr	w23, [x8]
	ldr	x0, [x24, #16]
	bl	_PQerrorMessage
	mov	x2, x0
Lloh102:
	adrp	x1, l_.str.5@PAGE
Lloh103:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x23
	bl	_fprintf
	b	LBB0_63
LBB0_62:
Lloh104:
	adrp	x8, _stderr@GOTPAGE
Lloh105:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh106:
	ldr	w23, [x8]
	ldr	x0, [x22, #8]
	bl	_PQerrorMessage
	mov	x2, x0
Lloh107:
	adrp	x1, l_.str.5@PAGE
Lloh108:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x23
	bl	_fprintf
	mov	x26, x27
	ldur	x27, [x29, #-128]               ; 8-byte Folded Reload
LBB0_63:
	bl	_INSTR_TIME_SET_CURRENT
	mov	x0, x27
	ldur	x1, [x29, #-112]                ; 8-byte Folded Reload
                                        ; kill: def $w1 killed $w1 killed $x1
	bl	_disconnect_all
	bl	_INSTR_TIME_SET_CURRENT
	ldr	w0, [x19, #24]
	bl	_INSTR_TIME_ACCUM_DIFF
	ldr	x0, [x19, #16]
	cbz	x0, LBB0_67
; %bb.64:
Lloh109:
	adrp	x8, _agg_interval@GOTPAGE
Lloh110:
	ldr	x8, [x8, _agg_interval@GOTPAGEOFF]
Lloh111:
	ldr	x8, [x8]
	cmp	x8, #1
	b.lt	LBB0_66
; %bb.65:
	sub	x2, x29, #100
	mov	x0, x19
	mov	x1, x27
	mov	w3, #0
	mov	w4, #0
	mov	w5, #0
	bl	_doLog
	ldr	x0, [x19, #16]
LBB0_66:
	bl	_fclose
	str	xzr, [x19, #16]
LBB0_67:
	mov	x0, x26
	bl	_free_socket_set
	ldur	x8, [x29, #-88]
Lloh112:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh113:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh114:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_70
; %bb.68:
	mov	x0, #0
	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_69:
Lloh115:
	adrp	x8, _stderr@GOTPAGE
Lloh116:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh117:
	ldr	w23, [x8]
Lloh118:
	adrp	x8, _SOCKET_WAIT_METHOD@GOTPAGE
Lloh119:
	ldr	x8, [x8, _SOCKET_WAIT_METHOD@GOTPAGEOFF]
Lloh120:
	ldr	x24, [x8]
	bl	_strerror
	str	x0, [sp, #-16]!
Lloh121:
	adrp	x1, l_.str.6@PAGE
Lloh122:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x23
	mov	x2, x24
	bl	_fprintf
	add	sp, sp, #16
	b	LBB0_63
LBB0_70:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh49, Lloh50
	.loh AdrpLdrGot	Lloh47, Lloh48
	.loh AdrpLdrGot	Lloh51, Lloh52
	.loh AdrpLdrGot	Lloh55, Lloh56
	.loh AdrpLdrGot	Lloh53, Lloh54
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpLdrGotLdr	Lloh57, Lloh58, Lloh59
	.loh AdrpLdrGot	Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGotLdr	Lloh68, Lloh69, Lloh70
	.loh AdrpLdrGot	Lloh71, Lloh72
	.loh AdrpLdrGot	Lloh79, Lloh80
	.loh AdrpLdrGotLdr	Lloh76, Lloh77, Lloh78
	.loh AdrpLdrGotLdr	Lloh73, Lloh74, Lloh75
	.loh AdrpLdrGot	Lloh81, Lloh82
	.loh AdrpLdrGotLdr	Lloh83, Lloh84, Lloh85
	.loh AdrpLdrGotLdr	Lloh86, Lloh87, Lloh88
	.loh AdrpLdrGotLdr	Lloh89, Lloh90, Lloh91
	.loh AdrpLdrGot	Lloh94, Lloh95
	.loh AdrpLdrGot	Lloh92, Lloh93
	.loh AdrpLdrGotLdr	Lloh96, Lloh97, Lloh98
	.loh AdrpAdd	Lloh102, Lloh103
	.loh AdrpLdrGotLdr	Lloh99, Lloh100, Lloh101
	.loh AdrpAdd	Lloh107, Lloh108
	.loh AdrpLdrGotLdr	Lloh104, Lloh105, Lloh106
	.loh AdrpLdrGotLdr	Lloh109, Lloh110, Lloh111
	.loh AdrpLdrGotLdr	Lloh112, Lloh113, Lloh114
	.loh AdrpAdd	Lloh121, Lloh122
	.loh AdrpLdrGotLdr	Lloh118, Lloh119, Lloh120
	.loh AdrpLdrGotLdr	Lloh115, Lloh116, Lloh117
	.cfi_endproc
                                        ; -- End function
	.comm	_progress,8,3                   ; @progress
	.comm	_use_log,8,3                    ; @use_log
	.comm	_MAXPGPATH,4,2                  ; @MAXPGPATH
	.comm	_logfile_prefix,8,3             ; @logfile_prefix
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pgbench_log"

l_.str.1:                               ; @.str.1
	.asciz	"%s.%d"

	.comm	_main_pid,4,2                   ; @main_pid
l_.str.2:                               ; @.str.2
	.asciz	"%s.%d.%d"

l_.str.3:                               ; @.str.3
	.asciz	"w"

	.comm	_stderr,4,2                     ; @stderr
l_.str.4:                               ; @.str.4
	.asciz	"could not open logfile \"%s\": %s\n"

	.comm	_errno,8,3                      ; @errno
	.comm	_is_connect,4,2                 ; @is_connect
	.comm	_CSTATE_CHOOSE_SCRIPT,8,3       ; @CSTATE_CHOOSE_SCRIPT
	.comm	_PG_INT64_MAX,4,2               ; @PG_INT64_MAX
	.comm	_CSTATE_SLEEP,8,3               ; @CSTATE_SLEEP
	.comm	_CSTATE_THROTTLE,8,3            ; @CSTATE_THROTTLE
	.comm	_CSTATE_WAIT_RESULT,8,3         ; @CSTATE_WAIT_RESULT
l_.str.5:                               ; @.str.5
	.asciz	"invalid socket: %s"

	.comm	_CSTATE_ABORTED,8,3             ; @CSTATE_ABORTED
	.comm	_CSTATE_FINISHED,8,3            ; @CSTATE_FINISHED
	.comm	_EINTR,8,3                      ; @EINTR
l_.str.6:                               ; @.str.6
	.asciz	"%s() failed: %s\n"

	.comm	_SOCKET_WAIT_METHOD,8,3         ; @SOCKET_WAIT_METHOD
	.comm	_agg_interval,8,3               ; @agg_interval
	.no_dead_strip	_threadRun
.subsections_via_symbols
