	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function brinsummarize
LCPI0_0:
	.quad	0x3ff0000000000000              ## double 1
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_brinsummarize:                         ## @brinsummarize
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, %r14
	movq	%r8, -80(%rbp)                  ## 8-byte Spill
	movl	%ecx, -68(%rbp)                 ## 4-byte Spill
	movl	%edx, %r12d
	movl	%esi, %ebx
	xorl	%r15d, %r15d
	leaq	-48(%rbp), %rsi
	movl	%edi, -60(%rbp)                 ## 4-byte Spill
	xorl	%edx, %edx
	callq	_brinRevmapInitialize
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	%ebx, -64(%rbp)                 ## 4-byte Spill
	movl	%ebx, %edi
	callq	_RelationGetNumberOfBlocks
	movl	%eax, %r13d
	movq	_BRIN_ALL_BLOCKRANGES@GOTPCREL(%rip), %rax
	cmpl	%r12d, (%rax)
	je	LBB0_2
## %bb.1:
	movl	-48(%rbp), %esi
	movl	%r12d, %eax
	cltd
	idivl	%esi
	subl	%edx, %r12d
	addl	%r12d, %esi
	movl	%r13d, %edi
	callq	_Min
	movl	%eax, %r13d
	movl	%r12d, %r15d
LBB0_2:
	cmpl	%r13d, %r15d
	jle	LBB0_4
## %bb.3:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_brinRevmapTerminate
	jmp	LBB0_21
LBB0_4:
	movq	_InvalidBuffer@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	xorl	%ebx, %ebx
	movl	$0, %r12d
	cmpl	%r13d, %r15d
	jge	LBB0_17
## %bb.5:
	xorl	%r12d, %r12d
	xorl	%ebx, %ebx
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_6 Depth=1
	movl	-44(%rbp), %edi
	movq	_BUFFER_LOCK_UNLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_LockBuffer
