	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_define_collelem                ## -- Begin function define_collelem
	.p2align	4, 0x90
_define_collelem:                       ## @define_collelem
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	%rsi, %rdi
	callq	_wcslen
	movq	_COLLATE_STR_LEN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jge	LBB0_1
## %bb.3:
	movl	$1, %edi
	movl	$24, %esi
	callq	_calloc
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	%rax, %r12
	movq	%r15, 16(%rax)
	movq	%r14, (%rax)
	movq	_COLL_WEIGHTS_MAX@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_8
## %bb.6:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_new_pri
	movq	8(%r12), %rcx
	movl	%eax, (%rcx,%rbx,4)
	incq	%rbx
	movslq	(%r14), %rax
	cmpq	%rax, %rbx
	jl	LBB0_7
LBB0_8:
	movq	_elem_by_symbol@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	movq	%r14, %rsi
	movq	%r12, %rdx
	callq	_RB_FIND
	testq	%rax, %rax
	jne	LBB0_10
## %bb.9:
	movq	_elem_by_expand@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movq	%r15, %rsi
	movq	%r12, %rdx
	callq	_RB_FIND
	testq	%rax, %rax
	je	LBB0_11
LBB0_10:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_fprintf
	movq	%r12, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_free                           ## TAILCALL
LBB0_1:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_2
LBB0_4:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
LBB0_2:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fprintf                        ## TAILCALL
LBB0_11:
	movl	(%r14), %edi
	movq	%r14, %rsi
	movq	%r12, %rdx
	callq	_RB_INSERT
	movl	(%r15), %edi
	movq	%r15, %rsi
	movq	%r12, %rdx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_RB_INSERT                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_COLLATE_STR_LEN,8,3            ## @COLLATE_STR_LEN
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"expanded collation element too long"

L_.str.1:                               ## @.str.1
	.asciz	"out of memory"

	.comm	_COLL_WEIGHTS_MAX,4,2           ## @COLL_WEIGHTS_MAX
	.comm	_elem_by_symbol,4,2             ## @elem_by_symbol
	.comm	_elem_by_expand,4,2             ## @elem_by_expand
L_.str.2:                               ## @.str.2
	.asciz	"duplicate collating element definition"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_define_collelem                ; -- Begin function define_collelem
	.p2align	2
_define_collelem:                       ; @define_collelem
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x21, x1
	mov	x20, x0
	mov	x0, x1
	bl	_wcslen
Lloh0:
	adrp	x8, _COLLATE_STR_LEN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _COLLATE_STR_LEN@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ge	LBB0_8
; %bb.1:
	mov	w0, #1
	mov	w1, #24
	bl	_calloc
	cbz	x0, LBB0_9
; %bb.2:
	mov	x19, x0
	str	x21, [x0, #16]
	str	x20, [x0]
Lloh3:
	adrp	x20, _COLL_WEIGHTS_MAX@GOTPAGE
Lloh4:
	ldr	x20, [x20, _COLL_WEIGHTS_MAX@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.3:
	mov	x21, #0
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	bl	_new_pri
	ldr	x8, [x19, #8]
	str	w0, [x8, x21, lsl #2]
	add	x21, x21, #1
	ldrsw	x8, [x20]
	cmp	x21, x8
	b.lt	LBB0_4
LBB0_5:
Lloh5:
	adrp	x20, _elem_by_symbol@GOTPAGE
Lloh6:
	ldr	x20, [x20, _elem_by_symbol@GOTPAGEOFF]
	ldr	w0, [x20]
	mov	x1, x20
	mov	x2, x19
	bl	_RB_FIND
	cbnz	x0, LBB0_7
; %bb.6:
Lloh7:
	adrp	x21, _elem_by_expand@GOTPAGE
Lloh8:
	ldr	x21, [x21, _elem_by_expand@GOTPAGEOFF]
	ldr	w0, [x21]
	mov	x1, x21
	mov	x2, x19
	bl	_RB_FIND
	cbz	x0, LBB0_11
LBB0_7:
Lloh9:
	adrp	x8, _stderr@GOTPAGE
Lloh10:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_fprintf
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_free
LBB0_8:
Lloh14:
	adrp	x8, _stderr@GOTPAGE
Lloh15:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
Lloh17:
	adrp	x1, l_.str@PAGE
Lloh18:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_10
LBB0_9:
Lloh19:
	adrp	x8, _stderr@GOTPAGE
Lloh20:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
Lloh22:
	adrp	x1, l_.str.1@PAGE
Lloh23:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_10:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_fprintf
LBB0_11:
	ldr	w0, [x20]
	mov	x1, x20
	mov	x2, x19
	bl	_RB_INSERT
	ldr	w0, [x21]
	mov	x1, x21
	mov	x2, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_RB_INSERT
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_COLLATE_STR_LEN,8,3            ; @COLLATE_STR_LEN
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"expanded collation element too long"

l_.str.1:                               ; @.str.1
	.asciz	"out of memory"

	.comm	_COLL_WEIGHTS_MAX,4,2           ; @COLL_WEIGHTS_MAX
	.comm	_elem_by_symbol,4,2             ; @elem_by_symbol
	.comm	_elem_by_expand,4,2             ; @elem_by_expand
l_.str.2:                               ; @.str.2
	.asciz	"duplicate collating element definition"

.subsections_via_symbols
