	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function composite_to_json
_composite_to_json:                     ## @composite_to_json
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	testl	%edx, %edx
	leaq	L_.str.1(%rip), %rax
	leaq	L_.str(%rip), %rcx
	cmoveq	%rax, %rcx
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	callq	_DatumGetHeapTupleHeader
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_HeapTupleHeaderGetTypeId
	movl	%eax, %r14d
	movl	%ebx, %edi
	callq	_HeapTupleHeaderGetTypMod
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_lookup_rowtype_tupdesc
	movq	%rax, %r12
	movl	%ebx, %edi
	callq	_HeapTupleHeaderGetDatumLength
	movl	%eax, -60(%rbp)
	movl	%ebx, -64(%rbp)
	movl	%r15d, %edi
	movl	$123, %esi
	callq	_appendStringInfoChar
	cmpl	$0, (%r12)
	jle	LBB0_11
## %bb.1:
	xorl	%ebx, %ebx
	xorl	%r14d, %r14d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	incl	%ebx
	cmpl	(%r12), %ebx
	jge	LBB0_11
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_TupleDescAttr
	cmpq	$0, 8(%rax)
	jne	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %r13
	testl	%r14d, %r14d
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r15d, %edi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	callq	_appendStringInfoString
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	4(%r13), %edi
	callq	_NameStr
	movl	%r15d, %edi
	movq	%rax, %rsi
	callq	_escape_json
	movl	%r15d, %edi
	movl	$58, %esi
	callq	_appendStringInfoChar
	incl	%ebx
	leaq	-64(%rbp), %rdi
	movl	%ebx, %esi
	movq	%r12, %rdx
	leaq	-52(%rbp), %rcx
	callq	_heap_getattr
	movl	%eax, %r14d
	movl	-52(%rbp), %esi
	testl	%esi, %esi
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_JSONTYPE_NULL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%ecx, -48(%rbp)
	movq	_InvalidOid@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movl	%r8d, -44(%rbp)
	jmp	LBB0_9
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r13), %edi
	leaq	-48(%rbp), %rsi
	leaq	-44(%rbp), %rdx
	callq	_json_categorize_type
	movl	-52(%rbp), %esi
	movl	-48(%rbp), %ecx
	movl	-44(%rbp), %r8d
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%r14d, %edi
	movl	%r15d, %edx
	xorl	%r9d, %r9d
	callq	_datum_to_json
	movl	$1, %r14d
	cmpl	(%r12), %ebx
	jl	LBB0_2
LBB0_11:
	movl	%r15d, %edi
	movl	$125, %esi
	callq	_appendStringInfoChar
	movq	%r12, %rdi
	callq	_ReleaseTupleDesc
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	",\n "

L_.str.1:                               ## @.str.1
	.asciz	","

	.comm	_JSONTYPE_NULL,4,2              ## @JSONTYPE_NULL
	.comm	_InvalidOid,4,2                 ## @InvalidOid
	.no_dead_strip	_composite_to_json
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function composite_to_json
_composite_to_json:                     ; @composite_to_json
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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, x1
Lloh0:
	adrp	x8, l_.str@PAGE
Lloh1:
	add	x8, x8, l_.str@PAGEOFF
Lloh2:
	adrp	x9, l_.str.1@PAGE
Lloh3:
	add	x9, x9, l_.str.1@PAGEOFF
	cmp	w2, #0
	csel	x20, x9, x8, eq
	bl	_DatumGetHeapTupleHeader
	mov	x22, x0
	bl	_HeapTupleHeaderGetTypeId
	mov	x21, x0
	mov	x0, x22
	bl	_HeapTupleHeaderGetTypMod
	mov	x1, x0
	mov	x0, x21
	bl	_lookup_rowtype_tupdesc
	mov	x21, x0
	mov	x0, x22
	bl	_HeapTupleHeaderGetDatumLength
	stp	w22, w0, [sp, #24]
	mov	x0, x19
	mov	w1, #123
	bl	_appendStringInfoChar
	ldr	w8, [x21]
	cmp	w8, #1
	b.lt	LBB0_11
; %bb.1:
	mov	w22, #0
	mov	w24, #0
Lloh4:
	adrp	x25, _JSONTYPE_NULL@GOTPAGE
Lloh5:
	ldr	x25, [x25, _JSONTYPE_NULL@GOTPAGEOFF]
Lloh6:
	adrp	x26, _InvalidOid@GOTPAGE
Lloh7:
	ldr	x26, [x26, _InvalidOid@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	w22, w22, #1
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x21]
	cmp	w22, w8
	b.ge	LBB0_11
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	mov	x1, x22
	bl	_TupleDescAttr
	ldr	x8, [x0, #8]
	cbnz	x8, LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x23, x0
	cbz	w24, LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x20
	bl	_appendStringInfoString
LBB0_7:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x23, #4]
	bl	_NameStr
	mov	x1, x0
	mov	x0, x19
	bl	_escape_json
	mov	x0, x19
	mov	w1, #58
	bl	_appendStringInfoChar
	add	w22, w22, #1
	add	x0, sp, #24
	add	x3, sp, #20
	mov	x1, x22
	mov	x2, x21
	bl	_heap_getattr
	mov	x24, x0
	ldr	w1, [sp, #20]
	cbz	w1, LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w3, [x25]
	ldr	w4, [x26]
	stp	w4, w3, [sp, #12]
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x23]
	add	x1, sp, #16
	add	x2, sp, #12
	bl	_json_categorize_type
	ldp	w3, w1, [sp, #16]
	ldr	w4, [sp, #12]
LBB0_10:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x24
	mov	x2, x19
	mov	w5, #0
	bl	_datum_to_json
	mov	w24, #1
	b	LBB0_3
LBB0_11:
	mov	x0, x19
	mov	w1, #125
	bl	_appendStringInfoChar
	mov	x0, x21
	bl	_ReleaseTupleDesc
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	",\n "

l_.str.1:                               ; @.str.1
	.asciz	","

	.comm	_JSONTYPE_NULL,4,2              ; @JSONTYPE_NULL
	.comm	_InvalidOid,4,2                 ; @InvalidOid
	.no_dead_strip	_composite_to_json
.subsections_via_symbols
