	.file	"extr_isa207-common.c_mmcra_sdar_mode.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	mmcra_sdar_mode, @function
mmcra_sdar_mode:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	ebp, edi
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	mov	rbx, rsi
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	mov	edi, DWORD PTR CPU_FTR_ARCH_300[rip]
	call	cpu_has_feature@PLT
	test	rax, rax
	jne	.L10
	mov	rax, QWORD PTR MMCRA_SDAR_MODE_TLB[rip]
	or	QWORD PTR [rbx], rax
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L10:
	.cfi_restore_state
	mov	edi, ebp
	call	is_event_marked@PLT
	test	rax, rax
	mov	rax, QWORD PTR [rbx]
	jne	.L4
	test	QWORD PTR MMCRA_SAMPLE_ENABLE[rip], rax
	jne	.L4
	mov	edi, ebp
	call	p9_SDAR_MODE@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR MMCRA_SDAR_MODE_DCACHE[rip]
	or	QWORD PTR [rbx], rax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L4:
	and	rax, QWORD PTR MMCRA_SDAR_MODE_NO_UPDATES[rip]
	mov	QWORD PTR [rbx], rax
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	mov	edi, ebp
	call	p9_SDAR_MODE@PLT
	mov	rcx, QWORD PTR MMCRA_SDAR_MODE_SHIFT[rip]
	sal	rax, cl
	or	QWORD PTR [rbx], rax
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	mmcra_sdar_mode, .-mmcra_sdar_mode
	.comm	MMCRA_SDAR_MODE_TLB,8,8
	.comm	MMCRA_SDAR_MODE_SHIFT,8,8
	.comm	MMCRA_SDAR_MODE_NO_UPDATES,8,8
	.comm	MMCRA_SDAR_MODE_DCACHE,8,8
	.comm	MMCRA_SAMPLE_ENABLE,8,8
	.comm	CPU_FTR_ARCH_300,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_isa207-common.c_mmcra_sdar_mode.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	mmcra_sdar_mode, %function
mmcra_sdar_mode:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, .L13
	push	{r4, r5, r6, lr}
	mov	r5, r0
	ldr	r0, [r3]
	mov	r4, r1
	bl	cpu_has_feature
	cmp	r0, #0
	bne	.L10
	ldr	r2, .L13+4
	ldr	r3, [r4]
	ldr	r2, [r2]
	orr	r3, r3, r2
	str	r3, [r4]
	pop	{r4, r5, r6, pc}
.L10:
	mov	r0, r5
	bl	is_event_marked
	cmp	r0, #0
	bne	.L11
	ldr	r3, .L13+8
	ldr	r2, [r4]
	ldr	r3, [r3]
	tst	r2, r3
	beq	.L5
.L4:
	ldr	r3, .L13+12
	ldr	r3, [r3]
	and	r3, r3, r2
	str	r3, [r4]
	pop	{r4, r5, r6, pc}
.L11:
	ldr	r2, [r4]
	b	.L4
.L5:
	mov	r0, r5
	bl	p9_SDAR_MODE
	cmp	r0, #0
	bne	.L12
	ldr	r2, .L13+16
	ldr	r3, [r4]
	ldr	r2, [r2]
	orr	r3, r3, r2
	str	r3, [r4]
	pop	{r4, r5, r6, pc}
.L12:
	mov	r0, r5
	bl	p9_SDAR_MODE
	ldr	r2, .L13+20
	ldr	r3, [r4]
	ldr	r2, [r2]
	orr	r3, r3, r0, lsl r2
	str	r3, [r4]
	pop	{r4, r5, r6, pc}
.L14:
	.align	2
.L13:
	.word	CPU_FTR_ARCH_300
	.word	MMCRA_SDAR_MODE_TLB
	.word	MMCRA_SAMPLE_ENABLE
	.word	MMCRA_SDAR_MODE_NO_UPDATES
	.word	MMCRA_SDAR_MODE_DCACHE
	.word	MMCRA_SDAR_MODE_SHIFT
	.size	mmcra_sdar_mode, .-mmcra_sdar_mode
	.comm	MMCRA_SDAR_MODE_TLB,4,4
	.comm	MMCRA_SDAR_MODE_SHIFT,4,4
	.comm	MMCRA_SDAR_MODE_NO_UPDATES,4,4
	.comm	MMCRA_SDAR_MODE_DCACHE,4,4
	.comm	MMCRA_SAMPLE_ENABLE,4,4
	.comm	CPU_FTR_ARCH_300,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
