	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pqsecure_open_gss              ## -- Begin function pqsecure_open_gss
	.p2align	4, 0x90
_pqsecure_open_gss:                     ## @pqsecure_open_gss
	.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	$120, %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	_GSS_C_EMPTY_BUFFER@GOTPCREL(%rip), %rax
	movups	(%rax), %xmm0
	movaps	%xmm0, -96(%rbp)
	movaps	%xmm0, -80(%rbp)
	cmpb	$0, _pqsecure_open_gss.first(%rip)
	je	LBB0_7
## %bb.1:
	movq	_PqGSSSendPointer@GOTPCREL(%rip), %r15
	movq	(%r15), %rbx
	testq	%rbx, %rbx
	je	LBB0_6
## %bb.2:
	movq	_PqGSSSendStart@GOTPCREL(%rip), %r12
	movq	(%r12), %rsi
	subq	%rsi, %rbx
	movq	_PqGSSSendBuffer@GOTPCREL(%rip), %rax
	addq	(%rax), %rsi
	movq	%r14, %rdi
	movq	%rbx, %rdx
	callq	_pqsecure_raw_write
	movq	%rax, -56(%rbp)
	testq	%rax, %rax
	jns	LBB0_4
## %bb.3:
	movq	_errno@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	_EWOULDBLOCK@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_17
LBB0_4:
	cmpq	%rbx, %rax
	jne	LBB0_16
## %bb.5:
	movq	$0, (%r12)
	movq	$0, (%r15)
LBB0_6:
	cmpl	$0, 8(%r14)
	jne	LBB0_8
	jmp	LBB0_22
LBB0_7:
	movq	_PqGSSResultLength@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
	movq	_PqGSSResultPointer@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
	movq	_PqGSSRecvLength@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
	movq	_PqGSSRecvPointer@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	_PqGSSSendStart@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	_PqGSSSendPointer@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movb	$1, _pqsecure_open_gss.first(%rip)
	cmpl	$0, 8(%r14)
	je	LBB0_22
LBB0_8:
	movq	_PqGSSRecvLength@GOTPCREL(%rip), %r13
	movl	(%r13), %ebx
	cmpq	$3, %rbx
	ja	LBB0_11
## %bb.9:
	movq	_PqGSSRecvBuffer@GOTPCREL(%rip), %rax
	movq	%rbx, %rsi
	addq	(%rax), %rsi
	movl	$4, %edx
	subl	%ebx, %edx
	leaq	-56(%rbp), %rcx
	movq	%r14, %rdi
	callq	_gss_read
	movq	_PGRES_POLLING_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_28
## %bb.10:
	movl	(%r13), %ebx
	addl	-56(%rbp), %ebx
	movl	%ebx, (%r13)
	cmpl	$3, %ebx
	jbe	LBB0_20
LBB0_11:
	movq	_PqGSSRecvBuffer@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	cmpb	$69, (%r12)
	jne	LBB0_14
## %bb.12:
	movslq	%ebx, %rax
	addq	%rax, %r12
	movq	_PQ_GSS_RECV_BUFFER_SIZE@GOTPCREL(%rip), %rax
	notl	%ebx
	addl	(%rax), %ebx
	leaq	-56(%rbp), %rcx
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_gss_read
	movq	_PGRES_POLLING_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_28
## %bb.13:
	movl	-56(%rbp), %eax
	addl	%eax, (%r13)
	addq	$20, %r14
	movq	_PqGSSRecvBuffer@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	incq	%rdx
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_printfPQExpBuffer
	jmp	LBB0_26
LBB0_14:
	movl	(%r12), %edi
	callq	_ntohl
	movl	%eax, -96(%rbp)
	movslq	%eax, %r15
	movq	_PQ_GSS_RECV_BUFFER_SIZE@GOTPCREL(%rip), %rdx
	movslq	(%rdx), %rcx
	addq	$-4, %rcx
	cmpq	%r15, %rcx
	jae	LBB0_18
## %bb.15:
	addq	$20, %r14
	leaq	L_.str.1(%rip), %rdi
	movq	%rdx, %rbx
	callq	_libpq_gettext
	movslq	%eax, %rsi
	movslq	(%rbx), %rcx
	addq	$-4, %rcx
	movq	%r14, %rdi
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_printfPQExpBuffer
	jmp	LBB0_26
