	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_inv_open                       ## -- Begin function inv_open
	.p2align	4, 0x90
_inv_open:                              ## @inv_open
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	_INV_WRITE@GOTPCREL(%rip), %r8
	movq	_IFS_WRLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_IFS_RDLOCK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, %esi
	orl	%eax, %esi
	movq	_INV_READ@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r13d
	andl	%r14d, %r13d
	cmovnel	%ecx, %r13d
	testl	%r14d, (%r8)
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%edi, %r15d
	cmovnel	%esi, %r13d
	testl	%r13d, %r13d
	je	LBB0_1
## %bb.2:
	testl	%r13d, %eax
	je	LBB0_4
LBB0_3:
	xorl	%r12d, %r12d
	jmp	LBB0_5
LBB0_1:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	_ERRCODE_INVALID_PARAMETER_VALUE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %esi
	callq	_errmsg
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_ereport
	movq	_IFS_WRLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%r13d, %eax
	jne	LBB0_3
LBB0_4:
	xorl	%eax, %eax
	callq	_GetActiveSnapshot
	movq	%rax, %r12
LBB0_5:
	movl	%r15d, %edi
	movq	%r12, %rsi
	callq	_myLargeObjectExists
	testl	%eax, %eax
	jne	LBB0_7
## %bb.6:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_UNDEFINED_OBJECT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str.1(%rip), %rdi
	movl	%r15d, %esi
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_7:
	movq	_lo_compat_privileges@GOTPCREL(%rip), %rbx
	movq	_IFS_RDLOCK@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_11
## %bb.8:
	cmpl	$0, (%rbx)
	jne	LBB0_11
## %bb.9:
	xorl	%eax, %eax
	callq	_GetUserId
	movq	_ACL_SELECT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%r15d, %edi
	movl	%eax, %esi
	movq	%r12, %rcx
	callq	_pg_largeobject_aclcheck_snapshot
	movq	_ACLCHECK_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_11
## %bb.10:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	_ERRCODE_INSUFFICIENT_PRIVILEGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str.2(%rip), %rdi
	movl	%r15d, %esi
	callq	_errmsg
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_11:
	movq	_IFS_WRLOCK@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_15
## %bb.12:
	cmpl	$0, (%rbx)
	jne	LBB0_15
## %bb.13:
	xorl	%eax, %eax
	callq	_GetUserId
	movq	_ACL_UPDATE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%r15d, %edi
	movl	%eax, %esi
	movq	%r12, %rcx
	callq	_pg_largeobject_aclcheck_snapshot
	movq	_ACLCHECK_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_15
## %bb.14:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_INSUFFICIENT_PRIVILEGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str.2(%rip), %rdi
	movl	%r15d, %esi
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_15:
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movl	$32, %esi
	callq	_MemoryContextAlloc
	movq	%rax, %rbx
	movl	%r15d, (%rax)
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_GetCurrentSubTransactionId
	movl	%eax, 24(%rbx)
	movq	$0, 16(%rbx)
	movl	%r13d, 4(%rbx)
	testq	%r12, %r12
	je	LBB0_17
## %bb.16:
	movq	_TopTransactionResourceOwner@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_RegisterSnapshotOnOwner
	movq	%rax, %r14
LBB0_17:
	movq	%r14, 8(%rbx)
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INV_WRITE,4,2                  ## @INV_WRITE
	.comm	_IFS_WRLOCK,4,2                 ## @IFS_WRLOCK
	.comm	_IFS_RDLOCK,4,2                 ## @IFS_RDLOCK
	.comm	_INV_READ,4,2                   ## @INV_READ
	.comm	_ERROR,4,2                      ## @ERROR
	.comm	_ERRCODE_INVALID_PARAMETER_VALUE,4,2 ## @ERRCODE_INVALID_PARAMETER_VALUE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid flags for opening a large object: %d"

	.comm	_ERRCODE_UNDEFINED_OBJECT,4,2   ## @ERRCODE_UNDEFINED_OBJECT
L_.str.1:                               ## @.str.1
	.asciz	"large object %u does not exist"

	.comm	_lo_compat_privileges,4,2       ## @lo_compat_privileges
	.comm	_ACL_SELECT,4,2                 ## @ACL_SELECT
	.comm	_ACLCHECK_OK,8,3                ## @ACLCHECK_OK
	.comm	_ERRCODE_INSUFFICIENT_PRIVILEGE,4,2 ## @ERRCODE_INSUFFICIENT_PRIVILEGE
