	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_uc_sync_recv                   ## -- Begin function uc_sync_recv
	.p2align	4, 0x90
_uc_sync_recv:                          ## @uc_sync_recv
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$16, %rsp
	leaq	L_.str(%rip), %rdi
	callq	_uc_dbgmsg
	movq	_uc_cfg@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rax
	cmpq	$0, 8(%rcx)
	jne	LBB0_2
## %bb.1:
	movq	_SYNC_CLIENT@GOTPCREL(%rip), %rcx
	jmp	LBB0_3
LBB0_2:
	movq	_SYNC_SERVER@GOTPCREL(%rip), %rcx
LBB0_3:
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rax
	movq	_SYNC_RECV@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rax,%rcx,4), %edi
	leaq	-1(%rbp), %rsi
	movl	$1, %edx
	callq	_read
	testl	%eax, %eax
	js	LBB0_6
## %bb.4:
	je	LBB0_7
## %bb.5:
	leaq	L_.str.3(%rip), %rdi
	callq	_uc_dbgmsg
	xorl	%eax, %eax
	jmp	LBB0_9
LBB0_6:
	leaq	L_.str.1(%rip), %rdi
	callq	_uc_logmsg
	jmp	LBB0_8
LBB0_7:
	leaq	L_.str.2(%rip), %rdi
	xorl	%esi, %esi
	callq	_uc_logmsgx
LBB0_8:
	movl	$-1, %eax
LBB0_9:
	addq	$16, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sync: wait"

	.comm	_uc_cfg,16,3                    ## @uc_cfg
	.comm	_SYNC_SERVER,8,3                ## @SYNC_SERVER
	.comm	_SYNC_CLIENT,8,3                ## @SYNC_CLIENT
	.comm	_SYNC_RECV,8,3                  ## @SYNC_RECV
L_.str.1:                               ## @.str.1
	.asciz	"sync_recv: read"

L_.str.2:                               ## @.str.2
	.asciz	"sync_recv: read %zd of 1 byte"

L_.str.3:                               ## @.str.3
	.asciz	"sync: received"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_uc_sync_recv                   ; -- Begin function uc_sync_recv
	.p2align	2
_uc_sync_recv:                          ; @uc_sync_recv
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #32
	.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
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_uc_dbgmsg
Lloh2:
	adrp	x8, _uc_cfg@GOTPAGE
Lloh3:
	ldr	x8, [x8, _uc_cfg@GOTPAGEOFF]
Lloh4:
	adrp	x9, _SYNC_SERVER@GOTPAGE
Lloh5:
	ldr	x9, [x9, _SYNC_SERVER@GOTPAGEOFF]
Lloh6:
	adrp	x10, _SYNC_CLIENT@GOTPAGE
Lloh7:
	ldr	x10, [x10, _SYNC_CLIENT@GOTPAGEOFF]
	ldp	x11, x8, [x8]
	cmp	x8, #0
	csel	x8, x10, x9, eq
	ldr	x8, [x8]
	ldr	x8, [x11, x8, lsl #3]
Lloh8:
	adrp	x9, _SYNC_RECV@GOTPAGE
Lloh9:
	ldr	x9, [x9, _SYNC_RECV@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	ldr	w0, [x8, x9, lsl #2]
	sub	x1, x29, #1
	mov	w2, #1
	bl	_read
	tbnz	w0, #31, LBB0_3
; %bb.1:
	cbz	w0, LBB0_4
; %bb.2:
Lloh11:
	adrp	x0, l_.str.3@PAGE
Lloh12:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_uc_dbgmsg
	mov	w0, #0
	b	LBB0_6
LBB0_3:
Lloh13:
	adrp	x0, l_.str.1@PAGE
Lloh14:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_uc_logmsg
	b	LBB0_5
LBB0_4:
Lloh15:
	adrp	x0, l_.str.2@PAGE
Lloh16:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	w1, #0
	bl	_uc_logmsgx
LBB0_5:
	mov	w0, #-1
LBB0_6:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #32
	ret
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sync: wait"

	.comm	_uc_cfg,16,3                    ; @uc_cfg
	.comm	_SYNC_SERVER,8,3                ; @SYNC_SERVER
	.comm	_SYNC_CLIENT,8,3                ; @SYNC_CLIENT
	.comm	_SYNC_RECV,8,3                  ; @SYNC_RECV
l_.str.1:                               ; @.str.1
	.asciz	"sync_recv: read"

l_.str.2:                               ; @.str.2
	.asciz	"sync_recv: read %zd of 1 byte"

l_.str.3:                               ; @.str.3
	.asciz	"sync: received"

.subsections_via_symbols
