	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_acpi_ns_attach_object          ## -- Begin function acpi_ns_attach_object
	.p2align	4, 0x90
_acpi_ns_attach_object:                 ## @acpi_ns_attach_object
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	_ns_attach_object@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_ACPI_FUNCTION_TRACE
	testq	%rbx, %rbx
	jne	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_ACPI_ERROR
	movq	_AE_BAD_PARAMETER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_return_ACPI_STATUS
LBB0_2:
	movq	_ACPI_TYPE_ANY@GOTPCREL(%rip), %r12
	testq	%r14, %r14
	jne	LBB0_5
## %bb.3:
	cmpq	%r15, (%r12)
	je	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rdi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_ACPI_ERROR
	movq	_AE_BAD_PARAMETER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_return_ACPI_STATUS
LBB0_5:
	movq	%rbx, %rdi
	callq	_ACPI_GET_DESCRIPTOR_TYPE
	movq	_ACPI_DESC_TYPE_NAMED@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rax
	jne	LBB0_6
## %bb.7:
	cmpq	%r14, 8(%rbx)
	je	LBB0_8
LBB0_9:
	testq	%r14, %r14
	je	LBB0_10
LBB0_11:
	movq	%r14, %rdi
	callq	_ACPI_GET_DESCRIPTOR_TYPE
	cmpq	(%r13), %rax
	jne	LBB0_15
## %bb.12:
	movq	8(%r14), %rax
	testq	%rax, %rax
	je	LBB0_15
## %bb.13:
	movq	%r14, %r12
	movq	%rax, %r14
	jmp	LBB0_14
LBB0_6:
	movq	%rbx, %rdi
	callq	_acpi_ut_get_descriptor_name
	movl	%eax, %edi
	callq	_ACPI_ERROR
	movq	_AE_BAD_PARAMETER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_return_ACPI_STATUS
	cmpq	%r14, 8(%rbx)
	jne	LBB0_9
LBB0_8:
	movl	%ebx, %edi
	callq	_ACPI_DEBUG_PRINT
	movq	_AE_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_return_ACPI_STATUS
	testq	%r14, %r14
	jne	LBB0_11
LBB0_10:
	xorl	%r14d, %r14d
LBB0_14:
	movq	(%r12), %r15
LBB0_15:
	movq	%rbx, %rdi
	callq	_acpi_ut_get_node_name
	movl	%eax, %edi
	callq	_ACPI_DEBUG_PRINT
	cmpq	$0, 8(%rbx)
	je	LBB0_17
## %bb.16:
	movq	%rbx, %rdi
	callq	_acpi_ns_detach_object
LBB0_17:
	testq	%r14, %r14
	je	LBB0_21
## %bb.18:
	movq	%r14, %rdi
	callq	_acpi_ut_add_reference
	movq	%r14, %rcx
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	%rcx, %rax
	movq	(%rcx), %rcx
	testq	%rcx, %rcx
	jne	LBB0_19
## %bb.20:
	movq	8(%rbx), %rcx
	movq	%rcx, (%rax)
LBB0_21:
	movq	%r15, (%rbx)
	movq	%r14, 8(%rbx)
	movq	_AE_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_return_ACPI_STATUS             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ACPI_TYPE_ANY,8,3              ## @ACPI_TYPE_ANY
	.comm	_ns_attach_object,4,2           ## @ns_attach_object
	.comm	_AE_INFO,4,2                    ## @AE_INFO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Null NamedObj handle"

	.comm	_AE_BAD_PARAMETER,4,2           ## @AE_BAD_PARAMETER
L_.str.1:                               ## @.str.1
	.asciz	"Null object, but type not ACPI_TYPE_ANY"

	.comm	_ACPI_DESC_TYPE_NAMED,8,3       ## @ACPI_DESC_TYPE_NAMED
	.comm	_ACPI_DB_EXEC,4,2               ## @ACPI_DB_EXEC
	.comm	_AE_OK,4,2                      ## @AE_OK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_acpi_ns_attach_object          ; -- Begin function acpi_ns_attach_object
	.p2align	2
_acpi_ns_attach_object:                 ; @acpi_ns_attach_object
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x21, x2
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _ns_attach_object@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ns_attach_object@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_ACPI_FUNCTION_TRACE
Lloh3:
	adrp	x22, _AE_BAD_PARAMETER@GOTPAGE
