	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function conn_get_buffer_window
_conn_get_buffer_window:                ## @conn_get_buffer_window
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	8(%rdi), %rax
	movq	16(%rdi), %rsi
	movq	(%rax), %rbx
	movl	24(%rdi), %edi
	callq	_h2o_socket_prepare_for_latency_optimized_write
	movq	8(%r14), %rcx
	movq	8(%rcx), %rcx
	cmpq	%rbx, %rax
	jae	LBB0_2
## %bb.1:
	movq	%rax, %rbx
	cmpq	%rcx, %rax
	jb	LBB0_4
LBB0_2:
	subq	%rcx, %rbx
	movq	_H2O_HTTP2_FRAME_HEADER_SIZE@GOTPCREL(%rip), %rax
	subq	(%rax), %rbx
	jae	LBB0_3
LBB0_4:
	xorl	%eax, %eax
	jmp	LBB0_5
LBB0_3:
	movq	%r14, %rdi
	callq	_h2o_http2_window_get_avail
	cmpq	%rbx, %rax
	cmovaeq	%rbx, %rax
LBB0_5:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_H2O_HTTP2_FRAME_HEADER_SIZE,8,3 ## @H2O_HTTP2_FRAME_HEADER_SIZE
	.no_dead_strip	_conn_get_buffer_window
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function conn_get_buffer_window
_conn_get_buffer_window:                ; @conn_get_buffer_window
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldp	x8, x1, [x0, #8]
	ldr	x20, [x8]
	ldr	w0, [x0, #24]
	bl	_h2o_socket_prepare_for_latency_optimized_write
	ldr	x8, [x19, #8]
	ldr	x8, [x8, #8]
	cmp	x0, x20
	b.hs	LBB0_2
; %bb.1:
	mov	x20, x0
	cmp	x0, x8
	b.lo	LBB0_3
LBB0_2:
Lloh0:
	adrp	x9, _H2O_HTTP2_FRAME_HEADER_SIZE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _H2O_HTTP2_FRAME_HEADER_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	sub	x8, x20, x8
	subs	x20, x8, x9
	b.hs	LBB0_4
LBB0_3:
	mov	x0, #0
	b	LBB0_5
LBB0_4:
	mov	x0, x19
	bl	_h2o_http2_window_get_avail
	cmp	x0, x20
	csel	x0, x0, x20, lo
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_H2O_HTTP2_FRAME_HEADER_SIZE,8,3 ; @H2O_HTTP2_FRAME_HEADER_SIZE
	.no_dead_strip	_conn_get_buffer_window
.subsections_via_symbols
