	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function acpi_battery_set_alarm
_acpi_battery_set_alarm:                ## @acpi_battery_set_alarm
	.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	%r12
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_ACPI_TYPE_INTEGER@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -40(%rbp)
	movl	$1, -56(%rbp)
	leaq	-40(%rbp), %rax
	movq	%rax, -48(%rbp)
	callq	_acpi_battery_present
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	cmpl	$0, 16(%r14)
	je	LBB0_2
## %bb.3:
	movl	(%r14), %eax
	movl	%eax, -40(%rbp)
	leaq	4(%r14), %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	movq	8(%r14), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	leaq	-56(%rbp), %rdx
	xorl	%ecx, %ecx
	callq	_acpi_evaluate_object
	movl	%eax, %r12d
	movq	%r15, %rdi
	callq	_mutex_unlock
	movl	%r12d, %edi
	callq	_ACPI_FAILURE
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_6
LBB0_2:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_6
LBB0_5:
	movl	(%r14), %edi
	callq	_ACPI_DEBUG_PRINT
LBB0_6:
	movl	%ebx, %eax
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ACPI_TYPE_INTEGER,4,2          ## @ACPI_TYPE_INTEGER
	.comm	_ENODEV,4,2                     ## @ENODEV
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"_BTP"

	.comm	_ACPI_DB_INFO,4,2               ## @ACPI_DB_INFO
	.no_dead_strip	_acpi_battery_set_alarm
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function acpi_battery_set_alarm
_acpi_battery_set_alarm:                ; @acpi_battery_set_alarm
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _ACPI_TYPE_INTEGER@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ACPI_TYPE_INTEGER@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [sp, #24]
	mov	w8, #1
	str	w8, [sp, #8]
	add	x8, sp, #24
	str	x8, [sp, #16]
	bl	_acpi_battery_present
	cbz	w0, LBB0_3
; %bb.1:
	ldr	w8, [x19, #16]
	cbz	w8, LBB0_3
; %bb.2:
	ldr	w8, [x19]
	str	w8, [sp, #24]
	add	x20, x19, #4
	mov	x0, x20
	bl	_mutex_lock
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #8
	mov	x3, #0
	bl	_acpi_evaluate_object
	mov	x21, x0
	mov	x0, x20
	bl	_mutex_unlock
	mov	x0, x21
	bl	_ACPI_FAILURE
	cbz	x0, LBB0_5
LBB0_3:
Lloh5:
	adrp	x8, _ENODEV@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_5:
	ldr	w0, [x19]
	bl	_ACPI_DEBUG_PRINT
	mov	w0, #0
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_ACPI_TYPE_INTEGER,4,2          ; @ACPI_TYPE_INTEGER
	.comm	_ENODEV,4,2                     ; @ENODEV
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"_BTP"

	.comm	_ACPI_DB_INFO,4,2               ; @ACPI_DB_INFO
	.no_dead_strip	_acpi_battery_set_alarm
.subsections_via_symbols
