	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_add_child_join_rel_equivalences ## -- Begin function add_child_join_rel_equivalences
	.p2align	4, 0x90
_add_child_join_rel_equivalences:       ## @add_child_join_rel_equivalences
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %rbx
	movq	%rdx, -88(%rbp)                 ## 8-byte Spill
	movl	%esi, -76(%rbp)                 ## 4-byte Spill
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movl	8(%r8), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	12(%r8), %r14d
	movq	%r8, %rdi
	callq	_IS_JOIN_REL
	testq	%rax, %rax
	movq	%rbx, -96(%rbp)                 ## 8-byte Spill
	je	LBB0_1
## %bb.2:
	movq	%rbx, %rdi
	callq	_IS_JOIN_REL
	xorl	%edi, %edi
	testq	%rax, %rax
	setne	%dil
	jmp	LBB0_3
LBB0_1:
	xorl	%edi, %edi
LBB0_3:
	callq	_Assert
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	movl	%r14d, %esi
	callq	_get_eclass_indexes_for_relids
	movq	%rax, -104(%rbp)                ## 8-byte Spill
	movq	%rax, %rdi
	movl	$-1, %esi
	callq	_bms_next_member
	testl	%eax, %eax
	js	LBB0_21
## %bb.4:
	movl	%eax, %r12d
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_20:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	-104(%rbp), %rdi                ## 8-byte Reload
	movl	%r12d, %esi
	callq	_bms_next_member
	movl	%eax, %r12d
	testl	%eax, %eax
	js	LBB0_21
LBB0_5:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movl	%r12d, %esi
	callq	_list_nth
	cmpq	$0, 8(%rax)
	jne	LBB0_20
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	%rax, %r13
	movl	4(%rax), %esi
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	callq	_bms_overlap
	movl	%eax, %edi
	callq	_Assert
	movl	(%r13), %edi
	callq	_list_length
	testl	%eax, %eax
	jle	LBB0_20
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	%eax, %r15d
	xorl	%ebx, %ebx
	jmp	LBB0_8
LBB0_17:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	-60(%rbp), %esi                 ## 4-byte Reload
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_adjust_child_relids_multilevel
	movl	%eax, %ecx
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movl	-64(%rbp), %edx                 ## 4-byte Reload
LBB0_18:                                ##   in Loop: Header=BB0_8 Depth=2
	movl	(%r14), %r9d
	movq	%r13, %rdi
	movl	$1, %r8d
	callq	_add_eq_member
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_8 Depth=2
	incl	%ebx
	cmpl	%ebx, %r15d
	je	LBB0_20
LBB0_8:                                 ##   Parent Loop BB0_5 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r13), %edi
	movl	%ebx, %esi
	callq	_list_nth
	cmpq	$0, 32(%rax)
	jne	LBB0_19
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=2
	movq	%rax, %r14
	cmpq	$0, 24(%rax)
	jne	LBB0_19
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=2
	movl	8(%r14), %edi
	callq	_bms_membership
	movq	_BMS_MULTIPLE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_19
## %bb.11:                              ##   in Loop: Header=BB0_8 Depth=2
	movl	8(%r14), %edi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	callq	_bms_overlap
	testl	%eax, %eax
	je	LBB0_19
## %bb.12:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	-96(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	_RELOPT_JOINREL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	16(%r14), %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	-76(%rbp), %edx                 ## 4-byte Reload
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	callq	_adjust_appendrel_attrs
	jmp	LBB0_15
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=2
	xorl	%edi, %edi
	movq	_RELOPT_OTHER_JOINREL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_Assert
	movq	16(%r14), %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_adjust_appendrel_attrs_multilevel
LBB0_15:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	8(%r14), %edi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	callq	_bms_difference
	movl	%eax, %edi
	movl	-48(%rbp), %esi                 ## 4-byte Reload
	callq	_bms_add_members
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	movl	4(%r14), %edi
	movl	%edi, -60(%rbp)                 ## 4-byte Spill
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	callq	_bms_overlap
	testl	%eax, %eax
	jne	LBB0_17
## %bb.16:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movl	-64(%rbp), %edx                 ## 4-byte Reload
	movl	-60(%rbp), %ecx                 ## 4-byte Reload
	jmp	LBB0_18
LBB0_21:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BMS_MULTIPLE,8,3               ## @BMS_MULTIPLE
	.comm	_RELOPT_JOINREL,8,3             ## @RELOPT_JOINREL
	.comm	_RELOPT_OTHER_JOINREL,8,3       ## @RELOPT_OTHER_JOINREL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_add_child_join_rel_equivalences ; -- Begin function add_child_join_rel_equivalences
	.p2align	2