LBB0_16:
	addq	%rbx, (%r12)
LBB0_17:
	movq	_PGRES_POLLING_WRITING@GOTPCREL(%rip), %rax
	jmp	LBB0_27
LBB0_18:
	movslq	%ebx, %rcx
	addq	%rcx, %r12
	subl	%ecx, %eax
	addl	$4, %eax
	leaq	-56(%rbp), %rcx
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_gss_read
	movq	_PGRES_POLLING_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_28
## %bb.19:
	movl	(%r13), %eax
	addl	-56(%rbp), %eax
	movl	%eax, (%r13)
	cltq
	addq	$-4, %rax
	cmpq	%r15, %rax
	jae	LBB0_21
LBB0_20:
	movq	_PGRES_POLLING_READING@GOTPCREL(%rip), %rax
	jmp	LBB0_27
LBB0_21:
	movq	_PqGSSRecvBuffer@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	addq	$4, %rax
	movq	%rax, -88(%rbp)
LBB0_22:
	movq	%r14, %rdi
	callq	_pg_GSS_load_servicename
	movq	%rax, -56(%rbp)
	movq	_STATUS_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_26
## %bb.23:
	leaq	8(%r14), %rdx
	movl	12(%r14), %esi
	movl	16(%r14), %ecx
	movq	_GSS_C_NO_OID@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	_GSS_REQUIRED_FLAGS@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	xorps	%xmm0, %xmm0
	movups	%xmm0, 40(%rsp)
	leaq	-80(%rbp), %rax
	movq	%rax, 32(%rsp)
	leaq	-96(%rbp), %rax
	movq	%rax, 16(%rsp)
	movq	$0, 24(%rsp)
	movl	$0, 8(%rsp)
	movl	$0, (%rsp)
	leaq	-44(%rbp), %rdi
	callq	_gss_init_sec_context
	movl	%eax, %ebx
	movq	_PqGSSRecvLength@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
	movq	_PqGSSRecvPointer@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movl	%ebx, %edi
	callq	_GSS_ERROR
	testq	%rax, %rax
	je	LBB0_29
## %bb.24:
	leaq	L_.str.2(%rip), %rdi
LBB0_25:
	callq	_libpq_gettext
	movl	-44(%rbp), %ecx
	movl	%eax, %edi
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_pg_GSS_error
LBB0_26:
	movq	_PGRES_POLLING_FAILED@GOTPCREL(%rip), %rax
LBB0_27:
	movq	(%rax), %rax
LBB0_28:
	addq	$120, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_29:
	movslq	-80(%rbp), %rdi
	testq	%rdi, %rdi
	je	LBB0_32
## %bb.30:
	movq	_PQ_GSS_SEND_BUFFER_SIZE@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	addq	$-4, %rax
	cmpq	%rdi, %rax
	jae	LBB0_35
## %bb.31:
	leaq	L_.str.4(%rip), %rdi
	jmp	LBB0_25
LBB0_32:
	leaq	12(%r14), %rsi
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_gss_release_cred
	movq	_GSS_C_NO_CREDENTIAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r14)
	movl	$1, 4(%r14)
	movl	8(%r14), %esi
	movq	_GSS_C_QOP_DEFAULT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_PQ_GSS_SEND_BUFFER_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	addl	$-4, %r8d
	movq	_max_packet_size@GOTPCREL(%rip), %r9
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_gss_wrap_size_limit
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_GSS_ERROR
	testq	%rax, %rax
	je	LBB0_34
## %bb.33:
	leaq	L_.str.3(%rip), %rdi
	callq	_libpq_gettext
	movl	-44(%rbp), %ecx
	movl	%eax, %edi
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_pg_GSS_error
LBB0_34:
	movq	_PGRES_POLLING_OK@GOTPCREL(%rip), %rax
	jmp	LBB0_27
