	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pnpbios_encode_allocated_resource_data
_pnpbios_encode_allocated_resource_data: ## @pnpbios_encode_allocated_resource_data
	.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	%rdi, -48(%rbp)                 ## 8-byte Spill
	testq	%rsi, %rsi
	je	LBB0_1
## %bb.2:
	movq	%rdx, %r8
	movq	%rsi, %rbx
	cmpq	%rdx, %rsi
	jae	LBB0_28
## %bb.3:
	movq	_LARGE_TAG@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	xorl	%r13d, %r13d
	movl	$0, -72(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -68(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -52(%rbp)                   ## 4-byte Folded Spill
	movq	%r8, -64(%rbp)                  ## 8-byte Spill
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_26:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	leaq	L_.str(%rip), %rsi
                                        ## kill: def $edx killed $edx killed $rdx
	movl	%r12d, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movq	-64(%rbp), %r8                  ## 8-byte Reload
LBB0_27:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	_LARGE_TAG@GOTPCREL(%rip), %rax
	movzbl	(%rax), %eax
	xorl	%ecx, %ecx
	testb	%al, (%rbx)
	setne	%cl
	leal	(%r12,%rcx,2), %ecx
	incl	%ecx
	addq	%rcx, %rbx
	cmpq	%r8, %rbx
	jae	LBB0_28
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	(%rbx), %edx
	testb	%dl, %al
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movzwl	1(%rbx), %r12d
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_4 Depth=1
	movl	%edx, %r12d
	andl	$7, %r12d
	shrl	$3, %edx
	andl	$15, %edx
LBB0_7:                                 ##   in Loop: Header=BB0_4 Depth=1
	leal	-128(%rdx), %eax
	cmpb	$8, %al
	ja	LBB0_26
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	movzbl	%al, %eax
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_20:                                ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$7, %r12d
	jne	LBB0_26
## %bb.21:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_IO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	-52(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %edx
	callq	_pnp_get_resource
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_port
	jmp	LBB0_22
LBB0_16:                                ##   in Loop: Header=BB0_4 Depth=1
	movl	%r12d, %eax
	andl	$-2, %eax
	cmpl	$2, %eax
	jne	LBB0_26
## %bb.17:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_IRQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	-68(%rbp), %r14d                ## 4-byte Reload
	movl	%r14d, %edx
	callq	_pnp_get_resource
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_irq
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	incl	%r14d
	movl	%r14d, -68(%rbp)                ## 4-byte Spill
	jmp	LBB0_27
LBB0_23:                                ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$3, %r12d
	jne	LBB0_26
## %bb.24:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_IO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	-52(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %edx
	callq	_pnp_get_resource
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_fixed_port
LBB0_22:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	incl	%r15d
	movl	%r15d, -52(%rbp)                ## 4-byte Spill
	jmp	LBB0_27
LBB0_18:                                ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$2, %r12d
	jne	LBB0_26
## %bb.19:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_DMA@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	-72(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %edx
	callq	_pnp_get_resource
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_dma
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	incl	%r15d
	movl	%r15d, -72(%rbp)                ## 4-byte Spill
	jmp	LBB0_27
LBB0_12:                                ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$17, %r12d
	jne	LBB0_26
## %bb.13:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	%r13d, %edx
	callq	_pnp_get_resource
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_mem32
	jmp	LBB0_11
LBB0_9:                                 ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$9, %r12d
	jne	LBB0_26
## %bb.10:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	%r13d, %edx
	callq	_pnp_get_resource
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_mem
	jmp	LBB0_11
LBB0_14:                                ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$9, %r12d
	jne	LBB0_26
## %bb.15:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	%r13d, %edx
	callq	_pnp_get_resource
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_pnpbios_encode_fixed_mem32
LBB0_11:                                ##   in Loop: Header=BB0_4 Depth=1
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	incl	%r13d
	jmp	LBB0_27
LBB0_28:
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_29
LBB0_1:
	xorl	%ebx, %ebx
LBB0_29:
	movq	%rbx, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_25:
	addq	$2, %rbx
	jmp	LBB0_29
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_27, LBB0_27-LJTI0_0
.set L0_0_set_20, LBB0_20-LJTI0_0
.set L0_0_set_16, LBB0_16-LJTI0_0
.set L0_0_set_23, LBB0_23-LJTI0_0
.set L0_0_set_25, LBB0_25-LJTI0_0
.set L0_0_set_18, LBB0_18-LJTI0_0
.set L0_0_set_12, LBB0_12-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_14, LBB0_14-LJTI0_0
LJTI0_0:
	.long	L0_0_set_27
	.long	L0_0_set_20
	.long	L0_0_set_16
	.long	L0_0_set_23
	.long	L0_0_set_25
	.long	L0_0_set_18
	.long	L0_0_set_12
	.long	L0_0_set_9
	.long	L0_0_set_14
	.end_data_region
                                        ## -- End function
	.comm	_LARGE_TAG,1,0                  ## @LARGE_TAG
	.comm	_IORESOURCE_MEM,4,2             ## @IORESOURCE_MEM
	.comm	_IORESOURCE_IRQ,4,2             ## @IORESOURCE_IRQ
	.comm	_IORESOURCE_DMA,4,2             ## @IORESOURCE_DMA
	.comm	_IORESOURCE_IO,4,2              ## @IORESOURCE_IO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unknown tag %#x length %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"no end tag in resource structure\n"

	.no_dead_strip	_pnpbios_encode_allocated_resource_data
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pnpbios_encode_allocated_resource_data
_pnpbios_encode_allocated_resource_data: ; @pnpbios_encode_allocated_resource_data
	.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
	cbz	x1, LBB0_25
; %bb.1:
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	cmp	x1, x2
	b.hs	LBB0_24
; %bb.2:
	mov	w22, #0
	mov	w24, #0
	mov	w26, #0
	mov	w25, #0
Lloh0:
	adrp	x27, _LARGE_TAG@GOTPAGE
Lloh1:
	ldr	x27, [x27, _LARGE_TAG@GOTPAGEOFF]
	ldrb	w9, [x27]
Lloh2:
	adrp	x28, lJTI0_0@PAGE
Lloh3:
	add	x28, x28, lJTI0_0@PAGEOFF
	b	LBB0_5
LBB0_3:                                 ;   in Loop: Header=BB0_5 Depth=1
	stp	x8, x23, [sp]
	mov	x0, x19
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldrb	w8, [x20]
	ldrb	w9, [x27]
	tst	w9, w8
	add	w8, w23, #3
	csinc	w8, w8, w23, ne
	add	x20, x20, x8
	cmp	x20, x21
	b.hs	LBB0_24
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldrb	w8, [x20]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldurh	w23, [x20, #1]
	b	LBB0_8
LBB0_7:                                 ;   in Loop: Header=BB0_5 Depth=1
	and	w23, w8, #0x7
	ubfx	w8, w8, #3, #4
LBB0_8:                                 ;   in Loop: Header=BB0_5 Depth=1
	sub	w9, w8, #128
	cmp	w9, #8
	b.hi	LBB0_3
; %bb.9:                                ;   in Loop: Header=BB0_5 Depth=1
	adr	x10, LBB0_4
	ldrb	w11, [x28, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_10:                                ;   in Loop: Header=BB0_5 Depth=1
	cmp	w23, #7
	b.ne	LBB0_3
; %bb.11:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh6:
	adrp	x8, _IORESOURCE_IO@GOTPAGE
Lloh7:
	ldr	x8, [x8, _IORESOURCE_IO@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x25
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_port
	add	w25, w25, #1
	b	LBB0_4
LBB0_12:                                ;   in Loop: Header=BB0_5 Depth=1
	and	w9, w23, #0xfffe
	cmp	w9, #2
	b.ne	LBB0_3
; %bb.13:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh9:
	adrp	x8, _IORESOURCE_IRQ@GOTPAGE
Lloh10:
	ldr	x8, [x8, _IORESOURCE_IRQ@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x26
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_irq
	add	w26, w26, #1
	b	LBB0_4
LBB0_14:                                ;   in Loop: Header=BB0_5 Depth=1
	cmp	w23, #3
	b.ne	LBB0_3
; %bb.15:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh12:
	adrp	x8, _IORESOURCE_IO@GOTPAGE
Lloh13:
	ldr	x8, [x8, _IORESOURCE_IO@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x25
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_fixed_port
	add	w25, w25, #1
	b	LBB0_4
LBB0_16:                                ;   in Loop: Header=BB0_5 Depth=1
	cmp	w23, #2
	b.ne	LBB0_3
; %bb.17:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh15:
	adrp	x8, _IORESOURCE_DMA@GOTPAGE
Lloh16:
	ldr	x8, [x8, _IORESOURCE_DMA@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x24
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_dma
	add	w24, w24, #1
	b	LBB0_4
LBB0_18:                                ;   in Loop: Header=BB0_5 Depth=1
	cmp	w23, #17
	b.ne	LBB0_3
; %bb.19:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh18:
	adrp	x8, _IORESOURCE_MEM@GOTPAGE
Lloh19:
	ldr	x8, [x8, _IORESOURCE_MEM@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x22
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_mem32
	add	w22, w22, #1
	b	LBB0_4
LBB0_20:                                ;   in Loop: Header=BB0_5 Depth=1
	cmp	w23, #9
	b.ne	LBB0_3
; %bb.21:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh21:
	adrp	x8, _IORESOURCE_MEM@GOTPAGE
Lloh22:
	ldr	x8, [x8, _IORESOURCE_MEM@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x22
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_mem
	add	w22, w22, #1
	b	LBB0_4
LBB0_22:                                ;   in Loop: Header=BB0_5 Depth=1
	cmp	w23, #9
	b.ne	LBB0_3
; %bb.23:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh24:
	adrp	x8, _IORESOURCE_MEM@GOTPAGE
Lloh25:
	ldr	x8, [x8, _IORESOURCE_MEM@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x22
	bl	_pnp_get_resource
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_pnpbios_encode_fixed_mem32
	add	w22, w22, #1
	b	LBB0_4
LBB0_24:
Lloh27:
	adrp	x1, l_.str.1@PAGE
Lloh28:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_err
LBB0_25:
	mov	x0, #0
LBB0_26:
	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
LBB0_27:
	add	x0, x20, #2
	b	LBB0_26
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_4-LBB0_4)>>2
	.byte	(LBB0_10-LBB0_4)>>2
	.byte	(LBB0_12-LBB0_4)>>2
	.byte	(LBB0_14-LBB0_4)>>2
	.byte	(LBB0_27-LBB0_4)>>2
	.byte	(LBB0_16-LBB0_4)>>2
	.byte	(LBB0_18-LBB0_4)>>2
	.byte	(LBB0_20-LBB0_4)>>2
	.byte	(LBB0_22-LBB0_4)>>2
                                        ; -- End function
	.comm	_LARGE_TAG,1,0                  ; @LARGE_TAG
	.comm	_IORESOURCE_MEM,4,2             ; @IORESOURCE_MEM
	.comm	_IORESOURCE_IRQ,4,2             ; @IORESOURCE_IRQ
	.comm	_IORESOURCE_DMA,4,2             ; @IORESOURCE_DMA
	.comm	_IORESOURCE_IO,4,2              ; @IORESOURCE_IO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unknown tag %#x length %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"no end tag in resource structure\n"

	.no_dead_strip	_pnpbios_encode_allocated_resource_data
.subsections_via_symbols
