	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function arm_spe_perf_aux_output_begin
_arm_spe_perf_aux_output_begin:         ## @arm_spe_perf_aux_output_begin
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	callq	_perf_aux_output_begin
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	cmpq	$0, 8(%rax)
	je	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	callq	_arm_spe_pmu_next_snapshot_off
	jmp	LBB0_5
LBB0_1:
	movq	_PERF_HES_STOPPED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%rbx)
	xorl	%r13d, %r13d
	jmp	LBB0_9
LBB0_4:
	movq	%r14, %rdi
	callq	_arm_spe_pmu_next_off
LBB0_5:
	movl	%eax, %r12d
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movq	_SYS_PMBLIMITR_EL1_E_SHIFT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_BIT
	movl	%eax, %r13d
	orl	%r12d, %r13d
	jmp	LBB0_8
LBB0_6:
	xorl	%r13d, %r13d
LBB0_8:
	movl	(%r15), %ebx
	addl	%ebx, %r13d
	movl	(%r14), %edi
	movq	%r15, %rsi
	callq	_PERF_IDX2OFF
	addl	%eax, %ebx
	movq	_SYS_PMBPTR_EL1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	callq	_write_sysreg_s
LBB0_9:
	movq	_SYS_PMBLIMITR_EL1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r13d, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_write_sysreg_s                 ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_PERF_HES_STOPPED,4,2           ## @PERF_HES_STOPPED
	.comm	_SYS_PMBLIMITR_EL1_E_SHIFT,4,2  ## @SYS_PMBLIMITR_EL1_E_SHIFT
	.comm	_SYS_PMBPTR_EL1,4,2             ## @SYS_PMBPTR_EL1
	.comm	_SYS_PMBLIMITR_EL1,4,2          ## @SYS_PMBLIMITR_EL1
	.no_dead_strip	_arm_spe_perf_aux_output_begin
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function arm_spe_perf_aux_output_begin
_arm_spe_perf_aux_output_begin:         ; @arm_spe_perf_aux_output_begin
	.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	x22, x1
	mov	x19, x0
	bl	_perf_aux_output_begin
	cbz	x0, LBB0_4
; %bb.1:
	mov	x20, x0
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_5
; %bb.2:
	mov	x0, x19
	bl	_arm_spe_pmu_next_snapshot_off
	mov	x21, x0
	cbz	w0, LBB0_6
LBB0_3:
Lloh0:
	adrp	x8, _SYS_PMBLIMITR_EL1_E_SHIFT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SYS_PMBLIMITR_EL1_E_SHIFT@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_BIT
	orr	w8, w0, w21
	b	LBB0_7
LBB0_4:
	mov	w21, #0
Lloh3:
	adrp	x8, _PERF_HES_STOPPED@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PERF_HES_STOPPED@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
	b	LBB0_8
LBB0_5:
	mov	x0, x19
	bl	_arm_spe_pmu_next_off
	mov	x21, x0
	cbnz	w0, LBB0_3
LBB0_6:
	mov	w8, #0
LBB0_7:
	ldr	w22, [x20]
	add	w21, w8, w22
	ldr	w0, [x19]
	mov	x1, x20
	bl	_PERF_IDX2OFF
	add	w0, w0, w22
Lloh6:
	adrp	x8, _SYS_PMBPTR_EL1@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SYS_PMBPTR_EL1@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_write_sysreg_s
LBB0_8:
Lloh9:
	adrp	x8, _SYS_PMBLIMITR_EL1@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SYS_PMBLIMITR_EL1@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x21
	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
	b	_write_sysreg_s
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_PERF_HES_STOPPED,4,2           ; @PERF_HES_STOPPED
	.comm	_SYS_PMBLIMITR_EL1_E_SHIFT,4,2  ; @SYS_PMBLIMITR_EL1_E_SHIFT
	.comm	_SYS_PMBPTR_EL1,4,2             ; @SYS_PMBPTR_EL1
	.comm	_SYS_PMBLIMITR_EL1,4,2          ; @SYS_PMBLIMITR_EL1
	.no_dead_strip	_arm_spe_perf_aux_output_begin
.subsections_via_symbols
