	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function make_result_opt_error
_make_result_opt_error:                 ## @make_result_opt_error
	.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	16(%rdi), %rbx
	movl	(%rdi), %ecx
	movl	4(%rdi), %edi
	testq	%rsi, %rsi
	je	LBB0_2
## %bb.1:
	movl	$0, (%rsi)
LBB0_2:
	movq	_NUMERIC_NAN@GOTPCREL(%rip), %r14
	cmpl	(%r14), %edi
	jne	LBB0_4
## %bb.3:
	movq	_NUMERIC_HDRSZ_SHORT@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	callq	_palloc
	movq	%rax, %r13
	movq	(%rbx), %rsi
	movq	%rax, %rdi
	callq	_SET_VARSIZE
	movl	(%r14), %eax
	movl	%eax, (%r13)
	jmp	LBB0_29
LBB0_4:
	movl	8(%r13), %eax
	testl	%eax, %eax
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	jle	LBB0_10
## %bb.5:
	movl	%ecx, %r14d
	subl	%eax, %r14d
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$0, (%rbx)
	jne	LBB0_10
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	addq	$8, %rbx
	decl	%ecx
	leal	-1(%rax), %edx
	cmpl	$1, %eax
	movl	%edx, %eax
	jg	LBB0_6
## %bb.8:
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_10:
	movl	%ecx, %r14d
LBB0_11:
	movl	%eax, %ecx
	movl	%eax, %r12d
	sarl	$31, %r12d
	andl	%eax, %r12d
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	%ecx, %r15d
	testl	%ecx, %ecx
	jle	LBB0_15
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	leaq	-1(%rcx), %rax
	cmpq	$0, -8(%rbx,%rcx,8)
	movq	%rax, %rcx
	je	LBB0_12
## %bb.14:
	incl	%eax
	movl	%eax, %r12d
LBB0_15:
	testl	%r12d, %r12d
	jne	LBB0_17
## %bb.16:
	movq	_NUMERIC_POS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%r12d, %r14d
LBB0_17:
	movl	%edi, -44(%rbp)                 ## 4-byte Spill
	movl	12(%r13), %edi
	movl	%r14d, %esi
	callq	_NUMERIC_CAN_BE_SHORT
	testq	%rax, %rax
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movl	%r14d, -48(%rbp)                ## 4-byte Spill
	je	LBB0_21
## %bb.18:
	movq	_NUMERIC_HDRSZ_SHORT@GOTPCREL(%rip), %rax
	movslq	%r12d, %r14
	shlq	$3, %r14
	addq	(%rax), %r14
	movq	%r14, %rdi
	callq	_palloc
	movq	%rax, %r13
	movq	%rax, %rdi
	movq	%r14, %rsi
	callq	_SET_VARSIZE
	movq	_NUMERIC_NEG@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	movq	_NUMERIC_SHORT@GOTPCREL(%rip), %rcx
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	cmpl	(%rdx), %esi
	jne	LBB0_20
## %bb.19:
	movq	_NUMERIC_SHORT_SIGN_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_20:
	orl	(%rcx), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	12(%rcx), %edx
	movq	_NUMERIC_SHORT_DSCALE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %edx
	movq	_NUMERIC_SHORT_WEIGHT_SIGN_MASK@GOTPCREL(%rip), %rcx
	movl	-48(%rbp), %r14d                ## 4-byte Reload
	movl	%r14d, %esi
	sarl	$31, %esi
	andl	(%rcx), %esi
	orl	%edx, %esi
	movq	_NUMERIC_SHORT_WEIGHT_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%r14d, %ecx
	orl	%esi, %ecx
	orl	%eax, %ecx
	movl	%ecx, 12(%r13)
	jmp	LBB0_22
LBB0_21:
	movq	_NUMERIC_HDRSZ@GOTPCREL(%rip), %rax
	movslq	%r12d, %r14
	shlq	$3, %r14
	addq	(%rax), %r14
	movq	%r14, %rdi
	callq	_palloc
	movq	%rax, %r13
	movq	%rax, %rdi
	movq	%r14, %rsi
	movl	-48(%rbp), %r14d                ## 4-byte Reload
	callq	_SET_VARSIZE
	movq	_NUMERIC_DSCALE_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	andl	12(%rcx), %eax
	orl	-44(%rbp), %eax                 ## 4-byte Folded Reload
	movl	%eax, 4(%r13)
	movl	%r14d, 8(%r13)
