	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hpc_writecmdtoindex
_hpc_writecmdtoindex:                   ## @hpc_writecmdtoindex
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
                                        ## kill: def $esi killed $esi def $rsi
	movl	%edi, %eax
	leal	-128(%rax), %ecx
	cmpl	$16, %ecx
	ja	LBB0_5
## %bb.1:
	movl	$15, %eax
	movl	$99296, %edx                    ## imm = 0x183E0
	btl	%ecx, %edx
	jb	LBB0_6
## %bb.2:
	movl	$31, %eax
	btl	%ecx, %eax
	jae	LBB0_4
## %bb.3:
	movl	%esi, %eax
	popq	%rbp
	retq
LBB0_4:
	movq	_WPG_1ST_BUS_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addl	%esi, %eax
	decl	%eax
	popq	%rbp
	retq
LBB0_5:
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_err
	movq	_HPC_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_6:
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_WPG_1ST_BUS_INDEX,4,2          ## @WPG_1ST_BUS_INDEX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"hpc_writecmdtoindex - Error invalid cmd[%x]\n"

	.comm	_HPC_ERROR,4,2                  ## @HPC_ERROR
	.no_dead_strip	_hpc_writecmdtoindex
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hpc_writecmdtoindex
_hpc_writecmdtoindex:                   ; @hpc_writecmdtoindex
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	sub	w9, w0, #128
	cmp	w9, #16
	b.hi	LBB0_6
; %bb.1:
	mov	w8, #1
	lsl	w8, w8, w9
	mov	w9, #33760
	movk	w9, #1, lsl #16
	tst	w8, w9
	b.ne	LBB0_4
; %bb.2:
	tst	w8, #0x1f
	b.ne	LBB0_5
; %bb.3:
Lloh0:
	adrp	x8, _WPG_1ST_BUS_INDEX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WPG_1ST_BUS_INDEX@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	add	w8, w1, w8
	sub	w1, w8, #1
	b	LBB0_5
LBB0_4:
	mov	w1, #15
LBB0_5:
	mov	x0, x1
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_6:
	mov	x8, x0
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x8
	bl	_err
Lloh5:
	adrp	x8, _HPC_ERROR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _HPC_ERROR@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_WPG_1ST_BUS_INDEX,4,2          ; @WPG_1ST_BUS_INDEX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"hpc_writecmdtoindex - Error invalid cmd[%x]\n"

	.comm	_HPC_ERROR,4,2                  ; @HPC_ERROR
	.no_dead_strip	_hpc_writecmdtoindex
.subsections_via_symbols
