	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function execute_foreign_modify
_execute_foreign_modify:                ## @execute_foreign_modify
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %r15
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %rbx
	movq	_CMD_INSERT@GOTPCREL(%rip), %rax
	cmpq	%rdx, (%rax)
	sete	%al
	movq	_CMD_UPDATE@GOTPCREL(%rip), %r13
	cmpq	%rdx, (%r13)
	sete	%cl
	orb	%al, %cl
	movq	_CMD_DELETE@GOTPCREL(%rip), %r14
	cmpq	%rdx, (%r14)
	movq	(%rsi), %r12
	sete	%al
	orb	%cl, %al
	movzbl	%al, %edi
	callq	_Assert
	cmpl	$0, 28(%r12)
	je	LBB0_1
## %bb.2:
	cmpq	%rbx, (%r13)
	jne	LBB0_3
	jmp	LBB0_5
LBB0_1:
	movq	%r12, %rdi
	callq	_prepare_foreign_modify
	cmpq	%rbx, (%r13)
	je	LBB0_5
LBB0_3:
	cmpq	%rbx, (%r14)
	je	LBB0_5
## %bb.4:
	xorl	%esi, %esi
	jmp	LBB0_8
LBB0_5:
	movl	32(%r12), %esi
	leaq	-44(%rbp), %rdx
	movq	%r15, %rdi
	callq	_ExecGetJunkAttribute
	movl	%eax, %ebx
	cmpl	$0, -44(%rbp)
	je	LBB0_7
## %bb.6:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_elog
LBB0_7:
	movl	%ebx, %edi
	callq	_DatumGetPointer
	movq	%rax, %rsi
LBB0_8:
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r12, %rdi
	movq	%r14, %rdx
	callq	_convert_prep_stmt_params
	movl	28(%r12), %esi
	movl	20(%r12), %edi
	movl	24(%r12), %edx
	movl	$0, (%rsp)
	movq	%rax, %rcx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_PQsendQueryPrepared
	testl	%eax, %eax
	jne	LBB0_10
## %bb.9:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	16(%r12), %r8d
	movl	20(%r12), %edx
	xorl	%esi, %esi
	xorl	%ecx, %ecx
	callq	_pgfdw_report_error
LBB0_10:
	movl	16(%r12), %esi
	movl	20(%r12), %edi
	callq	_pgfdw_get_result
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_PQresultStatus
	movq	8(%r12), %rcx
	testq	%rcx, %rcx
	jne	LBB0_11
## %bb.12:
	movq	_PGRES_COMMAND_OK@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	jne	LBB0_14
	jmp	LBB0_15
LBB0_11:
	movq	_PGRES_TUPLES_OK@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_15
LBB0_14:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	16(%r12), %r8d
	movl	20(%r12), %edx
	movq	%r15, %rsi
	movl	$1, %ecx
	callq	_pgfdw_report_error
	movq	8(%r12), %rcx
LBB0_15:
	movq	%r15, %rdi
	testq	%rcx, %rcx
	je	LBB0_18
## %bb.16:
	callq	_PQntuples
	movl	%eax, %ebx
	testl	%eax, %eax
	jle	LBB0_19
## %bb.17:
	movq	%r12, %rdi
	movq	%r14, %rsi
	movq	%r15, %rdx
	callq	_store_returning_result
	jmp	LBB0_19
LBB0_18:
	callq	_PQcmdTuples
	movl	%eax, %edi
	callq	_atoi
	movl	%eax, %ebx
LBB0_19:
	movq	%r15, %rdi
	callq	_PQclear
	movl	(%r12), %edi
	callq	_MemoryContextReset
	xorl	%eax, %eax
	testl	%ebx, %ebx
	cmovgq	%r14, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CMD_INSERT,8,3                 ## @CMD_INSERT
	.comm	_CMD_UPDATE,8,3                 ## @CMD_UPDATE
	.comm	_CMD_DELETE,8,3                 ## @CMD_DELETE
	.comm	_ERROR,4,2                      ## @ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ctid is NULL"

	.comm	_PGRES_TUPLES_OK,8,3            ## @PGRES_TUPLES_OK
	.comm	_PGRES_COMMAND_OK,8,3           ## @PGRES_COMMAND_OK
	.no_dead_strip	_execute_foreign_modify
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function execute_foreign_modify
_execute_foreign_modify:                ; @execute_foreign_modify
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x21, x4
	mov	x19, x3
	mov	x22, x2
Lloh0:
	adrp	x8, _CMD_INSERT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CMD_INSERT@GOTPAGEOFF]
	ldr	x20, [x1]
