	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function build_master_stree_branch
_build_master_stree_branch:             ## @build_master_stree_branch
	.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
                                        ## kill: def $esi killed $esi def $rsi
	movq	%rdi, %r12
	cmpl	$2, %esi
	je	LBB0_5
## %bb.1:
	cmpl	$1, %esi
	je	LBB0_4
## %bb.2:
	testl	%esi, %esi
	jne	LBB0_39
## %bb.3:
	movq	16(%r12), %rcx
	movq	%r12, %rax
	jmp	LBB0_6
LBB0_5:
	leaq	8(%r12), %rax
	movq	16(%r12), %rcx
	addq	$8, %rcx
	jmp	LBB0_6
LBB0_4:
	leaq	4(%r12), %rax
	movq	16(%r12), %rcx
	addq	$4, %rcx
LBB0_6:
	movl	(%rcx), %ebx
	movl	(%rax), %r14d
	leal	(%rsi,%rsi), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	leal	1(%rsi,%rsi), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movb	$1, %al
	movq	%r12, %r15
	movb	$1, %cl
	testl	%r14d, %r14d
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_10
## %bb.7:
	movq	%r12, %rbx
	movl	%r14d, %r13d
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	movl	$-1, %edx
	callq	_ring_next_sw
	testq	%rax, %rax
	je	LBB0_9
## %bb.12:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_sw_in_master_stree
	testl	%eax, %eax
	jne	LBB0_9
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	callq	_grow_master_stree_branch
	movq	%r15, %rbx
	decl	%r13d
	jne	LBB0_8
## %bb.14:
	movb	$1, %cl
	jmp	LBB0_15
LBB0_9:
	xorl	%r15d, %r15d
	xorl	%ecx, %ecx
LBB0_15:
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movb	$1, %al
LBB0_10:
	leal	-1(%rbx), %r13d
	cmpl	%r13d, %r14d
	jae	LBB0_11
## %bb.16:
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	movl	$1, %edx
	callq	_ring_next_sw
	testq	%rax, %rax
	je	LBB0_18
## %bb.19:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_sw_in_master_stree
	testl	%eax, %eax
	jne	LBB0_18
## %bb.20:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_grow_master_stree_branch
	incl	%r14d
	movq	%rbx, %r12
	cmpl	%r13d, %r14d
	jb	LBB0_17
## %bb.21:
	movq	%rbx, %r12
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movb	$1, %al
	jmp	LBB0_22
LBB0_11:
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_23
LBB0_18:
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
LBB0_22:
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
LBB0_23:
	andb	%al, %cl
	cmpb	$1, %cl
	je	LBB0_39
## %bb.24:
	testl	%ebx, %ebx
	jne	LBB0_25
LBB0_39:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_35:                                ##   in Loop: Header=BB0_25 Depth=1
	movq	%r12, %rdi
	movq	%r13, %rsi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_grow_master_stree_branch
	.p2align	4, 0x90
LBB0_38:                                ##   in Loop: Header=BB0_25 Depth=1
	movq	%r13, %r12
	decl	%ebx
	je	LBB0_39
LBB0_25:                                ## =>This Inner Loop Header: Depth=1
	testq	%r15, %r15
	jne	LBB0_27
## %bb.26:                              ##   in Loop: Header=BB0_25 Depth=1
	xorl	%r15d, %r15d
	testq	%r12, %r12
	jne	LBB0_33
	jmp	LBB0_36
	.p2align	4, 0x90
LBB0_27:                                ##   in Loop: Header=BB0_25 Depth=1
	movq	%rbx, %r13
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	$-1, %edx
	callq	_ring_next_sw
	testq	%rax, %rax
	je	LBB0_28
## %bb.29:                              ##   in Loop: Header=BB0_25 Depth=1
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_sw_in_master_stree
	testl	%eax, %eax
	je	LBB0_30
LBB0_28:                                ##   in Loop: Header=BB0_25 Depth=1
	xorl	%r15d, %r15d
	jmp	LBB0_31
LBB0_30:                                ##   in Loop: Header=BB0_25 Depth=1
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	callq	_grow_master_stree_branch
	movq	%rbx, %r15
LBB0_31:                                ##   in Loop: Header=BB0_25 Depth=1
	movq	%r13, %rbx
	testq	%r12, %r12
	je	LBB0_36
LBB0_33:                                ##   in Loop: Header=BB0_25 Depth=1
	movq	%r12, %rdi
	movl	%r14d, %esi
	movl	$1, %edx
	callq	_ring_next_sw
	testq	%rax, %rax
	je	LBB0_36
## %bb.34:                              ##   in Loop: Header=BB0_25 Depth=1
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_sw_in_master_stree
	testl	%eax, %eax
	je	LBB0_35
LBB0_36:                                ##   in Loop: Header=BB0_25 Depth=1
	testq	%r15, %r15
	je	LBB0_39
## %bb.37:                              ##   in Loop: Header=BB0_25 Depth=1
	xorl	%r13d, %r13d
	jmp	LBB0_38
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_build_master_stree_branch
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function build_master_stree_branch
_build_master_stree_branch:             ; @build_master_stree_branch
	.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	x21, x0
	cmp	w1, #2
	b.eq	LBB0_4
