	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ProcessResult
_ProcessResult:                         ## @ProcessResult
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %rdi
	callq	_AcceptResult
	testl	%eax, %eax
	je	LBB0_30
## %bb.1:
	movl	$1, -44(%rbp)                   ## 4-byte Folded Spill
	movq	_pset@GOTPCREL(%rip), %r13
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r14), %rdi
	callq	_PQresultStatus
	movl	%eax, %r12d
	leal	-128(%r12), %eax
	cmpl	$4, %eax
	ja	LBB0_14
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$19, %ecx
	btl	%eax, %ecx
	jae	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	testb	$1, %r15b
	jne	LBB0_25
	jmp	LBB0_31
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	xorl	%eax, %eax
	callq	_SetCancelConn
	cmpl	$130, %r12d
	jne	LBB0_15
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$0, -60(%rbp)
	movq	%r13, %rbx
	movq	16(%r13), %rax
	testq	%rax, %rax
	je	LBB0_18
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, -56(%rbp)
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movb	$1, %al
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	(%rbx), %edi
	movq	-56(%rbp), %rsi
	leaq	-72(%rbp), %rdx
	callq	_handleCopyOut
	testq	%rax, %rax
	movq	%rbx, %rcx
	setne	%bl
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	setne	%r12b
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	setne	%dl
	cmpq	24(%rcx), %rax
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	-72(%rbp), %rdi
	movb	%dl, -44(%rbp)                  ## 1-byte Spill
	callq	_PQclear
	movzbl	-44(%rbp), %edx                 ## 1-byte Folded Reload
	movq	$0, -72(%rbp)
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	andb	%dl, %r12b
	cmpb	$0, -48(%rbp)                   ## 1-byte Folded Reload
	jne	LBB0_23
## %bb.12:                              ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$0, -60(%rbp)
	movq	-56(%rbp), %rdi
	je	LBB0_22
## %bb.13:                              ##   in Loop: Header=BB0_2 Depth=1
	callq	_pclose
	xorl	%eax, %eax
	callq	_restore_sigpipe_trap
	jmp	LBB0_23
LBB0_14:                                ##   in Loop: Header=BB0_2 Depth=1
	leaq	L_.str(%rip), %rdi
	movl	%r12d, %esi
	callq	_pg_log_error
	testb	$1, %r15b
	jne	LBB0_25
	jmp	LBB0_31
LBB0_15:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rax
	movq	16(%r13), %rbx
	testq	%rbx, %rbx
	jne	LBB0_17
## %bb.16:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rax), %rbx
LBB0_17:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	%rbx, -56(%rbp)
	movl	(%rax), %r12d
	movq	(%r14), %rdi
	callq	_PQbinaryTuples
	movl	%r12d, %edi
	movq	%rbx, %rsi
	movl	%eax, %edx
	leaq	-72(%rbp), %rcx
	callq	_handleCopyIn
	testq	%rax, %rax
	setne	%al
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	setne	%bl
	andb	%al, %bl
	jmp	LBB0_24
LBB0_18:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	32(%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_27
## %bb.19:                              ##   in Loop: Header=BB0_2 Depth=1
	leaq	-56(%rbp), %rsi
	leaq	-60(%rbp), %rdx
	callq	_openQueryOutputFile
	testq	%rax, %rax
	je	LBB0_28
## %bb.20:                              ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$0, -60(%rbp)
	je	LBB0_29
## %bb.21:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	$0, -48(%rbp)                   ## 4-byte Folded Spill
	xorl	%eax, %eax
	callq	_disable_sigpipe_trap
	jmp	LBB0_9
LBB0_22:                                ##   in Loop: Header=BB0_2 Depth=1
	callq	_fclose
LBB0_23:                                ##   in Loop: Header=BB0_2 Depth=1
	andb	%r12b, %bl
LBB0_24:                                ##   in Loop: Header=BB0_2 Depth=1
	movzbl	%bl, %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	xorl	%eax, %eax
	callq	_ResetCancelConn
	movq	(%r14), %rdi
	callq	_PQclear
	movq	-72(%rbp), %rax
	movq	%rax, (%r14)
LBB0_25:                                ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r13), %edi
	callq	_PQgetResult
	movq	(%r14), %rdi
	testq	%rax, %rax
	je	LBB0_32
