	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function arm_rdi_store_registers
_arm_rdi_store_registers:               ## @arm_rdi_store_registers
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	cmpl	$-1, %edi
	je	LBB0_1
## %bb.4:
	movl	%edi, %ebx
	leaq	-48(%rbp), %rsi
	callq	_deprecated_read_register_gen
	movq	-48(%rbp), %rdx
	leaq	-80(%rbp), %rdi
	movl	$4, %esi
	callq	_store_unsigned_integer
	movq	_ARM_PC_REGNUM@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jne	LBB0_6
## %bb.5:
	movq	_RDIReg_PC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	jmp	LBB0_10
LBB0_1:
	movq	_NUM_REGS@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_12
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %edi
	callq	_arm_rdi_store_registers
	incl	%ebx
	cmpl	(%r14), %ebx
	jl	LBB0_3
	jmp	LBB0_12
LBB0_6:
	movq	_ARM_PS_REGNUM@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jne	LBB0_8
## %bb.7:
	movq	_RDIReg_CPSR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	jmp	LBB0_10
LBB0_8:
	cmpl	$15, %ebx
	ja	LBB0_12
## %bb.9:
	movl	$1, %esi
	movl	%ebx, %ecx
	shll	%cl, %esi
LBB0_10:
	leaq	-80(%rbp), %rdx
	movl	$255, %edi
	callq	_angel_RDI_CPUwrite
	movq	_RDIError_NoError@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_12
## %bb.11:
	movl	%eax, %edi
	callq	_rdi_error_message
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_printf_filtered
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-24(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	addq	$64, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_NUM_REGS,4,2                   ## @NUM_REGS
	.comm	_ARM_PC_REGNUM,4,2              ## @ARM_PC_REGNUM
	.comm	_RDIReg_PC,4,2                  ## @RDIReg_PC
	.comm	_ARM_PS_REGNUM,4,2              ## @ARM_PS_REGNUM
	.comm	_RDIReg_CPSR,4,2                ## @RDIReg_CPSR
	.comm	_RDIError_NoError,4,2           ## @RDIError_NoError
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"RDI_CPUwrite: %s\n"

	.no_dead_strip	_arm_rdi_store_registers
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function arm_rdi_store_registers
_arm_rdi_store_registers:               ; @arm_rdi_store_registers
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-24]
	cmn	w0, #1
	b.eq	LBB0_3
; %bb.1:
	mov	x19, x0
	add	x1, sp, #32
	bl	_deprecated_read_register_gen
	ldr	x2, [sp, #32]
	add	x0, sp, #8
	mov	w1, #4
	bl	_store_unsigned_integer
Lloh3:
	adrp	x8, _ARM_PC_REGNUM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ARM_PC_REGNUM@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ne	LBB0_6
; %bb.2:
Lloh6:
	adrp	x8, _RDIReg_PC@GOTPAGE
Lloh7:
	ldr	x8, [x8, _RDIReg_PC@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	b	LBB0_10
LBB0_3:
Lloh9:
	adrp	x20, _NUM_REGS@GOTPAGE
Lloh10:
	ldr	x20, [x20, _NUM_REGS@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.4:
	mov	w19, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_arm_rdi_store_registers
	add	w19, w19, #1
	ldr	w8, [x20]
	cmp	w19, w8
	b.lt	LBB0_5
	b	LBB0_12
LBB0_6:
Lloh11:
	adrp	x8, _ARM_PS_REGNUM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ARM_PS_REGNUM@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ne	LBB0_8
; %bb.7:
Lloh14:
	adrp	x8, _RDIReg_CPSR@GOTPAGE
Lloh15:
	ldr	x8, [x8, _RDIReg_CPSR@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	b	LBB0_10
LBB0_8:
	cmp	w19, #15
	b.hi	LBB0_12
; %bb.9:
	mov	w8, #1
	lsl	w1, w8, w19
LBB0_10:
	add	x2, sp, #8
	mov	w0, #255
	bl	_angel_RDI_CPUwrite
Lloh17:
	adrp	x8, _RDIError_NoError@GOTPAGE
Lloh18:
	ldr	x8, [x8, _RDIError_NoError@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	cmp	w0, w8
	b.eq	LBB0_12
; %bb.11:
	bl	_rdi_error_message
	mov	x1, x0
Lloh20:
	adrp	x0, l_.str@PAGE
Lloh21:
	add	x0, x0, l_.str@PAGEOFF
	bl	_printf_filtered
LBB0_12:
	ldur	x8, [x29, #-24]
Lloh22:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh23:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.13:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_NUM_REGS,4,2                   ; @NUM_REGS
	.comm	_ARM_PC_REGNUM,4,2              ; @ARM_PC_REGNUM
	.comm	_RDIReg_PC,4,2                  ; @RDIReg_PC
	.comm	_ARM_PS_REGNUM,4,2              ; @ARM_PS_REGNUM
	.comm	_RDIReg_CPSR,4,2                ; @RDIReg_CPSR
	.comm	_RDIError_NoError,4,2           ; @RDIError_NoError
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"RDI_CPUwrite: %s\n"

	.no_dead_strip	_arm_rdi_store_registers
.subsections_via_symbols