; %bb.1:
	cmp	w19, #1
	b.eq	LBB0_5
; %bb.2:
	cbnz	w19, LBB0_24
; %bb.3:
	ldr	x9, [x21, #16]
	mov	x8, x21
	b	LBB0_6
LBB0_4:
	add	x8, x21, #8
	ldr	x9, [x21, #16]
	add	x9, x9, #8
	b	LBB0_6
LBB0_5:
	add	x8, x21, #4
	ldr	x9, [x21, #16]
	add	x9, x9, #4
LBB0_6:
	ldr	w25, [x9]
	ldr	w26, [x8]
	lsl	w20, w19, #1
	mov	w27, #1
	mov	w22, #1
	bfi	w22, w19, #1, #31
	cbz	w26, LBB0_12
; %bb.7:
	mov	x24, x21
	mov	x27, x26
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x24
	mov	x1, x19
	mov	w2, #-1
	bl	_ring_next_sw
	mov	x23, x0
	cbz	x0, LBB0_14
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x23
	bl	_sw_in_master_stree
	cbnz	w0, LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x24
	mov	x1, x23
	mov	x2, x22
	mov	x3, x20
	bl	_grow_master_stree_branch
	mov	x24, x23
	subs	w27, w27, #1
	b.ne	LBB0_8
; %bb.11:
	mov	w27, #1
	b	LBB0_15
LBB0_12:
	mov	x23, x21
	b	LBB0_15
LBB0_13:
	mov	x23, #0
LBB0_14:
	mov	w27, #0
LBB0_15:
	sub	w28, w25, #1
	cmp	w26, w28
	b.hs	LBB0_20
LBB0_16:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	mov	x1, x19
	mov	w2, #1
	bl	_ring_next_sw
	cbz	x0, LBB0_21
; %bb.17:                               ;   in Loop: Header=BB0_16 Depth=1
	mov	x24, x0
	bl	_sw_in_master_stree
	cbnz	w0, LBB0_21
; %bb.18:                               ;   in Loop: Header=BB0_16 Depth=1
	mov	x0, x21
	mov	x1, x24
	mov	x2, x20
	mov	x3, x22
	bl	_grow_master_stree_branch
	add	w26, w26, #1
	mov	x21, x24
	cmp	w26, w28
	b.lo	LBB0_16
; %bb.19:
	mov	w8, #1
	mov	x21, x24
	b	LBB0_22
LBB0_20:
	mov	w8, #1
	b	LBB0_22
LBB0_21:
	mov	x21, #0
	mov	w8, #0
LBB0_22:
	and	w8, w27, w8
	cmp	w8, #1
	b.eq	LBB0_24
; %bb.23:
	cbnz	w25, LBB0_27
LBB0_24:
	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_25:                                ;   in Loop: Header=BB0_27 Depth=1
	mov	x0, x21
	mov	x1, x24
	mov	x2, x20
	mov	x3, x22
	bl	_grow_master_stree_branch
LBB0_26:                                ;   in Loop: Header=BB0_27 Depth=1
	mov	x21, x24
	subs	w25, w25, #1
	b.eq	LBB0_24
LBB0_27:                                ; =>This Inner Loop Header: Depth=1
	cbz	x23, LBB0_31
; %bb.28:                               ;   in Loop: Header=BB0_27 Depth=1
	mov	x0, x23
	mov	x1, x19
	mov	w2, #-1
	bl	_ring_next_sw
	cbz	x0, LBB0_30
; %bb.29:                               ;   in Loop: Header=BB0_27 Depth=1
	mov	x24, x0
	bl	_sw_in_master_stree
	cbz	w0, LBB0_36
LBB0_30:                                ;   in Loop: Header=BB0_27 Depth=1
	mov	x23, #0
LBB0_31:                                ;   in Loop: Header=BB0_27 Depth=1
	cbz	x21, LBB0_34
LBB0_32:                                ;   in Loop: Header=BB0_27 Depth=1
	mov	x0, x21
	mov	x1, x19
	mov	w2, #1
	bl	_ring_next_sw
	cbz	x0, LBB0_34
; %bb.33:                               ;   in Loop: Header=BB0_27 Depth=1
	mov	x24, x0
	bl	_sw_in_master_stree
	cbz	w0, LBB0_25
LBB0_34:                                ;   in Loop: Header=BB0_27 Depth=1
	cbz	x23, LBB0_24
; %bb.35:                               ;   in Loop: Header=BB0_27 Depth=1
	mov	x24, #0
	b	LBB0_26
LBB0_36:                                ;   in Loop: Header=BB0_27 Depth=1
	mov	x0, x23
	mov	x1, x24
	mov	x2, x22
	mov	x3, x20
	bl	_grow_master_stree_branch
	mov	x23, x24
	cbnz	x21, LBB0_32
	b	LBB0_34
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_build_master_stree_branch
.subsections_via_symbols