## %bb.26:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %rbx
	callq	_PQclear
	movq	%rbx, (%r14)
	movq	%rbx, %rdi
	callq	_AcceptResult
	movb	$1, %r15b
	testl	%eax, %eax
	jne	LBB0_2
	jmp	LBB0_33
LBB0_27:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	24(%rbx), %rax
	jmp	LBB0_7
LBB0_28:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	$0, -56(%rbp)
	jmp	LBB0_8
LBB0_29:                                ##   in Loop: Header=BB0_2 Depth=1
	movl	$0, -48(%rbp)                   ## 4-byte Folded Spill
	jmp	LBB0_9
LBB0_30:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
LBB0_31:
	movq	(%r14), %rdi
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	movl	%r14d, %esi
	callq	_SetResultVariables
	jmp	LBB0_35
LBB0_32:
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	movl	%r14d, %esi
	callq	_SetResultVariables
	testb	$1, %r15b
	je	LBB0_35
	jmp	LBB0_34
LBB0_33:
	movq	(%r14), %rdi
	xorl	%r14d, %r14d
	xorl	%esi, %esi
	callq	_SetResultVariables
LBB0_34:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_CheckConnection
	testl	%eax, %eax
	je	LBB0_36
LBB0_35:
	movl	%r14d, %ebx
LBB0_36:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unexpected PQresultStatus: %d"

	.comm	_pset,40,3                      ## @pset
	.no_dead_strip	_ProcessResult
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ProcessResult
_ProcessResult:                         ; @ProcessResult
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	ldr	x0, [x0]
	bl	_AcceptResult
	cbz	w0, LBB0_27
; %bb.1:
	mov	w25, #0
	mov	w24, #1
Lloh0:
	adrp	x26, _pset@GOTPAGE
Lloh1:
	ldr	x26, [x26, _pset@GOTPAGEOFF]
	mov	w27, #19
	mov	w19, #1
Lloh2:
	adrp	x21, l_.str@PAGE
Lloh3:
	add	x21, x21, l_.str@PAGEOFF
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x20]
	bl	_PQresultStatus
	mov	x22, x0
	sub	w8, w0, #128
	cmp	w8, #4
	b.hi	LBB0_11
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	lsl	w8, w24, w8
	tst	w8, w27
	b.eq	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	tbnz	w25, #0, LBB0_22
	b	LBB0_28
LBB0_5:                                 ;   in Loop: Header=BB0_2 Depth=1
	bl	_SetCancelConn
	cmp	w22, #130
	b.ne	LBB0_12