LBB0_35:
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_htonl
	movl	%eax, -60(%rbp)
	movq	_PqGSSSendBuffer@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	leaq	-60(%rbp), %rsi
	movl	$4, %edx
	callq	_memcpy
	movq	_PqGSSSendPointer@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	addq	$4, %rdi
	movq	%rdi, (%rbx)
	addq	(%r14), %rdi
	movq	-72(%rbp), %rsi
	movl	-80(%rbp), %edx
	callq	_memcpy
	movslq	-80(%rbp), %rax
	addq	%rax, (%rbx)
	leaq	-44(%rbp), %rdi
	leaq	-80(%rbp), %rsi
	callq	_gss_release_buffer
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_pqsecure_open_gss.first,1,2 ## @pqsecure_open_gss.first
	.comm	_GSS_C_EMPTY_BUFFER,16,3        ## @GSS_C_EMPTY_BUFFER
	.comm	_PqGSSResultLength,4,2          ## @PqGSSResultLength
	.comm	_PqGSSResultPointer,4,2         ## @PqGSSResultPointer
	.comm	_PqGSSRecvLength,4,2            ## @PqGSSRecvLength
	.comm	_PqGSSRecvPointer,8,3           ## @PqGSSRecvPointer
	.comm	_PqGSSSendStart,8,3             ## @PqGSSSendStart
	.comm	_PqGSSSendPointer,8,3           ## @PqGSSSendPointer
	.comm	_PqGSSSendBuffer,8,3            ## @PqGSSSendBuffer
	.comm	_errno,8,3                      ## @errno
	.comm	_EWOULDBLOCK,8,3                ## @EWOULDBLOCK
	.comm	_PGRES_POLLING_WRITING,8,3      ## @PGRES_POLLING_WRITING
	.comm	_PqGSSRecvBuffer,8,3            ## @PqGSSRecvBuffer
	.comm	_PGRES_POLLING_OK,8,3           ## @PGRES_POLLING_OK
	.comm	_PGRES_POLLING_READING,8,3      ## @PGRES_POLLING_READING
	.comm	_PQ_GSS_RECV_BUFFER_SIZE,4,2    ## @PQ_GSS_RECV_BUFFER_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s\n"

	.comm	_PGRES_POLLING_FAILED,8,3       ## @PGRES_POLLING_FAILED
L_.str.1:                               ## @.str.1
	.asciz	"oversize GSSAPI packet sent by the server (%zu > %zu)\n"

	.comm	_STATUS_OK,8,3                  ## @STATUS_OK
	.comm	_GSS_C_NO_OID,4,2               ## @GSS_C_NO_OID
	.comm	_GSS_REQUIRED_FLAGS,4,2         ## @GSS_REQUIRED_FLAGS
L_.str.2:                               ## @.str.2
	.asciz	"could not initiate GSSAPI security context"

	.comm	_GSS_C_NO_CREDENTIAL,4,2        ## @GSS_C_NO_CREDENTIAL
	.comm	_GSS_C_QOP_DEFAULT,4,2          ## @GSS_C_QOP_DEFAULT
	.comm	_PQ_GSS_SEND_BUFFER_SIZE,4,2    ## @PQ_GSS_SEND_BUFFER_SIZE
	.comm	_max_packet_size,4,2            ## @max_packet_size
L_.str.3:                               ## @.str.3
	.asciz	"GSSAPI size check error"

L_.str.4:                               ## @.str.4
	.asciz	"GSSAPI context establishment error"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pqsecure_open_gss              ; -- Begin function pqsecure_open_gss
	.p2align	2
_pqsecure_open_gss:                     ; @pqsecure_open_gss
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #176
	.cfi_def_cfa_offset 176
	stp	x26, x25, [sp, #96]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #112]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #128]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #144]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #160]            ; 16-byte Folded Spill
	add	x29, sp, #160
	.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	x19, x0
Lloh0:
	adrp	x8, _GSS_C_EMPTY_BUFFER@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GSS_C_EMPTY_BUFFER@GOTPAGEOFF]
