	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_intel_enable_engine_stats      ## -- Begin function intel_enable_engine_stats
	.p2align	4, 0x90
_intel_enable_engine_stats:             ## @intel_enable_engine_stats
	.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	%rdi, %r15
	callq	_intel_engine_supports_stats
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	leaq	32(%r15), %r14
	movq	%r14, %rdi
	callq	_execlists_active_lock_bh
	movq	%r15, %rdi
	callq	_write_seqlock_irqsave
	xorl	%edi, %edi
	cmpl	$-1, 24(%r15)
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_16
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_17
LBB0_4:
	movl	24(%r15), %eax
	leal	1(%rax), %ecx
	movl	%ecx, 24(%r15)
	xorl	%ebx, %ebx
	testl	%eax, %eax
	jne	LBB0_16
## %bb.5:
	xorl	%eax, %eax
	callq	_ktime_get
	movl	%eax, 4(%r15)
	movq	40(%r15), %rax
	cmpq	$0, (%rax)
	je	LBB0_9
## %bb.6:
	movq	16(%r15), %rcx
	addq	$8, %rax
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	incq	%rcx
	cmpq	$0, (%rax)
	leaq	8(%rax), %rax
	jne	LBB0_7
## %bb.8:
	movq	%rcx, 16(%r15)
LBB0_9:
	movq	(%r14), %rbx
	movq	(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_14
## %bb.10:
	addq	$8, %rbx
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	movq	(%rbx), %rax
	addq	$8, %rbx
	testq	%rax, %rax
	je	LBB0_14
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movl	(%rax), %edi
	callq	_intel_context_inflight_count
	testl	%eax, %eax
	jne	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	incq	16(%r15)
	jmp	LBB0_13
LBB0_14:
	xorl	%ebx, %ebx
	cmpq	$0, 16(%r15)
	je	LBB0_16
## %bb.15:
	movl	4(%r15), %eax
	movl	%eax, 8(%r15)
LBB0_16:
	movq	%r15, %rdi
	callq	_write_sequnlock_irqrestore
	movq	%r14, %rdi
	callq	_execlists_active_unlock_bh
LBB0_17:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_EBUSY,4,2                      ## @EBUSY
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_intel_enable_engine_stats      ; -- Begin function intel_enable_engine_stats
	.p2align	2
_intel_enable_engine_stats:             ; @intel_enable_engine_stats
	.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, x0
	bl	_intel_engine_supports_stats
	cbz	w0, LBB0_3
; %bb.1:
	add	x20, x19, #32
	mov	x0, x20
	bl	_execlists_active_lock_bh
	mov	x0, x19
	bl	_write_seqlock_irqsave
	ldr	w8, [x19, #24]
	cmn	w8, #1
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_4
; %bb.2:
Lloh0:
	adrp	x8, _EBUSY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_17
LBB0_3:
Lloh3:
	adrp	x8, _ENODEV@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_18
LBB0_4:
	ldr	w8, [x19, #24]
	add	w9, w8, #1
	str	w9, [x19, #24]
	cbz	w8, LBB0_6
LBB0_5:
	mov	w21, #0
	b	LBB0_17
LBB0_6:
	bl	_ktime_get
	str	w0, [x19, #4]
	ldr	x9, [x19, #40]
	ldr	x8, [x9]
	cbz	x8, LBB0_10
; %bb.7:
	ldr	x8, [x19, #16]
	add	x9, x9, #8
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	add	x8, x8, #1
	ldr	x10, [x9], #8
	cbnz	x10, LBB0_8
; %bb.9:
	str	x8, [x19, #16]
LBB0_10:
	ldr	x9, [x20]
	ldr	x8, [x9]
	cbz	x8, LBB0_15
; %bb.11:
	add	x21, x9, #8
	b	LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	ldr	x8, [x21], #8
	cbz	x8, LBB0_15
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x8]
	bl	_intel_context_inflight_count
	cbnz	w0, LBB0_12
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x8, [x19, #16]
	add	x8, x8, #1
	str	x8, [x19, #16]
	b	LBB0_12
LBB0_15:
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_5
; %bb.16:
	mov	w21, #0
	ldr	w8, [x19, #4]
	str	w8, [x19, #8]
LBB0_17:
	mov	x0, x19
	bl	_write_sequnlock_irqrestore
	mov	x0, x20
	bl	_execlists_active_unlock_bh
LBB0_18:
	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
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_EBUSY,4,2                      ; @EBUSY
.subsections_via_symbols
