	.file	"extr_topology.c_store_cpu_topology.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"CPU%u: cluster %d core %d thread %d mpidr %#016llx\n"
	.text
	.p2align 4
	.globl	store_cpu_topology
	.type	store_cpu_topology, @function
store_cpu_topology:
.LFB0:
	.cfi_startproc
	endbr64
	mov	eax, edi
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	lea	rdx, [rax+rax*2]
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rax
	mov	rax, QWORD PTR cpu_topology[rip]
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	lea	rbx, [rax+rdx*4]
	cmp	DWORD PTR [rbx], -1
	je	.L8
.L2:
	endbr64
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	edi, ebp
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	update_siblings_masks@PLT
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	xor	eax, eax
	call	read_cpuid_mpidr@PLT
	mov	r12d, eax
	test	DWORD PTR MPIDR_UP_BITMASK[rip], eax
	jne	.L1
	test	DWORD PTR MPIDR_MT_BITMASK[rip], eax
	jne	.L9
	mov	DWORD PTR 4[rbx], -1
	xor	esi, esi
	mov	edi, eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	mov	esi, 1
	mov	edi, r12d
	mov	DWORD PTR 8[rbx], eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	mov	esi, 2
	mov	edi, r12d
	mov	r14d, eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	mov	esi, 3
	mov	edi, r12d
	mov	r13d, eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	sal	r13d, 8
	sal	eax, 16
	or	r13d, eax
	mov	edx, r13d
	or	edx, r14d
	mov	DWORD PTR [rbx], edx
.L5:
	mov	ecx, DWORD PTR 8[rbx]
	mov	r8d, DWORD PTR 4[rbx]
	mov	r9d, r12d
	mov	esi, ebp
	lea	rdi, .LC0[rip]
	call	pr_debug@PLT
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	edi, ebp
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	update_siblings_masks@PLT
	.p2align 4,,10
	.p2align 3
.L9:
	.cfi_restore_state
	xor	esi, esi
	mov	edi, eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	mov	esi, 1
	mov	edi, r12d
	mov	DWORD PTR 4[rbx], eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	mov	esi, 2
	mov	edi, r12d
	mov	DWORD PTR 8[rbx], eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	mov	esi, 3
	mov	edi, r12d
	mov	r13d, eax
	call	MPIDR_AFFINITY_LEVEL@PLT
	sal	eax, 8
	mov	edx, eax
	or	edx, r13d
	mov	DWORD PTR [rbx], edx
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L1:
	pop	rbx
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	store_cpu_topology, .-store_cpu_topology
	.comm	cpu_topology,8,8
	.comm	MPIDR_UP_BITMASK,4,4
	.comm	MPIDR_MT_BITMASK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_topology.c_store_cpu_topology.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"CPU%u: cluster %d core %d thread %d mpidr %#016llx\012"
	.ascii	"\000"
	.text
	.align	2
	.global	store_cpu_topology
	.syntax unified
	.arm
	.fpu softvfp
	.type	store_cpu_topology, %function
store_cpu_topology:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r2, .L10
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	add	r3, r0, r0, lsl #1
	ldr	r6, [r2]
	lsl	r8, r3, #2
	ldr	r9, [r6, r8]
	mov	r4, r0
	cmn	r9, #1
	sub	sp, sp, #8
	add	r5, r6, r3, lsl #2
	beq	.L8
.L2:
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	b	update_siblings_masks
.L8:
	bl	read_cpuid_mpidr
	ldr	r3, .L10+4
	mov	r7, r0
	ldr	r1, [r3]
	ands	r1, r0, r1
	bne	.L1
	ldr	r3, .L10+8
	ldr	r3, [r3]
	ands	r3, r0, r3
	bne	.L9
	mov	r1, r3
	str	r9, [r5, #4]
	bl	MPIDR_AFFINITY_LEVEL
	mov	r1, #1
	str	r0, [r5, #8]
	mov	r0, r7
	bl	MPIDR_AFFINITY_LEVEL
	mov	r1, #2
	mov	r9, r0
	mov	r0, r7
	bl	MPIDR_AFFINITY_LEVEL
	mov	r1, #3
	mov	r10, r0
	mov	r0, r7
	bl	MPIDR_AFFINITY_LEVEL
	lsl	r2, r0, #16
	orr	r2, r2, r10, lsl #8
	orr	r2, r2, r9
	str	r2, [r6, r8]
.L5:
	ldr	r3, [r5, #8]
	str	r7, [sp, #4]
	ldr	r1, [r5, #4]
	ldr	r0, .L10+12
	str	r1, [sp]
	mov	r1, r4
	bl	pr_debug
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	b	update_siblings_masks
.L9:
	bl	MPIDR_AFFINITY_LEVEL
	mov	r1, #1
	str	r0, [r5, #4]
	mov	r0, r7
	bl	MPIDR_AFFINITY_LEVEL
	mov	r1, #2
	str	r0, [r5, #8]
	mov	r0, r7
	bl	MPIDR_AFFINITY_LEVEL
	mov	r1, #3
	mov	r9, r0
	mov	r0, r7
	bl	MPIDR_AFFINITY_LEVEL
	orr	r2, r9, r0, lsl #8
	str	r2, [r6, r8]
	b	.L5
.L1:
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L11:
	.align	2
.L10:
	.word	cpu_topology
	.word	MPIDR_UP_BITMASK
	.word	MPIDR_MT_BITMASK
	.word	.LC0
	.size	store_cpu_topology, .-store_cpu_topology
	.comm	cpu_topology,4,4
	.comm	MPIDR_UP_BITMASK,4,4
	.comm	MPIDR_MT_BITMASK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