Lloh2:
	ldr	q0, [x8]
	stp	q0, q0, [sp, #48]
	adrp	x8, _pqsecure_open_gss.first@PAGE
	ldrb	w9, [x8, _pqsecure_open_gss.first@PAGEOFF]
Lloh3:
	adrp	x22, _PqGSSRecvLength@GOTPAGE
Lloh4:
	ldr	x22, [x22, _PqGSSRecvLength@GOTPAGEOFF]
	tbz	w9, #0, LBB0_6
; %bb.1:
Lloh5:
	adrp	x21, _PqGSSSendPointer@GOTPAGE
Lloh6:
	ldr	x21, [x21, _PqGSSSendPointer@GOTPAGEOFF]
	ldr	x8, [x21]
	cbz	x8, LBB0_7
; %bb.2:
Lloh7:
	adrp	x23, _PqGSSSendStart@GOTPAGE
Lloh8:
	ldr	x23, [x23, _PqGSSSendStart@GOTPAGEOFF]
	ldr	x9, [x23]
	sub	x20, x8, x9
Lloh9:
	adrp	x8, _PqGSSSendBuffer@GOTPAGE
Lloh10:
	ldr	x8, [x8, _PqGSSSendBuffer@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	add	x1, x8, x9
	mov	x0, x19
	mov	x2, x20
	bl	_pqsecure_raw_write
	stur	x0, [x29, #-72]
	tbz	x0, #63, LBB0_4
; %bb.3:
Lloh12:
	adrp	x8, _errno@GOTPAGE
Lloh13:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
Lloh15:
	adrp	x9, _EWOULDBLOCK@GOTPAGE
Lloh16:
	ldr	x9, [x9, _EWOULDBLOCK@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_18
LBB0_4:
	cmp	x0, x20
	b.ne	LBB0_17
; %bb.5:
	str	xzr, [x23]
	str	xzr, [x21]
	b	LBB0_7
LBB0_6:
Lloh18:
	adrp	x9, _PqGSSResultLength@GOTPAGE
Lloh19:
	ldr	x9, [x9, _PqGSSResultLength@GOTPAGEOFF]
Lloh20:
	str	wzr, [x9]
Lloh21:
	adrp	x9, _PqGSSResultPointer@GOTPAGE
Lloh22:
	ldr	x9, [x9, _PqGSSResultPointer@GOTPAGEOFF]
Lloh23:
	str	wzr, [x9]
	str	wzr, [x22]
Lloh24:
	adrp	x9, _PqGSSRecvPointer@GOTPAGE
Lloh25:
	ldr	x9, [x9, _PqGSSRecvPointer@GOTPAGEOFF]
Lloh26:
	str	xzr, [x9]
Lloh27:
	adrp	x9, _PqGSSSendStart@GOTPAGE
Lloh28:
	ldr	x9, [x9, _PqGSSSendStart@GOTPAGEOFF]
Lloh29:
	str	xzr, [x9]
Lloh30:
	adrp	x9, _PqGSSSendPointer@GOTPAGE
Lloh31:
	ldr	x9, [x9, _PqGSSSendPointer@GOTPAGEOFF]
Lloh32:
	str	xzr, [x9]
	mov	w9, #1
	strb	w9, [x8, _pqsecure_open_gss.first@PAGEOFF]
LBB0_7:
	mov	x20, x19
	ldr	w8, [x20, #8]!
	cbz	w8, LBB0_23
; %bb.8:
	ldr	w24, [x22]
Lloh33:
	adrp	x21, _PqGSSRecvBuffer@GOTPAGE
Lloh34:
	ldr	x21, [x21, _PqGSSRecvBuffer@GOTPAGEOFF]
	cmp	w24, #3
	b.hi	LBB0_11
; %bb.9:
	ldr	x8, [x21]
	add	x1, x8, x24
	mov	w8, #4
	sub	w2, w8, w24
	sub	x3, x29, #72
	mov	x0, x19
	bl	_gss_read
Lloh35:
	adrp	x8, _PGRES_POLLING_OK@GOTPAGE
Lloh36:
	ldr	x8, [x8, _PGRES_POLLING_OK@GOTPAGEOFF]
Lloh37:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_29
; %bb.10:
	ldur	w8, [x29, #-72]
	ldr	w9, [x22]
	add	w24, w9, w8
	str	w24, [x22]
	cmp	w24, #3
	b.ls	LBB0_21
LBB0_11:
	ldr	x25, [x21]
	ldrb	w8, [x25]
	cmp	w8, #69
	b.ne	LBB0_14
; %bb.12:
	add	x1, x25, w24, sxtw
Lloh38:
	adrp	x8, _PQ_GSS_RECV_BUFFER_SIZE@GOTPAGE
Lloh39:
	ldr	x8, [x8, _PQ_GSS_RECV_BUFFER_SIZE@GOTPAGEOFF]
Lloh40:
	ldr	w8, [x8]
	mvn	w9, w24
	add	w2, w8, w9
	sub	x3, x29, #72
	mov	x0, x19
	bl	_gss_read
Lloh41:
	adrp	x8, _PGRES_POLLING_OK@GOTPAGE
Lloh42:
	ldr	x8, [x8, _PGRES_POLLING_OK@GOTPAGEOFF]
Lloh43:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_29
; %bb.13:
	ldur	w8, [x29, #-72]
	ldr	w9, [x22]
	add	w8, w9, w8
	str	w8, [x22]
	add	x0, x19, #20
	ldr	x8, [x21]
	add	x8, x8, #1
	str	x8, [sp]
Lloh44:
	adrp	x1, l_.str@PAGE
Lloh45:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_16
LBB0_14:
	ldr	w0, [x25]
	bl	_ntohl
                                        ; kill: def $w0 killed $w0 def $x0
	str	w0, [sp, #64]
	sxtw	x23, w0
Lloh46:
	adrp	x26, _PQ_GSS_RECV_BUFFER_SIZE@GOTPAGE
Lloh47:
	ldr	x26, [x26, _PQ_GSS_RECV_BUFFER_SIZE@GOTPAGEOFF]
	ldrsw	x8, [x26]
	sub	x8, x8, #4
	cmp	x8, x23
	b.hs	LBB0_19
; %bb.15:
	add	x19, x19, #20
Lloh48:
	adrp	x0, l_.str.1@PAGE
Lloh49:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_libpq_gettext
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x1, w0
	ldrsw	x8, [x26]
	sub	x8, x8, #4
	stp	x23, x8, [sp]
	mov	x0, x19
LBB0_16:
	bl	_printfPQExpBuffer
	b	LBB0_27
LBB0_17:
	ldr	x8, [x23]
	add	x8, x8, x20
	str	x8, [x23]
LBB0_18:
Lloh50:
	adrp	x8, _PGRES_POLLING_WRITING@GOTPAGE
Lloh51:
	ldr	x8, [x8, _PGRES_POLLING_WRITING@GOTPAGEOFF]
	b	LBB0_28
LBB0_19:
	add	x1, x25, w24, sxtw
	sub	w8, w23, w24
	add	w2, w8, #4
	sub	x3, x29, #72
	mov	x0, x19
	bl	_gss_read
Lloh52:
	adrp	x8, _PGRES_POLLING_OK@GOTPAGE
Lloh53:
	ldr	x8, [x8, _PGRES_POLLING_OK@GOTPAGEOFF]
Lloh54:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_29
; %bb.20:
	ldur	w8, [x29, #-72]
	ldr	w9, [x22]
	add	w8, w9, w8
	str	w8, [x22]
	sxtw	x8, w8
	sub	x8, x8, #4
	cmp	x8, x23
	b.hs	LBB0_22
LBB0_21:
Lloh55:
	adrp	x8, _PGRES_POLLING_READING@GOTPAGE
Lloh56:
	ldr	x8, [x8, _PGRES_POLLING_READING@GOTPAGEOFF]
	b	LBB0_28
LBB0_22:
	ldr	x8, [x21]
	add	x8, x8, #4
	str	x8, [sp, #72]
LBB0_23:
	mov	x0, x19
	bl	_pg_GSS_load_servicename
	stur	x0, [x29, #-72]
Lloh57:
	adrp	x8, _STATUS_OK@GOTPAGE
Lloh58:
	ldr	x8, [x8, _STATUS_OK@GOTPAGEOFF]
Lloh59:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_27
; %bb.24:
	mov	x21, x19
	ldp	w1, w3, [x21, #12]!
Lloh60:
	adrp	x8, _GSS_C_NO_OID@GOTPAGE
Lloh61:
	ldr	x8, [x8, _GSS_C_NO_OID@GOTPAGEOFF]
Lloh62:
	ldr	w4, [x8]
Lloh63:
	adrp	x8, _GSS_REQUIRED_FLAGS@GOTPAGE
Lloh64:
	ldr	x8, [x8, _GSS_REQUIRED_FLAGS@GOTPAGEOFF]
Lloh65:
	ldr	w5, [x8]
	stp	xzr, xzr, [sp, #24]
	add	x8, sp, #48
	stp	xzr, x8, [sp, #8]
	add	x8, sp, #64
	sub	x0, x29, #76
	str	x8, [sp]
	mov	x2, x20
	mov	w6, #0
	mov	w7, #0
	bl	_gss_init_sec_context
	mov	x20, x0
	str	wzr, [x22]
Lloh66:
	adrp	x8, _PqGSSRecvPointer@GOTPAGE
Lloh67:
	ldr	x8, [x8, _PqGSSRecvPointer@GOTPAGEOFF]
Lloh68:
	str	xzr, [x8]
	bl	_GSS_ERROR
	cbz	x0, LBB0_30
; %bb.25:
Lloh69:
	adrp	x0, l_.str.2@PAGE
Lloh70:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_26:
	bl	_libpq_gettext
	ldur	w3, [x29, #-76]
	mov	x1, x19
	mov	x2, x20
	bl	_pg_GSS_error
LBB0_27:
Lloh71:
	adrp	x8, _PGRES_POLLING_FAILED@GOTPAGE
Lloh72:
	ldr	x8, [x8, _PGRES_POLLING_FAILED@GOTPAGEOFF]
LBB0_28:
	ldr	x0, [x8]
LBB0_29:
	ldp	x29, x30, [sp, #160]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #144]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #128]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #112]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #96]             ; 16-byte Folded Reload
	add	sp, sp, #176
	ret
LBB0_30:
	ldrsw	x0, [sp, #48]
	cbz	w0, LBB0_33
; %bb.31:
Lloh73:
	adrp	x8, _PQ_GSS_SEND_BUFFER_SIZE@GOTPAGE
Lloh74:
	ldr	x8, [x8, _PQ_GSS_SEND_BUFFER_SIZE@GOTPAGEOFF]
Lloh75:
	ldrsw	x8, [x8]
	sub	x8, x8, #4
	cmp	x8, x0
	b.hs	LBB0_36
; %bb.32:
Lloh76:
	adrp	x0, l_.str.4@PAGE
Lloh77:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_26
LBB0_33:
	sub	x0, x29, #76
	mov	x1, x21
	bl	_gss_release_cred
Lloh78:
	adrp	x8, _GSS_C_NO_CREDENTIAL@GOTPAGE
Lloh79:
	ldr	x8, [x8, _GSS_C_NO_CREDENTIAL@GOTPAGEOFF]
Lloh80:
	ldr	w8, [x8]
	str	w8, [x19, #12]
	mov	w8, #1
	str	w8, [x19, #4]
Lloh81:
	adrp	x8, _GSS_C_QOP_DEFAULT@GOTPAGE
Lloh82:
	ldr	x8, [x8, _GSS_C_QOP_DEFAULT@GOTPAGEOFF]
	ldr	w1, [x19, #8]
Lloh83:
	ldr	w3, [x8]
Lloh84:
	adrp	x8, _PQ_GSS_SEND_BUFFER_SIZE@GOTPAGE
Lloh85:
	ldr	x8, [x8, _PQ_GSS_SEND_BUFFER_SIZE@GOTPAGEOFF]
Lloh86:
	ldr	w8, [x8]
	sub	w4, w8, #4
Lloh87:
	adrp	x5, _max_packet_size@GOTPAGE
Lloh88:
	ldr	x5, [x5, _max_packet_size@GOTPAGEOFF]
	sub	x0, x29, #76
	mov	w2, #1
	bl	_gss_wrap_size_limit
	mov	x20, x0
	bl	_GSS_ERROR
	cbz	x0, LBB0_35
; %bb.34:
Lloh89:
	adrp	x0, l_.str.3@PAGE
Lloh90:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_libpq_gettext
	ldur	w3, [x29, #-76]
	mov	x1, x19
	mov	x2, x20
	bl	_pg_GSS_error
LBB0_35:
Lloh91:
	adrp	x8, _PGRES_POLLING_OK@GOTPAGE
Lloh92:
	ldr	x8, [x8, _PGRES_POLLING_OK@GOTPAGEOFF]
	b	LBB0_28
LBB0_36:
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_htonl
	str	w0, [sp, #80]
Lloh93:
	adrp	x19, _PqGSSSendBuffer@GOTPAGE
Lloh94:
	ldr	x19, [x19, _PqGSSSendBuffer@GOTPAGEOFF]
	ldr	x0, [x19]
	add	x1, sp, #80
	mov	w2, #4
	bl	_memcpy
Lloh95:
	adrp	x20, _PqGSSSendPointer@GOTPAGE
Lloh96:
	ldr	x20, [x20, _PqGSSSendPointer@GOTPAGEOFF]
	ldr	x8, [x20]
	add	x8, x8, #4
	str	x8, [x20]
	ldr	x9, [x19]
	add	x0, x9, x8
	ldr	x1, [sp, #56]
	ldr	w2, [sp, #48]
	bl	_memcpy
	ldrsw	x8, [sp, #48]
	ldr	x9, [x20]
	add	x8, x9, x8
	str	x8, [x20]
	sub	x0, x29, #76
	add	x1, sp, #48
	bl	_gss_release_buffer
	b	LBB0_18
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotStr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotStr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotStr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotStr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotStr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpAdd	Lloh48, Lloh49
	.loh AdrpLdrGot	Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpLdrGot	Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh57, Lloh58, Lloh59
	.loh AdrpLdrGotStr	Lloh66, Lloh67, Lloh68
	.loh AdrpLdrGotLdr	Lloh63, Lloh64, Lloh65
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpAdd	Lloh69, Lloh70
	.loh AdrpLdrGot	Lloh71, Lloh72
	.loh AdrpLdrGotLdr	Lloh73, Lloh74, Lloh75
	.loh AdrpAdd	Lloh76, Lloh77
	.loh AdrpLdrGot	Lloh87, Lloh88
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.loh AdrpLdrGotLdr	Lloh81, Lloh82, Lloh83
	.loh AdrpLdrGotLdr	Lloh78, Lloh79, Lloh80
	.loh AdrpAdd	Lloh89, Lloh90
	.loh AdrpLdrGot	Lloh91, Lloh92
	.loh AdrpLdrGot	Lloh95, Lloh96
	.loh AdrpLdrGot	Lloh93, Lloh94
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_pqsecure_open_gss.first,1,2 ; @pqsecure_open_gss.first
	.comm	_GSS_C_EMPTY_BUFFER,16,3        ; @GSS_C_EMPTY_BUFFER
	.comm	_PqGSSResultLength,4,2          ; @PqGSSResultLength
	.comm	_PqGSSResultPointer,4,2         ; @PqGSSResultPointer
	.comm	_PqGSSRecvLength,4,2            ; @PqGSSRecvLength
	.comm	_PqGSSRecvPointer,8,3           ; @PqGSSRecvPointer
	.comm	_PqGSSSendStart,8,3             ; @PqGSSSendStart
	.comm	_PqGSSSendPointer,8,3           ; @PqGSSSendPointer
	.comm	_PqGSSSendBuffer,8,3            ; @PqGSSSendBuffer
	.comm	_errno,8,3                      ; @errno
	.comm	_EWOULDBLOCK,8,3                ; @EWOULDBLOCK
	.comm	_PGRES_POLLING_WRITING,8,3      ; @PGRES_POLLING_WRITING
	.comm	_PqGSSRecvBuffer,8,3            ; @PqGSSRecvBuffer
	.comm	_PGRES_POLLING_OK,8,3           ; @PGRES_POLLING_OK
	.comm	_PGRES_POLLING_READING,8,3      ; @PGRES_POLLING_READING
	.comm	_PQ_GSS_RECV_BUFFER_SIZE,4,2    ; @PQ_GSS_RECV_BUFFER_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s\n"

	.comm	_PGRES_POLLING_FAILED,8,3       ; @PGRES_POLLING_FAILED
l_.str.1:                               ; @.str.1
	.asciz	"oversize GSSAPI packet sent by the server (%zu > %zu)\n"

	.comm	_STATUS_OK,8,3                  ; @STATUS_OK
	.comm	_GSS_C_NO_OID,4,2               ; @GSS_C_NO_OID
	.comm	_GSS_REQUIRED_FLAGS,4,2         ; @GSS_REQUIRED_FLAGS
l_.str.2:                               ; @.str.2
	.asciz	"could not initiate GSSAPI security context"

	.comm	_GSS_C_NO_CREDENTIAL,4,2        ; @GSS_C_NO_CREDENTIAL
	.comm	_GSS_C_QOP_DEFAULT,4,2          ; @GSS_C_QOP_DEFAULT
	.comm	_PQ_GSS_SEND_BUFFER_SIZE,4,2    ; @PQ_GSS_SEND_BUFFER_SIZE
	.comm	_max_packet_size,4,2            ; @max_packet_size
l_.str.3:                               ; @.str.3
	.asciz	"GSSAPI size check error"

l_.str.4:                               ; @.str.4
	.asciz	"GSSAPI context establishment error"

.subsections_via_symbols