LBB0_16:                                ##   in Loop: Header=BB0_6 Depth=1
	addl	-48(%rbp), %r15d
	cmpl	%r13d, %r15d
	jge	LBB0_17
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$0, -68(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	-48(%rbp), %eax
	addl	%r15d, %eax
	cmpl	%r13d, %eax
	jg	LBB0_17
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=1
	xorl	%eax, %eax
	callq	_CHECK_FOR_INTERRUPTS
	movq	_BUFFER_LOCK_SHARE@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movq	$0, (%rsp)
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%r15d, %esi
	leaq	-44(%rbp), %rdx
	leaq	-84(%rbp), %rcx
	xorl	%r8d, %r8d
	callq	_brinGetTupleForHeapBlock
	testq	%rax, %rax
	je	LBB0_9
## %bb.13:                              ##   in Loop: Header=BB0_6 Depth=1
	testq	%r14, %r14
	je	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_6 Depth=1
	movsd	(%r14), %xmm0                   ## xmm0 = mem[0],zero
	addsd	LCPI0_0(%rip), %xmm0
	movsd	%xmm0, (%r14)
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_6 Depth=1
	testq	%r12, %r12
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	xorl	%edi, %edi
	testq	%rbx, %rbx
	sete	%dil
	callq	_Assert
	movl	-48(%rbp), %edx
	movl	-60(%rbp), %ebx                 ## 4-byte Reload
	movl	%ebx, %edi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_initialize_brin_buildstate
	movq	%rax, %r12
	movl	%ebx, %edi
	callq	_BuildIndexInfo
	movq	%rax, %rbx
LBB0_11:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	%rbx, %rdi
	movq	%r12, %rsi
	movl	-64(%rbp), %edx                 ## 4-byte Reload
	movl	%r15d, %ecx
	movl	%r13d, %r8d
	callq	_summarize_range
	movl	(%r12), %esi
	movl	4(%r12), %edi
	callq	_brin_memtuple_initialize
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_16
## %bb.12:                              ##   in Loop: Header=BB0_6 Depth=1
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	addsd	LCPI0_0(%rip), %xmm0
	movsd	%xmm0, (%rax)
	jmp	LBB0_16
LBB0_17:
	movl	-44(%rbp), %edi
	callq	_BufferIsValid
	testq	%rax, %rax
	je	LBB0_19
## %bb.18:
	movl	-44(%rbp), %edi
	callq	_ReleaseBuffer
LBB0_19:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_brinRevmapTerminate
	testq	%r12, %r12
	je	LBB0_21
## %bb.20:
	movq	%r12, %rdi
	callq	_terminate_brin_buildstate
	movq	%rbx, %rdi
	callq	_pfree
LBB0_21:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BRIN_ALL_BLOCKRANGES,4,2       ## @BRIN_ALL_BLOCKRANGES
	.comm	_InvalidBuffer,4,2              ## @InvalidBuffer
	.comm	_BUFFER_LOCK_SHARE,4,2          ## @BUFFER_LOCK_SHARE
	.comm	_BUFFER_LOCK_UNLOCK,4,2         ## @BUFFER_LOCK_UNLOCK
	.no_dead_strip	_brinsummarize
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function brinsummarize
_brinsummarize:                         ; @brinsummarize
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	d9, d8, [sp, #16]               ; 16-byte Folded Spill
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset b8, -104
	.cfi_offset b9, -112
	mov	x20, x5
	mov	x21, x4
	mov	x22, x3
	mov	x26, x2
	mov	x23, x1
	add	x1, sp, #12
	str	w0, [sp]                        ; 4-byte Folded Spill
	mov	x2, #0
	bl	_brinRevmapInitialize
	mov	x19, x0
	mov	x0, x23
	bl	_RelationGetNumberOfBlocks
	mov	x25, x0
Lloh0:
	adrp	x8, _BRIN_ALL_BLOCKRANGES@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BRIN_ALL_BLOCKRANGES@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w26
	b.ne	LBB0_15
; %bb.1:
	mov	w26, #0
	cmp	w26, w25
	b.gt	LBB0_16
LBB0_2:
Lloh3:
	adrp	x8, _InvalidBuffer@GOTPAGE
Lloh4:
	ldr	x8, [x8, _InvalidBuffer@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [sp, #8]
	cmp	w26, w25
	b.ge	LBB0_17
; %bb.3:
	mov	x27, #0
	mov	x28, #0
Lloh6:
	adrp	x24, _BUFFER_LOCK_SHARE@GOTPAGE
Lloh7:
	ldr	x24, [x24, _BUFFER_LOCK_SHARE@GOTPAGEOFF]
	fmov	d8, #1.00000000
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	w0, [sp, #8]
Lloh8:
	adrp	x8, _BUFFER_LOCK_UNLOCK@GOTPAGE
Lloh9:
	ldr	x8, [x8, _BUFFER_LOCK_UNLOCK@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	bl	_LockBuffer
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [sp, #12]
	add	w26, w8, w26
	cmp	w26, w25
	b.ge	LBB0_18
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	cbnz	w22, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [sp, #12]
	add	w8, w8, w26
	cmp	w8, w25
	b.gt	LBB0_18
LBB0_8:                                 ;   in Loop: Header=BB0_6 Depth=1
	bl	_CHECK_FOR_INTERRUPTS
	ldr	w5, [x24]
	add	x2, sp, #8
	add	x3, sp, #4
	mov	x0, x19
	mov	x1, x26
	mov	x4, #0
	mov	x6, #0
	bl	_brinGetTupleForHeapBlock
	cbz	x0, LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	cbz	x20, LBB0_4
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	d0, [x20]
	fadd	d0, d0, d8
	str	d0, [x20]
	b	LBB0_4
LBB0_11:                                ;   in Loop: Header=BB0_6 Depth=1
	cbnz	x27, LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_6 Depth=1
	cmp	x28, #0
	cset	w0, eq
	bl	_Assert
	ldr	w2, [sp, #12]
	ldr	w28, [sp]                       ; 4-byte Folded Reload
	mov	x0, x28
	mov	x1, x19
	bl	_initialize_brin_buildstate
	mov	x27, x0
	mov	x0, x28
	bl	_BuildIndexInfo
	mov	x28, x0
LBB0_13:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x28
	mov	x1, x27
	mov	x2, x23
	mov	x3, x26
	mov	x4, x25
	bl	_summarize_range
	ldp	w1, w0, [x27]
	bl	_brin_memtuple_initialize
	cbz	x21, LBB0_5
; %bb.14:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	d0, [x21]
	fadd	d0, d0, d8
	str	d0, [x21]
	b	LBB0_5
LBB0_15:
	ldr	w8, [sp, #12]
	sdiv	w9, w26, w8
	mul	w26, w9, w8
	add	w1, w26, w8
	mov	x0, x25
	bl	_Min
	mov	x25, x0
	cmp	w26, w25
	b.le	LBB0_2
LBB0_16:
	mov	x0, x19
	bl	_brinRevmapTerminate
	b	LBB0_22
LBB0_17:
	mov	x28, #0
	mov	x27, #0
LBB0_18:
	ldr	w0, [sp, #8]
	bl	_BufferIsValid
	cbz	x0, LBB0_20
; %bb.19:
	ldr	w0, [sp, #8]
	bl	_ReleaseBuffer
LBB0_20:
	mov	x0, x19
	bl	_brinRevmapTerminate
	cbz	x27, LBB0_22
; %bb.21:
	mov	x0, x27
	bl	_terminate_brin_buildstate
	mov	x0, x28
	bl	_pfree
LBB0_22:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	ldp	d9, d8, [sp, #16]               ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_BRIN_ALL_BLOCKRANGES,4,2       ; @BRIN_ALL_BLOCKRANGES
	.comm	_InvalidBuffer,4,2              ; @InvalidBuffer
	.comm	_BUFFER_LOCK_SHARE,4,2          ; @BUFFER_LOCK_SHARE
	.comm	_BUFFER_LOCK_UNLOCK,4,2         ; @BUFFER_LOCK_UNLOCK
	.no_dead_strip	_brinsummarize
.subsections_via_symbols
