	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function test_sendrecv_symmetric_buffers
_test_sendrecv_symmetric_buffers:       ## @test_sendrecv_symmetric_buffers
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r12d
	movq	%rsp, -72(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	%edi, -60(%rbp)
	movl	%edi, %ebx
	shrl	$31, %ebx
	addl	%edi, %ebx
	sarl	%ebx
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r15
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r14
	leaq	-56(%rbp), %rdi
	testl	%r12d, %r12d
	je	LBB0_2
## %bb.1:
	callq	_do_socketpair
	jmp	LBB0_3
LBB0_2:
	callq	_do_socketpair_nonblocking
LBB0_3:
	movl	-56(%rbp), %edi
	movq	_SOL_SOCKET@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_SO_SNDBUF@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-60(%rbp), %r12
	movq	%r12, %rcx
	movl	$4, %r8d
	callq	_setsockopt
	xorl	%edi, %edi
	movl	%eax, %esi
	callq	_ATF_REQUIRE_EQ
	movl	-52(%rbp), %edi
	movl	(%r13), %esi
	movq	_SO_RCVBUF@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rcx
	movl	$4, %r8d
	callq	_setsockopt
	xorl	%edi, %edi
	movl	%eax, %esi
	callq	_ATF_REQUIRE_EQ
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_bzero
	movl	-56(%rbp), %edi
	movq	_MSG_EOR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rsi
	movl	%ebx, %edx
	callq	_send
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_4
LBB0_5:
	leaq	L_.str.2(%rip), %rdx
	movl	%ebx, %edi
	movl	%r15d, %esi
	movl	%ebx, %ecx
	movl	%r15d, %r8d
	callq	_ATF_CHECK_EQ_MSG
	movl	-52(%rbp), %edi
	movq	_MSG_WAITALL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_recv
	movl	%eax, %r14d
	testl	%eax, %eax
	js	LBB0_6
LBB0_7:
	leaq	L_.str.2(%rip), %rdx
	movl	%ebx, %edi
	movl	%r14d, %esi
	movl	%ebx, %ecx
	movl	%r14d, %r8d
	callq	_ATF_CHECK_EQ_MSG
	movl	-56(%rbp), %edi
	callq	_close
	movl	-52(%rbp), %edi
	callq	_close
	movq	-72(%rbp), %rsp                 ## 8-byte Reload
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_9
## %bb.8:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	callq	_test_sendrecv_symmetric_buffers.cold.2
	jmp	LBB0_5
LBB0_6:
	callq	_test_sendrecv_symmetric_buffers.cold.1
	jmp	LBB0_7
LBB0_9:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.p2align	4, 0x90                         ## -- Begin function test_sendrecv_symmetric_buffers.cold.1
_test_sendrecv_symmetric_buffers.cold.1: ## @test_sendrecv_symmetric_buffers.cold.1
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	leaq	L_.str.3(%rip), %rdi
	callq	_perror
	leaq	L_.str.4(%rip), %rdi
	callq	_atf_tc_fail
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.p2align	4, 0x90                         ## -- Begin function test_sendrecv_symmetric_buffers.cold.2
_test_sendrecv_symmetric_buffers.cold.2: ## @test_sendrecv_symmetric_buffers.cold.2
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	leaq	L_.str(%rip), %rdi
	callq	_perror
	leaq	L_.str.1(%rip), %rdi
	callq	_atf_tc_fail
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SOL_SOCKET,4,2                 ## @SOL_SOCKET
	.comm	_SO_SNDBUF,4,2                  ## @SO_SNDBUF
	.comm	_SO_RCVBUF,4,2                  ## @SO_RCVBUF
	.comm	_MSG_EOR,4,2                    ## @MSG_EOR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"send"

L_.str.1:                               ## @.str.1
	.asciz	"send returned < 0"

L_.str.2:                               ## @.str.2
	.asciz	"expected %zd=send(...) but got %zd"

	.comm	_MSG_WAITALL,4,2                ## @MSG_WAITALL
L_.str.3:                               ## @.str.3
	.asciz	"recv"

L_.str.4:                               ## @.str.4
	.asciz	"recv returned < 0"

	.no_dead_strip	_test_sendrecv_symmetric_buffers
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function test_sendrecv_symmetric_buffers
_test_sendrecv_symmetric_buffers:       ; @test_sendrecv_symmetric_buffers
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	sub	sp, sp, #32
	mov	x22, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	stur	w0, [x29, #-68]
	cmp	w0, #0
	cinc	w8, w0, lt
	asr	w19, w8, #1
	mov	x9, x19
Lloh3:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh4:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x19, #15
	and	x12, x9, #0x1fffffff0
	sub	x21, x8, x12
	mov	sp, x21
	mov	x9, x19
Lloh5:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh6:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	sub	x20, x8, x12
	mov	sp, x20
	sub	x0, x29, #64
	cbz	w1, LBB0_2
; %bb.1:
	bl	_do_socketpair
	b	LBB0_3
LBB0_2:
	bl	_do_socketpair_nonblocking
LBB0_3:
	ldur	w0, [x29, #-64]
Lloh7:
	adrp	x23, _SOL_SOCKET@GOTPAGE
Lloh8:
	ldr	x23, [x23, _SOL_SOCKET@GOTPAGEOFF]
	ldr	w1, [x23]
Lloh9:
	adrp	x8, _SO_SNDBUF@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SO_SNDBUF@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	sub	x3, x29, #68
	mov	w4, #4
	bl	_setsockopt
	mov	x1, x0
	mov	w0, #0
	bl	_ATF_REQUIRE_EQ
	ldur	w0, [x29, #-60]
	ldr	w1, [x23]
Lloh12:
	adrp	x8, _SO_RCVBUF@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SO_RCVBUF@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
	sub	x3, x29, #68
	mov	w4, #4
	bl	_setsockopt
	mov	x1, x0
	mov	w0, #0
	bl	_ATF_REQUIRE_EQ
	mov	x0, x21
	mov	x1, x19
	bl	_bzero
	ldur	w0, [x29, #-64]
Lloh15:
	adrp	x8, _MSG_EOR@GOTPAGE
Lloh16:
	ldr	x8, [x8, _MSG_EOR@GOTPAGEOFF]
Lloh17:
	ldr	w3, [x8]
	mov	x1, x21
	mov	x2, x19
	bl	_send
	mov	x21, x0
	tbnz	w0, #31, LBB0_7
LBB0_4:
Lloh18:
	adrp	x2, l_.str.2@PAGE
Lloh19:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, x19
	mov	x1, x21
	mov	x3, x19
	mov	x4, x21
	bl	_ATF_CHECK_EQ_MSG
	ldur	w0, [x29, #-60]
Lloh20:
	adrp	x8, _MSG_WAITALL@GOTPAGE
Lloh21:
	ldr	x8, [x8, _MSG_WAITALL@GOTPAGEOFF]
Lloh22:
	ldr	w3, [x8]
	mov	x1, x20
	mov	x2, x19
	bl	_recv
	mov	x20, x0
	tbnz	w0, #31, LBB0_8
LBB0_5:
Lloh23:
	adrp	x2, l_.str.2@PAGE
Lloh24:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, x19
	mov	x1, x20
	mov	x3, x19
	mov	x4, x20
	bl	_ATF_CHECK_EQ_MSG
	ldur	w0, [x29, #-64]
	bl	_close
	ldur	w0, [x29, #-60]
	bl	_close
	mov	sp, x22
	ldur	x8, [x29, #-56]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_9
; %bb.6:
	sub	sp, x29, #48
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_7:
	bl	_test_sendrecv_symmetric_buffers.cold.2
	b	LBB0_4
LBB0_8:
	bl	_test_sendrecv_symmetric_buffers.cold.1
	b	LBB0_5
LBB0_9:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.p2align	2                               ; -- Begin function test_sendrecv_symmetric_buffers.cold.1
_test_sendrecv_symmetric_buffers.cold.1: ; @test_sendrecv_symmetric_buffers.cold.1
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh28:
	adrp	x0, l_.str.3@PAGE
Lloh29:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_perror
Lloh30:
	adrp	x0, l_.str.4@PAGE
Lloh31:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_atf_tc_fail
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.p2align	2                               ; -- Begin function test_sendrecv_symmetric_buffers.cold.2
_test_sendrecv_symmetric_buffers.cold.2: ; @test_sendrecv_symmetric_buffers.cold.2
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh32:
	adrp	x0, l_.str@PAGE
Lloh33:
	add	x0, x0, l_.str@PAGEOFF
	bl	_perror
Lloh34:
	adrp	x0, l_.str.1@PAGE
Lloh35:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_atf_tc_fail
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpAdd	Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.comm	_SOL_SOCKET,4,2                 ; @SOL_SOCKET
	.comm	_SO_SNDBUF,4,2                  ; @SO_SNDBUF
	.comm	_SO_RCVBUF,4,2                  ; @SO_RCVBUF
	.comm	_MSG_EOR,4,2                    ; @MSG_EOR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"send"

l_.str.1:                               ; @.str.1
	.asciz	"send returned < 0"

l_.str.2:                               ; @.str.2
	.asciz	"expected %zd=send(...) but got %zd"

	.comm	_MSG_WAITALL,4,2                ; @MSG_WAITALL
l_.str.3:                               ; @.str.3
	.asciz	"recv"

l_.str.4:                               ; @.str.4
	.asciz	"recv returned < 0"

	.no_dead_strip	_test_sendrecv_symmetric_buffers
.subsections_via_symbols
