	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pt_qry_header_mode             ## -- Begin function pt_qry_header_mode
	.p2align	4, 0x90
_pt_qry_header_mode:                    ## @pt_qry_header_mode
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.3:
	movq	%rdi, %r14
	movl	(%rdi), %esi
	leaq	8(%rdi), %rdx
	leaq	-40(%rbp), %rdi
	callq	_pt_pkt_read_mode
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_11
## %bb.4:
	leaq	4(%r14), %rdi
	movq	_evb_psbend@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pt_evq_enqueue
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	%rax, %r15
	movl	-40(%rbp), %eax
	cmpl	$128, %eax
	je	LBB0_9
## %bb.7:
	cmpl	$129, %eax
	jne	LBB0_10
## %bb.8:
	movq	_ptev_exec_mode@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r15)
	leaq	-28(%rbp), %rdi
	callq	_pt_get_exec_mode
	movl	%eax, 8(%r15)
	jmp	LBB0_10
LBB0_1:
	movq	_pte_internal@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_5:
	movq	_pte_nomem@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_11
LBB0_9:
	movq	_ptev_tsx@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r15)
	movl	-32(%rbp), %eax
	movl	%eax, 4(%r15)
	movl	-36(%rbp), %eax
	movl	%eax, (%r15)
LBB0_10:
	addl	%ebx, (%r14)
	xorl	%ebx, %ebx
LBB0_11:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_pte_internal,4,2               ## @pte_internal
	.comm	_evb_psbend,4,2                 ## @evb_psbend
	.comm	_pte_nomem,4,2                  ## @pte_nomem
	.comm	_ptev_exec_mode,4,2             ## @ptev_exec_mode
	.comm	_ptev_tsx,4,2                   ## @ptev_tsx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pt_qry_header_mode             ; -- Begin function pt_qry_header_mode
	.p2align	2
_pt_qry_header_mode:                    ; @pt_qry_header_mode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	cbz	x0, LBB0_6
; %bb.1:
	mov	x20, x0
	mov	x2, x0
	ldr	w1, [x2], #8
	mov	x0, sp
	bl	_pt_pkt_read_mode
	mov	x19, x0
	tbnz	w0, #31, LBB0_11
; %bb.2:
	add	x0, x20, #4
Lloh0:
	adrp	x8, _evb_psbend@GOTPAGE
Lloh1:
	ldr	x8, [x8, _evb_psbend@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_pt_evq_enqueue
	cbz	x0, LBB0_7
; %bb.3:
	mov	x21, x0
	ldr	w8, [sp]
	cmp	w8, #128
	b.eq	LBB0_9
; %bb.4:
	cmp	w8, #129
	b.ne	LBB0_10
; %bb.5:
Lloh3:
	adrp	x8, _ptev_exec_mode@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ptev_exec_mode@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [x21, #12]
	mov	x8, sp
	add	x0, x8, #12
	bl	_pt_get_exec_mode
	str	w0, [x21, #8]
	b	LBB0_10
LBB0_6:
Lloh6:
	adrp	x8, _pte_internal@GOTPAGE
Lloh7:
	ldr	x8, [x8, _pte_internal@GOTPAGEOFF]
	b	LBB0_8
LBB0_7:
Lloh8:
	adrp	x8, _pte_nomem@GOTPAGE
Lloh9:
	ldr	x8, [x8, _pte_nomem@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_11
LBB0_9:
Lloh10:
	adrp	x8, _ptev_tsx@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ptev_tsx@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	str	w8, [x21, #12]
	ldur	d0, [sp, #4]
	str	d0, [x21]
LBB0_10:
	ldr	w8, [x20]
	add	w8, w8, w19
	mov	w19, #0
	str	w8, [x20]
LBB0_11:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_pte_internal,4,2               ; @pte_internal
	.comm	_evb_psbend,4,2                 ; @evb_psbend
	.comm	_pte_nomem,4,2                  ; @pte_nomem
	.comm	_ptev_exec_mode,4,2             ; @ptev_exec_mode
	.comm	_ptev_tsx,4,2                   ; @ptev_tsx
.subsections_via_symbols
