	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_foreignscan_references
_set_foreignscan_references:            ## @set_foreignscan_references
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movq	%rsi, %r13
	movq	%rdi, %r15
	movq	32(%rsi), %rax
	testq	%rax, %rax
	jle	LBB0_2
## %bb.1:
	movslq	%r14d, %rcx
	addq	%rcx, %rax
	movq	%rax, 32(%r13)
LBB0_2:
	movq	(%r13), %rdi
	movq	_NIL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rdi
	jne	LBB0_4
## %bb.3:
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	48(%r13), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_fix_scan_list
	movq	%rax, 48(%r13)
	movq	40(%r13), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_fix_scan_list
	movq	%rax, 40(%r13)
	movq	24(%r13), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_fix_scan_list
	movq	%rax, 24(%r13)
	movq	16(%r13), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_fix_scan_list
	movq	%rax, 16(%r13)
	testl	%r14d, %r14d
	jg	LBB0_7
	jmp	LBB0_12
LBB0_4:
	callq	_build_tlist_index
	movq	%rax, %r12
	movq	48(%r13), %rsi
	movq	_INDEX_VAR@GOTPCREL(%rip), %rbx
	movl	(%rbx), %ecx
	movq	%r15, %rdi
	movq	%rax, %rdx
	movl	%r14d, %r8d
	callq	_fix_upper_expr
	movq	%rax, 48(%r13)
	movq	40(%r13), %rsi
	movl	(%rbx), %ecx
	movq	%r15, %rdi
	movq	%r12, %rdx
	movl	%r14d, %r8d
	callq	_fix_upper_expr
	movq	%rax, 40(%r13)
	movq	24(%r13), %rsi
	movl	(%rbx), %ecx
	movq	%r15, %rdi
	movq	%r12, %rdx
	movl	%r14d, %r8d
	callq	_fix_upper_expr
	movq	%rax, 24(%r13)
	movq	16(%r13), %rsi
	movl	(%rbx), %ecx
	movq	%r15, %rdi
	movq	%r12, %rdx
	movl	%r14d, %r8d
	callq	_fix_upper_expr
	movq	%rax, 16(%r13)
	movq	%r12, %rdi
	callq	_pfree
	movq	(%r13), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_fix_scan_list
	movq	%rax, (%r13)
	testl	%r14d, %r14d
	jle	LBB0_12
LBB0_7:
	movq	8(%r13), %rdi
	movl	$-1, %esi
	callq	_bms_next_member
	testl	%eax, %eax
	js	LBB0_8
## %bb.9:
	movl	%eax, %ebx
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	leal	(%rbx,%r14), %esi
	movq	%r15, %rdi
	callq	_bms_add_member
	movq	%rax, %r15
	movq	8(%r13), %rdi
	movl	%ebx, %esi
	callq	_bms_next_member
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_10
	jmp	LBB0_11
LBB0_8:
	xorl	%r15d, %r15d
LBB0_11:
	movq	%r15, 8(%r13)
LBB0_12:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NIL,8,3                        ## @NIL
	.comm	_INDEX_VAR,4,2                  ## @INDEX_VAR
	.no_dead_strip	_set_foreignscan_references
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_foreignscan_references
_set_foreignscan_references:            ; @set_foreignscan_references
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
	ldr	x8, [x1, #32]
	cmp	x8, #1
	b.lt	LBB0_2
; %bb.1:
	add	x8, x8, w20, sxtw
	str	x8, [x19, #32]
LBB0_2:
	ldr	x0, [x19]
Lloh0:
	adrp	x9, _NIL@GOTPAGE
Lloh1:
	ldr	x9, [x9, _NIL@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x0, x9
	ccmp	x8, #0, #4, eq
	b.ne	LBB0_4
; %bb.3:
	bl	_build_tlist_index
	mov	x22, x0
	ldr	x1, [x19, #48]
Lloh3:
	adrp	x23, _INDEX_VAR@GOTPAGE
Lloh4:
	ldr	x23, [x23, _INDEX_VAR@GOTPAGEOFF]
	ldr	w3, [x23]
	mov	x0, x21
	mov	x2, x22
	mov	x4, x20
	bl	_fix_upper_expr
	str	x0, [x19, #48]
	ldr	x1, [x19, #40]
	ldr	w3, [x23]
	mov	x0, x21
	mov	x2, x22
	mov	x4, x20
	bl	_fix_upper_expr
	str	x0, [x19, #40]
	ldr	x1, [x19, #24]
	ldr	w3, [x23]
	mov	x0, x21
	mov	x2, x22
	mov	x4, x20
	bl	_fix_upper_expr
	str	x0, [x19, #24]
	ldr	x1, [x19, #16]
	ldr	w3, [x23]
	mov	x0, x21
	mov	x2, x22
	mov	x4, x20
	bl	_fix_upper_expr
	str	x0, [x19, #16]
	mov	x0, x22
	bl	_pfree
	ldr	x1, [x19]
	mov	x0, x21
	mov	x2, x20
	bl	_fix_scan_list
	str	x0, [x19]
	cmp	w20, #1
	b.ge	LBB0_5
	b	LBB0_10
LBB0_4:
	ldr	x1, [x19, #48]
	mov	x0, x21
	mov	x2, x20
	bl	_fix_scan_list
	str	x0, [x19, #48]
	ldr	x1, [x19, #40]
	mov	x0, x21
	mov	x2, x20
	bl	_fix_scan_list
	str	x0, [x19, #40]
	ldr	x1, [x19, #24]
	mov	x0, x21
	mov	x2, x20
	bl	_fix_scan_list
	str	x0, [x19, #24]
	ldr	x1, [x19, #16]
	mov	x0, x21
	mov	x2, x20
	bl	_fix_scan_list
	str	x0, [x19, #16]
	cmp	w20, #1
	b.lt	LBB0_10
LBB0_5:
	ldr	x0, [x19, #8]
	mov	w1, #-1
	bl	_bms_next_member
	tbnz	w0, #31, LBB0_8
; %bb.6:
	mov	x21, x0
	mov	x22, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	add	w1, w21, w20
	mov	x0, x22
	bl	_bms_add_member
	mov	x22, x0
	ldr	x0, [x19, #8]
	mov	x1, x21
	bl	_bms_next_member
	mov	x21, x0
	tbz	w0, #31, LBB0_7
	b	LBB0_9
LBB0_8:
	mov	x22, #0
LBB0_9:
	str	x22, [x19, #8]
LBB0_10:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_NIL,8,3                        ; @NIL
	.comm	_INDEX_VAR,4,2                  ; @INDEX_VAR
	.no_dead_strip	_set_foreignscan_references
.subsections_via_symbols
