	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function test_bio_rdonly_mem_buf
_test_bio_rdonly_mem_buf:               ## @test_bio_rdonly_mem_buf
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	leaq	L_.str(%rip), %rdi
	movl	$12, %esi
	callq	_BIO_new_mem_buf
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_TEST_ptr
	testl	%eax, %eax
	je	LBB0_10
## %bb.1:
	leaq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	movl	$5, %edx
	callq	_BIO_read
	movl	%eax, %edi
	movl	$5, %esi
	callq	_TEST_int_eq
	testl	%eax, %eax
	je	LBB0_10
## %bb.2:
	leaq	L_.str.1(%rip), %rdx
	leaq	-48(%rbp), %rdi
	movl	$5, %esi
	movl	$5, %ecx
	callq	_TEST_mem_eq
	testl	%eax, %eax
	je	LBB0_10
## %bb.3:
	leaq	-56(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_BIO_get_mem_ptr
	xorl	%r14d, %r14d
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_TEST_int_gt
	testl	%eax, %eax
	je	LBB0_11
## %bb.4:
	movq	_BIO_NOCLOSE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_BIO_set_close
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_BIO_s_mem
	movl	%eax, %edi
	callq	_BIO_new
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_TEST_ptr
	testl	%eax, %eax
	je	LBB0_12
## %bb.5:
	movq	-56(%rbp), %rsi
	movq	_BIO_CLOSE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	callq	_BIO_set_mem_buf
	movq	_BIO_FLAGS_MEM_RDONLY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_BIO_set_flags
	leaq	-48(%rbp), %rsi
	movq	%r15, %rdi
	movl	$16, %edx
	callq	_BIO_read
	movl	%eax, %edi
	movl	$7, %esi
	callq	_TEST_int_eq
	testl	%eax, %eax
	je	LBB0_12
## %bb.6:
	leaq	L_.str.2(%rip), %rdx
	leaq	-48(%rbp), %rdi
	movl	$7, %esi
	movl	$7, %ecx
	callq	_TEST_mem_eq
	testl	%eax, %eax
	je	LBB0_12
## %bb.7:
	movq	%r15, %rdi
	callq	_BIO_reset
	xorl	%r14d, %r14d
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_TEST_int_gt
	testl	%eax, %eax
	je	LBB0_12
## %bb.8:
	leaq	-48(%rbp), %rsi
	movq	%r15, %rdi
	movl	$16, %edx
	callq	_BIO_read
	movl	%eax, %edi
	movl	$7, %esi
	callq	_TEST_int_eq
	testl	%eax, %eax
	je	LBB0_12
## %bb.9:
	leaq	L_.str.2(%rip), %rdx
	leaq	-48(%rbp), %rdi
	movl	$7, %esi
	movl	$7, %ecx
	callq	_TEST_mem_eq
	xorl	%r14d, %r14d
	testl	%eax, %eax
	setne	%r14b
	jmp	LBB0_12
LBB0_10:
	xorl	%r14d, %r14d
LBB0_11:
	xorl	%r15d, %r15d
LBB0_12:
	movq	%rbx, %rdi
	callq	_BIO_free
	movq	%r15, %rdi
	callq	_BIO_free
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_15
## %bb.13:
	movl	%r14d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Hello World\n"

L_.str.1:                               ## @.str.1
	.asciz	"Hello"

	.comm	_BIO_NOCLOSE,4,2                ## @BIO_NOCLOSE
	.comm	_BIO_CLOSE,4,2                  ## @BIO_CLOSE
	.comm	_BIO_FLAGS_MEM_RDONLY,4,2       ## @BIO_FLAGS_MEM_RDONLY
L_.str.2:                               ## @.str.2
	.asciz	" World\n"

	.no_dead_strip	_test_bio_rdonly_mem_buf
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function test_bio_rdonly_mem_buf
_test_bio_rdonly_mem_buf:               ; @test_bio_rdonly_mem_buf
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	mov	w1, #12
	bl	_BIO_new_mem_buf
	mov	x19, x0
	bl	_TEST_ptr
	cbz	w0, LBB0_10
; %bb.1:
	add	x1, sp, #8
	mov	x0, x19
	mov	w2, #5
	bl	_BIO_read
	mov	w1, #5
	bl	_TEST_int_eq
	cbz	w0, LBB0_10
; %bb.2:
Lloh5:
	adrp	x2, l_.str.1@PAGE
Lloh6:
	add	x2, x2, l_.str.1@PAGEOFF
	add	x0, sp, #8
	mov	w1, #5
	mov	w3, #5
	bl	_TEST_mem_eq
	cbz	w0, LBB0_10
; %bb.3:
	mov	x1, sp
	mov	x0, x19
	bl	_BIO_get_mem_ptr
	mov	w1, #0
	bl	_TEST_int_gt
	cbz	w0, LBB0_10
; %bb.4:
Lloh7:
	adrp	x8, _BIO_NOCLOSE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _BIO_NOCLOSE@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_BIO_set_close
	bl	_BIO_s_mem
	bl	_BIO_new
	mov	x20, x0
	bl	_TEST_ptr
	cbz	w0, LBB0_13
; %bb.5:
	ldr	x1, [sp]
Lloh10:
	adrp	x8, _BIO_CLOSE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _BIO_CLOSE@GOTPAGEOFF]
