	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ReportStatusToSCMgr            ## -- Begin function ReportStatusToSCMgr
	.p2align	4, 0x90
_ReportStatusToSCMgr:                   ## @ReportStatusToSCMgr
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	(%rsi), %rcx
	movq	_SERVICE_START_PENDING@GOTPCREL(%rip), %rbx
	xorl	%eax, %eax
	movl	$0, %edx
	cmpq	(%rbx), %rcx
	je	LBB0_2
## %bb.1:
	movq	_SERVICE_ACCEPT_STOP@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
LBB0_2:
	movq	%rdx, 16(%rsi)
	movq	_SERVICE_RUNNING@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_5
## %bb.3:
	movq	_SERVICE_STOPPED@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_5
## %bb.4:
	movslq	_ReportStatusToSCMgr.dwCheckPoint(%rip), %rax
	leal	1(%rax), %ecx
	movl	%ecx, _ReportStatusToSCMgr.dwCheckPoint(%rip)
LBB0_5:
	movq	%rax, 8(%rsi)
	callq	_SetServiceStatus
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_7
## %bb.6:
	movq	_MSG_FLAGS_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	leaq	L_.str(%rip), %rdi
	callq	_TEXT
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_MsgToEventLog
LBB0_7:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__DATA,__data
	.p2align	2                               ## @ReportStatusToSCMgr.dwCheckPoint
_ReportStatusToSCMgr.dwCheckPoint:
	.long	1                               ## 0x1

	.comm	_TRUE,4,2                       ## @TRUE
	.comm	_SERVICE_START_PENDING,8,3      ## @SERVICE_START_PENDING
	.comm	_SERVICE_ACCEPT_STOP,8,3        ## @SERVICE_ACCEPT_STOP
	.comm	_SERVICE_RUNNING,8,3            ## @SERVICE_RUNNING
	.comm	_SERVICE_STOPPED,8,3            ## @SERVICE_STOPPED
	.comm	_MSG_FLAGS_ERROR,4,2            ## @MSG_FLAGS_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SetServiceStatus"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ReportStatusToSCMgr            ; -- Begin function ReportStatusToSCMgr
	.p2align	2
_ReportStatusToSCMgr:                   ; @ReportStatusToSCMgr
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x8, #0
	ldr	x9, [x1]
Lloh0:
	adrp	x10, _SERVICE_START_PENDING@GOTPAGE
Lloh1:
	ldr	x10, [x10, _SERVICE_START_PENDING@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x10]
Lloh3:
	adrp	x11, _SERVICE_ACCEPT_STOP@GOTPAGE
Lloh4:
	ldr	x11, [x11, _SERVICE_ACCEPT_STOP@GOTPAGEOFF]
Lloh5:
	ldr	x11, [x11]
	cmp	x9, x10
	csel	x10, xzr, x11, eq
	str	x10, [x1, #16]
Lloh6:
	adrp	x10, _SERVICE_RUNNING@GOTPAGE
Lloh7:
	ldr	x10, [x10, _SERVICE_RUNNING@GOTPAGEOFF]
Lloh8:
	ldr	x10, [x10]
	cmp	x9, x10
Lloh9:
	adrp	x10, _SERVICE_STOPPED@GOTPAGE
Lloh10:
	ldr	x10, [x10, _SERVICE_STOPPED@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	ccmp	x9, x10, #4, ne
	b.eq	LBB0_2
; %bb.1:
	adrp	x9, _ReportStatusToSCMgr.dwCheckPoint@PAGE
	ldrsw	x8, [x9, _ReportStatusToSCMgr.dwCheckPoint@PAGEOFF]
	add	w10, w8, #1
	str	w10, [x9, _ReportStatusToSCMgr.dwCheckPoint@PAGEOFF]
LBB0_2:
	str	x8, [x1, #8]
	bl	_SetServiceStatus
	mov	x19, x0
	cbnz	w0, LBB0_4
; %bb.3:
Lloh12:
	adrp	x8, _MSG_FLAGS_ERROR@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MSG_FLAGS_ERROR@GOTPAGEOFF]
Lloh14:
	ldr	w20, [x8]
Lloh15:
	adrp	x0, l_.str@PAGE
Lloh16:
	add	x0, x0, l_.str@PAGEOFF
	bl	_TEXT
	mov	x1, x0
	mov	x0, x20
	bl	_MsgToEventLog
LBB0_4:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__DATA,__data
	.p2align	2                               ; @ReportStatusToSCMgr.dwCheckPoint
_ReportStatusToSCMgr.dwCheckPoint:
	.long	1                               ; 0x1

	.comm	_TRUE,4,2                       ; @TRUE
	.comm	_SERVICE_START_PENDING,8,3      ; @SERVICE_START_PENDING
	.comm	_SERVICE_ACCEPT_STOP,8,3        ; @SERVICE_ACCEPT_STOP
	.comm	_SERVICE_RUNNING,8,3            ; @SERVICE_RUNNING
	.comm	_SERVICE_STOPPED,8,3            ; @SERVICE_STOPPED
	.comm	_MSG_FLAGS_ERROR,4,2            ; @MSG_FLAGS_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SetServiceStatus"

.subsections_via_symbols
