	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ena_com_create_io_queue        ## -- Begin function ena_com_create_io_queue
	.p2align	4, 0x90
_ena_com_create_io_queue:               ## @ena_com_create_io_queue
	.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
	movq	%rsi, %rbx
	movq	(%rsi), %rsi
	movq	_ENA_TOTAL_NUM_QUEUES@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	cmpq	%rdx, %rsi
	jae	LBB0_1
## %bb.2:
	movq	8(%rdi), %r13
	movq	16(%rdi), %r15
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	leaq	(,%rsi,8), %rax
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	leaq	(%rax,%rax,4), %r12
	leaq	(%r15,%r12), %rdi
	leaq	(%r12,%r13), %r14
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	movl	20(%rbx), %eax
	movl	%eax, 28(%r13,%r12)
	movq	8(%rbx), %rcx
	movq	%rcx, (%r13,%r12)
	movq	(%rbx), %rdx
	movq	%rdx, 8(%r13,%r12)
	movl	24(%rbx), %esi
	movl	%esi, 32(%r13,%r12)
	movl	%eax, 28(%r15,%r12)
	movq	%rcx, (%r15,%r12)
	movq	%rdx, 8(%r15,%r12)
	movl	16(%rbx), %eax
	movl	%eax, 24(%r15,%r12)
	movq	-72(%rbp), %r12                 ## 8-byte Reload
	movq	_ENA_COM_IO_QUEUE_DIRECTION_TX@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jne	LBB0_4
## %bb.3:
	movq	_u32@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r12), %esi
	movq	_SZ_256@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_min_t
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%rcx,%rcx,4), %rcx
	movl	%eax, 20(%r15,%rcx,8)
LBB0_4:
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	callq	_ena_com_init_io_sq
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.5:
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	_ena_com_init_io_cq
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.6:
	movq	%r12, %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	callq	_ena_com_create_io_cq
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.7:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%rax,4), %rax
	movl	16(%r13,%rax,8), %edx
	movq	%r12, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_ena_com_create_io_sq
	testl	%eax, %eax
	je	LBB0_8
## %bb.9:
	movl	%eax, %r15d
	movq	%r12, %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	callq	_ena_com_destroy_io_cq
LBB0_10:
	movq	%r12, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	_ena_com_io_queue_free
	jmp	LBB0_11
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_11:
	movl	%r15d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	xorl	%r15d, %r15d
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_ENA_TOTAL_NUM_QUEUES,8,3       ## @ENA_TOTAL_NUM_QUEUES
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Qid (%d) is bigger than max num of queues (%d)\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENA_COM_IO_QUEUE_DIRECTION_TX,8,3 ## @ENA_COM_IO_QUEUE_DIRECTION_TX
	.comm	_u32,4,2                        ## @u32
	.comm	_SZ_256,4,2                     ## @SZ_256
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ena_com_create_io_queue        ; -- Begin function ena_com_create_io_queue
	.p2align	2
_ena_com_create_io_queue:               ; @ena_com_create_io_queue
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	ldr	x22, [x1]
Lloh0:
	adrp	x8, _ENA_TOTAL_NUM_QUEUES@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENA_TOTAL_NUM_QUEUES@GOTPAGEOFF]
Lloh2:
	ldr	x2, [x8]
	cmp	x22, x2
	b.hs	LBB0_9
; %bb.1:
	mov	x23, x1
	mov	x19, x0
	add	x8, x22, x22, lsl #2
	lsl	x8, x8, #3
	ldp	x25, x24, [x0, #8]
	add	x21, x24, x8
	add	x20, x25, x8
	mov	x0, x21
	mov	w1, #0
	mov	w2, #40
	bl	_memset
	mov	x0, x20
	mov	w1, #0
	mov	w2, #40
	bl	_memset
	ldp	x9, x8, [x23]
	stp	x8, x9, [x20]
	ldur	d0, [x23, #20]
	stur	d0, [x20, #28]
	str	s0, [x21, #28]
	stp	x8, x9, [x21]
	ldr	w9, [x23, #16]
	str	w9, [x21, #24]
Lloh3:
	adrp	x9, _ENA_COM_IO_QUEUE_DIRECTION_TX@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ENA_COM_IO_QUEUE_DIRECTION_TX@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
; %bb.2:
Lloh6:
	adrp	x8, _u32@GOTPAGE
Lloh7:
	ldr	x8, [x8, _u32@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	ldr	w1, [x19]
Lloh9:
	adrp	x8, _SZ_256@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SZ_256@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	bl	_min_t
	mov	w8, #40
	madd	x8, x22, x8, x24
	str	w0, [x8, #20]
LBB0_3:
	mov	x0, x19
	mov	x1, x23
	mov	x2, x21
	bl	_ena_com_init_io_sq
	mov	x24, x0
	cbnz	w0, LBB0_8
; %bb.4:
	mov	x0, x19
	mov	x1, x23
	mov	x2, x20
	bl	_ena_com_init_io_cq
	mov	x24, x0
	cbnz	w0, LBB0_8
; %bb.5:
	mov	x0, x19
	mov	x1, x20
	bl	_ena_com_create_io_cq
	mov	x24, x0
	cbnz	w0, LBB0_8
; %bb.6:
	mov	w8, #40
	madd	x8, x22, x8, x25
	ldr	w2, [x8, #16]
	mov	x0, x19
	mov	x1, x21
	bl	_ena_com_create_io_sq
	mov	x24, x0
	cbz	w0, LBB0_10
; %bb.7:
	mov	x0, x19
	mov	x1, x20
	bl	_ena_com_destroy_io_cq
LBB0_8:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_ena_com_io_queue_free
	b	LBB0_10
LBB0_9:
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x22
	bl	_pr_err
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w24, w8
LBB0_10:
	mov	x0, x24
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_ENA_TOTAL_NUM_QUEUES,8,3       ; @ENA_TOTAL_NUM_QUEUES
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Qid (%d) is bigger than max num of queues (%d)\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENA_COM_IO_QUEUE_DIRECTION_TX,8,3 ; @ENA_COM_IO_QUEUE_DIRECTION_TX
	.comm	_u32,4,2                        ; @u32
	.comm	_SZ_256,4,2                     ; @SZ_256
.subsections_via_symbols