; %bb.6:                                ;   in Loop: Header=BB0_2 Depth=1
	str	wzr, [sp, #12]
	ldr	x8, [x26, #16]
	cbz	x8, LBB0_13
LBB0_7:                                 ;   in Loop: Header=BB0_2 Depth=1
	str	x8, [sp, #24]
LBB0_8:                                 ;   in Loop: Header=BB0_2 Depth=1
	mov	w22, #1
LBB0_9:                                 ;   in Loop: Header=BB0_2 Depth=1
	ldr	w0, [x26]
	ldr	x1, [sp, #24]
	add	x2, sp, #16
	bl	_handleCopyOut
	cmp	x0, #0
	ccmp	w19, #0, #4, ne
	ldr	x8, [sp, #24]
	ccmp	x8, #0, #4, ne
	cset	w19, ne
	ldr	x9, [x26, #24]
	cmp	x8, x9
	b.eq	LBB0_17
; %bb.10:                               ;   in Loop: Header=BB0_2 Depth=1
	tbz	w22, #0, LBB0_18
	b	LBB0_21
LBB0_11:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x21
	mov	x1, x22
	bl	_pg_log_error
	tbnz	w25, #0, LBB0_22
	b	LBB0_28
LBB0_12:                                ;   in Loop: Header=BB0_2 Depth=1
	ldp	x9, x8, [x26, #8]
	cmp	x8, #0
	csel	x22, x9, x8, eq
	str	x22, [sp, #24]
	ldr	w23, [x26]
	ldr	x0, [x20]
	bl	_PQbinaryTuples
	mov	x2, x0
	add	x3, sp, #16
	mov	x0, x23
	mov	x1, x22
	bl	_handleCopyIn
	cmp	x0, #0
	ccmp	w19, #0, #4, ne
	cset	w19, ne
	b	LBB0_21
LBB0_13:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x0, [x26, #32]
	cbz	x0, LBB0_24
; %bb.14:                               ;   in Loop: Header=BB0_2 Depth=1
	add	x1, sp, #24
	add	x2, sp, #12
	bl	_openQueryOutputFile
	cbz	x0, LBB0_25
; %bb.15:                               ;   in Loop: Header=BB0_2 Depth=1
	ldr	w8, [sp, #12]
	cbz	w8, LBB0_26
; %bb.16:                               ;   in Loop: Header=BB0_2 Depth=1
	bl	_disable_sigpipe_trap
	mov	w22, #0
	b	LBB0_9
LBB0_17:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x0, [sp, #16]
	bl	_PQclear
	str	xzr, [sp, #16]
	tbnz	w22, #0, LBB0_21
LBB0_18:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w8, [sp, #12]
	ldr	x0, [sp, #24]
	cbz	w8, LBB0_20
; %bb.19:                               ;   in Loop: Header=BB0_2 Depth=1
	bl	_pclose
	bl	_restore_sigpipe_trap
	b	LBB0_21
LBB0_20:                                ;   in Loop: Header=BB0_2 Depth=1
	bl	_fclose
LBB0_21:                                ;   in Loop: Header=BB0_2 Depth=1
	bl	_ResetCancelConn
	ldr	x0, [x20]
	bl	_PQclear
	ldr	x8, [sp, #16]
	str	x8, [x20]
LBB0_22:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w0, [x26]
	bl	_PQgetResult
	mov	x22, x0
	ldr	x0, [x20]
	cbz	x22, LBB0_29
; %bb.23:                               ;   in Loop: Header=BB0_2 Depth=1
	bl	_PQclear
	str	x22, [x20]
	mov	x0, x22
	bl	_AcceptResult
	mov	w25, #1
	cbnz	w0, LBB0_2
	b	LBB0_32
LBB0_24:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x8, [x26, #24]
	b	LBB0_7
LBB0_25:                                ;   in Loop: Header=BB0_2 Depth=1
	str	xzr, [sp, #24]
	b	LBB0_8
LBB0_26:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w22, #0
	b	LBB0_9
LBB0_27:
	mov	w19, #0
LBB0_28:
	ldr	x0, [x20]
	mov	x1, x19
	bl	_SetResultVariables
	b	LBB0_31
LBB0_29:
	mov	x1, x19
	bl	_SetResultVariables
	tbz	w25, #0, LBB0_31
; %bb.30:
	bl	_CheckConnection
	cbz	w0, LBB0_33
LBB0_31:
	mov	x0, x19
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_32:
	ldr	x0, [x20]
	mov	w1, #0
	bl	_SetResultVariables
	mov	w19, #0
	bl	_CheckConnection
	cbnz	w0, LBB0_31
LBB0_33:
	mov	w19, #0
	b	LBB0_31
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unexpected PQresultStatus: %d"

	.comm	_pset,40,3                      ; @pset
	.no_dead_strip	_ProcessResult
.subsections_via_symbols
