	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_heap_drop_with_catalog         ## -- Begin function heap_drop_with_catalog
	.p2align	4, 0x90
_heap_drop_with_catalog:                ## @heap_drop_with_catalog
	.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	%rdi, %r13
	movq	_InvalidOid@GOTPCREL(%rip), %rax
	movq	(%rax), %r14
	movq	_RELOID@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	callq	_ObjectIdGetDatum
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_SearchSysCache1
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_HeapTupleIsValid
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movq	%r13, %rdx
	callq	_elog
LBB0_2:
	movq	%r12, %rdi
	callq	_GETSTRUCT
	cmpq	$0, (%rax)
	movq	%r14, %rbx
	je	LBB0_6
## %bb.3:
	movq	%r13, %rdi
	callq	_get_partition_parent
	movq	%rax, %rbx
	movq	_AccessExclusiveLock@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%rax, %rdi
	callq	_LockRelationOid
	movq	%rbx, %rdi
	callq	_get_default_partition_oid
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_OidIsValid
	cmpq	%r13, %r14
	je	LBB0_6
## %bb.4:
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movl	(%r15), %esi
	movq	%r14, %rdi
	callq	_LockRelationOid
LBB0_6:
	movq	%r12, %rdi
	callq	_ReleaseSysCache
	movq	_AccessExclusiveLock@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_relation_open
	movq	%rax, %r12
	leaq	L_.str.1(%rip), %rsi
	movq	%rax, %rdi
	callq	_CheckTableNotInUse
	movq	%r12, %rdi
	callq	_CheckTableForSerializableConflictIn
	movq	(%r12), %rax
	movq	(%rax), %rax
	movq	_RELKIND_FOREIGN_TABLE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_10
## %bb.7:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	_ForeignTableRelationId@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_RowExclusiveLock@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_table_open
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	_FOREIGNTABLEREL@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r13, %rdi
	callq	_ObjectIdGetDatum
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_SearchSysCache1
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_HeapTupleIsValid
	testl	%eax, %eax
	jne	LBB0_9
## %bb.8:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	movq	%r13, %rdx
	callq	_elog
LBB0_9:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_CatalogTupleDelete
	movq	%r15, %rdi
	callq	_ReleaseSysCache
	movq	_RowExclusiveLock@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_table_close
	movq	(%r12), %rax
	movq	(%rax), %rax
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
LBB0_10:
	movq	_RELKIND_PARTITIONED_TABLE@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	jne	LBB0_12
## %bb.11:
	movq	%r13, %rdi
	callq	_RemovePartitionKeyByRelId
LBB0_12:
	cmpq	%r13, %r14
	jne	LBB0_14
## %bb.13:
	movq	_InvalidOid@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%rbx, %rdi
	callq	_update_default_partition_oid
LBB0_14:
	movq	(%r12), %rax
	movq	(%rax), %rax
	movq	_RELKIND_VIEW@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_19
## %bb.15:
	movq	_RELKIND_COMPOSITE_TYPE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_19
## %bb.16:
	movq	_RELKIND_FOREIGN_TABLE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_19
## %bb.17:
	cmpq	(%r15), %rax
	je	LBB0_19
## %bb.18:
	movq	%r12, %rdi
	callq	_RelationDropStorage
LBB0_19:
	movq	_NoLock@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_relation_close
	movq	_InvalidOid@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	%r13, %rsi
	callq	_RemoveSubscriptionRel
	movq	%r13, %rdi
	callq	_remove_on_commit_action
	movq	%r13, %rdi
	callq	_RelationForgetRelation
	movq	%r13, %rdi
	callq	_RelationRemoveInheritance
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_RemoveStatistics
	movq	%r13, %rdi
	callq	_DeleteAttributeTuples
	movq	%r13, %rdi
	callq	_DeleteRelationTuple
	movq	%rbx, %rdi
	callq	_OidIsValid
	testq	%rax, %rax
	je	LBB0_24
## %bb.20:
	movq	%r14, %rdi
	callq	_OidIsValid
	testq	%rax, %rax
	je	LBB0_23
## %bb.21:
	cmpq	%r13, %r14
	je	LBB0_23
## %bb.22:
	movq	%r14, %rdi
	callq	_CacheInvalidateRelcacheByRelid
LBB0_23:
	movq	%rbx, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_CacheInvalidateRelcacheByRelid ## TAILCALL
LBB0_24:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_InvalidOid,8,3                 ## @InvalidOid
	.comm	_RELOID,4,2                     ## @RELOID
	.comm	_ERROR,4,2                      ## @ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cache lookup failed for relation %u"

	.comm	_AccessExclusiveLock,4,2        ## @AccessExclusiveLock
