	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ofw_getprop_alloc              ## -- Begin function ofw_getprop_alloc
	.p2align	4, 0x90
_ofw_getprop_alloc:                     ## @ofw_getprop_alloc
	.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
	movl	%r9d, -44(%rbp)                 ## 4-byte Spill
	movq	%r8, %r12
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %rbx
	movl	%esi, %r13d
	movl	%edi, %r14d
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r14d, %edi
	movl	%r13d, %esi
	movq	%rbx, %rdx
	callq	_ofw_getproplen
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_11
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	addl	-44(%rbp), %r15d                ## 4-byte Folded Reload
	cmpl	%r15d, (%r12)
	jge	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rdi
	testq	%rdi, %rdi
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	callq	_free
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	_OFIOCMAXVALUE@GOTPCREL(%rip), %rax
	addl	(%rax), %r15d
	movl	%r15d, (%r12)
	movl	%r15d, %edi
	callq	_ofw_malloc
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
LBB0_6:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	%r13d, -60(%rbp)
	movq	%rbx, %rdi
	callq	_strlen
	movl	%eax, -64(%rbp)
	movq	%rbx, -88(%rbp)
	movl	(%r12), %eax
	subl	-44(%rbp), %eax                 ## 4-byte Folded Reload
	movl	%eax, -80(%rbp)
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	%rax, -72(%rbp)
	movq	_OFIOCGET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edi
	leaq	-88(%rbp), %rdx
	callq	_ioctl
	cmpl	$-1, %eax
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	_errno@GOTPCREL(%rip), %rdx
	cmpq	%rcx, (%rdx)
	je	LBB0_1
LBB0_8:
	cmpl	$-1, %eax
	jne	LBB0_10
## %bb.9:
	movq	_EX_IOERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_err
LBB0_10:
	movl	-80(%rbp), %r15d
LBB0_11:
	movl	%r15d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_OFIOCMAXVALUE,4,2              ## @OFIOCMAXVALUE
	.comm	_OFIOCGET,4,2                   ## @OFIOCGET
	.comm	_errno,8,3                      ## @errno
	.comm	_ENOMEM,8,3                     ## @ENOMEM
	.comm	_EX_IOERR,4,2                   ## @EX_IOERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ioctl(..., OFIOCGET, ...) failed"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ofw_getprop_alloc              ; -- Begin function ofw_getprop_alloc
	.p2align	2
_ofw_getprop_alloc:                     ; @ofw_getprop_alloc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	mov	x19, x5
	mov	x20, x4
	mov	x21, x3
	mov	x22, x2
	mov	x23, x1
	mov	x24, x0
Lloh0:
	adrp	x26, _OFIOCGET@GOTPAGE
Lloh1:
	ldr	x26, [x26, _OFIOCGET@GOTPAGEOFF]
Lloh2:
	adrp	x27, _errno@GOTPAGE
Lloh3:
	ldr	x27, [x27, _errno@GOTPAGEOFF]
Lloh4:
	adrp	x28, _ENOMEM@GOTPAGE
Lloh5:
	ldr	x28, [x28, _ENOMEM@GOTPAGEOFF]
	b	LBB0_3
LBB0_1:                                 ;   in Loop: Header=BB0_3 Depth=1
Lloh6:
	adrp	x8, _OFIOCMAXVALUE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _OFIOCMAXVALUE@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	add	w0, w8, w25
	str	w0, [x20]
	bl	_ofw_malloc
	str	x0, [x21]
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	str	w23, [sp, #28]
	mov	x0, x22
	bl	_strlen
	str	w0, [sp, #24]
	str	x22, [sp]
	ldr	w8, [x20]
	sub	w8, w8, w19
	str	w8, [sp, #8]
	ldr	x8, [x21]
	str	x8, [sp, #16]
	ldr	w1, [x26]
	mov	x2, sp
	mov	x0, x24
	bl	_ioctl
	ldr	x8, [x27]
	ldr	x9, [x28]
	cmn	w0, #1
	ccmp	x8, x9, #0, eq
	b.ne	LBB0_7
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x24
	mov	x1, x23
	mov	x2, x22
	bl	_ofw_getproplen
	tbnz	w0, #31, LBB0_10
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x20]
	add	w25, w0, w19
	cmp	w8, w25
	b.ge	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x0, [x21]
	cbz	x0, LBB0_1
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	bl	_free
	b	LBB0_1
LBB0_7:
	cmn	w0, #1
	b.ne	LBB0_9
; %bb.8:
Lloh9:
	adrp	x8, _EX_IOERR@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EX_IOERR@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_err
LBB0_9:
	ldr	w0, [sp, #8]
LBB0_10:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_OFIOCMAXVALUE,4,2              ; @OFIOCMAXVALUE
	.comm	_OFIOCGET,4,2                   ; @OFIOCGET
	.comm	_errno,8,3                      ; @errno
	.comm	_ENOMEM,8,3                     ; @ENOMEM
	.comm	_EX_IOERR,4,2                   ; @EX_IOERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ioctl(..., OFIOCGET, ...) failed"

.subsections_via_symbols
