	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hisi_read_sccl_and_ccl_id
_hisi_read_sccl_and_ccl_id:             ## @hisi_read_sccl_and_ccl_id
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	xorl	%eax, %eax
	callq	_read_cpuid_mpidr
	movl	%eax, %ebx
	movq	_MPIDR_MT_BITMASK@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_5
## %bb.1:
	movl	%ebx, %edi
	movl	$2, %esi
	callq	_MPIDR_AFFINITY_LEVEL
	testq	%r15, %r15
	je	LBB0_3
## %bb.2:
	movl	%eax, %ecx
	sarl	$3, %ecx
	movl	%ecx, (%r15)
LBB0_3:
	testq	%r14, %r14
	je	LBB0_10
## %bb.4:
	andl	$7, %eax
	jmp	LBB0_9
LBB0_5:
	testq	%r15, %r15
	je	LBB0_7
## %bb.6:
	movl	%ebx, %edi
	movl	$2, %esi
	callq	_MPIDR_AFFINITY_LEVEL
	movl	%eax, (%r15)
LBB0_7:
	testq	%r14, %r14
	je	LBB0_10
## %bb.8:
	movl	%ebx, %edi
	movl	$1, %esi
	callq	_MPIDR_AFFINITY_LEVEL
LBB0_9:
	movl	%eax, (%r14)
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MPIDR_MT_BITMASK,4,2           ## @MPIDR_MT_BITMASK
	.no_dead_strip	_hisi_read_sccl_and_ccl_id
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hisi_read_sccl_and_ccl_id
_hisi_read_sccl_and_ccl_id:             ; @hisi_read_sccl_and_ccl_id
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	bl	_read_cpuid_mpidr
	mov	x21, x0
Lloh0:
	adrp	x8, _MPIDR_MT_BITMASK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MPIDR_MT_BITMASK@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_5
; %bb.1:
	mov	x0, x21
	mov	w1, #2
	bl	_MPIDR_AFFINITY_LEVEL
	cbz	x20, LBB0_3
; %bb.2:
	asr	w8, w0, #3
	str	w8, [x20]
LBB0_3:
	cbz	x19, LBB0_10
; %bb.4:
	and	w0, w0, #0x7
	b	LBB0_9
LBB0_5:
	cbz	x20, LBB0_7
; %bb.6:
	mov	x0, x21
	mov	w1, #2
	bl	_MPIDR_AFFINITY_LEVEL
	str	w0, [x20]
LBB0_7:
	cbz	x19, LBB0_10
; %bb.8:
	mov	x0, x21
	mov	w1, #1
	bl	_MPIDR_AFFINITY_LEVEL
LBB0_9:
	str	w0, [x19]
LBB0_10:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_MPIDR_MT_BITMASK,4,2           ; @MPIDR_MT_BITMASK
	.no_dead_strip	_hisi_read_sccl_and_ccl_id
.subsections_via_symbols
