	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function t4_get_tp_e2c_map
_t4_get_tp_e2c_map:                     ## @t4_get_tp_e2c_map
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movl	$0, -28(%rbp)
	movq	_MPS_CMN_CTL_A@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_t4_read_reg
	movl	%eax, %edi
	callq	_NUMPORTS_G
	movl	%eax, %ecx
	movl	$1, %eax
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %eax
	cmpl	%r14d, %eax
	jbe	LBB0_1
## %bb.2:
	movq	_FW_PARAMS_MNEM_DEV@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_FW_PARAMS_MNEM_V
	movl	%eax, %r15d
	movq	_FW_PARAMS_PARAM_DEV_TPCHMAP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_FW_PARAMS_PARAM_X_V
	orl	%r15d, %eax
	movl	%eax, -32(%rbp)
	movl	(%rbx), %edx
	movl	4(%rbx), %esi
	leaq	-28(%rbp), %rax
	movq	%rax, (%rsp)
	xorl	%r15d, %r15d
	leaq	-32(%rbp), %r9
	movq	%rbx, %rdi
	xorl	%ecx, %ecx
	movl	$1, %r8d
	callq	_t4_query_params_ns
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movl	-28(%rbp), %eax
	shll	$3, %r14d
	movl	%r14d, %ecx
	sarl	%cl, %eax
	movzbl	%al, %r15d
	jmp	LBB0_4
LBB0_1:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	movl	%eax, %ecx
	callq	_CH_WARN
	xorl	%r15d, %r15d
LBB0_4:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MPS_CMN_CTL_A,4,2              ## @MPS_CMN_CTL_A
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"TP E2C Channel Port Index %d >= Nports %d\n"

	.comm	_FW_PARAMS_MNEM_DEV,4,2         ## @FW_PARAMS_MNEM_DEV
	.comm	_FW_PARAMS_PARAM_DEV_TPCHMAP,4,2 ## @FW_PARAMS_PARAM_DEV_TPCHMAP
	.no_dead_strip	_t4_get_tp_e2c_map
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function t4_get_tp_e2c_map
_t4_get_tp_e2c_map:                     ; @t4_get_tp_e2c_map
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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, x1
	mov	x20, x0
	str	wzr, [sp, #8]
Lloh0:
	adrp	x8, _MPS_CMN_CTL_A@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MPS_CMN_CTL_A@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_t4_read_reg
	bl	_NUMPORTS_G
	mov	w8, #1
	lsl	w3, w8, w0
	cmp	w3, w19
	b.ls	LBB0_3
; %bb.1:
Lloh3:
	adrp	x8, _FW_PARAMS_MNEM_DEV@GOTPAGE
Lloh4:
	ldr	x8, [x8, _FW_PARAMS_MNEM_DEV@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_FW_PARAMS_MNEM_V
	mov	x21, x0
Lloh6:
	adrp	x8, _FW_PARAMS_PARAM_DEV_TPCHMAP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _FW_PARAMS_PARAM_DEV_TPCHMAP@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_FW_PARAMS_PARAM_X_V
	orr	w8, w0, w21
	str	w8, [sp, #12]
	ldp	w2, w1, [x20]
	add	x5, sp, #12
	add	x6, sp, #8
	mov	x0, x20
	mov	w3, #0
	mov	w4, #1
	bl	_t4_query_params_ns
	mov	x8, x0
	mov	w0, #0
	cbnz	w8, LBB0_4
; %bb.2:
	ldr	w8, [sp, #8]
	lsl	w9, w19, #3
	asr	w8, w8, w9
	and	w0, w8, #0xff
	b	LBB0_4
LBB0_3:
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x19
	bl	_CH_WARN
	mov	w0, #0
LBB0_4:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_MPS_CMN_CTL_A,4,2              ; @MPS_CMN_CTL_A
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"TP E2C Channel Port Index %d >= Nports %d\n"

	.comm	_FW_PARAMS_MNEM_DEV,4,2         ; @FW_PARAMS_MNEM_DEV
	.comm	_FW_PARAMS_PARAM_DEV_TPCHMAP,4,2 ; @FW_PARAMS_PARAM_DEV_TPCHMAP
	.no_dead_strip	_t4_get_tp_e2c_map
.subsections_via_symbols
