	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_replace_text_regexp            ## -- Begin function replace_text_regexp
	.p2align	4, 0x90
_replace_text_regexp:                   ## @replace_text_regexp
	.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	$200, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, -184(%rbp)                ## 4-byte Spill
	movq	%rdx, %r13
	movq	%rsi, -216(%rbp)                ## 8-byte Spill
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_VARSIZE_ANY_EXHDR
	movl	%eax, %r15d
	movq	%rsp, -232(%rbp)                ## 8-byte Spill
	movq	_REGEXP_REPLACE_BACKREF_CNT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$3, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r14
	leaq	-176(%rbp), %rdi
	callq	_initStringInfo
	leal	4(,%r15,4), %edi
	callq	_palloc
	movq	%rax, %rbx
	movq	%r12, %rdi
	callq	_VARDATA_ANY
	movq	%rax, %rdi
	movq	%rbx, -208(%rbp)                ## 8-byte Spill
	movq	%rbx, %rsi
	movl	%r15d, %edx
	callq	_pg_mb2wchar_with_len
	movq	%r13, -200(%rbp)                ## 8-byte Spill
	movq	%r13, %rdi
	movq	%rax, %r13
	callq	_check_replace_text_has_escape_char
	movl	%eax, -180(%rbp)                ## 4-byte Spill
	movq	%r12, -224(%rbp)                ## 8-byte Spill
	movq	%r12, %rdi
	callq	_VARDATA_ANY
	movq	%rax, %r15
	xorl	%ebx, %ebx
	xorl	%r12d, %r12d
	movq	%r13, -192(%rbp)                ## 8-byte Spill
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_CHECK_FOR_INTERRUPTS
	movq	_REGEXP_REPLACE_BACKREF_CNT@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movq	-216(%rbp), %rdi                ## 8-byte Reload
	movq	-208(%rbp), %rsi                ## 8-byte Reload
	movq	%r13, %rdx
	movl	%ebx, %ecx
	xorl	%r8d, %r8d
	pushq	$0
	pushq	%r14
	callq	_pg_regexec
	addq	$16, %rsp
	movl	%eax, %ebx
	movq	_REG_NOMATCH@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	je	LBB0_13
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	_REG_OKAY@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	je	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	xorl	%eax, %eax
	callq	_CHECK_FOR_INTERRUPTS
	movl	%ebx, %edi
	movq	-216(%rbp), %rsi                ## 8-byte Reload
	leaq	-160(%rbp), %rdx
	movl	$100, %ecx
	callq	_pg_regerror
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_INVALID_REGULAR_EXPRESSION@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	leaq	L_.str(%rip), %rdi
	leaq	-160(%rbp), %rsi
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_4:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	(%r14), %esi
	subl	%r12d, %esi
	jle	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	%r15, %rdi
	callq	_charlen_to_bytelen
	movl	%eax, %ebx
	leaq	-176(%rbp), %rdi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_appendBinaryStringInfo
	movslq	%ebx, %r13
	addq	%r15, %r13
	movl	(%r14), %r12d
	cmpl	$0, -180(%rbp)                  ## 4-byte Folded Reload
	je	LBB0_9
LBB0_8:                                 ##   in Loop: Header=BB0_1 Depth=1
	leaq	-176(%rbp), %rdi
	movq	-200(%rbp), %rsi                ## 8-byte Reload
	movq	%r14, %rdx
	movq	%r13, %rcx
	movl	%r12d, %r8d
	callq	_appendStringInfoRegexpSubstr
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	%r15, %r13
	cmpl	$0, -180(%rbp)                  ## 4-byte Folded Reload
	jne	LBB0_8
LBB0_9:                                 ##   in Loop: Header=BB0_1 Depth=1
	leaq	-176(%rbp), %rdi
	movq	-200(%rbp), %rsi                ## 8-byte Reload
	callq	_appendStringInfoText