L_.str.2:                               ## @.str.2
	.asciz	"permission denied for large object %u"

	.comm	_ACL_UPDATE,4,2                 ## @ACL_UPDATE
	.comm	_TopTransactionResourceOwner,4,2 ## @TopTransactionResourceOwner
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_inv_open                       ; -- Begin function inv_open
	.p2align	2
_inv_open:                              ; @inv_open
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x2
	mov	x19, x0
Lloh0:
	adrp	x8, _INV_WRITE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _INV_WRITE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x8]
Lloh3:
	adrp	x24, _IFS_WRLOCK@GOTPAGE
Lloh4:
	ldr	x24, [x24, _IFS_WRLOCK@GOTPAGEOFF]
	ldr	w8, [x24]
Lloh5:
	adrp	x25, _IFS_RDLOCK@GOTPAGE
Lloh6:
	ldr	x25, [x25, _IFS_RDLOCK@GOTPAGEOFF]
	ldr	w10, [x25]
Lloh7:
	adrp	x11, _INV_READ@GOTPAGE
Lloh8:
	ldr	x11, [x11, _INV_READ@GOTPAGEOFF]
	orr	w12, w10, w8
Lloh9:
	ldr	w11, [x11]
	tst	w11, w1
	csel	w10, wzr, w10, eq
	tst	w9, w1
	csel	w23, w10, w12, eq
	cbz	w23, LBB0_3
; %bb.1:
	tst	w8, w23
	b.eq	LBB0_4
LBB0_2:
	mov	x21, #0
	b	LBB0_5
LBB0_3:
	mov	x21, x1
Lloh10:
	adrp	x8, _ERROR@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh12:
	ldr	w22, [x8]
Lloh13:
	adrp	x8, _ERRCODE_INVALID_PARAMETER_VALUE@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ERRCODE_INVALID_PARAMETER_VALUE@GOTPAGEOFF]
Lloh15:
	ldr	w0, [x8]
	bl	_errcode
Lloh16:
	adrp	x0, l_.str@PAGE
Lloh17:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	bl	_errmsg
	mov	x1, x0
	mov	x0, x22
	bl	_ereport
	ldr	w8, [x24]
	tst	w8, w23
	b.ne	LBB0_2
LBB0_4:
	bl	_GetActiveSnapshot
	mov	x21, x0
LBB0_5:
	mov	x0, x19
	mov	x1, x21
	bl	_myLargeObjectExists
	cbnz	w0, LBB0_7
; %bb.6:
Lloh18:
	adrp	x8, _ERROR@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh20:
	ldr	w22, [x8]
Lloh21:
	adrp	x8, _ERRCODE_UNDEFINED_OBJECT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ERRCODE_UNDEFINED_OBJECT@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	bl	_errcode
Lloh24:
	adrp	x0, l_.str.1@PAGE
Lloh25:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x19
	bl	_errmsg
	mov	x1, x0
	mov	x0, x22
	bl	_ereport
LBB0_7:
	ldr	w8, [x25]
Lloh26:
	adrp	x26, _lo_compat_privileges@GOTPAGE
Lloh27:
	ldr	x26, [x26, _lo_compat_privileges@GOTPAGEOFF]
	and	w8, w8, w23
	ldr	w9, [x26]
	cmp	w8, #0
	ccmp	w9, #0, #0, ne
Lloh28:
	adrp	x25, _ACLCHECK_OK@GOTPAGE
Lloh29:
	ldr	x25, [x25, _ACLCHECK_OK@GOTPAGEOFF]
	b.ne	LBB0_10
; %bb.8:
	bl	_GetUserId
	mov	x1, x0
Lloh30:
	adrp	x8, _ACL_SELECT@GOTPAGE
Lloh31:
	ldr	x8, [x8, _ACL_SELECT@GOTPAGEOFF]
Lloh32:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x3, x21
	bl	_pg_largeobject_aclcheck_snapshot
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_10
; %bb.9:
Lloh33:
	adrp	x8, _ERROR@GOTPAGE
