	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function evthread_win32_cond_wait
_evthread_win32_cond_wait:              ## @evthread_win32_cond_wait
	.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	%rsi, %r14
	movq	%rdi, %r12
	movq	_INFINITE@GOTPCREL(%rip), %rax
	testq	%rdx, %rdx
	je	LBB0_1
## %bb.2:
	movq	%rax, %r13
	movq	%rdx, %rdi
	callq	_evutil_tv_to_msec_
	movq	%rax, %rbx
	jmp	LBB0_3
LBB0_1:
	movq	%rax, %r13
	movq	(%rax), %rbx
LBB0_3:
	leaq	16(%r12), %r15
	movq	%r15, %rdi
	callq	_EnterCriticalSection
	incl	24(%r12)
	movl	(%r12), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	%r15, %rdi
	callq	_LeaveCriticalSection
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	callq	_LeaveCriticalSection
	xorl	%eax, %eax
	callq	_GetTickCount
	addq	%rbx, %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_4 Depth=1
	testq	%rax, %rax
	je	LBB0_17
LBB0_18:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	%r15, %rdi
	callq	_LeaveCriticalSection
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	20(%r12), %edi
	movq	%rbx, %rsi
	callq	_WaitForSingleObject
	movq	%rax, %r14
	movq	%r15, %rdi
	callq	_EnterCriticalSection
	movq	8(%r12), %rax
	testq	%rax, %rax
	je	LBB0_10
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	cmpl	%ecx, (%r12)
	jne	LBB0_6
LBB0_10:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	_WAIT_OBJECT_0@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %r14
	jne	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_4 Depth=1
	cmpq	(%r13), %rbx
	je	LBB0_16
## %bb.13:                              ##   in Loop: Header=BB0_4 Depth=1
	xorl	%eax, %eax
	callq	_GetTickCount
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	subq	%rax, %rbx
	jle	LBB0_14
## %bb.15:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	8(%r12), %rax
	jmp	LBB0_16
	.p2align	4, 0x90
LBB0_17:                                ##   in Loop: Header=BB0_4 Depth=1
	movl	20(%r12), %edi
	callq	_ResetEvent
	jmp	LBB0_18
LBB0_11:
	movq	_WAIT_TIMEOUT@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	cmpq	(%rax), %r14
	sete	%cl
	leal	(%rcx,%rcx), %r14d
	decl	%r14d
	jmp	LBB0_7
LBB0_6:
	decq	%rax
	movq	%rax, 8(%r12)
	xorl	%r14d, %r14d
	jmp	LBB0_7
LBB0_14:
	movl	$1, %r14d
LBB0_7:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	decl	24(%r12)
	movq	%r15, %rdi
	callq	_LeaveCriticalSection
	movq	%rbx, %rdi
	callq	_EnterCriticalSection
	movq	%r15, %rdi
	callq	_EnterCriticalSection
	cmpl	$0, 24(%r12)
	jne	LBB0_9
## %bb.8:
	movl	20(%r12), %edi
	callq	_ResetEvent
LBB0_9:
	movq	%r15, %rdi
	callq	_LeaveCriticalSection
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INFINITE,8,3                   ## @INFINITE
	.comm	_WAIT_OBJECT_0,8,3              ## @WAIT_OBJECT_0
	.comm	_WAIT_TIMEOUT,8,3               ## @WAIT_TIMEOUT
	.no_dead_strip	_evthread_win32_cond_wait
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function evthread_win32_cond_wait
_evthread_win32_cond_wait:              ; @evthread_win32_cond_wait
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x24, _INFINITE@GOTPAGE
Lloh1:
	ldr	x24, [x24, _INFINITE@GOTPAGEOFF]
	cbz	x2, LBB0_2
; %bb.1:
	mov	x0, x2
	bl	_evutil_tv_to_msec_
	mov	x22, x0
	b	LBB0_3
LBB0_2:
	ldr	x22, [x24]
LBB0_3:
	add	x21, x19, #16
	mov	x0, x21
	bl	_EnterCriticalSection
	ldr	w8, [x19, #24]
	add	w8, w8, #1
	str	w8, [x19, #24]
	ldr	w25, [x19]
	mov	x0, x21
	bl	_LeaveCriticalSection
	mov	x0, x20
	bl	_LeaveCriticalSection
	bl	_GetTickCount
	add	x26, x0, x22
Lloh2:
	adrp	x27, _WAIT_OBJECT_0@GOTPAGE
Lloh3:
	ldr	x27, [x27, _WAIT_OBJECT_0@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	cbz	x8, LBB0_12
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x21
	bl	_LeaveCriticalSection
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x19, #20]
	mov	x1, x22
	bl	_WaitForSingleObject
	mov	x23, x0
	mov	x0, x21
	bl	_EnterCriticalSection
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w9, [x19]
	cmp	w9, w25
	b.ne	LBB0_14
LBB0_8:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x9, [x27]
	cmp	x23, x9
	b.ne	LBB0_13
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x9, [x24]
	cmp	x22, x9
	b.eq	LBB0_4
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	bl	_GetTickCount
	subs	x22, x26, x0
	b.le	LBB0_15
; %bb.11:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [x19, #8]
	b	LBB0_4
LBB0_12:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w0, [x19, #20]
	bl	_ResetEvent
	b	LBB0_5
LBB0_13:
Lloh4:
	adrp	x8, _WAIT_TIMEOUT@GOTPAGE
Lloh5:
	ldr	x8, [x8, _WAIT_TIMEOUT@GOTPAGEOFF]
Lloh6:
	ldr	x8, [x8]
	cmp	x23, x8
	mov	w8, #1
	cneg	w22, w8, ne
	b	LBB0_16
LBB0_14:
	mov	w22, #0
	sub	x8, x8, #1
	str	x8, [x19, #8]
	b	LBB0_16
LBB0_15:
	mov	w22, #1
LBB0_16:
	ldr	w8, [x19, #24]
	sub	w8, w8, #1
	str	w8, [x19, #24]
	mov	x0, x21
	bl	_LeaveCriticalSection
	mov	x0, x20
	bl	_EnterCriticalSection
	mov	x0, x21
	bl	_EnterCriticalSection
	ldr	w8, [x19, #24]
	cbnz	w8, LBB0_18
; %bb.17:
	ldr	w0, [x19, #20]
	bl	_ResetEvent
LBB0_18:
	mov	x0, x21
	bl	_LeaveCriticalSection
	mov	x0, x22
	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
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_INFINITE,8,3                   ; @INFINITE
	.comm	_WAIT_OBJECT_0,8,3              ; @WAIT_OBJECT_0
	.comm	_WAIT_TIMEOUT,8,3               ; @WAIT_TIMEOUT
	.no_dead_strip	_evthread_win32_cond_wait
.subsections_via_symbols
