	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function init_qp_queue
_init_qp_queue:                         ## @init_qp_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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -80(%rbp)                  ## 8-byte Spill
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r15
	movq	16(%rbp), %rdx
	movl	(%rdx), %r12d
	xorl	%ebx, %ebx
	testl	%r12d, %r12d
	je	LBB0_18
## %bb.1:
	movl	%r8d, %r14d
	movl	24(%rbp), %r8d
	movl	(%rdi), %eax
	movl	%eax, -68(%rbp)                 ## 4-byte Spill
	addq	$4, %rdi
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	cmpq	$0, 8(%rdx)
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	je	LBB0_2
## %bb.7:
	movb	4(%rdx), %cl
	movl	$128, %eax
	shll	%cl, %eax
	movq	%rdx, %r13
	movl	16(%rdx), %r9d
	movl	$1, (%rsp)
	movl	$1, %r12d
	movq	%rsi, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movl	$1, %edx
	movl	%eax, %ecx
	callq	_ipz_queue_ctor
	testl	%eax, %eax
	jne	LBB0_4
	jmp	LBB0_8
LBB0_2:
	movq	_EHCA_PAGESIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rdx, %r13
	movl	16(%rdx), %r9d
	movl	$0, (%rsp)
	movq	%rsi, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movl	%r12d, %edx
	callq	_ipz_queue_ctor
	testl	%eax, %eax
	je	LBB0_8
## %bb.3:
	testl	%r12d, %r12d
	jg	LBB0_4
LBB0_17:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_ipz_qeit_reset
	xorl	%ebx, %ebx
	jmp	LBB0_18
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	_H_PAGE_REGISTERED@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rbx
	jne	LBB0_11
LBB0_16:                                ##   in Loop: Header=BB0_4 Depth=1
	decl	%r12d
	je	LBB0_17
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_ipz_qpageit_get_inc
	testq	%rax, %rax
	je	LBB0_5
## %bb.9:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%rax, %rdi
	callq	_virt_to_abs
	movl	4(%r15), %ecx
	movl	8(%r15), %esi
	xorl	%edx, %edx
	cmpq	$0, 8(%r13)
	sete	%dl
	movl	%ecx, 8(%rsp)
	movl	%edx, (%rsp)
	movl	-68(%rbp), %edi                 ## 4-byte Reload
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	movl	%r14d, %r8d
	movq	%rax, %r9
	callq	_hipz_h_register_rpage_qp
	movq	%rax, %rbx
	cmpl	$1, %r12d
	jne	LBB0_15
## %bb.10:                              ##   in Loop: Header=BB0_4 Depth=1
	cmpq	-80(%rbp), %rbx                 ## 8-byte Folded Reload
	jne	LBB0_11
## %bb.13:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	%r15, %rdi
	callq	_ipz_qpageit_get_inc
	testq	%rax, %rax
	je	LBB0_16
