	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function connection_new
LCPI0_0:
	.long	1                               ## 0x1
	.long	1                               ## 0x1
	.long	8192                            ## 0x2000
	.long	8192                            ## 0x2000
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_connection_new:                        ## @connection_new
	.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
	movl	%edi, %r15d
	movl	$1, %edi
	movl	$192, %esi
	callq	_calloc
	movq	%rax, %rbx
	movq	%rax, %r12
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_log_err
LBB0_2:
	movq	_CONN_DIGEST_NONE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 184(%r12)
	movq	%rax, 176(%r12)
	movaps	LCPI0_0(%rip), %xmm0            ## xmm0 = [1,1,8192,8192]
	movups	%xmm0, (%r12)
	movabsq	$281474976972800, %rax          ## imm = 0x1000000040000
	movq	%rax, 16(%r12)
	movl	%r15d, 24(%r12)
	movl	16(%r14), %eax
	movl	%eax, 80(%r12)
	leaq	40(%rbx), %rdi
	leaq	12(%r14), %rsi
	movl	$40, %edx
	callq	_memcpy
	leaq	136(%rbx), %rdi
	leaq	8(%r14), %rsi
	movl	$40, %edx
	callq	_memcpy
	movl	4(%r14), %eax
	movl	%eax, 128(%r12)
	addq	$88, %rbx
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movl	$40, %edx
	callq	_memcpy
	movl	88(%r12), %ecx
	testl	%ecx, %ecx
	jne	LBB0_4
## %bb.3:
	movl	$16777215, (%rbx)               ## imm = 0xFFFFFF
	movl	$16777215, %ecx                 ## imm = 0xFFFFFF
LBB0_4:
	movl	92(%r12), %eax
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	movl	%ecx, 92(%r12)
	movl	%ecx, %eax
LBB0_6:
	movl	96(%r12), %ecx
	testl	%ecx, %ecx
	jne	LBB0_8
## %bb.7:
	movl	$16777215, 96(%r12)             ## imm = 0xFFFFFF
	movl	$16777215, %ecx                 ## imm = 0xFFFFFF
LBB0_8:
	movl	100(%r12), %esi
	movl	$16777215, %edx                 ## imm = 0xFFFFFF
	testl	%esi, %esi
	cmovnel	%esi, %edx
	je	LBB0_10
## %bb.9:
	cmpl	%ecx, %edx
	jle	LBB0_11
LBB0_10:
	cmpl	%ecx, %edx
	cmovll	%edx, %ecx
	movl	%ecx, 100(%r12)
LBB0_11:
	cmpl	%eax, 12(%r12)
	jle	LBB0_13
## %bb.12:
	movl	%eax, 12(%r12)
LBB0_13:
	movq	56(%r12), %r15
	movq	64(%r12), %r14
	cmpb	$0, (%r15)
	je	LBB0_15
## %bb.14:
	leaq	-64(%rbp), %rdx
	movq	%r12, %rdi
	movq	%r15, %rsi
	movl	$1, %ecx
	callq	_resolve_addr
	jmp	LBB0_16
LBB0_15:
	movq	$0, -64(%rbp)
LBB0_16:
	leaq	-56(%rbp), %rdx
	movq	%r12, %rdi
	movq	%r14, %rsi
	xorl	%ecx, %ecx
	callq	_resolve_addr
	cmpq	$0, 72(%r12)
	je	LBB0_18
## %bb.17:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	callq	_fail
	leaq	L_.str.2(%rip), %rsi
	movl	$1, %edi
	callq	_log_errx
LBB0_18:
	movq	-56(%rbp), %rax
	movl	16(%rax), %edi
	movl	8(%rax), %edx
	movl	12(%rax), %esi
	callq	_socket
	movq	%rax, 32(%r12)
	testq	%rax, %rax
	jns	LBB0_20
## %bb.19:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	movq	%r12, %rdi
	movq	%rax, %rsi
	callq	_fail
	leaq	L_.str.3(%rip), %rsi
	movl	$1, %edi
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_log_err
	movq	32(%r12), %rax
