	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function evhttp_handle_request
_evhttp_handle_request:                 ## @evhttp_handle_request
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	%rsi, -32(%rbp)
	movq	$0, 16(%rdi)
	movl	(%rdi), %eax
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	cmpq	$0, 8(%r14)
	je	LBB0_2
## %bb.4:
	movq	%rsi, %rbx
	movl	(%rsi), %edi
	testl	%eax, %edi
	je	LBB0_5
## %bb.6:
	movq	%r14, %rdi
	callq	_evhttp_request_get_host
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	leaq	-32(%rbp), %rsi
	movq	%rbx, %rdi
	movq	%rax, %rdx
	callq	_evhttp_find_vhost
	movq	-32(%rbp), %rbx
LBB0_8:
	addq	$16, %rbx
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_evhttp_dispatch_callback
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	*8(%rax)
	jmp	LBB0_17
LBB0_2:
	movq	_HTTP_BADREQUEST@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %esi
	movq	%r14, %rdi
	xorl	%edx, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_evhttp_send_error              ## TAILCALL
LBB0_5:
	callq	_event_debug
	movq	_HTTP_NOTIMPLEMENTED@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_10:
	movq	-32(%rbp), %rcx
	movq	8(%rcx), %rax
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movl	4(%rcx), %esi
	movq	%r14, %rdi
	callq	*%rax
	jmp	LBB0_17
LBB0_12:
	movq	8(%r14), %rdi
	callq	_evhttp_htmlescape
	testq	%rax, %rax
	je	LBB0_13
## %bb.14:
	movq	%rax, %rbx
	xorl	%eax, %eax
	callq	_evbuffer_new
	testq	%rax, %rax
	je	LBB0_15
## %bb.16:
	movq	%rax, %r15
	movq	_HTTP_NOTFOUND@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r14, %rdi
	callq	_evhttp_response_code_
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	movq	%rbx, %rdx
	callq	_evbuffer_add_printf
	movq	%rbx, %rdi
	callq	_mm_free
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_evhttp_send_page_
	movq	%r15, %rdi
	callq	_evbuffer_free
	jmp	LBB0_17
LBB0_15:
	movq	%rbx, %rdi
	callq	_mm_free
LBB0_13:
	movl	4(%r14), %edi
	callq	_evhttp_connection_free
LBB0_17:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_HTTP_BADREQUEST,4,2            ## @HTTP_BADREQUEST
	.comm	_HTTP_NOTIMPLEMENTED,4,2        ## @HTTP_NOTIMPLEMENTED
	.comm	_HTTP_NOTFOUND,4,2              ## @HTTP_NOTFOUND
	.section	__TEXT,__cstring,cstring_literals
L_.str.1:                               ## @.str.1
	.asciz	"Not Found"

L_.str.2:                               ## @.str.2
	.asciz	"<html><head><title>404 Not Found</title></head><body><h1>Not Found</h1><p>The requested URL %s was not found on this server.</p></body></html>\n"

	.comm	_ERR_FORMAT,4,2                 ## @ERR_FORMAT
	.no_dead_strip	_evhttp_handle_request
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function evhttp_handle_request
_evhttp_handle_request:                 ; @evhttp_handle_request
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	str	x1, [sp, #8]
	str	xzr, [x0, #16]
	ldr	w8, [x0]
	cbz	w8, LBB0_7
; %bb.1:
	ldr	x9, [x19, #8]
	cbz	x9, LBB0_7
; %bb.2:
	mov	x20, x1
	ldr	w0, [x1]
	tst	w0, w8
	b.eq	LBB0_9
; %bb.3:
	mov	x0, x19
	bl	_evhttp_request_get_host
	cbz	x0, LBB0_5
; %bb.4:
	mov	x2, x0
	add	x1, sp, #8
	mov	x0, x20
	bl	_evhttp_find_vhost
	ldr	x20, [sp, #8]
LBB0_5:
	add	x0, x20, #16
	mov	x1, x19
	bl	_evhttp_dispatch_callback
	cbz	x0, LBB0_10
; %bb.6:
	ldr	x8, [x0, #8]
	ldr	w1, [x0]
	b	LBB0_12
LBB0_7:
Lloh0:
	adrp	x8, _HTTP_BADREQUEST@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HTTP_BADREQUEST@GOTPAGEOFF]
LBB0_8:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, #0
	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
	add	sp, sp, #64
	b	_evhttp_send_error
LBB0_9:
	bl	_event_debug
Lloh2:
	adrp	x8, _HTTP_NOTIMPLEMENTED@GOTPAGE
Lloh3:
	ldr	x8, [x8, _HTTP_NOTIMPLEMENTED@GOTPAGEOFF]
	b	LBB0_8
LBB0_10:
	ldr	x9, [sp, #8]
	ldr	x8, [x9, #8]
	cbz	x8, LBB0_14
; %bb.11:
	ldr	w1, [x9, #4]
LBB0_12:
	mov	x0, x19
	blr	x8
LBB0_13:
	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
	add	sp, sp, #64
	ret
LBB0_14:
	ldr	x0, [x19, #8]
	bl	_evhttp_htmlescape
	cbz	x0, LBB0_18
; %bb.15:
	mov	x20, x0
	bl	_evbuffer_new
	cbz	x0, LBB0_17
; %bb.16:
	mov	x21, x0
Lloh4:
	adrp	x8, _HTTP_NOTFOUND@GOTPAGE
Lloh5:
	ldr	x8, [x8, _HTTP_NOTFOUND@GOTPAGEOFF]
Lloh6:
	ldr	w1, [x8]
Lloh7:
	adrp	x2, l_.str.1@PAGE
Lloh8:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_evhttp_response_code_
Lloh9:
	adrp	x1, l_.str.2@PAGE
Lloh10:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x21
                                        ; kill: def $w1 killed $w1 killed $x1
	mov	x2, x20
	bl	_evbuffer_add_printf
	mov	x0, x20
	bl	_mm_free
	mov	x0, x19
	mov	x1, x21
	bl	_evhttp_send_page_
	mov	x0, x21
	bl	_evbuffer_free
	b	LBB0_13
LBB0_17:
	mov	x0, x20
	bl	_mm_free
LBB0_18:
	ldr	w0, [x19, #4]
	bl	_evhttp_connection_free
	b	LBB0_13
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_HTTP_BADREQUEST,4,2            ; @HTTP_BADREQUEST
	.comm	_HTTP_NOTIMPLEMENTED,4,2        ; @HTTP_NOTIMPLEMENTED
	.comm	_HTTP_NOTFOUND,4,2              ; @HTTP_NOTFOUND
	.section	__TEXT,__cstring,cstring_literals
l_.str.1:                               ; @.str.1
	.asciz	"Not Found"

l_.str.2:                               ; @.str.2
	.asciz	"<html><head><title>404 Not Found</title></head><body><h1>Not Found</h1><p>The requested URL %s was not found on this server.</p></body></html>\n"

	.comm	_ERR_FORMAT,4,2                 ; @ERR_FORMAT
	.no_dead_strip	_evhttp_handle_request
.subsections_via_symbols
