	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function compress_core
_compress_core:                         ## @compress_core
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movq	%rdx, %r14
	movl	%esi, %r12d
	movq	%rdi, %r13
	movslq	8(%rdi), %rbx
	decq	%rbx
	movq	(%rdi), %rax
	movq	16(%rdi), %rcx
	movq	%rbx, %rdx
	shlq	$4, %rdx
	movq	(%rcx,%rdx), %rdx
	cmpq	%rax, %rdx
	jne	LBB0_2
## %bb.1:
	movq	%r13, %rdi
	callq	_expand_buf
	incq	%rbx
	movq	(%r13), %rax
	movq	16(%r13), %rcx
	movq	%rbx, %rdx
	shlq	$4, %rdx
	movq	(%rcx,%rdx), %rdx
LBB0_2:
	shlq	$4, %rbx
	leaq	(,%rdx,4), %rsi
	addq	8(%rcx,%rbx), %rsi
	movq	%rsi, -56(%rbp)
	subq	%rdx, %rax
	movq	%rax, -48(%rbp)
	movl	24(%r13), %edi
	movq	$0, (%rsp)
	leaq	-48(%rbp), %r8
	leaq	-56(%rbp), %r9
	movl	%r12d, %esi
	movq	%r15, %rdx
	movq	%r14, %rcx
	callq	_BrotliEncoderCompressStream
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	callq	_h2o_fatal
LBB0_4:
	movq	(%r13), %rax
	movq	16(%r13), %rcx
	subq	-48(%rbp), %rax
	movq	%rax, (%rcx,%rbx)
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"BrotliEncoderCompressStream"

	.no_dead_strip	_compress_core
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function compress_core
_compress_core:                         ; @compress_core
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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, x3
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	ldrsw	x8, [x0, #8]
	sub	x23, x8, #1
	ldr	x8, [x0, #16]
	lsl	x9, x23, #4
	ldr	x9, [x8, x9]
	ldr	x10, [x0]
	cmp	x9, x10
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_expand_buf
	add	x23, x23, #1
	ldr	x8, [x19, #16]
	lsl	x9, x23, #4
	ldr	x9, [x8, x9]
	ldr	x10, [x19]
LBB0_2:
	add	x8, x8, x23, lsl #4
	ldr	x8, [x8, #8]
	add	x11, x8, x9, lsl #2
	sub	x8, x10, x9
	stp	x8, x11, [sp]
	ldr	w0, [x19, #24]
	mov	x4, sp
	add	x5, sp, #8
	mov	x1, x22
	mov	x2, x20
	mov	x3, x21
	mov	x6, #0
	bl	_BrotliEncoderCompressStream
	cbnz	w0, LBB0_4
; %bb.3:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_h2o_fatal
LBB0_4:
	ldr	x8, [x19]
	ldr	x9, [sp]
	sub	x8, x8, x9
	ldr	x9, [x19, #16]
	lsl	x10, x23, #4
	str	x8, [x9, x10]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"BrotliEncoderCompressStream"

	.no_dead_strip	_compress_core
.subsections_via_symbols
