	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_PerformPortalClose             ## -- Begin function PerformPortalClose
	.p2align	4, 0x90
_PerformPortalClose:                    ## @PerformPortalClose
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	testq	%rdi, %rdi
	je	LBB0_5
## %bb.1:
	movq	%rdi, %r14
	cmpb	$0, (%rdi)
	jne	LBB0_3
## %bb.2:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_INVALID_CURSOR_NAME@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_3:
	movq	%r14, %rdi
	callq	_GetPortalByName
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_PortalIsValid
	testl	%eax, %eax
	je	LBB0_6
## %bb.4:
	movl	%ebx, %edi
	xorl	%esi, %esi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_PortalDrop                     ## TAILCALL
LBB0_5:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_PortalHashTableDeleteAll       ## TAILCALL
LBB0_6:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_UNDEFINED_CURSOR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str.1(%rip), %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_ereport                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ERROR,4,2                      ## @ERROR
	.comm	_ERRCODE_INVALID_CURSOR_NAME,4,2 ## @ERRCODE_INVALID_CURSOR_NAME
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid cursor name: must not be empty"

	.comm	_ERRCODE_UNDEFINED_CURSOR,4,2   ## @ERRCODE_UNDEFINED_CURSOR
L_.str.1:                               ## @.str.1
	.asciz	"cursor \"%s\" does not exist"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_PerformPortalClose             ; -- Begin function PerformPortalClose
	.p2align	2
_PerformPortalClose:                    ; @PerformPortalClose
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	cbz	x0, LBB0_5
; %bb.1:
	mov	x19, x0
	ldrb	w8, [x0]
	cbnz	w8, LBB0_3
; %bb.2:
Lloh0:
	adrp	x8, _ERROR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
Lloh3:
	adrp	x8, _ERRCODE_INVALID_CURSOR_NAME@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ERRCODE_INVALID_CURSOR_NAME@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_errcode
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_errmsg
	mov	x1, x0
	mov	x0, x20
	bl	_ereport
LBB0_3:
	mov	x0, x19
	bl	_GetPortalByName
	mov	x20, x0
	bl	_PortalIsValid
	cbz	w0, LBB0_6
; %bb.4:
	mov	x0, x20
	mov	w1, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_PortalDrop
LBB0_5:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_PortalHashTableDeleteAll
LBB0_6:
Lloh8:
	adrp	x8, _ERROR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh10:
	ldr	w20, [x8]
Lloh11:
	adrp	x8, _ERRCODE_UNDEFINED_CURSOR@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ERRCODE_UNDEFINED_CURSOR@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_errcode
	str	x19, [sp]
Lloh14:
	adrp	x0, l_.str.1@PAGE
Lloh15:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_errmsg
	mov	x1, x0
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_ereport
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_ERROR,4,2                      ; @ERROR
	.comm	_ERRCODE_INVALID_CURSOR_NAME,4,2 ; @ERRCODE_INVALID_CURSOR_NAME
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid cursor name: must not be empty"

	.comm	_ERRCODE_UNDEFINED_CURSOR,4,2   ; @ERRCODE_UNDEFINED_CURSOR
l_.str.1:                               ; @.str.1
	.asciz	"cursor \"%s\" does not exist"

.subsections_via_symbols
