	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function handle_activity
_handle_activity:                       ## @handle_activity
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -24
	movl	%esi, %ebx
	movl	%edi, %ecx
	leaq	L_.str(%rip), %rsi
	leaq	L_.str.1(%rip), %rdx
	leaq	-16(%rbp), %rdi
	callq	_asprintf
	movq	-16(%rbp), %rsi
	testq	%rsi, %rsi
	jne	LBB0_2
## %bb.1:
	leaq	L_.str.2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_err
	movq	-16(%rbp), %rsi
LBB0_2:
	movq	_EFI_GLOBAL_GUID@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-24(%rbp), %rdx
	leaq	-32(%rbp), %rcx
	leaq	-36(%rbp), %r8
	callq	_efi_get_variable
	testq	%rax, %rax
	jns	LBB0_4
## %bb.3:
	movq	-16(%rbp), %rdx
	leaq	L_.str.3(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_err
LBB0_4:
	movq	-24(%rbp), %rdi
	callq	_le32dec
	movq	_LOAD_OPTION_ACTIVE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%esi, %ecx
	orl	%eax, %ecx
	notl	%esi
	andl	%eax, %esi
	testl	%ebx, %ebx
	cmovnel	%ecx, %esi
	movq	-24(%rbp), %rdi
	callq	_le32enc
	movq	-16(%rbp), %rdi
	movq	-24(%rbp), %rsi
	movq	-32(%rbp), %rdx
	callq	_set_bootvar
	testq	%rax, %rax
	jns	LBB0_6
## %bb.5:
	leaq	L_.str.4(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	callq	_err
LBB0_6:
	addq	$40, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s%04X"

L_.str.1:                               ## @.str.1
	.asciz	"Boot"

L_.str.2:                               ## @.str.2
	.asciz	"asprintf"

	.comm	_EFI_GLOBAL_GUID,4,2            ## @EFI_GLOBAL_GUID
L_.str.3:                               ## @.str.3
	.asciz	"No such bootvar %s\n"

	.comm	_LOAD_OPTION_ACTIVE,4,2         ## @LOAD_OPTION_ACTIVE
L_.str.4:                               ## @.str.4
	.asciz	"handle activity efi_set_variable"

	.no_dead_strip	_handle_activity
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function handle_activity
_handle_activity:                       ; @handle_activity
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x19, x1
	mov	x3, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
Lloh2:
	adrp	x2, l_.str.1@PAGE
Lloh3:
	add	x2, x2, l_.str.1@PAGEOFF
	add	x0, sp, #16
	bl	_asprintf
	ldr	x1, [sp, #16]
	cbnz	x1, LBB0_2
; %bb.1:
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_err
	ldr	x1, [sp, #16]
LBB0_2:
Lloh6:
	adrp	x8, _EFI_GLOBAL_GUID@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EFI_GLOBAL_GUID@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	add	x2, sp, #32
	add	x3, sp, #24
	sub	x4, x29, #20
	bl	_efi_get_variable
	tbz	x0, #63, LBB0_4
; %bb.3:
	ldr	x8, [sp, #16]
	str	x8, [sp]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_4:
	ldr	x0, [sp, #32]
	bl	_le32dec
Lloh11:
	adrp	x8, _LOAD_OPTION_ACTIVE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _LOAD_OPTION_ACTIVE@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	orr	w9, w8, w0
	bic	w8, w0, w8
	cmp	w19, #0
	csel	w1, w8, w9, eq
	ldr	x0, [sp, #32]
	bl	_le32enc
	ldp	x0, x2, [sp, #16]
	ldr	x1, [sp, #32]
	bl	_set_bootvar
	tbz	x0, #63, LBB0_6
; %bb.5:
Lloh14:
	adrp	x1, l_.str.4@PAGE
Lloh15:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_6:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s%04X"

l_.str.1:                               ; @.str.1
	.asciz	"Boot"

l_.str.2:                               ; @.str.2
	.asciz	"asprintf"

	.comm	_EFI_GLOBAL_GUID,4,2            ; @EFI_GLOBAL_GUID
l_.str.3:                               ; @.str.3
	.asciz	"No such bootvar %s\n"

	.comm	_LOAD_OPTION_ACTIVE,4,2         ; @LOAD_OPTION_ACTIVE
l_.str.4:                               ; @.str.4
	.asciz	"handle activity efi_set_variable"

	.no_dead_strip	_handle_activity
.subsections_via_symbols