Lloh4:
	ldr	x22, [x22, _AE_BAD_PARAMETER@GOTPAGEOFF]
	cbnz	x19, LBB0_2
; %bb.1:
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_ACPI_ERROR
	ldr	w0, [x22]
	bl	_return_ACPI_STATUS
LBB0_2:
	cbnz	x20, LBB0_5
; %bb.3:
Lloh7:
	adrp	x8, _ACPI_TYPE_ANY@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ACPI_TYPE_ANY@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	cmp	x8, x21
	b.eq	LBB0_5
; %bb.4:
Lloh10:
	adrp	x0, l_.str.1@PAGE
Lloh11:
	add	x0, x0, l_.str.1@PAGEOFF
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_ACPI_ERROR
	ldr	w0, [x22]
	bl	_return_ACPI_STATUS
LBB0_5:
	mov	x0, x19
	bl	_ACPI_GET_DESCRIPTOR_TYPE
Lloh12:
	adrp	x23, _ACPI_DESC_TYPE_NAMED@GOTPAGE
Lloh13:
	ldr	x23, [x23, _ACPI_DESC_TYPE_NAMED@GOTPAGEOFF]
	ldr	x8, [x23]
	cmp	x0, x8
	b.eq	LBB0_7
; %bb.6:
	mov	x0, x19
	bl	_acpi_ut_get_descriptor_name
	bl	_ACPI_ERROR
	ldr	w0, [x22]
	bl	_return_ACPI_STATUS
LBB0_7:
	ldr	x8, [x19, #8]
Lloh14:
	adrp	x22, _AE_OK@GOTPAGE
Lloh15:
	ldr	x22, [x22, _AE_OK@GOTPAGEOFF]
	cmp	x8, x20
	b.eq	LBB0_12
; %bb.8:
	cbz	x20, LBB0_13
LBB0_9:
	mov	x0, x20
	bl	_ACPI_GET_DESCRIPTOR_TYPE
	ldr	x8, [x23]
	cmp	x0, x8
	b.ne	LBB0_15
; %bb.10:
	ldr	x9, [x20, #8]
	cbz	x9, LBB0_15
; %bb.11:
	mov	x8, x20
	mov	x20, x9
	b	LBB0_14
LBB0_12:
	mov	x0, x19
	bl	_ACPI_DEBUG_PRINT
	ldr	w0, [x22]
	bl	_return_ACPI_STATUS
	cbnz	x20, LBB0_9
LBB0_13:
Lloh16:
	adrp	x8, _ACPI_TYPE_ANY@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ACPI_TYPE_ANY@GOTPAGEOFF]
LBB0_14:
	ldr	x21, [x8]
LBB0_15:
	mov	x0, x19
	bl	_acpi_ut_get_node_name
	bl	_ACPI_DEBUG_PRINT
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_17
; %bb.16:
	mov	x0, x19
	bl	_acpi_ns_detach_object
LBB0_17:
	cbz	x20, LBB0_21
; %bb.18:
	mov	x0, x20
	bl	_acpi_ut_add_reference
	mov	x9, x20
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	mov	x8, x9
	ldr	x9, [x9]
	cbnz	x9, LBB0_19
; %bb.20:
	ldr	x9, [x19, #8]
	str	x9, [x8]
LBB0_21:
	stp	x21, x20, [x19]
	ldr	w0, [x22]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_return_ACPI_STATUS
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ACPI_TYPE_ANY,8,3              ; @ACPI_TYPE_ANY
	.comm	_ns_attach_object,4,2           ; @ns_attach_object
	.comm	_AE_INFO,4,2                    ; @AE_INFO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Null NamedObj handle"

	.comm	_AE_BAD_PARAMETER,4,2           ; @AE_BAD_PARAMETER
l_.str.1:                               ; @.str.1
	.asciz	"Null object, but type not ACPI_TYPE_ANY"

	.comm	_ACPI_DESC_TYPE_NAMED,8,3       ; @ACPI_DESC_TYPE_NAMED
	.comm	_ACPI_DB_EXEC,4,2               ; @ACPI_DB_EXEC
	.comm	_AE_OK,4,2                      ; @AE_OK
.subsections_via_symbols