LBB0_20:
	movq	_SOCKBUF_SIZE@GOTPCREL(%rip), %rbx
	movl	(%rbx), %ecx
	movl	%ecx, -44(%rbp)
	movq	_SOL_SOCKET@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_SO_RCVBUF@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	leaq	-44(%rbp), %rcx
	movq	%rax, %rdi
	movl	$4, %r8d
	callq	_setsockopt
	cmpl	$-1, %eax
	jne	LBB0_22
## %bb.21:
	leaq	L_.str.4(%rip), %rdi
	callq	_log_warn
LBB0_22:
	movl	(%rbx), %eax
	movl	%eax, -44(%rbp)
	movq	32(%r12), %rdi
	movl	(%r13), %esi
	movq	_SO_SNDBUF@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-44(%rbp), %rcx
	movl	$4, %r8d
	callq	_setsockopt
	cmpl	$-1, %eax
	jne	LBB0_24
## %bb.23:
	leaq	L_.str.5(%rip), %rdi
	callq	_log_warn
LBB0_24:
	movq	-64(%rbp), %rax
	testq	%rax, %rax
	je	LBB0_27
## %bb.25:
	movq	32(%r12), %rdi
	movl	(%rax), %edx
	movl	4(%rax), %esi
	callq	_bind
	testl	%eax, %eax
	je	LBB0_27
## %bb.26:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	movq	%r12, %rdi
	movq	%rax, %rsi
	callq	_fail
	leaq	L_.str.6(%rip), %rsi
	movl	$1, %edi
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_log_err
LBB0_27:
	leaq	L_.str.7(%rip), %rdi
	movq	%r14, %rsi
	callq	_log_debugx
	movq	32(%r12), %rdi
	movq	-56(%rbp), %rax
	movl	(%rax), %edx
	movl	4(%rax), %esi
	callq	_connect
	testl	%eax, %eax
	je	LBB0_29
## %bb.28:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	movq	%r12, %rdi
	movq	%rax, %rsi
	callq	_fail
	leaq	L_.str.8(%rip), %rsi
	movl	$1, %edi
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_log_err
LBB0_29:
	movq	%r12, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"calloc"

	.comm	_CONN_DIGEST_NONE,8,3           ## @CONN_DIGEST_NONE
L_.str.1:                               ## @.str.1
	.asciz	"iSER not supported"

L_.str.2:                               ## @.str.2
	.asciz	"iscsid(8) compiled without ICL_KERNEL_PROXY does not support iSER"

	.comm	_errno,4,2                      ## @errno
L_.str.3:                               ## @.str.3
	.asciz	"failed to create socket for %s"

	.comm	_SOCKBUF_SIZE,4,2               ## @SOCKBUF_SIZE
	.comm	_SOL_SOCKET,4,2                 ## @SOL_SOCKET
	.comm	_SO_RCVBUF,4,2                  ## @SO_RCVBUF
L_.str.4:                               ## @.str.4
	.asciz	"setsockopt(SO_RCVBUF) failed"

	.comm	_SO_SNDBUF,4,2                  ## @SO_SNDBUF
L_.str.5:                               ## @.str.5
	.asciz	"setsockopt(SO_SNDBUF) failed"

L_.str.6:                               ## @.str.6
	.asciz	"failed to bind to %s"

L_.str.7:                               ## @.str.7
	.asciz	"connecting to %s"

L_.str.8:                               ## @.str.8
	.asciz	"failed to connect to %s"

	.comm	_ISCSIDCONNECT,4,2              ## @ISCSIDCONNECT
	.no_dead_strip	_connection_new
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ; -- Begin function connection_new
lCPI0_0:
	.long	1                               ; 0x1
	.long	1                               ; 0x1
	.long	8192                            ; 0x2000
	.long	8192                            ; 0x2000
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3
lCPI0_1:
	.long	262144                          ; 0x40000
	.long	65536                           ; 0x10000
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_connection_new:                        ; @connection_new
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x20, x1
	mov	x21, x0
	mov	w0, #1
	mov	w1, #192
	bl	_calloc
	mov	x19, x0
	cbnz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_log_err