LBB0_22:
	movq	%r13, %rdi
	callq	_NUMERIC_NDIGITS
	xorl	%edi, %edi
	cmpl	%r12d, %eax
	sete	%dil
	callq	_Assert
	testl	%r15d, %r15d
	jle	LBB0_24
## %bb.23:
	movq	%r13, %rdi
	callq	_NUMERIC_DIGITS
	shll	$3, %r12d
	movl	%eax, %edi
	movq	%rbx, %rsi
	movl	%r12d, %edx
	callq	_memcpy
LBB0_24:
	movq	%r13, %rdi
	callq	_NUMERIC_WEIGHT
	cmpl	%r14d, %eax
	jne	LBB0_26
## %bb.25:
	movq	%r13, %rdi
	callq	_NUMERIC_DSCALE
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	cmpl	12(%rcx), %eax
	je	LBB0_29
LBB0_26:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_28
## %bb.27:
	movl	$1, (%rax)
	xorl	%r13d, %r13d
	jmp	LBB0_30
LBB0_28:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str.1(%rip), %rdi
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_29:
	leaq	L_.str(%rip), %rdi
	movq	%r13, %rsi
	callq	_dump_numeric
LBB0_30:
	movq	%r13, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NUMERIC_NAN,4,2                ## @NUMERIC_NAN
	.comm	_NUMERIC_HDRSZ_SHORT,8,3        ## @NUMERIC_HDRSZ_SHORT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"make_result()"

	.comm	_NUMERIC_POS,4,2                ## @NUMERIC_POS
	.comm	_NUMERIC_NEG,4,2                ## @NUMERIC_NEG
	.comm	_NUMERIC_SHORT,4,2              ## @NUMERIC_SHORT
	.comm	_NUMERIC_SHORT_SIGN_MASK,4,2    ## @NUMERIC_SHORT_SIGN_MASK
	.comm	_NUMERIC_SHORT_DSCALE_SHIFT,4,2 ## @NUMERIC_SHORT_DSCALE_SHIFT
	.comm	_NUMERIC_SHORT_WEIGHT_SIGN_MASK,4,2 ## @NUMERIC_SHORT_WEIGHT_SIGN_MASK
	.comm	_NUMERIC_SHORT_WEIGHT_MASK,4,2  ## @NUMERIC_SHORT_WEIGHT_MASK
	.comm	_NUMERIC_HDRSZ,8,3              ## @NUMERIC_HDRSZ
	.comm	_NUMERIC_DSCALE_MASK,4,2        ## @NUMERIC_DSCALE_MASK
	.comm	_ERROR,4,2                      ## @ERROR
	.comm	_ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE,4,2 ## @ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE
L_.str.1:                               ## @.str.1
	.asciz	"value overflows numeric format"

	.no_dead_strip	_make_result_opt_error
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function make_result_opt_error
_make_result_opt_error:                 ; @make_result_opt_error
	.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, x1
	mov	x20, x0
	ldr	x11, [x0, #16]
	ldp	w10, w8, [x0]
	cbz	x1, LBB0_2
; %bb.1:
	str	wzr, [x19]
LBB0_2:
Lloh0:
	adrp	x21, _NUMERIC_NAN@GOTPAGE
Lloh1:
	ldr	x21, [x21, _NUMERIC_NAN@GOTPAGEOFF]
	ldr	w9, [x21]
	cmp	w8, w9
	b.ne	LBB0_4
; %bb.3:
Lloh2:
	adrp	x19, _NUMERIC_HDRSZ_SHORT@GOTPAGE
Lloh3:
	ldr	x19, [x19, _NUMERIC_HDRSZ_SHORT@GOTPAGEOFF]
	ldr	x0, [x19]
	bl	_palloc
	mov	x22, x0
	ldr	x1, [x19]
	bl	_SET_VARSIZE
	ldr	w8, [x21]
	str	w8, [x22]
	b	LBB0_24
LBB0_4:
	ldr	w12, [x20, #8]
	subs	w9, w12, #1
	b.lt	LBB0_9
; %bb.5:
	add	x9, x11, w9, uxtw #3
	add	x21, x9, #8
	sub	w9, w10, w12
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x13, [x11]
	cbnz	x13, LBB0_9
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x11, x11, #8
	sub	w10, w10, #1
	subs	w12, w12, #1
	b.gt	LBB0_6
; %bb.8:
	mov	w12, #0
	b	LBB0_10
LBB0_9:
	mov	x21, x11
	mov	x9, x10
LBB0_10:
	mov	w10, w12
	cmp	w12, #0
	csel	w25, w12, wzr, lt
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	mov	x26, x10
	cmp	w10, #1
	b.lt	LBB0_14
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	sub	x11, x10, #1
	add	x10, x21, x10, lsl #3
	ldur	x12, [x10, #-8]
	mov	x10, x11
	cbz	x12, LBB0_11
; %bb.13:
	add	w25, w11, #1
LBB0_14:
Lloh4:
	adrp	x10, _NUMERIC_POS@GOTPAGE
Lloh5:
	ldr	x10, [x10, _NUMERIC_POS@GOTPAGEOFF]
Lloh6:
	ldr	w10, [x10]
	cmp	w25, #0
	csel	w23, wzr, w9, eq
	csel	w27, w10, w8, eq
	ldr	w0, [x20, #12]
	mov	x1, x23
	bl	_NUMERIC_CAN_BE_SHORT
	cbz	x0, LBB0_16
; %bb.15:
Lloh7:
	adrp	x8, _NUMERIC_HDRSZ_SHORT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _NUMERIC_HDRSZ_SHORT@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	add	x24, x8, w25, sxtw #3
	mov	x0, x24
	bl	_palloc
	mov	x22, x0
	mov	x1, x24
	bl	_SET_VARSIZE
Lloh10:
	adrp	x8, _NUMERIC_NEG@GOTPAGE
Lloh11:
	ldr	x8, [x8, _NUMERIC_NEG@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _NUMERIC_SHORT@GOTPAGE
Lloh14:
	ldr	x9, [x9, _NUMERIC_SHORT@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
Lloh16:
	adrp	x10, _NUMERIC_SHORT_SIGN_MASK@GOTPAGE
Lloh17:
	ldr	x10, [x10, _NUMERIC_SHORT_SIGN_MASK@GOTPAGEOFF]
Lloh18:
	ldr	w10, [x10]
	cmp	w27, w8
	csel	w8, w10, wzr, eq
	orr	w8, w8, w9
	ldr	w9, [x20, #12]
Lloh19:
	adrp	x10, _NUMERIC_SHORT_DSCALE_SHIFT@GOTPAGE
Lloh20:
	ldr	x10, [x10, _NUMERIC_SHORT_DSCALE_SHIFT@GOTPAGEOFF]
Lloh21:
	ldr	w10, [x10]
	lsl	w9, w9, w10
	orr	w8, w8, w9
Lloh22:
	adrp	x9, _NUMERIC_SHORT_WEIGHT_SIGN_MASK@GOTPAGE
Lloh23:
	ldr	x9, [x9, _NUMERIC_SHORT_WEIGHT_SIGN_MASK@GOTPAGEOFF]
Lloh24:
	ldr	w9, [x9]
	and	w9, w9, w23, asr #31
	orr	w8, w8, w9
Lloh25:
	adrp	x9, _NUMERIC_SHORT_WEIGHT_MASK@GOTPAGE
Lloh26:
	ldr	x9, [x9, _NUMERIC_SHORT_WEIGHT_MASK@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
	and	w9, w9, w23
	orr	w8, w8, w9
	str	w8, [x22, #12]
	b	LBB0_17
LBB0_16:
Lloh28:
	adrp	x8, _NUMERIC_HDRSZ@GOTPAGE
Lloh29:
	ldr	x8, [x8, _NUMERIC_HDRSZ@GOTPAGEOFF]
Lloh30:
	ldr	x8, [x8]
	add	x24, x8, w25, sxtw #3
	mov	x0, x24
	bl	_palloc
	mov	x22, x0
	mov	x1, x24
	bl	_SET_VARSIZE
Lloh31:
	adrp	x8, _NUMERIC_DSCALE_MASK@GOTPAGE
Lloh32:
	ldr	x8, [x8, _NUMERIC_DSCALE_MASK@GOTPAGEOFF]
	ldr	w9, [x20, #12]
Lloh33:
	ldr	w8, [x8]
	and	w8, w8, w9
	orr	w8, w8, w27
	stp	w8, w23, [x22, #4]
LBB0_17:
	mov	x0, x22
	bl	_NUMERIC_NDIGITS
	cmp	w0, w25
	cset	w0, eq
	bl	_Assert
	cmp	w26, #1
	b.lt	LBB0_19
; %bb.18:
	mov	x0, x22
	bl	_NUMERIC_DIGITS
	lsl	w2, w25, #3
	mov	x1, x21
	bl	_memcpy
LBB0_19:
	mov	x0, x22
	bl	_NUMERIC_WEIGHT
	cmp	w0, w23
	b.ne	LBB0_21
; %bb.20:
	mov	x0, x22
	bl	_NUMERIC_DSCALE
	ldr	w8, [x20, #12]
	cmp	w0, w8
	b.eq	LBB0_24
LBB0_21:
	cbz	x19, LBB0_23
; %bb.22:
	mov	x22, #0
	mov	w8, #1
	str	w8, [x19]
	b	LBB0_25
LBB0_23:
Lloh34:
	adrp	x8, _ERROR@GOTPAGE
Lloh35:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh36:
	ldr	w19, [x8]
Lloh37:
	adrp	x8, _ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE@GOTPAGE
Lloh38:
	ldr	x8, [x8, _ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE@GOTPAGEOFF]
Lloh39:
	ldr	w0, [x8]
	bl	_errcode
Lloh40:
	adrp	x0, l_.str.1@PAGE
Lloh41:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_errmsg
	mov	x1, x0
	mov	x0, x19
	bl	_ereport
LBB0_24:
Lloh42:
	adrp	x0, l_.str@PAGE
Lloh43:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x22
	bl	_dump_numeric
LBB0_25:
	mov	x0, x22
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpAdd	Lloh42, Lloh43
	.cfi_endproc
                                        ; -- End function
	.comm	_NUMERIC_NAN,4,2                ; @NUMERIC_NAN
	.comm	_NUMERIC_HDRSZ_SHORT,8,3        ; @NUMERIC_HDRSZ_SHORT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"make_result()"

	.comm	_NUMERIC_POS,4,2                ; @NUMERIC_POS
	.comm	_NUMERIC_NEG,4,2                ; @NUMERIC_NEG
	.comm	_NUMERIC_SHORT,4,2              ; @NUMERIC_SHORT
	.comm	_NUMERIC_SHORT_SIGN_MASK,4,2    ; @NUMERIC_SHORT_SIGN_MASK
	.comm	_NUMERIC_SHORT_DSCALE_SHIFT,4,2 ; @NUMERIC_SHORT_DSCALE_SHIFT
	.comm	_NUMERIC_SHORT_WEIGHT_SIGN_MASK,4,2 ; @NUMERIC_SHORT_WEIGHT_SIGN_MASK
	.comm	_NUMERIC_SHORT_WEIGHT_MASK,4,2  ; @NUMERIC_SHORT_WEIGHT_MASK
	.comm	_NUMERIC_HDRSZ,8,3              ; @NUMERIC_HDRSZ
	.comm	_NUMERIC_DSCALE_MASK,4,2        ; @NUMERIC_DSCALE_MASK
	.comm	_ERROR,4,2                      ; @ERROR
	.comm	_ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE,4,2 ; @ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE
l_.str.1:                               ; @.str.1
	.asciz	"value overflows numeric format"

	.no_dead_strip	_make_result_opt_error
.subsections_via_symbols