Lloh34:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh35:
	ldr	w22, [x8]
Lloh36:
	adrp	x8, _ERRCODE_INSUFFICIENT_PRIVILEGE@GOTPAGE
Lloh37:
	ldr	x8, [x8, _ERRCODE_INSUFFICIENT_PRIVILEGE@GOTPAGEOFF]
Lloh38:
	ldr	w0, [x8]
	bl	_errcode
Lloh39:
	adrp	x0, l_.str.2@PAGE
Lloh40:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x19
	bl	_errmsg
	mov	x1, x0
	mov	x0, x22
	bl	_ereport
LBB0_10:
	ldr	w8, [x24]
	and	w8, w8, w23
	ldr	w9, [x26]
	cmp	w8, #0
	ccmp	w9, #0, #0, ne
	b.ne	LBB0_13
; %bb.11:
	bl	_GetUserId
	mov	x1, x0
Lloh41:
	adrp	x8, _ACL_UPDATE@GOTPAGE
Lloh42:
	ldr	x8, [x8, _ACL_UPDATE@GOTPAGEOFF]
Lloh43:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x3, x21
	bl	_pg_largeobject_aclcheck_snapshot
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_13
; %bb.12:
Lloh44:
	adrp	x8, _ERROR@GOTPAGE
Lloh45:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh46:
	ldr	w22, [x8]
Lloh47:
	adrp	x8, _ERRCODE_INSUFFICIENT_PRIVILEGE@GOTPAGE
Lloh48:
	ldr	x8, [x8, _ERRCODE_INSUFFICIENT_PRIVILEGE@GOTPAGEOFF]
Lloh49:
	ldr	w0, [x8]
	bl	_errcode
Lloh50:
	adrp	x0, l_.str.2@PAGE
Lloh51:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x19
	bl	_errmsg
	mov	x1, x0
	mov	x0, x22
	bl	_ereport
LBB0_13:
	mov	x0, x20
	mov	w1, #32
	bl	_MemoryContextAlloc
	mov	x20, x0
	str	w19, [x0]
	bl	_GetCurrentSubTransactionId
	str	w0, [x20, #24]
	str	xzr, [x20, #16]
	str	w23, [x20, #4]
	cbz	x21, LBB0_15
; %bb.14:
Lloh52:
	adrp	x8, _TopTransactionResourceOwner@GOTPAGE
Lloh53:
	ldr	x8, [x8, _TopTransactionResourceOwner@GOTPAGEOFF]
Lloh54:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_RegisterSnapshotOnOwner
	b	LBB0_16
LBB0_15:
	mov	x0, #0
LBB0_16:
	str	x0, [x20, #8]
	mov	x0, x20
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.cfi_endproc
                                        ; -- End function
	.comm	_INV_WRITE,4,2                  ; @INV_WRITE
	.comm	_IFS_WRLOCK,4,2                 ; @IFS_WRLOCK
	.comm	_IFS_RDLOCK,4,2                 ; @IFS_RDLOCK
	.comm	_INV_READ,4,2                   ; @INV_READ
	.comm	_ERROR,4,2                      ; @ERROR
	.comm	_ERRCODE_INVALID_PARAMETER_VALUE,4,2 ; @ERRCODE_INVALID_PARAMETER_VALUE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid flags for opening a large object: %d"

	.comm	_ERRCODE_UNDEFINED_OBJECT,4,2   ; @ERRCODE_UNDEFINED_OBJECT
l_.str.1:                               ; @.str.1
	.asciz	"large object %u does not exist"

	.comm	_lo_compat_privileges,4,2       ; @lo_compat_privileges
	.comm	_ACL_SELECT,4,2                 ; @ACL_SELECT
	.comm	_ACLCHECK_OK,8,3                ; @ACLCHECK_OK
	.comm	_ERRCODE_INSUFFICIENT_PRIVILEGE,4,2 ; @ERRCODE_INSUFFICIENT_PRIVILEGE
l_.str.2:                               ; @.str.2
	.asciz	"permission denied for large object %u"

	.comm	_ACL_UPDATE,4,2                 ; @ACL_UPDATE
	.comm	_TopTransactionResourceOwner,4,2 ; @TopTransactionResourceOwner
.subsections_via_symbols