LBB0_10:                                ##   in Loop: Header=BB0_1 Depth=1
	movl	4(%r14), %esi
	subl	%r12d, %esi
	movq	%r13, %rdi
	callq	_charlen_to_bytelen
	movslq	%eax, %r15
	addq	%r13, %r15
	movl	4(%r14), %r12d
	cmpl	$0, -184(%rbp)                  ## 4-byte Folded Reload
	je	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_1 Depth=1
	xorl	%ebx, %ebx
	cmpl	%r12d, (%r14)
	sete	%bl
	addl	%r12d, %ebx
	movslq	%ebx, %rax
	movq	-192(%rbp), %r13                ## 8-byte Reload
	cmpq	%rax, %r13
	jae	LBB0_1
	jmp	LBB0_13
LBB0_11:
	movq	-192(%rbp), %r13                ## 8-byte Reload
LBB0_13:
	movslq	%r12d, %rax
	cmpq	%rax, %r13
	jbe	LBB0_15
## %bb.14:
	movq	-224(%rbp), %rbx                ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_VARSIZE_ANY
	addl	%eax, %ebx
	subl	%r15d, %ebx
	leaq	-176(%rbp), %rdi
	movq	%r15, %rsi
	movl	%ebx, %edx
	callq	_appendBinaryStringInfo
LBB0_15:
	movq	-176(%rbp), %rdi
	movl	-168(%rbp), %esi
	callq	_cstring_to_text_with_len
	movq	%rax, %rbx
	movq	-176(%rbp), %rdi
	callq	_pfree
	movq	-208(%rbp), %rdi                ## 8-byte Reload
	callq	_pfree
	movq	-232(%rbp), %rsp                ## 8-byte Reload
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_17
## %bb.16:
	movq	%rbx, %rax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_REGEXP_REPLACE_BACKREF_CNT,4,2 ## @REGEXP_REPLACE_BACKREF_CNT
	.comm	_REG_NOMATCH,4,2                ## @REG_NOMATCH
	.comm	_REG_OKAY,4,2                   ## @REG_OKAY
	.comm	_ERROR,4,2                      ## @ERROR
	.comm	_ERRCODE_INVALID_REGULAR_EXPRESSION,4,2 ## @ERRCODE_INVALID_REGULAR_EXPRESSION
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"regular expression failed: %s"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_replace_text_regexp            ; -- Begin function replace_text_regexp
	.p2align	2
