	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_acpi_ev_detach_region          ## -- Begin function acpi_ev_detach_region
	.p2align	4, 0x90
_acpi_ev_detach_region:                 ## @acpi_ev_detach_region
	.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	%rsi, %r14
	movq	%rdi, %r13
	movq	_ev_detach_region@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_ACPI_FUNCTION_TRACE
	movq	%r13, %rdi
	callq	_acpi_ns_get_secondary_object
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	16(%r13), %r15
	movq	16(%r15), %r12
	testq	%r12, %r12
	je	LBB0_15
## %bb.1:
	leaq	16(%r15), %rbx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	_AOPOBJ_SETUP_COMPLETE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, (%r13)
LBB0_13:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	$0, 16(%r13)
	movq	%r15, %rdi
	callq	_acpi_ut_remove_reference
LBB0_14:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	%r12, %rbx
	movq	8(%r12), %rax
	addq	$8, %rbx
	movq	%rax, %r12
	testq	%rax, %rax
	je	LBB0_15
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%r13, %r12
	jne	LBB0_14
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r15d, %edi
	callq	_ACPI_DEBUG_PRINT
	movq	8(%r13), %rax
	movq	%rax, (%rbx)
	movq	$0, 8(%r13)
	testq	%r14, %r14
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_ACPI_MTX_NAMESPACE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_acpi_ut_release_mutex
	movl	%eax, %edi
	callq	_ACPI_FAILURE
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_acpi_ev_execute_reg_method
	movl	%eax, %edi
	callq	_ACPI_FAILURE
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	24(%r13), %edi
	callq	_acpi_ut_get_region_name
	movl	%eax, %edi
	callq	_ACPI_EXCEPTION
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	testq	%r14, %r14
	je	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_ACPI_MTX_NAMESPACE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_acpi_ut_acquire_mutex
	movl	%eax, %edi
	callq	_ACPI_FAILURE
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_AOPOBJ_SETUP_COMPLETE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_13
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	_ACPI_REGION_DEACTIVATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r15), %edx
	movq	%r13, %rdi
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	callq	*8(%r15)
	movl	%eax, %edi
	callq	_ACPI_FAILURE
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	24(%r13), %edi
	callq	_acpi_ut_get_region_name
	movl	%eax, %edi
	callq	_ACPI_EXCEPTION
	jmp	LBB0_12
LBB0_15:
	movl	%r15d, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ACPI_DEBUG_PRINT               ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ev_detach_region,4,2           ## @ev_detach_region
	.comm	_return_VOID,4,2                ## @return_VOID
	.comm	_ACPI_DB_OPREGION,4,2           ## @ACPI_DB_OPREGION
	.comm	_ACPI_MTX_NAMESPACE,4,2         ## @ACPI_MTX_NAMESPACE
	.comm	_AE_INFO,4,2                    ## @AE_INFO
	.comm	_AOPOBJ_SETUP_COMPLETE,4,2      ## @AOPOBJ_SETUP_COMPLETE
	.comm	_ACPI_REGION_DEACTIVATE,4,2     ## @ACPI_REGION_DEACTIVATE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_acpi_ev_detach_region          ; -- Begin function acpi_ev_detach_region
	.p2align	2
_acpi_ev_detach_region:                 ; @acpi_ev_detach_region
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _ev_detach_region@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ev_detach_region@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_ACPI_FUNCTION_TRACE
	mov	x0, x20
	bl	_acpi_ns_get_secondary_object
	ldr	x21, [x20, #16]
	mov	x27, x21
	ldr	x23, [x27, #16]!
	cbz	x23, LBB0_15
; %bb.1:
	mov	x22, x0
Lloh3:
	adrp	x24, _AOPOBJ_SETUP_COMPLETE@GOTPAGE
Lloh4:
	ldr	x24, [x24, _AOPOBJ_SETUP_COMPLETE@GOTPAGEOFF]
Lloh5:
	adrp	x25, _ACPI_REGION_DEACTIVATE@GOTPAGE
Lloh6:
	ldr	x25, [x25, _ACPI_REGION_DEACTIVATE@GOTPAGEOFF]
Lloh7:
	adrp	x26, _ACPI_MTX_NAMESPACE@GOTPAGE
Lloh8:
	ldr	x26, [x26, _ACPI_MTX_NAMESPACE@GOTPAGEOFF]
	b	LBB0_5
LBB0_2:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x24]
	ldr	w9, [x20]
	bic	w8, w9, w8
	str	w8, [x20]
LBB0_3:                                 ;   in Loop: Header=BB0_5 Depth=1
	str	xzr, [x20, #16]
	mov	x0, x21
	bl	_acpi_ut_remove_reference
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x23, #8]!
	mov	x27, x23
	mov	x23, x8
	cbz	x8, LBB0_15
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	cmp	x23, x20
	b.ne	LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x21
	bl	_ACPI_DEBUG_PRINT
	ldr	x8, [x20, #8]
	str	x8, [x27]
	str	xzr, [x20, #8]
	cbz	x19, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w0, [x26]
	bl	_acpi_ut_release_mutex
	bl	_ACPI_FAILURE
LBB0_8:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x20
	mov	w1, #0
	bl	_acpi_ev_execute_reg_method
	bl	_ACPI_FAILURE
	cbz	x0, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w0, [x20, #24]
	bl	_acpi_ut_get_region_name
	bl	_ACPI_EXCEPTION
LBB0_10:                                ;   in Loop: Header=BB0_5 Depth=1
	cbz	x19, LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_5 Depth=1
	ldr	w0, [x26]
	bl	_acpi_ut_acquire_mutex
	bl	_ACPI_FAILURE
LBB0_12:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x20]
	ldr	w9, [x24]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.13:                               ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x21, #8]
	ldr	w1, [x25]
	ldr	w2, [x21]
	mov	x0, x20
	mov	x3, x22
	blr	x8
	bl	_ACPI_FAILURE
	cbz	x0, LBB0_2
; %bb.14:                               ;   in Loop: Header=BB0_5 Depth=1
	ldr	w0, [x20, #24]
	bl	_acpi_ut_get_region_name
	bl	_ACPI_EXCEPTION
	b	LBB0_2
LBB0_15:
	mov	x0, x21
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_ACPI_DEBUG_PRINT
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_ev_detach_region,4,2           ; @ev_detach_region
	.comm	_return_VOID,4,2                ; @return_VOID
	.comm	_ACPI_DB_OPREGION,4,2           ; @ACPI_DB_OPREGION
	.comm	_ACPI_MTX_NAMESPACE,4,2         ; @ACPI_MTX_NAMESPACE
	.comm	_AE_INFO,4,2                    ; @AE_INFO
	.comm	_AOPOBJ_SETUP_COMPLETE,4,2      ; @AOPOBJ_SETUP_COMPLETE
	.comm	_ACPI_REGION_DEACTIVATE,4,2     ; @ACPI_REGION_DEACTIVATE
.subsections_via_symbols