L_.str.1:                               ## @.str.1
	.asciz	"DROP TABLE"

	.comm	_RELKIND_FOREIGN_TABLE,8,3      ## @RELKIND_FOREIGN_TABLE
	.comm	_ForeignTableRelationId,4,2     ## @ForeignTableRelationId
	.comm	_RowExclusiveLock,4,2           ## @RowExclusiveLock
	.comm	_FOREIGNTABLEREL,4,2            ## @FOREIGNTABLEREL
L_.str.2:                               ## @.str.2
	.asciz	"cache lookup failed for foreign table %u"

	.comm	_RELKIND_PARTITIONED_TABLE,8,3  ## @RELKIND_PARTITIONED_TABLE
	.comm	_RELKIND_VIEW,8,3               ## @RELKIND_VIEW
	.comm	_RELKIND_COMPOSITE_TYPE,8,3     ## @RELKIND_COMPOSITE_TYPE
	.comm	_NoLock,4,2                     ## @NoLock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_heap_drop_with_catalog         ; -- Begin function heap_drop_with_catalog
	.p2align	2
_heap_drop_with_catalog:                ; @heap_drop_with_catalog
	.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
	mov	x19, x0
Lloh0:
	adrp	x25, _InvalidOid@GOTPAGE
Lloh1:
	ldr	x25, [x25, _InvalidOid@GOTPAGEOFF]
	ldr	x20, [x25]
Lloh2:
	adrp	x8, _RELOID@GOTPAGE
Lloh3:
	ldr	x8, [x8, _RELOID@GOTPAGEOFF]
Lloh4:
	ldr	w21, [x8]
	bl	_ObjectIdGetDatum
	mov	x1, x0
	mov	x0, x21
	bl	_SearchSysCache1
	mov	x22, x0
	bl	_HeapTupleIsValid
	cbnz	w0, LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, _ERROR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	bl	_elog
LBB0_2:
	mov	x0, x22
	bl	_GETSTRUCT
	ldr	x8, [x0]
Lloh10:
	adrp	x23, _AccessExclusiveLock@GOTPAGE
Lloh11:
	ldr	x23, [x23, _AccessExclusiveLock@GOTPAGEOFF]
	cbz	x8, LBB0_6
; %bb.3:
	mov	x0, x19
	bl	_get_partition_parent
	mov	x21, x0
	ldr	w1, [x23]
	bl	_LockRelationOid
	mov	x0, x21
	bl	_get_default_partition_oid
	mov	x20, x0
	bl	_OidIsValid
	cmp	x20, x19
	b.eq	LBB0_7
; %bb.4:
	cbz	x0, LBB0_7
; %bb.5:
	ldr	w1, [x23]
	mov	x0, x20
	bl	_LockRelationOid
	b	LBB0_7
LBB0_6:
	mov	x21, x20
LBB0_7:
	mov	x0, x22
	bl	_ReleaseSysCache
	ldr	w1, [x23]
	mov	x0, x19
	bl	_relation_open
	mov	x22, x0
Lloh12:
	adrp	x1, l_.str.1@PAGE
Lloh13:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_CheckTableNotInUse
	mov	x0, x22
	bl	_CheckTableForSerializableConflictIn
	ldr	x8, [x22]
	ldr	x8, [x8]
Lloh14:
	adrp	x26, _RELKIND_FOREIGN_TABLE@GOTPAGE
Lloh15:
	ldr	x26, [x26, _RELKIND_FOREIGN_TABLE@GOTPAGEOFF]
	ldr	x9, [x26]
	cmp	x8, x9
	b.ne	LBB0_11
; %bb.8:
Lloh16:
	adrp	x8, _ForeignTableRelationId@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ForeignTableRelationId@GOTPAGEOFF]
Lloh18:
	ldr	w0, [x8]
Lloh19:
	adrp	x27, _RowExclusiveLock@GOTPAGE
Lloh20:
	ldr	x27, [x27, _RowExclusiveLock@GOTPAGEOFF]
	ldr	w1, [x27]
	bl	_table_open
	mov	x23, x0
Lloh21:
	adrp	x8, _FOREIGNTABLEREL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _FOREIGNTABLEREL@GOTPAGEOFF]
Lloh23:
	ldr	w24, [x8]
	mov	x0, x19
	bl	_ObjectIdGetDatum
	mov	x1, x0
	mov	x0, x24
	bl	_SearchSysCache1
	mov	x24, x0
	bl	_HeapTupleIsValid
	cbnz	w0, LBB0_10