LBB0_2:
Lloh2:
	adrp	x8, _CONN_DIGEST_NONE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CONN_DIGEST_NONE@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	stp	x8, x8, [x19, #176]
Lloh5:
	adrp	x8, lCPI0_0@PAGE
Lloh6:
	ldr	q0, [x8, lCPI0_0@PAGEOFF]
	str	q0, [x19]
Lloh7:
	adrp	x8, lCPI0_1@PAGE
Lloh8:
	ldr	d0, [x8, lCPI0_1@PAGEOFF]
	str	d0, [x19, #16]
	str	w21, [x19, #24]
	ldr	w8, [x20, #16]
	str	w8, [x19, #80]
	add	x0, x19, #40
	add	x1, x20, #12
	mov	w2, #40
	bl	_memcpy
	add	x0, x19, #136
	add	x1, x20, #8
	mov	w2, #40
	bl	_memcpy
	ldr	w8, [x20, #4]
	str	w8, [x19, #128]
	add	x21, x19, #88
	mov	x0, x21
	mov	x1, x20
	mov	w2, #40
	bl	_memcpy
	ldr	w9, [x19, #88]
	cbz	w9, LBB0_12
; %bb.3:
	ldr	w8, [x19, #92]
	cbz	w8, LBB0_13
LBB0_4:
	ldr	w9, [x19, #96]
	cbz	w9, LBB0_14
LBB0_5:
	ldr	w11, [x19, #100]
	mov	w10, #16777215
	cmp	w11, #0
	csel	w10, w10, w11, eq
	cbz	w11, LBB0_7
; %bb.6:
	cmp	w10, w9
	b.le	LBB0_8
LBB0_7:
	cmp	w10, w9
	csel	w9, w10, w9, lt
	str	w9, [x19, #100]
LBB0_8:
	ldr	w9, [x19, #12]
	cmp	w9, w8
	b.le	LBB0_10
; %bb.9:
	str	w8, [x19, #12]
LBB0_10:
	ldp	x21, x20, [x19, #56]
	ldrb	w8, [x21]
	cbz	w8, LBB0_15
; %bb.11:
	add	x2, sp, #24
	mov	x0, x19
	mov	x1, x21
	mov	w3, #1
	bl	_resolve_addr
	b	LBB0_16
LBB0_12:
	mov	w9, #16777215
	str	w9, [x21]
	ldr	w8, [x19, #92]
	cbnz	w8, LBB0_4
LBB0_13:
	str	w9, [x19, #92]
	mov	x8, x9
	ldr	w9, [x19, #96]
	cbnz	w9, LBB0_5
LBB0_14:
	mov	w9, #16777215
	str	w9, [x19, #96]
	b	LBB0_5
LBB0_15:
	str	xzr, [sp, #24]
LBB0_16:
	add	x2, sp, #16
	mov	x0, x19
	mov	x1, x20
	mov	w3, #0
	bl	_resolve_addr
	ldr	x8, [x19, #72]
	cbz	x8, LBB0_18
; %bb.17:
Lloh9:
	adrp	x1, l_.str.1@PAGE
Lloh10:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_fail
Lloh11:
	adrp	x1, l_.str.2@PAGE
Lloh12:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_log_errx
LBB0_18:
	ldr	x8, [sp, #16]
	ldp	w1, w0, [x8, #12]
	ldr	w2, [x8, #8]
	bl	_socket
	str	x0, [x19, #32]
Lloh13:
	adrp	x22, _errno@GOTPAGE
Lloh14:
	ldr	x22, [x22, _errno@GOTPAGEOFF]
	tbz	x0, #63, LBB0_20
; %bb.19:
	ldr	w0, [x22]
	bl	_strerror
	mov	x1, x0
	mov	x0, x19
	bl	_fail
	str	x21, [sp]
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w0, #1
	bl	_log_err
	ldr	x0, [x19, #32]
LBB0_20:
Lloh17:
	adrp	x23, _SOCKBUF_SIZE@GOTPAGE
Lloh18:
	ldr	x23, [x23, _SOCKBUF_SIZE@GOTPAGEOFF]
	ldr	w8, [x23]
	str	w8, [sp, #12]
Lloh19:
	adrp	x24, _SOL_SOCKET@GOTPAGE
Lloh20:
	ldr	x24, [x24, _SOL_SOCKET@GOTPAGEOFF]
	ldr	w1, [x24]
Lloh21:
	adrp	x8, _SO_RCVBUF@GOTPAGE
Lloh22:
	ldr	x8, [x8, _SO_RCVBUF@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
	add	x3, sp, #12
	mov	w4, #4
	bl	_setsockopt
	cmn	w0, #1
	b.ne	LBB0_22
; %bb.21:
Lloh24:
	adrp	x0, l_.str.4@PAGE
Lloh25:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_log_warn
LBB0_22:
	ldr	w8, [x23]
	str	w8, [sp, #12]
	ldr	x0, [x19, #32]
	ldr	w1, [x24]
Lloh26:
	adrp	x8, _SO_SNDBUF@GOTPAGE
Lloh27:
	ldr	x8, [x8, _SO_SNDBUF@GOTPAGEOFF]
Lloh28:
	ldr	w2, [x8]
	add	x3, sp, #12
	mov	w4, #4
	bl	_setsockopt
	cmn	w0, #1
	b.eq	LBB0_24
; %bb.23:
	ldr	x8, [sp, #24]
	cbnz	x8, LBB0_25
	b	LBB0_27
LBB0_24:
Lloh29:
	adrp	x0, l_.str.5@PAGE
Lloh30:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_log_warn
	ldr	x8, [sp, #24]
	cbz	x8, LBB0_27
LBB0_25:
	ldr	x0, [x19, #32]
	ldp	w2, w1, [x8]
	bl	_bind
	cbz	w0, LBB0_27
; %bb.26:
	ldr	w0, [x22]
	bl	_strerror
	mov	x1, x0
	mov	x0, x19
	bl	_fail
	str	x21, [sp]
Lloh31:
	adrp	x1, l_.str.6@PAGE
Lloh32:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	w0, #1
	bl	_log_err
LBB0_27:
Lloh33:
	adrp	x0, l_.str.7@PAGE
Lloh34:
	add	x0, x0, l_.str.7@PAGEOFF
	mov	x1, x20
	bl	_log_debugx
	ldr	x0, [x19, #32]
	ldr	x8, [sp, #16]
	ldp	w2, w1, [x8]
	bl	_connect
	cbz	w0, LBB0_29
; %bb.28:
	ldr	w0, [x22]
	bl	_strerror
	mov	x1, x0
	mov	x0, x19
	bl	_fail
	str	x20, [sp]
Lloh35:
	adrp	x1, l_.str.8@PAGE
Lloh36:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	w0, #1
	bl	_log_err
LBB0_29:
	mov	x0, x19
	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
	add	sp, sp, #96
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdr	Lloh7, Lloh8
	.loh AdrpAdrp	Lloh5, Lloh7
	.loh AdrpLdr	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"calloc"

	.comm	_CONN_DIGEST_NONE,8,3           ; @CONN_DIGEST_NONE
l_.str.1:                               ; @.str.1
	.asciz	"iSER not supported"

l_.str.2:                               ; @.str.2
	.asciz	"iscsid(8) compiled without ICL_KERNEL_PROXY does not support iSER"

	.comm	_errno,4,2                      ; @errno
l_.str.3:                               ; @.str.3
	.asciz	"failed to create socket for %s"

	.comm	_SOCKBUF_SIZE,4,2               ; @SOCKBUF_SIZE
	.comm	_SOL_SOCKET,4,2                 ; @SOL_SOCKET
	.comm	_SO_RCVBUF,4,2                  ; @SO_RCVBUF
l_.str.4:                               ; @.str.4
	.asciz	"setsockopt(SO_RCVBUF) failed"

	.comm	_SO_SNDBUF,4,2                  ; @SO_SNDBUF
l_.str.5:                               ; @.str.5
	.asciz	"setsockopt(SO_SNDBUF) failed"

l_.str.6:                               ; @.str.6
	.asciz	"failed to bind to %s"

l_.str.7:                               ; @.str.7
	.asciz	"connecting to %s"

l_.str.8:                               ; @.str.8
	.asciz	"failed to connect to %s"

	.comm	_ISCSIDCONNECT,4,2              ; @ISCSIDCONNECT
	.no_dead_strip	_connection_new
.subsections_via_symbols
