	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function remote_rdp_fetch_register
_remote_rdp_fetch_register:             ## @remote_rdp_fetch_register
	.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	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	cmpl	$-1, %edi
	je	LBB0_1
## %bb.4:
	movl	%edi, %ebx
	movq	%rsp, %r15
	movq	_MAX_REGISTER_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r14
	cmpl	$14, %ebx
	jg	LBB0_6
## %bb.5:
	movl	$1, %edi
	movl	%ebx, %ecx
	shll	%cl, %edi
	jmp	LBB0_9
LBB0_1:
	movq	_NUM_REGS@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_20
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %edi
	callq	_remote_rdp_fetch_register
	incl	%ebx
	cmpl	(%r14), %ebx
	jl	LBB0_3
	jmp	LBB0_20
LBB0_6:
	movq	_ARM_PC_REGNUM@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jne	LBB0_10
## %bb.7:
	movq	_RDP_CPU_READWRITE_MASK_PC@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_10:
	movq	_ARM_PS_REGNUM@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jne	LBB0_12
## %bb.11:
	movq	_RDP_CPU_READWRITE_MASK_CPSR@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %edi
LBB0_9:
	movq	%r14, %rsi
	callq	_rdp_fetch_one_register
LBB0_19:
	movl	%ebx, %edi
	movq	%r14, %rsi
	callq	_supply_register
	movq	%r15, %rsp
LBB0_20:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_22
## %bb.21:
	leaq	-24(%rbp), %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movq	_ARM_FPS_REGNUM@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jne	LBB0_15
## %bb.13:
	movq	_RDP_FPU_READWRITE_MASK_FPS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	jmp	LBB0_14
LBB0_15:
	movq	_ARM_F0_REGNUM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpl	%ebx, %eax
	jg	LBB0_18
## %bb.16:
	movq	_ARM_F7_REGNUM@GOTPCREL(%rip), %rcx
	cmpl	%ebx, (%rcx)
	jl	LBB0_18
## %bb.17:
	movl	%ebx, %ecx
	subl	%eax, %ecx
	movl	$1, %edi
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %edi
LBB0_14:
	movq	%r14, %rsi
	callq	_rdp_fetch_one_fpu_register
	jmp	LBB0_19
LBB0_18:
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	callq	_printf
	jmp	LBB0_19
LBB0_22:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_NUM_REGS,4,2                   ## @NUM_REGS
	.comm	_MAX_REGISTER_SIZE,4,2          ## @MAX_REGISTER_SIZE
	.comm	_ARM_PC_REGNUM,4,2              ## @ARM_PC_REGNUM
	.comm	_RDP_CPU_READWRITE_MASK_PC,4,2  ## @RDP_CPU_READWRITE_MASK_PC
	.comm	_ARM_PS_REGNUM,4,2              ## @ARM_PS_REGNUM
	.comm	_RDP_CPU_READWRITE_MASK_CPSR,4,2 ## @RDP_CPU_READWRITE_MASK_CPSR
	.comm	_ARM_FPS_REGNUM,4,2             ## @ARM_FPS_REGNUM
	.comm	_RDP_FPU_READWRITE_MASK_FPS,4,2 ## @RDP_FPU_READWRITE_MASK_FPS
	.comm	_ARM_F0_REGNUM,4,2              ## @ARM_F0_REGNUM
	.comm	_ARM_F7_REGNUM,4,2              ## @ARM_F7_REGNUM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Help me with fetch reg %d\n"

	.no_dead_strip	_remote_rdp_fetch_register
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function remote_rdp_fetch_register
_remote_rdp_fetch_register:             ; @remote_rdp_fetch_register
	.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
	sub	sp, sp, #16
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
	cmn	w0, #1
	b.eq	LBB0_3
; %bb.1:
	mov	x19, x0
	mov	x21, sp
Lloh3:
	adrp	x8, _MAX_REGISTER_SIZE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_REGISTER_SIZE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x1fffffff0
	sub	x20, x9, x8
	mov	sp, x20
	cmp	w0, #14
	b.gt	LBB0_6
; %bb.2:
	mov	w8, #1
	lsl	w0, w8, w19
	b	LBB0_11
LBB0_3:
Lloh8:
	adrp	x20, _NUM_REGS@GOTPAGE
