	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_check_client_encoding          ## -- Begin function check_client_encoding
	.p2align	4, 0x90
_check_client_encoding:                 ## @check_client_encoding
	.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
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	(%rdi), %rdi
	callq	_pg_valid_client_encoding
	xorl	%r14d, %r14d
	testl	%eax, %eax
	js	LBB0_10
## %bb.1:
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_pg_encoding_to_char
	movq	%rax, %r12
	movl	%ebx, %edi
	callq	_PrepareClientEncoding
	testq	%rax, %rax
	js	LBB0_2
## %bb.5:
	movq	(%r13), %rdi
	movq	%r12, %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_8
## %bb.6:
	movq	(%r13), %rdi
	leaq	L_.str.2(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	movq	(%r13), %rdi
	callq	_free
	movq	%r12, %rdi
	callq	_strdup
	movq	%rax, (%r13)
	testq	%rax, %rax
	je	LBB0_10
LBB0_8:
	movl	$4, %edi
	callq	_malloc
	movq	%rax, (%r15)
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movl	%ebx, (%rax)
	movl	$1, %r14d
	jmp	LBB0_10
LBB0_2:
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_IsTransactionState
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	_ERRCODE_FEATURE_NOT_SUPPORTED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_GUC_check_errcode
	xorl	%eax, %eax
	callq	_GetDatabaseEncodingName
	leaq	L_.str(%rip), %rdi
	movq	%r12, %rsi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_GUC_check_errdetail
	jmp	LBB0_10
LBB0_4:
	leaq	L_.str.1(%rip), %rdi
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_GUC_check_errdetail
LBB0_10:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ERRCODE_FEATURE_NOT_SUPPORTED,4,2 ## @ERRCODE_FEATURE_NOT_SUPPORTED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Conversion between %s and %s is not supported."

L_.str.1:                               ## @.str.1
	.asciz	"Cannot change \"client_encoding\" now."

L_.str.2:                               ## @.str.2
	.asciz	"UNICODE"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_check_client_encoding          ; -- Begin function check_client_encoding
	.p2align	2
_check_client_encoding:                 ; @check_client_encoding
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x1
	mov	x22, x0
	ldr	x0, [x0]
	bl	_pg_valid_client_encoding
	tbnz	w0, #31, LBB0_11
; %bb.1:
	mov	x20, x0
	bl	_pg_encoding_to_char
	mov	x21, x0
	mov	x0, x20
	bl	_PrepareClientEncoding
	tbnz	x0, #63, LBB0_7
; %bb.2:
	ldr	x0, [x22]
	mov	x1, x21
	bl	_strcmp
	cbz	x0, LBB0_5
; %bb.3:
	ldr	x0, [x22]
Lloh0:
	adrp	x1, l_.str.2@PAGE
Lloh1:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_strcmp
	cbz	x0, LBB0_5
; %bb.4:
	ldr	x0, [x22]
	bl	_free
	mov	x0, x21
	bl	_strdup
	str	x0, [x22]
	cbz	x0, LBB0_12
LBB0_5:
	mov	w0, #4
	bl	_malloc
	str	x0, [x19]
	cbz	x0, LBB0_12
; %bb.6:
	str	w20, [x0]
	mov	w0, #1
	b	LBB0_12
LBB0_7:
	bl	_IsTransactionState
	cbz	x0, LBB0_9
; %bb.8:
Lloh2:
	adrp	x8, _ERRCODE_FEATURE_NOT_SUPPORTED@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ERRCODE_FEATURE_NOT_SUPPORTED@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	bl	_GUC_check_errcode
	bl	_GetDatabaseEncodingName
                                        ; kill: def $w0 killed $w0 def $x0
	stp	x21, x0, [sp]
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_10
LBB0_9:
Lloh7:
	adrp	x0, l_.str.1@PAGE
Lloh8:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_10:
	bl	_GUC_check_errdetail
LBB0_11:
	mov	w0, #0
LBB0_12:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_ERRCODE_FEATURE_NOT_SUPPORTED,4,2 ; @ERRCODE_FEATURE_NOT_SUPPORTED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Conversion between %s and %s is not supported."

l_.str.1:                               ; @.str.1
	.asciz	"Cannot change \"client_encoding\" now."

l_.str.2:                               ; @.str.2
	.asciz	"UNICODE"

.subsections_via_symbols
