	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sqlp_wakeup                    ## -- Begin function sqlp_wakeup
	.p2align	4, 0x90
_sqlp_wakeup:                           ## @sqlp_wakeup
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_verbosity@GOTPCREL(%rip), %r12
	cmpl	$2, (%r12)
	jl	LBB0_2
## %bb.1:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	(%rbx), %r15d
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	movl	(%rax), %ecx
	movl	4(%rbx), %r8d
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	movl	%r15d, %edx
	xorl	%eax, %eax
	callq	_fprintf
LBB0_2:
	cmpl	$0, 4(%rbx)
	je	LBB0_3
## %bb.17:
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	cmpl	$128, (%rax)
	jne	LBB0_22
## %bb.18:
	cmpl	$2, (%r12)
	jl	LBB0_20
## %bb.19:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rbx), %edx
	leaq	L_.str.6(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
	jmp	LBB0_20
LBB0_3:
	movq	8(%rbx), %r10
	movq	_conn_wait_net@GOTPCREL(%rip), %r14
	cmpq	(%r14), %r10
	jne	LBB0_5
## %bb.4:
	movq	%r10, %rax
	jmp	LBB0_6
LBB0_5:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	48(%rbx), %ecx
	movl	52(%rbx), %r8d
	movl	40(%rbx), %r9d
	movl	44(%rbx), %r11d
	movl	(%rbx), %edx
	movl	16(%rbx), %r15d
	subq	$8, %rsp
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	pushq	%r10
	pushq	%r15
	pushq	%r11
	callq	_fprintf
	addq	$32, %rsp
	movq	8(%rbx), %rax
	movq	(%r14), %r10
LBB0_6:
	xorl	%edi, %edi
	cmpq	%r10, %rax
	sete	%dil
	callq	_assert
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	movl	(%rax), %eax
	cmpl	$129, %eax
	je	LBB0_11
## %bb.7:
	cmpl	$128, %eax
	jne	LBB0_14
## %bb.8:
	cmpl	$2, (%r12)
	jl	LBB0_10
## %bb.9:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rbx), %edx
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
LBB0_10:
	movq	_query_failed@GOTPCREL(%rip), %rax
	jmp	LBB0_21
LBB0_11:
	cmpl	$0, (%r12)
	jle	LBB0_13
## %bb.12:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rbx), %edx
	leaq	L_.str.3(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
LBB0_13:
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	movl	4(%rax), %r9d
	incl	%r9d
	movl	%r9d, 4(%rax)
	leaq	L_.str.4(%rip), %rcx
	movq	%rbx, %rdi
	movl	$1045, %esi                     ## imm = 0x415
	movl	$28000, %edx                    ## imm = 0x6D60
	movl	$6, %r8d
	callq	_send_error_packet
LBB0_20:
	movq	_query_none@GOTPCREL(%rip), %rax
LBB0_21:
	movl	(%rax), %r14d
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	movl	%r14d, (%rax)
LBB0_22:
	movl	4(%rbx), %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	movl	$-1000, 4(%rbx)                 ## imm = 0xFC18
	movq	_C_REPARSE@GOTPCREL(%rip), %rcx
	movl	16(%rbx), %eax
	orl	(%rcx), %eax
	movl	44(%rbx), %ecx
	movl	%eax, 16(%rbx)
	addl	40(%rbx), %ecx
	jle	LBB0_24
## %bb.23:
	movq	_C_WANTWR@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, 16(%rbx)
LBB0_24:
	movq	_conn_generation@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	incq	%rcx
	movq	%rcx, (%rax)
	movq	%rcx, 32(%rbx)
	movq	$0, 24(%rbx)
	movq	8(%rbx), %rax
	movq	_conn_error@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_26
## %bb.25:
	movq	_conn_expect_query@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 8(%rbx)
LBB0_26:
	movq	%rbx, %rdi
	callq	_clear_connection_timeout
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rbx), %edx
	leaq	L_.str.5(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	movl	$1, %edi
	cmpl	$128, (%rax)
	je	LBB0_16
## %bb.15:
	movq	%rbx, %rdi
	callq	_SQLS_DATA
	xorl	%edi, %edi
	cmpl	$129, (%rax)
	sete	%dil
LBB0_16:
	callq	_assert
	jmp	LBB0_22
	.cfi_endproc
                                        ## -- End function
	.comm	_verbosity,4,2                  ## @verbosity
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"connection %d wakes up, query_state=%d, queries_ok=%d\n"

	.comm	_conn_wait_net,8,3              ## @conn_wait_net
L_.str.1:                               ## @.str.1
	.asciz	"connection %d (IN: %d+%d, OUT: %d+%d, FLAGS: %d) is in state %d, conn_wait_net expected!\n"

L_.str.2:                               ## @.str.2
	.asciz	"connection %d: switching query_state to query_failed\n"

	.comm	_query_failed,4,2               ## @query_failed
L_.str.3:                               ## @.str.3
	.asciz	"connection %d: sending Failed packet because of timeout\n"

L_.str.4:                               ## @.str.4
	.asciz	"Failed"

	.comm	_query_none,8,3                 ## @query_none
L_.str.5:                               ## @.str.5
	.asciz	"connection %d awakened in impossible query_state\n"

L_.str.6:                               ## @.str.6
	.asciz	"connection %d: have ready target, switching query_state from query_wait_target to query_none\n"

	.comm	_C_REPARSE,4,2                  ## @C_REPARSE
	.comm	_C_WANTWR,4,2                   ## @C_WANTWR
	.comm	_conn_generation,8,3            ## @conn_generation
	.comm	_conn_error,8,3                 ## @conn_error
	.comm	_conn_expect_query,8,3          ## @conn_expect_query
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sqlp_wakeup                    ; -- Begin function sqlp_wakeup
	.p2align	2
_sqlp_wakeup:                           ; @sqlp_wakeup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
Lloh0:
	adrp	x22, _verbosity@GOTPAGE
Lloh1:
	ldr	x22, [x22, _verbosity@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w8, #2
	b.lt	LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _stderr@GOTPAGE
Lloh3:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh4:
	ldr	w20, [x8]
	ldr	w21, [x19]
	mov	x0, x19
	bl	_SQLS_DATA
	ldr	w8, [x0]
	ldr	w9, [x19, #4]
	stp	x8, x9, [sp]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x21
	bl	_fprintf
LBB0_2:
	ldr	w8, [x19, #4]
	cbz	w8, LBB0_6
; %bb.3:
	mov	x0, x19
	bl	_SQLS_DATA
	ldr	w8, [x0]
	cmp	w8, #128
	b.ne	LBB0_18
; %bb.4:
	ldr	w8, [x22]
	cmp	w8, #2
	b.lt	LBB0_17
; %bb.5:
Lloh7:
	adrp	x8, _stderr@GOTPAGE
Lloh8:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	ldr	w2, [x19]
Lloh10:
	adrp	x1, l_.str.6@PAGE
Lloh11:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_fprintf
	b	LBB0_17
LBB0_6:
	ldr	x8, [x19, #8]
Lloh12:
	adrp	x20, _conn_wait_net@GOTPAGE
Lloh13:
	ldr	x20, [x20, _conn_wait_net@GOTPAGEOFF]
	ldr	x9, [x20]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.7:
	mov	x9, x8
	b	LBB0_9
LBB0_8:
Lloh14:
	adrp	x9, _stderr@GOTPAGE
Lloh15:
	ldr	x9, [x9, _stderr@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x9]
	ldr	w2, [x19]
	ldp	w9, w10, [x19, #48]
	ldp	w11, w12, [x19, #40]
	ldr	w13, [x19, #16]
	stp	x13, x8, [sp, #32]
	stp	x11, x12, [sp, #16]
	stp	x9, x10, [sp]
Lloh17:
	adrp	x1, l_.str.1@PAGE
Lloh18:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_fprintf
	ldr	x9, [x19, #8]
	ldr	x8, [x20]
LBB0_9:
	cmp	x9, x8
	cset	w0, eq
	bl	_assert
	mov	x0, x19
	bl	_SQLS_DATA
	ldr	w8, [x0]
	cmp	w8, #129
	b.eq	LBB0_14
; %bb.10:
	cmp	w8, #128
	b.ne	LBB0_23
; %bb.11:
	ldr	w8, [x22]
	cmp	w8, #2
	b.lt	LBB0_13
; %bb.12:
Lloh19:
	adrp	x8, _stderr@GOTPAGE
Lloh20:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
	ldr	w2, [x19]
Lloh22:
	adrp	x1, l_.str.2@PAGE
Lloh23:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_fprintf
LBB0_13:
Lloh24:
	adrp	x8, _query_failed@GOTPAGE
Lloh25:
	ldr	x8, [x8, _query_failed@GOTPAGEOFF]
Lloh26:
	ldr	w20, [x8]
	mov	x0, x19
	bl	_SQLS_DATA
	str	w20, [x0]
	b	LBB0_18
LBB0_14:
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_16
; %bb.15:
Lloh27:
	adrp	x8, _stderr@GOTPAGE
Lloh28:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh29:
	ldr	w0, [x8]
	ldr	w2, [x19]
Lloh30:
	adrp	x1, l_.str.3@PAGE
Lloh31:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_fprintf
LBB0_16:
	mov	x0, x19
	bl	_SQLS_DATA
	ldr	w8, [x0, #4]
	add	w5, w8, #1
	str	w5, [x0, #4]
Lloh32:
	adrp	x3, l_.str.4@PAGE
Lloh33:
	add	x3, x3, l_.str.4@PAGEOFF
	mov	x0, x19
	mov	w1, #1045
	mov	w2, #28000
	mov	w4, #6
	bl	_send_error_packet
LBB0_17:
Lloh34:
	adrp	x8, _query_none@GOTPAGE
Lloh35:
	ldr	x8, [x8, _query_none@GOTPAGEOFF]
Lloh36:
	ldr	x20, [x8]
	mov	x0, x19
	bl	_SQLS_DATA
	str	w20, [x0]
LBB0_18:
	ldr	w8, [x19, #4]
	mvn	w8, w8
	lsr	w0, w8, #31
	bl	_assert
	mov	w8, #-1000
	str	w8, [x19, #4]
Lloh37:
	adrp	x8, _C_REPARSE@GOTPAGE
Lloh38:
	ldr	x8, [x8, _C_REPARSE@GOTPAGEOFF]
Lloh39:
	ldr	w8, [x8]
	ldr	w9, [x19, #16]
	orr	w8, w9, w8
	str	w8, [x19, #16]
	ldp	w9, w10, [x19, #40]
	add	w9, w10, w9
	cmp	w9, #1
	b.lt	LBB0_20
; %bb.19:
Lloh40:
	adrp	x9, _C_WANTWR@GOTPAGE
Lloh41:
	ldr	x9, [x9, _C_WANTWR@GOTPAGEOFF]
Lloh42:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x19, #16]
LBB0_20:
Lloh43:
	adrp	x8, _conn_generation@GOTPAGE
Lloh44:
	ldr	x8, [x8, _conn_generation@GOTPAGEOFF]
	ldr	x9, [x8]
	add	x9, x9, #1
	str	x9, [x8]
	stp	xzr, x9, [x19, #24]
	ldr	x8, [x19, #8]
Lloh45:
	adrp	x9, _conn_error@GOTPAGE
Lloh46:
	ldr	x9, [x9, _conn_error@GOTPAGEOFF]
Lloh47:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_22
; %bb.21:
Lloh48:
	adrp	x8, _conn_expect_query@GOTPAGE
Lloh49:
	ldr	x8, [x8, _conn_expect_query@GOTPAGEOFF]
Lloh50:
	ldr	x8, [x8]
	str	x8, [x19, #8]
LBB0_22:
	mov	x0, x19
	bl	_clear_connection_timeout
	mov	w0, #0
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_23:
Lloh51:
	adrp	x8, _stderr@GOTPAGE
Lloh52:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh53:
	ldr	w0, [x8]
	ldr	w2, [x19]
Lloh54:
	adrp	x1, l_.str.5@PAGE
Lloh55:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_fprintf
	mov	x0, x19
	bl	_SQLS_DATA
	ldr	w8, [x0]
	cmp	w8, #128
	b.ne	LBB0_25
; %bb.24:
	mov	w0, #1
	bl	_assert
	b	LBB0_18
LBB0_25:
	mov	x0, x19
	bl	_SQLS_DATA
	ldr	w8, [x0]
	cmp	w8, #129
	cset	w0, eq
	bl	_assert
	b	LBB0_18
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpAdd	Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.cfi_endproc
                                        ; -- End function
	.comm	_verbosity,4,2                  ; @verbosity
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"connection %d wakes up, query_state=%d, queries_ok=%d\n"

	.comm	_conn_wait_net,8,3              ; @conn_wait_net
l_.str.1:                               ; @.str.1
	.asciz	"connection %d (IN: %d+%d, OUT: %d+%d, FLAGS: %d) is in state %d, conn_wait_net expected!\n"

l_.str.2:                               ; @.str.2
	.asciz	"connection %d: switching query_state to query_failed\n"

	.comm	_query_failed,4,2               ; @query_failed
l_.str.3:                               ; @.str.3
	.asciz	"connection %d: sending Failed packet because of timeout\n"

l_.str.4:                               ; @.str.4
	.asciz	"Failed"

	.comm	_query_none,8,3                 ; @query_none
l_.str.5:                               ; @.str.5
	.asciz	"connection %d awakened in impossible query_state\n"

l_.str.6:                               ; @.str.6
	.asciz	"connection %d: have ready target, switching query_state from query_wait_target to query_none\n"

	.comm	_C_REPARSE,4,2                  ; @C_REPARSE
	.comm	_C_WANTWR,4,2                   ; @C_WANTWR
	.comm	_conn_generation,8,3            ; @conn_generation
	.comm	_conn_error,8,3                 ; @conn_error
	.comm	_conn_expect_query,8,3          ; @conn_expect_query
.subsections_via_symbols