Lloh12:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_BIO_set_mem_buf
Lloh13:
	adrp	x8, _BIO_FLAGS_MEM_RDONLY@GOTPAGE
Lloh14:
	ldr	x8, [x8, _BIO_FLAGS_MEM_RDONLY@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_BIO_set_flags
	add	x1, sp, #8
	mov	x0, x20
	mov	w2, #16
	bl	_BIO_read
	mov	w1, #7
	bl	_TEST_int_eq
	cbz	w0, LBB0_13
; %bb.6:
Lloh16:
	adrp	x2, l_.str.2@PAGE
Lloh17:
	add	x2, x2, l_.str.2@PAGEOFF
	add	x0, sp, #8
	mov	w1, #7
	mov	w3, #7
	bl	_TEST_mem_eq
	cbz	w0, LBB0_13
; %bb.7:
	mov	x0, x20
	bl	_BIO_reset
	mov	w1, #0
	bl	_TEST_int_gt
	cbz	w0, LBB0_13
; %bb.8:
	add	x1, sp, #8
	mov	x0, x20
	mov	w2, #16
	bl	_BIO_read
	mov	w1, #7
	bl	_TEST_int_eq
	cbz	w0, LBB0_13
; %bb.9:
Lloh18:
	adrp	x2, l_.str.2@PAGE
Lloh19:
	add	x2, x2, l_.str.2@PAGEOFF
	add	x0, sp, #8
	mov	w1, #7
	mov	w3, #7
	bl	_TEST_mem_eq
	cmp	w0, #0
	cset	w21, ne
	b	LBB0_11
LBB0_10:
	mov	w21, #0
	mov	x20, #0
LBB0_11:
	mov	x0, x19
	bl	_BIO_free
	mov	x0, x20
	bl	_BIO_free
	ldr	x8, [sp, #24]
Lloh20:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh21:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.12:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_13:
	mov	w21, #0
	b	LBB0_11
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Hello World\n"

l_.str.1:                               ; @.str.1
	.asciz	"Hello"

	.comm	_BIO_NOCLOSE,4,2                ; @BIO_NOCLOSE
	.comm	_BIO_CLOSE,4,2                  ; @BIO_CLOSE
	.comm	_BIO_FLAGS_MEM_RDONLY,4,2       ; @BIO_FLAGS_MEM_RDONLY
l_.str.2:                               ; @.str.2
	.asciz	" World\n"

	.no_dead_strip	_test_bio_rdonly_mem_buf
.subsections_via_symbols