Lloh9:
	ldr	x20, [x20, _NUM_REGS@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_13
; %bb.4:
	mov	w19, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_remote_rdp_fetch_register
	add	w19, w19, #1
	ldr	w8, [x20]
	cmp	w19, w8
	b.lt	LBB0_5
	b	LBB0_13
LBB0_6:
Lloh10:
	adrp	x8, _ARM_PC_REGNUM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ARM_PC_REGNUM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ne	LBB0_8
; %bb.7:
Lloh13:
	adrp	x8, _RDP_CPU_READWRITE_MASK_PC@GOTPAGE
Lloh14:
	ldr	x8, [x8, _RDP_CPU_READWRITE_MASK_PC@GOTPAGEOFF]
	b	LBB0_10
LBB0_8:
Lloh15:
	adrp	x8, _ARM_PS_REGNUM@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ARM_PS_REGNUM@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ne	LBB0_15
; %bb.9:
Lloh18:
	adrp	x8, _RDP_CPU_READWRITE_MASK_CPSR@GOTPAGE
Lloh19:
	ldr	x8, [x8, _RDP_CPU_READWRITE_MASK_CPSR@GOTPAGEOFF]
LBB0_10:
	ldr	w0, [x8]
LBB0_11:
	mov	x1, x20
	bl	_rdp_fetch_one_register
LBB0_12:
	mov	x0, x19
	mov	x1, x20
	bl	_supply_register
	mov	sp, x21
LBB0_13:
	ldur	x8, [x29, #-40]
Lloh20:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh21:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.14:
	sub	sp, x29, #32
	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
LBB0_15:
Lloh23:
	adrp	x8, _ARM_FPS_REGNUM@GOTPAGE
Lloh24:
	ldr	x8, [x8, _ARM_FPS_REGNUM@GOTPAGEOFF]
Lloh25:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ne	LBB0_17
; %bb.16:
Lloh26:
	adrp	x8, _RDP_FPU_READWRITE_MASK_FPS@GOTPAGE
Lloh27:
	ldr	x8, [x8, _RDP_FPU_READWRITE_MASK_FPS@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
	b	LBB0_20
LBB0_17:
Lloh29:
	adrp	x8, _ARM_F0_REGNUM@GOTPAGE
Lloh30:
	ldr	x8, [x8, _ARM_F0_REGNUM@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
Lloh32:
	adrp	x9, _ARM_F7_REGNUM@GOTPAGE
Lloh33:
	ldr	x9, [x9, _ARM_F7_REGNUM@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x9]
	cmp	w8, w19
	ccmp	w9, w19, #8, le
	b.ge	LBB0_19
; %bb.18:
Lloh35:
	adrp	x0, l_.str@PAGE
Lloh36:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_printf
	b	LBB0_12
LBB0_19:
	sub	w8, w19, w8
	mov	w9, #1
	lsl	w0, w9, w8
LBB0_20:
	mov	x1, x20
	bl	_rdp_fetch_one_fpu_register
	b	LBB0_12
LBB0_21:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpAdd	Lloh35, Lloh36
	.cfi_endproc
                                        ; -- End function
	.comm	_NUM_REGS,4,2                   ; @NUM_REGS
	.comm	_MAX_REGISTER_SIZE,4,2          ; @MAX_REGISTER_SIZE
	.comm	_ARM_PC_REGNUM,4,2              ; @ARM_PC_REGNUM
	.comm	_RDP_CPU_READWRITE_MASK_PC,4,2  ; @RDP_CPU_READWRITE_MASK_PC
	.comm	_ARM_PS_REGNUM,4,2              ; @ARM_PS_REGNUM
	.comm	_RDP_CPU_READWRITE_MASK_CPSR,4,2 ; @RDP_CPU_READWRITE_MASK_CPSR
	.comm	_ARM_FPS_REGNUM,4,2             ; @ARM_FPS_REGNUM
	.comm	_RDP_FPU_READWRITE_MASK_FPS,4,2 ; @RDP_FPU_READWRITE_MASK_FPS
	.comm	_ARM_F0_REGNUM,4,2              ; @ARM_F0_REGNUM
	.comm	_ARM_F7_REGNUM,4,2              ; @ARM_F7_REGNUM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Help me with fetch reg %d\n"

	.no_dead_strip	_remote_rdp_fetch_register
.subsections_via_symbols