Lloh2:
	ldr	x8, [x8]
	cmp	x8, x2
Lloh3:
	adrp	x23, _CMD_UPDATE@GOTPAGE
Lloh4:
	ldr	x23, [x23, _CMD_UPDATE@GOTPAGEOFF]
	ldr	x8, [x23]
	ccmp	x8, x2, #4, ne
Lloh5:
	adrp	x24, _CMD_DELETE@GOTPAGE
Lloh6:
	ldr	x24, [x24, _CMD_DELETE@GOTPAGEOFF]
	ldr	x8, [x24]
	ccmp	x8, x2, #4, ne
	cset	w0, eq
	bl	_Assert
	ldr	w8, [x20, #28]
	cbnz	w8, LBB0_2
; %bb.1:
	mov	x0, x20
	bl	_prepare_foreign_modify
LBB0_2:
	ldr	x8, [x23]
	ldr	x9, [x24]
	cmp	x8, x22
	ccmp	x9, x22, #4, ne
	b.ne	LBB0_6
; %bb.3:
	ldr	w1, [x20, #32]
	add	x2, sp, #12
	mov	x0, x21
	bl	_ExecGetJunkAttribute
	mov	x21, x0
	ldr	w8, [sp, #12]
	cbz	w8, LBB0_5
; %bb.4:
Lloh7:
	adrp	x8, _ERROR@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
Lloh10:
	adrp	x1, l_.str@PAGE
Lloh11:
	add	x1, x1, l_.str@PAGEOFF
	bl	_elog
LBB0_5:
	mov	x0, x21
	bl	_DatumGetPointer
	mov	x1, x0
	b	LBB0_7
LBB0_6:
	mov	x1, #0
LBB0_7:
	mov	x0, x20
	mov	x2, x19
	bl	_convert_prep_stmt_params
	mov	x3, x0
	ldp	w2, w1, [x20, #24]
	ldr	w0, [x20, #20]
	mov	x4, #0
	mov	x5, #0
	mov	w6, #0
	bl	_PQsendQueryPrepared
	cbnz	w0, LBB0_9
; %bb.8:
Lloh12:
	adrp	x8, _ERROR@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	ldp	w4, w2, [x20, #16]
	mov	x1, #0
	mov	w3, #0
	bl	_pgfdw_report_error
LBB0_9:
	ldp	w1, w0, [x20, #16]
	bl	_pgfdw_get_result
	mov	x21, x0
	bl	_PQresultStatus
	ldr	x8, [x20, #8]
Lloh15:
	adrp	x9, _PGRES_TUPLES_OK@GOTPAGE
Lloh16:
	ldr	x9, [x9, _PGRES_TUPLES_OK@GOTPAGEOFF]
Lloh17:
	adrp	x10, _PGRES_COMMAND_OK@GOTPAGE
Lloh18:
	ldr	x10, [x10, _PGRES_COMMAND_OK@GOTPAGEOFF]
	cmp	x8, #0
	csel	x9, x10, x9, eq
	ldr	x9, [x9]
	cmp	x0, x9
	b.eq	LBB0_11
; %bb.10:
Lloh19:
	adrp	x8, _ERROR@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
	ldp	w4, w2, [x20, #16]
	mov	x1, x21
	mov	w3, #1
	bl	_pgfdw_report_error
	ldr	x8, [x20, #8]
LBB0_11:
	mov	x0, x21
	cbz	x8, LBB0_14
; %bb.12:
	bl	_PQntuples
	mov	x22, x0
	cmp	w0, #1
	b.lt	LBB0_15
; %bb.13:
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_store_returning_result
	b	LBB0_15
LBB0_14:
	bl	_PQcmdTuples
	bl	_atoi
	mov	x22, x0
LBB0_15:
	mov	x0, x21
	bl	_PQclear
	ldr	w0, [x20]
	bl	_MemoryContextReset
	cmp	w22, #0
	csel	x0, x19, xzr, gt
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_CMD_INSERT,8,3                 ; @CMD_INSERT
	.comm	_CMD_UPDATE,8,3                 ; @CMD_UPDATE
	.comm	_CMD_DELETE,8,3                 ; @CMD_DELETE
	.comm	_ERROR,4,2                      ; @ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ctid is NULL"

	.comm	_PGRES_TUPLES_OK,8,3            ; @PGRES_TUPLES_OK
	.comm	_PGRES_COMMAND_OK,8,3           ; @PGRES_COMMAND_OK
	.no_dead_strip	_execute_foreign_modify
.subsections_via_symbols