## %bb.14:
	leaq	L_.str.3(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rax, %rdx
	callq	_ehca_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_12
LBB0_8:
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%edx, %edx
	callq	_ehca_err
	movq	_EBUSY@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_18
LBB0_5:
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%edx, %edx
	callq	_ehca_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_12
LBB0_11:
	leaq	L_.str.2(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rdx
	callq	_ehca_err
	movq	%rbx, %rdi
	callq	_ehca2ib_return_code
	movl	%eax, %ebx
LBB0_12:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_ipz_queue_dtor
LBB0_18:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EHCA_PAGESIZE,4,2              ## @EHCA_PAGESIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot allocate page for queue. ipz_rc=%i"

	.comm	_EBUSY,4,2                      ## @EBUSY
L_.str.1:                               ## @.str.1
	.asciz	"ipz_qpageit_get_inc() failed p_vpage= %p"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.2:                               ## @.str.2
	.asciz	"hipz_qp_register_rpage() h_ret=%lli"

L_.str.3:                               ## @.str.3
	.asciz	"ipz_qpageit_get_inc() should not succeed vpage=%p"

	.comm	_H_PAGE_REGISTERED,8,3          ## @H_PAGE_REGISTERED
	.no_dead_strip	_init_qp_queue
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function init_qp_queue
_init_qp_queue:                         ; @init_qp_queue
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	ldr	w27, [x6]
	cbz	w27, LBB0_15
; %bb.1:
	mov	x22, x6
	mov	x23, x5
	mov	x24, x4
	mov	x19, x3
	mov	x25, x2
	mov	x21, x0
	ldr	w26, [x21], #4
	ldr	x8, [x6, #8]
	str	x1, [sp, #8]                    ; 8-byte Folded Spill
	cbz	x8, LBB0_3
; %bb.2:
	ldr	w8, [x22, #4]
	mov	w9, #128
	lsl	w3, w9, w8
	ldr	w5, [x22, #16]
	mov	w27, #1
	mov	x0, x1
	mov	x1, x19
	mov	w2, #1
	mov	x4, x7
	mov	w6, #1
	bl	_ipz_queue_ctor
	cbnz	w0, LBB0_5
	b	LBB0_13
LBB0_3:
Lloh0:
	adrp	x8, _EHCA_PAGESIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EHCA_PAGESIZE@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	ldr	w5, [x22, #16]
	mov	x0, x1
	mov	x1, x19
	mov	x2, x27
	mov	x4, x7
	mov	w6, #0
	bl	_ipz_queue_ctor
	cbz	w0, LBB0_13
; %bb.4:
	cmp	w27, #1
	b.lt	LBB0_14
LBB0_5:
Lloh3:
	adrp	x20, _H_PAGE_REGISTERED@GOTPAGE
Lloh4:
	ldr	x20, [x20, _H_PAGE_REGISTERED@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=1
	ldr	x8, [x20]
	cmp	x28, x8
	b.ne	LBB0_18
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	subs	w27, w27, #1
	b.eq	LBB0_14
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_ipz_qpageit_get_inc
	cbz	x0, LBB0_16
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	bl	_virt_to_abs
	mov	x5, x0
	ldr	x8, [x22, #8]
	cmp	x8, #0
	cset	w6, eq
	ldp	w7, w1, [x25, #4]
	mov	x0, x26
	mov	x2, #0
	mov	w3, #0
	mov	x4, x24
	bl	_hipz_h_register_rpage_qp
	mov	x28, x0
	cmp	w27, #1
	b.ne	LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	cmp	x28, x23
	b.ne	LBB0_18
; %bb.11:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x25
	bl	_ipz_qpageit_get_inc
	cbz	x0, LBB0_7
; %bb.12:
	mov	x2, x0
Lloh5:
	adrp	x1, l_.str.3@PAGE
Lloh6:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x21
	b	LBB0_17
LBB0_13:
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	mov	x2, #0
	bl	_ehca_err
Lloh9:
	adrp	x8, _EBUSY@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_20
LBB0_14:
	mov	x0, x19
	bl	_ipz_qeit_reset
LBB0_15:
	mov	w21, #0
	b	LBB0_20
LBB0_16:
Lloh12:
	adrp	x1, l_.str.1@PAGE
Lloh13:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	mov	x2, #0
LBB0_17:
	bl	_ehca_err
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_19
LBB0_18:
Lloh17:
	adrp	x1, l_.str.2@PAGE
Lloh18:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x21
	mov	x2, x28
	bl	_ehca_err
	mov	x0, x28
	bl	_ehca2ib_return_code
	mov	x21, x0
LBB0_19:
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	mov	x1, x19
	bl	_ipz_queue_dtor
LBB0_20:
	mov	x0, x21
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_EHCA_PAGESIZE,4,2              ; @EHCA_PAGESIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot allocate page for queue. ipz_rc=%i"

	.comm	_EBUSY,4,2                      ; @EBUSY
l_.str.1:                               ; @.str.1
	.asciz	"ipz_qpageit_get_inc() failed p_vpage= %p"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.2:                               ; @.str.2
	.asciz	"hipz_qp_register_rpage() h_ret=%lli"

l_.str.3:                               ; @.str.3
	.asciz	"ipz_qpageit_get_inc() should not succeed vpage=%p"

	.comm	_H_PAGE_REGISTERED,8,3          ; @H_PAGE_REGISTERED
	.no_dead_strip	_init_qp_queue
.subsections_via_symbols