; %bb.9:
Lloh24:
	adrp	x8, _ERROR@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
Lloh27:
	adrp	x1, l_.str.2@PAGE
Lloh28:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x2, x19
	bl	_elog
LBB0_10:
	mov	x0, x23
	mov	x1, x24
	bl	_CatalogTupleDelete
	mov	x0, x24
	bl	_ReleaseSysCache
	ldr	w1, [x27]
	mov	x0, x23
	bl	_table_close
	ldr	x8, [x22]
	ldr	x8, [x8]
LBB0_11:
Lloh29:
	adrp	x23, _RELKIND_PARTITIONED_TABLE@GOTPAGE
Lloh30:
	ldr	x23, [x23, _RELKIND_PARTITIONED_TABLE@GOTPAGEOFF]
	ldr	x9, [x23]
	cmp	x8, x9
	b.ne	LBB0_13
; %bb.12:
	mov	x0, x19
	bl	_RemovePartitionKeyByRelId
LBB0_13:
	cmp	x20, x19
	b.ne	LBB0_15
; %bb.14:
	ldr	x1, [x25]
	mov	x0, x21
	bl	_update_default_partition_oid
LBB0_15:
	ldr	x8, [x22]
	ldr	x8, [x8]
Lloh31:
	adrp	x9, _RELKIND_VIEW@GOTPAGE
Lloh32:
	ldr	x9, [x9, _RELKIND_VIEW@GOTPAGEOFF]
Lloh33:
	ldr	x9, [x9]
Lloh34:
	adrp	x10, _RELKIND_COMPOSITE_TYPE@GOTPAGE
Lloh35:
	ldr	x10, [x10, _RELKIND_COMPOSITE_TYPE@GOTPAGEOFF]
Lloh36:
	ldr	x10, [x10]
	ldr	x11, [x26]
	ldr	x12, [x23]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	ccmp	x8, x11, #4, ne
	ccmp	x8, x12, #4, ne
	b.eq	LBB0_17
; %bb.16:
	mov	x0, x22
	bl	_RelationDropStorage
LBB0_17:
Lloh37:
	adrp	x8, _NoLock@GOTPAGE
Lloh38:
	ldr	x8, [x8, _NoLock@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
	mov	x0, x22
	bl	_relation_close
	ldr	x0, [x25]
	mov	x1, x19
	bl	_RemoveSubscriptionRel
	mov	x0, x19
	bl	_remove_on_commit_action
	mov	x0, x19
	bl	_RelationForgetRelation
	mov	x0, x19
	bl	_RelationRemoveInheritance
	mov	x0, x19
	mov	w1, #0
	bl	_RemoveStatistics
	mov	x0, x19
	bl	_DeleteAttributeTuples
	mov	x0, x19
	bl	_DeleteRelationTuple
	mov	x0, x21
	bl	_OidIsValid
	cbz	x0, LBB0_22
; %bb.18:
	mov	x0, x20
	bl	_OidIsValid
	cbz	x0, LBB0_21
; %bb.19:
	cmp	x20, x19
	b.eq	LBB0_21
; %bb.20:
	mov	x0, x20
	bl	_CacheInvalidateRelcacheByRelid
LBB0_21:
	mov	x0, x21
	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
	b	_CacheInvalidateRelcacheByRelid
LBB0_22:
	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
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_InvalidOid,8,3                 ; @InvalidOid
	.comm	_RELOID,4,2                     ; @RELOID
	.comm	_ERROR,4,2                      ; @ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cache lookup failed for relation %u"

	.comm	_AccessExclusiveLock,4,2        ; @AccessExclusiveLock
l_.str.1:                               ; @.str.1
	.asciz	"DROP TABLE"

	.comm	_RELKIND_FOREIGN_TABLE,8,3      ; @RELKIND_FOREIGN_TABLE
	.comm	_ForeignTableRelationId,4,2     ; @ForeignTableRelationId
	.comm	_RowExclusiveLock,4,2           ; @RowExclusiveLock
	.comm	_FOREIGNTABLEREL,4,2            ; @FOREIGNTABLEREL
l_.str.2:                               ; @.str.2
	.asciz	"cache lookup failed for foreign table %u"

	.comm	_RELKIND_PARTITIONED_TABLE,8,3  ; @RELKIND_PARTITIONED_TABLE
	.comm	_RELKIND_VIEW,8,3               ; @RELKIND_VIEW
	.comm	_RELKIND_COMPOSITE_TYPE,8,3     ; @RELKIND_COMPOSITE_TYPE
	.comm	_NoLock,4,2                     ; @NoLock
.subsections_via_symbols
