	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pwc_set_leds                   ## -- Begin function pwc_set_leds
	.p2align	4, 0x90
_pwc_set_leds:                          ## @pwc_set_leds
	.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
	pushq	%rax
	.cfi_offset %rbx, -24
	xorl	%ebx, %ebx
	cmpl	$730, (%rdi)                    ## imm = 0x2DA
	jl	LBB0_3
## %bb.1:
	movslq	%esi, %rax
	imulq	$1374389535, %rax, %rax         ## imm = 0x51EB851F
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$37, %rax
	addl	%ecx, %eax
	movslq	%edx, %rcx
	imulq	$1374389535, %rcx, %rdx         ## imm = 0x51EB851F
	movq	%rdx, %rcx
	shrq	$63, %rcx
	sarq	$37, %rdx
	addl	%ecx, %edx
	xorl	%ecx, %ecx
	testl	%eax, %eax
	cmovlel	%ecx, %eax
	cmpl	$255, %eax
	movl	$255, %esi
	cmovael	%esi, %eax
	testl	%edx, %edx
	cmovlel	%ecx, %edx
	cmpl	$255, %edx
	cmovael	%esi, %edx
	movq	8(%rdi), %rcx
	movl	%eax, (%rcx)
	movl	%edx, 4(%rcx)
	movq	_SET_STATUS_CTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_LED_FORMATTER@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$2, %r8d
	callq	_send_control_msg
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	callq	_PWC_ERROR
LBB0_3:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SET_STATUS_CTL,4,2             ## @SET_STATUS_CTL
	.comm	_LED_FORMATTER,4,2              ## @LED_FORMATTER
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to set LED on/off time (%d)\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pwc_set_leds                   ; -- Begin function pwc_set_leds
	.p2align	2
_pwc_set_leds:                          ; @pwc_set_leds
	.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
	ldr	w8, [x0]
	cmp	w8, #730
	b.ge	LBB0_2
; %bb.1:
	mov	w19, #0
	b	LBB0_4
LBB0_2:
	mov	w8, #34079
	movk	w8, #20971, lsl #16
	smull	x9, w1, w8
	lsr	x10, x9, #63
	asr	x9, x9, #37
	add	w9, w9, w10
	smull	x8, w2, w8
	lsr	x10, x8, #63
	asr	x8, x8, #37
	add	w8, w8, w10
	cmp	w9, #0
	csel	w9, w9, wzr, gt
	mov	w10, #255
	cmp	w9, #255
	csel	w9, w9, w10, lo
	cmp	w8, #0
	csel	w8, w8, wzr, gt
	cmp	w8, #255
	csel	w8, w8, w10, lo
	ldr	x3, [x0, #8]
	stp	w9, w8, [x3]
Lloh0:
	adrp	x8, _SET_STATUS_CTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SET_STATUS_CTL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _LED_FORMATTER@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LED_FORMATTER@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	w4, #2
	bl	_send_control_msg
	mov	x19, x0
	tbz	w0, #31, LBB0_4
; %bb.3:
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_PWC_ERROR
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	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_SET_STATUS_CTL,4,2             ; @SET_STATUS_CTL
	.comm	_LED_FORMATTER,4,2              ; @LED_FORMATTER
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to set LED on/off time (%d)\n"

.subsections_via_symbols