_replace_text_regexp:                   ; @replace_text_regexp
	.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
	sub	sp, sp, #144
	mov	x21, x3
	mov	x22, x2
	mov	x23, x1
	mov	x25, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
	bl	_VARSIZE_ANY_EXHDR
	mov	x19, x0
	mov	x8, sp
	stur	x8, [x29, #-216]                ; 8-byte Folded Spill
Lloh3:
	adrp	x8, _REGEXP_REPLACE_BACKREF_CNT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REGEXP_REPLACE_BACKREF_CNT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x8, x8, #3
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0xffffffff0
	sub	x24, x9, x8
	mov	sp, x24
	sub	x0, x29, #208
	bl	_initStringInfo
	lsl	w8, w19, #2
	add	w0, w8, #4
	bl	_palloc
	mov	x20, x0
	mov	x0, x25
	bl	_VARDATA_ANY
	mov	x1, x20
	mov	x2, x19
	bl	_pg_mb2wchar_with_len
	mov	x26, x0
	mov	x0, x22
	bl	_check_replace_text_has_escape_char
	mov	x27, x0
	stur	x25, [x29, #-224]               ; 8-byte Folded Spill
	mov	x0, x25
	bl	_VARDATA_ANY
	mov	x25, x0
	mov	w19, #0
	mov	w28, #0
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	bl	_CHECK_FOR_INTERRUPTS
Lloh8:
	adrp	x8, _REGEXP_REPLACE_BACKREF_CNT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _REGEXP_REPLACE_BACKREF_CNT@GOTPAGEOFF]
Lloh10:
	ldr	w5, [x8]
	mov	x0, x23
	mov	x1, x20
	mov	x2, x26
	mov	x3, x19
	mov	x4, #0
	mov	x6, x24
	mov	w7, #0
	bl	_pg_regexec
Lloh11:
	adrp	x8, _REG_NOMATCH@GOTPAGE
Lloh12:
	ldr	x8, [x8, _REG_NOMATCH@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	cmp	w0, w8
	b.eq	LBB0_11
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x19, x0
Lloh14:
	adrp	x8, _REG_OKAY@GOTPAGE
Lloh15:
	ldr	x8, [x8, _REG_OKAY@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	cmp	w0, w8
	b.eq	LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_1 Depth=1
	bl	_CHECK_FOR_INTERRUPTS
	sub	x2, x29, #188
	mov	x0, x19
	mov	x1, x23
	mov	w3, #100
	bl	_pg_regerror
Lloh17:
	adrp	x8, _ERROR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh19:
	ldr	w19, [x8]
Lloh20:
	adrp	x8, _ERRCODE_INVALID_REGULAR_EXPRESSION@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ERRCODE_INVALID_REGULAR_EXPRESSION@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	bl	_errcode
	sub	x1, x29, #188
Lloh23:
	adrp	x0, l_.str@PAGE
Lloh24:
	add	x0, x0, l_.str@PAGEOFF
	bl	_errmsg
	mov	x1, x0
	mov	x0, x19
	bl	_ereport
LBB0_4:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	w8, [x24]
	sub	w1, w8, w28
	cmp	w1, #1
	b.lt	LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x0, x25
	bl	_charlen_to_bytelen
	mov	x19, x0
	sub	x0, x29, #208
	mov	x1, x25
	mov	x2, x19
	bl	_appendBinaryStringInfo
	add	x25, x25, w19, sxtw
	ldr	w28, [x24]
LBB0_6:                                 ;   in Loop: Header=BB0_1 Depth=1
	sub	x0, x29, #208
	mov	x1, x22
	cbz	w27, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x2, x24
	mov	x3, x25
	mov	x4, x28
	bl	_appendStringInfoRegexpSubstr
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_1 Depth=1
	bl	_appendStringInfoText
LBB0_9:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	w8, [x24, #4]
	sub	w1, w8, w28
	mov	x0, x25
	bl	_charlen_to_bytelen
	add	x25, x25, w0, sxtw
	ldr	w28, [x24, #4]
	cbz	w21, LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_1 Depth=1
	ldr	w8, [x24]
	cmp	w8, w28
	cinc	w19, w28, eq
	cmp	x26, w19, sxtw
	b.hs	LBB0_1
LBB0_11:
	cmp	x26, w28, sxtw
	b.ls	LBB0_13
; %bb.12:
	ldur	x19, [x29, #-224]               ; 8-byte Folded Reload
	mov	x0, x19
	bl	_VARSIZE_ANY
	add	w8, w19, w0
	sub	w2, w8, w25
	sub	x0, x29, #208
	mov	x1, x25
	bl	_appendBinaryStringInfo
LBB0_13:
	ldur	x0, [x29, #-208]
	ldur	w1, [x29, #-200]
	bl	_cstring_to_text_with_len
	mov	x19, x0
	ldur	x0, [x29, #-208]
	bl	_pfree
	mov	x0, x20
	bl	_pfree
	ldur	x8, [x29, #-216]                ; 8-byte Folded Reload
	mov	sp, x8
	ldur	x8, [x29, #-88]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.14:
	mov	x0, x19
	sub	sp, x29, #80
	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
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_REGEXP_REPLACE_BACKREF_CNT,4,2 ; @REGEXP_REPLACE_BACKREF_CNT
	.comm	_REG_NOMATCH,4,2                ; @REG_NOMATCH
	.comm	_REG_OKAY,4,2                   ; @REG_OKAY
	.comm	_ERROR,4,2                      ; @ERROR
	.comm	_ERRCODE_INVALID_REGULAR_EXPRESSION,4,2 ; @ERRCODE_INVALID_REGULAR_EXPRESSION
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"regular expression failed: %s"

.subsections_via_symbols