_add_child_join_rel_equivalences:       ; @add_child_join_rel_equivalences
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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, x3
	str	x2, [sp, #8]                    ; 8-byte Folded Spill
	str	w1, [sp, #4]                    ; 4-byte Folded Spill
	mov	x22, x0
	ldp	w24, w23, [x4, #8]
	mov	x0, x4
	bl	_IS_JOIN_REL
	cbz	x0, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_IS_JOIN_REL
	cmp	x0, #0
	cset	w0, ne
LBB0_2:
	bl	_Assert
	mov	x0, x22
	mov	x1, x23
	bl	_get_eclass_indexes_for_relids
	mov	x25, x0
	mov	w1, #-1
	bl	_bms_next_member
	tbnz	w0, #31, LBB0_19
; %bb.3:
	mov	x26, x0
	str	w24, [sp, #28]                  ; 4-byte Folded Spill
	stp	x19, x22, [sp, #32]             ; 16-byte Folded Spill
	str	x25, [sp, #16]                  ; 8-byte Folded Spill
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x25
	mov	x1, x26
	bl	_bms_next_member
	mov	x26, x0
	tbnz	w0, #31, LBB0_19
LBB0_5:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
	ldr	w0, [x22]
	mov	x1, x26
	bl	_list_nth
	ldr	x8, [x0, #8]
	cbnz	x8, LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x27, x0
	ldr	w1, [x0, #4]
	mov	x0, x23
	bl	_bms_overlap
	bl	_Assert
	ldr	w0, [x27]
	bl	_list_length
	cmp	w0, #1
	b.lt	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x28, x0
	mov	w20, #0
	b	LBB0_10
LBB0_8:                                 ;   in Loop: Header=BB0_10 Depth=2
	ldr	w5, [x21]
	mov	x0, x27
	mov	x1, x19
	mov	x2, x22
	mov	x3, x25
	mov	w4, #1
	bl	_add_eq_member
	ldp	x19, x22, [sp, #32]             ; 16-byte Folded Reload
	ldr	w24, [sp, #28]                  ; 4-byte Folded Reload
	ldr	x25, [sp, #16]                  ; 8-byte Folded Reload
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=2
	add	w20, w20, #1
	cmp	w28, w20
	b.eq	LBB0_4
LBB0_10:                                ;   Parent Loop BB0_5 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w0, [x27]
	mov	x1, x20
	bl	_list_nth
	ldr	x8, [x0, #32]
	cbnz	x8, LBB0_9
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	mov	x21, x0
	ldr	x8, [x0, #24]
	cbnz	x8, LBB0_9
; %bb.12:                               ;   in Loop: Header=BB0_10 Depth=2
	ldr	w0, [x21, #8]
	bl	_bms_membership
Lloh0:
	adrp	x8, _BMS_MULTIPLE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BMS_MULTIPLE@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_9
; %bb.13:                               ;   in Loop: Header=BB0_10 Depth=2
	ldr	w0, [x21, #8]
	mov	x1, x23
	bl	_bms_overlap
	cbz	w0, LBB0_9
; %bb.14:                               ;   in Loop: Header=BB0_10 Depth=2
	ldr	x8, [x19]
Lloh3:
	adrp	x9, _RELOPT_JOINREL@GOTPAGE
Lloh4:
	ldr	x9, [x9, _RELOPT_JOINREL@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_16
; %bb.15:                               ;   in Loop: Header=BB0_10 Depth=2
	ldr	x1, [x21, #16]
	mov	x0, x22
	ldr	w2, [sp, #4]                    ; 4-byte Folded Reload
	ldr	x3, [sp, #8]                    ; 8-byte Folded Reload
	bl	_adjust_appendrel_attrs
	b	LBB0_17
LBB0_16:                                ;   in Loop: Header=BB0_10 Depth=2
Lloh6:
	adrp	x9, _RELOPT_OTHER_JOINREL@GOTPAGE
Lloh7:
	ldr	x9, [x9, _RELOPT_OTHER_JOINREL@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_Assert
	ldr	x1, [x21, #16]
	mov	x0, x22
	mov	x2, x24
	mov	x3, x23
	bl	_adjust_appendrel_attrs_multilevel
LBB0_17:                                ;   in Loop: Header=BB0_10 Depth=2
	mov	x19, x0
	ldr	w0, [x21, #8]
	mov	x1, x23
	bl	_bms_difference
	mov	x1, x24
	bl	_bms_add_members
	mov	x22, x0
	ldr	w25, [x21, #4]
	mov	x0, x25
	mov	x1, x23
	bl	_bms_overlap
	cbz	w0, LBB0_8
; %bb.18:                               ;   in Loop: Header=BB0_10 Depth=2
	ldr	x0, [sp, #40]                   ; 8-byte Folded Reload
	mov	x1, x25
	mov	x2, x24
	mov	x3, x23
	bl	_adjust_child_relids_multilevel
	mov	x25, x0
	b	LBB0_8
LBB0_19:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_BMS_MULTIPLE,8,3               ; @BMS_MULTIPLE
	.comm	_RELOPT_JOINREL,8,3             ; @RELOPT_JOINREL
	.comm	_RELOPT_OTHER_JOINREL,8,3       ; @RELOPT_OTHER_JOINREL
.subsections_via_symbols
